From: <smi...@us...> - 2003-12-29 19:39:19
|
Update of /cvsroot/devil-linux/build/scripts In directory sc8-pr-cvs1:/tmp/cvs-serv26093/scripts Modified Files: alsa-driver cipe e100 e1000 ebtables gcc hostap iANS iptables linux linux-wlan-ng loop-AES pcmcia-cs perl super-freeswan util-linux vsftpd Log Message: - enabled compilation of iptables with the GCC SSP - enabled compilation of kernel and all modules with the GCC Stack Smashing Protector - added workaround for lm_sensors 2.8.2 to be able to compile it under kernel 2.4.23 - compiled almost all executables as ET_DYN - added new functions to build system: disable_et_dyn () & enable_et_dyn () Index: alsa-driver =================================================================== RCS file: /cvsroot/devil-linux/build/scripts/alsa-driver,v retrieving revision 1.8 retrieving revision 1.9 diff -u -d -r1.8 -r1.9 --- alsa-driver 26 Dec 2003 23:57:53 -0000 1.8 +++ alsa-driver 29 Dec 2003 19:35:59 -0000 1.9 @@ -35,12 +35,8 @@ if [ "$CONFIG_ALSA" = "y" ]; then ./configure --with-isa-pnp=yes --with-oss=yes --with-sequencer=yes --with-cards=all --with-kernel=$KERNELDIR \ --with-moddir=$CDDIR/lib/modules/$KERNELVERSION/misc --sysconfdir=$ETCDIR || exit 1 - FLAGS="" - if [ "$CONFIG_GCC_STACK_PROTECTOR" = "y" ]; then - FLAGS="CFLAGS_KERNEL=-fno-stack-protector" - fi - make $PMAKE $FLAGS || exit 1 + make $PMAKE || exit 1 strip_debug fi ;; Index: cipe =================================================================== RCS file: /cvsroot/devil-linux/build/scripts/cipe,v retrieving revision 1.11 retrieving revision 1.12 diff -u -d -r1.11 -r1.12 --- cipe 13 Oct 2003 17:36:08 -0000 1.11 +++ cipe 29 Dec 2003 19:35:59 -0000 1.12 @@ -28,11 +28,6 @@ MYNAME=CIPE -FLAGS="gcc" -if [ "$CONFIG_GCC_STACK_PROTECTOR" = "y" ]; then - FLAGS="gcc -fno-stack-protector" -fi - case $1 in build ) if [ "$CONFIG_CIPE" = "y" ]; then @@ -43,7 +38,7 @@ # "This is pre-alpha stuff, much of it does not work as intended..." # - make $PMAKE "KCC=$FLAGS" || exit 1 + make $PMAKE || exit 1 strip_debug fi ;; Index: e100 =================================================================== RCS file: /cvsroot/devil-linux/build/scripts/e100,v retrieving revision 1.9 retrieving revision 1.10 diff -u -d -r1.9 -r1.10 --- e100 13 Oct 2003 17:36:08 -0000 1.9 +++ e100 29 Dec 2003 19:35:59 -0000 1.10 @@ -28,12 +28,7 @@ case $1 in build ) - FLAGS="" - if [ "$CONFIG_GCC_STACK_PROTECTOR" = "y" ]; then - FLAGS="CFLAGS_EXTRA=-fno-stack-protector" - fi - - make $PMAKE -C src KSRC=$KERNELDIR CC=gcc $FLAGS || exit 1 + make $PMAKE -C src KSRC=$KERNELDIR CC=gcc || exit 1 strip_debug ;; Index: e1000 =================================================================== RCS file: /cvsroot/devil-linux/build/scripts/e1000,v retrieving revision 1.9 retrieving revision 1.10 diff -u -d -r1.9 -r1.10 --- e1000 13 Oct 2003 17:36:08 -0000 1.9 +++ e1000 29 Dec 2003 19:35:59 -0000 1.10 @@ -28,12 +28,7 @@ case $1 in build ) - FLAGS="" - if [ "$CONFIG_GCC_STACK_PROTECTOR" = "y" ]; then - FLAGS="CFLAGS_EXTRA=-fno-stack-protector" - fi - - make $PMAKE -C src KSRC=$KERNELDIR CC=gcc $FLAGS || exit 1 + make $PMAKE -C src KSRC=$KERNELDIR CC=gcc || exit 1 strip_debug ;; Index: ebtables =================================================================== RCS file: /cvsroot/devil-linux/build/scripts/ebtables,v retrieving revision 1.3 retrieving revision 1.4 diff -u -d -r1.3 -r1.4 --- ebtables 17 Dec 2003 14:55:47 -0000 1.3 +++ ebtables 29 Dec 2003 19:35:59 -0000 1.4 @@ -41,11 +41,8 @@ done echo "CONFIG_IP_NF_MATCH_PHYSDEV=m" >> $KERNELDIR/.config - FLAGS="-Wall -Wunused" - if [ "$CONFIG_GCC_STACK_PROTECTOR" = "y" ]; then - FLAGS="$FLAGS -fno-stack-protector" - fi - make MANDIR=/usr/share/man CFLAGS="$FLAGS" $PMAKE all|| exit 1 + + make MANDIR=/usr/share/man $PMAKE all|| exit 1 strip_debug fi ;; Index: gcc =================================================================== RCS file: /cvsroot/devil-linux/build/scripts/gcc,v retrieving revision 1.14 retrieving revision 1.15 diff -u -d -r1.14 -r1.15 --- gcc 28 Dec 2003 01:48:37 -0000 1.14 +++ gcc 29 Dec 2003 19:35:59 -0000 1.15 @@ -25,6 +25,8 @@ MYNAME=GCC3 +KERNELDIR=$(find_src_dir linux) + case $1 in build ) if [ "$CONFIG_GCC_STACK_PROTECTOR" = "y" ]; then @@ -35,6 +37,12 @@ patch -p1 -i $WORKDIR/protectonly.dif || exit 1 cd .. touch ./.done_patch_protector + + if [ ! -f devil-linux-kernel-protector-patche.done ]; then + touch devil-linux-kernel-protector-patche.done + bzcat $DL_DIR/src/linux-2.4.23-protector-1.patch.bz2 | patch -p1 -d $KERNELDIR || exit 1 + fi + fi fi @@ -61,7 +69,7 @@ # install it, so we use the same version everywhere make install-no-fixedincludes || exit 1 - + if [ "$CONFIG_GCC_ET_DYN" = "y" ]; then pushd $(find_src_dir et_dyn) > /dev/null cd linux || exit 1 @@ -71,6 +79,7 @@ make || exit 1 GCCSPECDIR=$(dirname $(gcc --print-libgcc-file-name)) cp crt1S.o $GCCSPECDIR || exit 1 + ln -sf crt1S.o $GCCSPECDIR/Scrt1.o || exit 1 popd > /dev/null GCCVER=${GCCSPECDIR##*/} test ! -f $GCCSPECDIR/specs.orig && cp $GCCSPECDIR/specs $GCCSPECDIR/specs.orig Index: hostap =================================================================== RCS file: /cvsroot/devil-linux/build/scripts/hostap,v retrieving revision 1.10 retrieving revision 1.11 diff -u -d -r1.10 -r1.11 --- hostap 13 Oct 2003 17:36:08 -0000 1.10 +++ hostap 29 Dec 2003 19:35:59 -0000 1.11 @@ -35,17 +35,11 @@ case $1 in build ) if [ "$CONFIG_HOSTAP" = "y" ]; then - - FLAGS="CC=gcc" - if [ "$CONFIG_GCC_STACK_PROTECTOR" = "y" ]; then - FLAGS="CC=gcc -fno-stack-protector" - fi - if [ "$CONFIG_PCMCIA_CS" = "y" ]; then - make "$FLAGS" pci plx pccard EXTRA_CFLAG="-DPRISM2_HOSTAPD -DCONFIG_HOSTAP_FIRMWARE" \ + make pci plx pccard EXTRA_CFLAG="-DPRISM2_HOSTAPD -DCONFIG_HOSTAP_FIRMWARE" \ -e KERNEL_PATH=$KERNELDIR PCMCIA_PATH=$PCMCIADIR || exit 1 else - make "$FLAGS" pci plx pccard EXTRA_CFLAG="-DPRISM2_HOSTAPD -DCONFIG_HOSTAP_FIRMWARE" \ + make pci plx pccard EXTRA_CFLAG="-DPRISM2_HOSTAPD -DCONFIG_HOSTAP_FIRMWARE" \ -e KERNEL_PATH=$KERNELDIR || exit 1 fi cd hostapd Index: iANS =================================================================== RCS file: /cvsroot/devil-linux/build/scripts/iANS,v retrieving revision 1.13 retrieving revision 1.14 diff -u -d -r1.13 -r1.14 --- iANS 13 Oct 2003 17:36:08 -0000 1.13 +++ iANS 29 Dec 2003 19:35:59 -0000 1.14 @@ -30,12 +30,7 @@ case $1 in build ) if [ "$CONFIG_IANS" = "y" ]; then - FLAGS="" - if [ "$CONFIG_GCC_STACK_PROTECTOR" = "y" ]; then - FLAGS="CFLAGS_EXTRA=-fno-stack-protector" - fi - - make $PMAKE -C src KSRC=$KERNELDIR CC=gcc $FLAGS || exit 1 + make $PMAKE -C src KSRC=$KERNELDIR CC=gcc || exit 1 strip_debug fi ;; Index: iptables =================================================================== RCS file: /cvsroot/devil-linux/build/scripts/iptables,v retrieving revision 1.22 retrieving revision 1.23 diff -u -d -r1.22 -r1.23 --- iptables 22 Nov 2003 01:12:40 -0000 1.22 +++ iptables 29 Dec 2003 19:35:59 -0000 1.23 @@ -28,13 +28,9 @@ case $1 in build ) - FLAGS="-O2" - if [ "$CONFIG_GCC_STACK_PROTECTOR" = "y" ]; then - FLAGS="-O2 -fno-stack-protector" - fi replace_str Makefile "/usr/local" "/usr" # parallel build failes, do not use $PMAKE - make all COPT_FLAGS="$FLAGS" KERNEL_DIR=$KERNELDIR || exit 1 + make all KERNEL_DIR=$KERNELDIR || exit 1 strip_debug # install it, so other programs can use it make install install-devel || exit 1 Index: linux =================================================================== RCS file: /cvsroot/devil-linux/build/scripts/linux,v retrieving revision 1.48 retrieving revision 1.49 diff -u -d -r1.48 -r1.49 --- linux 20 Dec 2003 18:05:56 -0000 1.48 +++ linux 29 Dec 2003 19:35:59 -0000 1.49 @@ -35,19 +35,14 @@ cat .config.add >> .config || exit 1 fi - FLAGS="" - if [ "$CONFIG_GCC_STACK_PROTECTOR" = "y" ]; then - FLAGS="CFLAGS_EXTRA=-fno-stack-protector" - fi - if [ "$CONFIG_LINUX_UPDATE_PWC" = "y" ]; then cp -vdpfR ../pwc-*/2.4.*/* drivers/usb/ || exit 1 fi - make $FLAGS oldconfig - make $FLAGS dep || exit 1 - make $FLAGS $PMAKE bzImage || exit 1 - make $FLAGS $PMAKE modules || exit 1 + make oldconfig + make dep || exit 1 + make $PMAKE bzImage || exit 1 + make $PMAKE modules || exit 1 ;; install ) Index: linux-wlan-ng =================================================================== RCS file: /cvsroot/devil-linux/build/scripts/linux-wlan-ng,v retrieving revision 1.11 retrieving revision 1.12 diff -u -d -r1.11 -r1.12 --- linux-wlan-ng 13 Oct 2003 17:36:08 -0000 1.11 +++ linux-wlan-ng 29 Dec 2003 19:35:59 -0000 1.12 @@ -44,11 +44,6 @@ make default_config || exit 1 - if [ "$CONFIG_GCC_STACK_PROTECTOR" = "y" ]; then - echo "KERNEL_CFLAGS += -fno-stack-protector" >> config.mk - #echo 'CFLAGS = $(CFLAGS) -fno-stack-protector' >> config.mk - fi - make $PMAKE all || exit 1 make -C add-ons/keygen || exit 1 strip_debug Index: loop-AES =================================================================== RCS file: /cvsroot/devil-linux/build/scripts/loop-AES,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- loop-AES 18 Dec 2003 00:35:18 -0000 1.2 +++ loop-AES 29 Dec 2003 19:35:59 -0000 1.3 @@ -26,11 +26,7 @@ case $1 in build ) - FLAGS="" - if [ "$CONFIG_GCC_STACK_PROTECTOR" = "y" ]; then - FLAGS="CFLAGS_EXTRA=-fno-stack-protector" - fi - make $FLAGS LINUX_SOURCE=$KERNELDIR INSTALL_MOD_PATH=$(pwd) + make LINUX_SOURCE=$KERNELDIR INSTALL_MOD_PATH=$(pwd) ;; install ) Index: pcmcia-cs =================================================================== RCS file: /cvsroot/devil-linux/build/scripts/pcmcia-cs,v retrieving revision 1.11 retrieving revision 1.12 diff -u -d -r1.11 -r1.12 --- pcmcia-cs 17 Dec 2003 14:55:47 -0000 1.11 +++ pcmcia-cs 29 Dec 2003 19:35:59 -0000 1.12 @@ -31,9 +31,6 @@ build ) if [ "$CONFIG_PCMCIA_CS" = "y" ]; then ./Configure --kernel=$KERNELDIR --noprompt --notrust --cardbus --pnp --apm --nox11 --srctree --sysv --nox11 --rcdir=/etc/init.d || exit 1 - if [ "$CONFIG_GCC_STACK_PROTECTOR" = "y" ]; then - echo "CPPFLAGS += -fno-stack-protector" >> config.mk - fi echo "SYSV_INIT=y" >> ./config.out make $PMAKE all || exit 1 strip_debug Index: perl =================================================================== RCS file: /cvsroot/devil-linux/build/scripts/perl,v retrieving revision 1.26 retrieving revision 1.27 diff -u -d -r1.26 -r1.27 --- perl 26 Dec 2003 14:29:35 -0000 1.26 +++ perl 29 Dec 2003 19:35:59 -0000 1.27 @@ -61,6 +61,7 @@ make install || exit 1 rm -f /usr/share/man/man1/s2p.1 /usr/share/man/man1/psed.1 /usr/share/man/man1/c2ph.1 /usr/share/man/man1/pstruct.1 rm -f /usr/bin/perl /usr/bin/perl5.8.0 + rm -f /usr/bin/perl /usr/bin/perl5.8.2 rm -f /usr/bin/s2p /usr/bin/psed rm -f /usr/bin/pstruct /usr/bin/c2ph cp -vfdpR $WORKDIR/tmp/* /usr || exit 1 Index: super-freeswan =================================================================== RCS file: /cvsroot/devil-linux/build/scripts/super-freeswan,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- super-freeswan 17 Dec 2003 14:55:47 -0000 1.1 +++ super-freeswan 29 Dec 2003 19:35:59 -0000 1.2 @@ -57,13 +57,9 @@ KERNELSRC=$KERNELDIR # compile freeswan - FLAGS="" - if [ "$CONFIG_GCC_STACK_PROTECTOR" = "y" ]; then - FLAGS="CFLAGS_EXTRA=-fno-stack-protector" - fi # parallel build fails - do not use $PMAKE - make $FLAGS oldmod || exit 1 + make oldmod || exit 1 make programs || exit 1 strip_debug Index: util-linux =================================================================== RCS file: /cvsroot/devil-linux/build/scripts/util-linux,v retrieving revision 1.16 retrieving revision 1.17 diff -u -d -r1.16 -r1.17 --- util-linux 27 Dec 2003 22:00:48 -0000 1.16 +++ util-linux 29 Dec 2003 19:35:59 -0000 1.17 @@ -30,7 +30,11 @@ bzcat $SRCDIR/util-linux-2.12.diff.bz2 | patch -p1 || exit 1 ./configure || exit 1 replace_str defines.h "#define ENABLE_NLS" "" - make $PMAKE HAVE_SLN=yes ADD_RAW=yes DISABLE_NLS=yes || exit 1 + if [ "$CONFIG_GCC_ET_DYN" = "y" ]; then + make $PMAKE HAVE_SLN=yes ADD_RAW=yes DISABLE_NLS=yes LDFLAGS="-pie" || exit 1 + else + make $PMAKE HAVE_SLN=yes ADD_RAW=yes DISABLE_NLS=yes || exit 1 + fi strip_debug ;; Index: vsftpd =================================================================== RCS file: /cvsroot/devil-linux/build/scripts/vsftpd,v retrieving revision 1.8 retrieving revision 1.9 diff -u -d -r1.8 -r1.9 --- vsftpd 27 Dec 2003 20:34:25 -0000 1.8 +++ vsftpd 29 Dec 2003 19:35:59 -0000 1.9 @@ -29,8 +29,12 @@ case $1 in build ) if [ "$CONFIG_VSFTPD" = "y" ]; then - disable_et_dyn - make $PMAKE || exit 1 + disable_et_dyn + if [ "$CONFIG_GCC_ET_DYN" = "y" ]; then + make $PMAKE LINK="-Wl,-s,-pie" || exit 1 + else + make $PMAKE LINK="-Wl,-s" || exit 1 + fi strip_debug fi ;; |