From e0a0b0a0cb3db426d05b641e1fa43d9e7f28ab71 Mon Sep 17 00:00:00 2001 From: Michael Adam Date: Thu, 18 Sep 2008 05:02:14 +0200 Subject: [PATCH] packaging(RHEL-CTDB): adapt configure.rpm to changes to the spec file Michael (cherry picked from commit d249a9ca2a1761f20655cbcfe39fbc942547974d) Signed-off-by: Michael Adam --- packaging/RHEL-CTDB/configure.rpm | 66 ++++++++++++++++++++----------- 1 file changed, 44 insertions(+), 22 deletions(-) diff --git a/packaging/RHEL-CTDB/configure.rpm b/packaging/RHEL-CTDB/configure.rpm index 75960402053..444d3e2a8c8 100755 --- a/packaging/RHEL-CTDB/configure.rpm +++ b/packaging/RHEL-CTDB/configure.rpm @@ -1,34 +1,53 @@ +#!/bin/sh case `uname -m` in - x86_64) - libdir=/usr/lib64/samba - ;; - *) - libdir=/usr/lib/samba - ;; + x86_64) + _libarch=lib64 + ;; + *) + _libarch=lib + ;; esac -CFLAGS="-Wall -g -D_GNU_SOURCE" ./configure \ - --prefix=/usr \ - --localstatedir=/var \ - --with-configdir=/etc/samba \ - --with-libdir=$libdir \ - --with-lockdir=/var/lib/samba \ - --with-logfilebase=/var/log/samba \ - --with-mandir=/usr/man \ - --with-piddir=/var/run \ - --with-privatedir=/etc/samba \ - --with-sambabook=/usr/share/swat/using_samba \ - --with-swatdir=/usr/share/swat \ +_libarchdir=/usr/${_libarch} + +_prefix=/usr +_sysconfdir=/etc +_mandir=/usr/man +_datadir=/usr/share + +# check for ccache +ccache -h 2>&1 > /dev/null +if [ $? -eq 0 ]; then + CC="ccache gcc" +else + CC="gcc" +fi + +./autogen.sh + +CC="$CC" CFLAGS="-Wall -g -D_GNU_SOURCE" ./configure -C \ + --prefix=${_prefix} \ + --localstatedir=/var \ + --with-configdir=${_sysconfdir}/samba \ + --with-libdir=${_libarchdir}/samba \ + --with-pammodulesdir=/${_libarch}/security \ + --with-lockdir=/var/lib/samba \ + --with-logfilebase=/var/log/samba \ + --with-mandir=${_mandir} \ + --with-piddir=/var/run \ + --with-privatedir=${_sysconfdir}/samba \ + --with-sambabook=${_datadir}/swat/using_samba \ + --with-swatdir=${_datadir}/swat \ --disable-cups \ - --with-acl-support \ + --with-acl-support \ --with-ads \ - --with-automount \ - --with-fhs \ + --with-automount \ + --with-fhs \ --with-pam_smbpass \ --with-libsmbclient \ --with-libsmbsharemodes \ - --without-smbwrapper \ + --without-smbwrapper \ --with-pam \ --with-quotas \ --with-shared-modules=idmap_rid,idmap_ad,idmap_tdb2 \ @@ -40,3 +59,6 @@ CFLAGS="-Wall -g -D_GNU_SOURCE" ./configure \ --without-dnsupdate \ --with-aio-support \ $* + +make showlayout + -- 2.34.1