From 50d954433086ac43c7ab3bc048d3f53df8af5858 Mon Sep 17 00:00:00 2001 From: Herb Lewis Date: Sat, 22 Dec 2001 00:54:10 +0000 Subject: sync up packaging scripts (This used to be commit 3999e13ef89acd51df4cf215959eccd6217c86e3) --- packaging/SGI/idb.pl | 41 +++++++++++++++++++++++++++-------------- packaging/SGI/mkrelease.sh | 33 ++++++++++++++++++++++----------- 2 files changed, 49 insertions(+), 25 deletions(-) diff --git a/packaging/SGI/idb.pl b/packaging/SGI/idb.pl index 66cb3fa558..8858702b9f 100755 --- a/packaging/SGI/idb.pl +++ b/packaging/SGI/idb.pl @@ -112,7 +112,12 @@ chdir $curdir; # add my local files to the list of binaries to install @bins = sort byfilename (@sprogs,@progs,@progs1,@progs2,@mprogs,@scripts,@winbind_progs,@winbind_sprogs,("/findsmb","/sambalp","/smbprint")); -@nsswitch = sort byfilename (@winbind_lprogs,@winbind_pam_progs); + +# add libnss_wins.so if it was built +if (-e "$SRCDIR/source/nsswitch/libnss_wins.so") { + $libns_wins = "nsswitch/libnss_wins.so"; +} +@nsswitch = sort byfilename (@winbind_lprogs,@winbind_pam_progs,$libns_wins); # get a complete list of all files in the tree chdir "$SRCDIR/"; @@ -131,7 +136,7 @@ chdir $curdir; # strip out all the generated directories and the "*.o" files from the source # release -@allfiles = grep(!/^.*\.o$/ & !/^.*\.po$/ & !/^.*\.po32$/ & !/^source\/bin/ & !/^packaging\/SGI\/bins/ & !/^packaging\/SGI\/catman/ & !/^packaging\/SGI\/html/ & !/^packaging\/SGI\/codepages/ & !/^packaging\/SGI\/swat/, @allfiles); +@allfiles = grep(!/^.*\.o$/ & !/^.*\.po$/ & !/^.*\.po32$/ & !/^.*\.so$/ & !/^source\/bin/ & !/^packaging\/SGI\/bins/ & !/^packaging\/SGI\/catman/ & !/^packaging\/SGI\/html/ & !/^packaging\/SGI\/codepages/ & !/^packaging\/SGI\/swat/, @allfiles); open(IDB,"> $curdir/$PKG.idb") || die "Unable to open $PKG.idb for output\n"; @@ -180,12 +185,18 @@ while(@bins) { } elsif ($filename eq "smbd") { print IDB "f 0755 root sys usr/samba/bin/$filename $SRCPFX/source/$nextfile $PKG.sw.base \n"; - print IDB "f 0755 root sys usr/samba/bin/$filename.noquota $SRCPFX/source/$nextfile.noquota $PKG.sw.base \n"; - print IDB "f 0755 root sys usr/samba/bin/$filename.profile $SRCPFX/source/$nextfile.profile $PKG.sw.base \n"; + if (-e "$SRCDIR/source/$nextfile.noquota") { + print IDB "f 0755 root sys usr/samba/bin/$filename.noquota $SRCPFX/source/$nextfile.noquota $PKG.sw.base \n"; + } + if (-e "$SRCDIR/source/$nextfile.profile") { + print IDB "f 0755 root sys usr/samba/bin/$filename.profile $SRCPFX/source/$nextfile.profile $PKG.sw.base \n"; + } } elsif ($filename eq "nmbd") { print IDB "f 0755 root sys usr/samba/bin/$filename $SRCPFX/source/$nextfile $PKG.sw.base \n"; - print IDB "f 0755 root sys usr/samba/bin/$filename.profile $SRCPFX/source/$nextfile.profile $PKG.sw.base \n"; + if (-e "$SRCDIR/source/$nextfile.profile") { + print IDB "f 0755 root sys usr/samba/bin/$filename.profile $SRCPFX/source/$nextfile.profile $PKG.sw.base \n"; + } } else { print IDB "f 0755 root sys usr/samba/bin/$filename $SRCPFX/source/$nextfile $PKG.sw.base \n"; @@ -216,15 +227,6 @@ while (@codepage) { } print IDB "f 0644 root sys usr/samba/lib/smb.conf $SRCPFX/packaging/SGI/smb.conf $PKG.sw.base config(suggest)\n"; -if (@nsswitch) { - print IDB "d 0644 root sys usr/samba/nsswitch $SRCPFX/packaging/SGI $PKG.sw.base\n"; - while(@nsswitch) { - $nextfile = shift @nsswitch; - ($filename = $nextfile) =~ s/^.*\///;; - print IDB "f 0755 root sys usr/samba/nsswitch/$filename $SRCPFX/source/$nextfile $PKG.sw.base \n"; - } -} - print IDB "d 0755 lp sys usr/samba/printer $SRCPFX/packaging/SGI $PKG.sw.base\n"; print IDB "d 0755 lp sys usr/samba/printer/W32ALPHA $SRCPFX/packaging/SGI $PKG.sw.base\n"; print IDB "d 0755 lp sys usr/samba/printer/W32MIPS $SRCPFX/packaging/SGI $PKG.sw.base\n"; @@ -301,6 +303,17 @@ while (@catman) { } print IDB "f 0664 root sys usr/share/catman/u_man/cat$dirnum/$file $SRCPFX/$nextfile $PKG.man.manpages\n"; } + +if (@nsswitch) { + print IDB "d 0755 root sys var/ns/lib $SRCPFX/packaging/SGI $PKG.sw.base\n"; + while(@nsswitch) { + $nextfile = shift @nsswitch; + ($filename = $nextfile) =~ s/^.*\///; + $filename =~ s/libnss/libns/; + print IDB "f 0644 root sys var/ns/lib/$filename $SRCPFX/source/$nextfile $PKG.sw.base \n"; + } +} + print IDB "d 01777 lp sys var/spool/samba $SRCPFX/packaging/SGI $PKG.sw.base\n"; close IDB; diff --git a/packaging/SGI/mkrelease.sh b/packaging/SGI/mkrelease.sh index a85a64569b..7412a02d4f 100755 --- a/packaging/SGI/mkrelease.sh +++ b/packaging/SGI/mkrelease.sh @@ -7,8 +7,8 @@ # You can specify clean to do a make clean before building. Make clean # will also run configure and generate the required Makefile. # -# You can specify which targets to build. If targets are specified, the -# specified targets will be built but inst packages will not be generated. +# This will build an smbd.noquota, smbd.profile, nmbd.profile and the +# entire package with quota support and acl support. doclean="" SGI_ABI=-n32 @@ -31,6 +31,7 @@ if [ "$doclean" = "clean" ]; then if [ -f Makefile ]; then make distclean fi + rm -rf bin/*.profile bin/*.noquota cd ../packaging/SGI rm -rf bins catman html codepages swat samba.idb samba.spec fi @@ -50,7 +51,7 @@ fi cd ../../source if [ "$doclean" = "clean" ]; then echo Create SGI specific Makefile - ./configure --prefix=/usr/samba --sbindir='${exec_prefix}/bin' --mandir=/usr/share/catman --with-acl-support + ./configure --prefix=/usr/samba --sbindir=/usr/samba/bin --mandir=/usr/share/catman --with-acl-support --with-quotas --with-smbwrapper errstat=$? if [ $errstat -ne 0 ]; then echo "Error $errstat creating Makefile\n"; @@ -63,6 +64,7 @@ fi # echo Making binaries +echo "===================== Making Profile versions =======================" make clean make headers make -P "CFLAGS=-O -g3 -D WITH_PROFILE" bin/smbd bin/nmbd @@ -74,7 +76,9 @@ fi mv bin/smbd bin/smbd.profile mv bin/nmbd bin/nmbd.profile +echo "===================== Making No Quota versions =======================" make clean +make headers make -P "CFLAGS=-O -g3 -D QUOTAOBJS=smbd/noquotas.o" bin/smbd errstat=$? if [ $errstat -ne 0 ]; then @@ -83,7 +87,21 @@ if [ $errstat -ne 0 ]; then fi mv bin/smbd bin/smbd.noquota -make -P "CFLAGS=-O -g3" all +echo "===================== Making smbwrapper.32.so =======================" +# cannot use -mips3 with 32 bit shared libraries so reset the ISA variable +# just for this object +ISA= +export ISA +make -P "CFLAGS=-O -g3" bin/smbwrapper.32.so +errstat=$? +if [ $errstat -ne 0 ]; then + echo "Error $errstat building sources\n"; + exit $errstat; +fi +ISA=-mips3 +export ISA +echo "===================== Making Regular versions =======================" +make -P "CFLAGS=-O -g3" all nsswitch/libnss_wins.so errstat=$? if [ $errstat -ne 0 ]; then echo "Error $errstat building sources\n"; @@ -92,13 +110,6 @@ fi cd ../packaging/SGI -# -# Don't generate packages if targets were specified -# -if [ "$1" != "" ]; then - exit 0; -fi - # generate the packages # echo Generating Inst Packages -- cgit