diff options
author | kent <kent> | 2001-07-04 02:31:44 +0000 |
---|---|---|
committer | kent <kent> | 2001-07-04 02:31:44 +0000 |
commit | b032fd3dad693cb3fda877f7c1c06df2fa60fac0 (patch) | |
tree | c011ee7ae1df31554a97f629e171e0cdcaa6f1cc /lang/gcc-ssp | |
parent | 62d32372f33625e17ae9372deaaf65506fe07a1f (diff) | |
download | pkgsrc-b032fd3dad693cb3fda877f7c1c06df2fa60fac0.tar.gz |
-fstack-protector is enabled by default.
Build with `make bootstrap.'
Diffstat (limited to 'lang/gcc-ssp')
-rw-r--r-- | lang/gcc-ssp/Makefile | 9 | ||||
-rw-r--r-- | lang/gcc-ssp/files/gcc.mk | 4 |
2 files changed, 6 insertions, 7 deletions
diff --git a/lang/gcc-ssp/Makefile b/lang/gcc-ssp/Makefile index 671ad46d026..7e1c064a5fd 100644 --- a/lang/gcc-ssp/Makefile +++ b/lang/gcc-ssp/Makefile @@ -1,8 +1,8 @@ -# $NetBSD: Makefile,v 1.2 2001/06/30 16:16:11 kent Exp $ +# $NetBSD: Makefile,v 1.3 2001/07/04 02:31:44 kent Exp $ DISTNAME= gcc-2.95.2 GCC_VERSION= 2.95.2 -PKGNAME= gcc-ssp-2.95.2nb2 +PKGNAME= gcc-ssp-2.95.2nb3 PKGBASENAME= gcc-ssp CATEGORIES= lang security MASTER_SITES= ${MASTER_SITE_GNU:=gcc/} @@ -59,9 +59,7 @@ PLIST_SRC= ${PKGDIR}/PLIST.NetBSD-sparc PLIST_SRC+= ${PKGDIR}/PLIST .endif .else -.if (${CC} != gcc) ALL_TARGET= bootstrap -.endif GCC_PREFIX= ${LOCALBASE} PLIST_SRC= ${PKGDIR}/PLIST.SunOS MESSAGE= ${PKGDIR}/MESSAGE.SunOS @@ -77,6 +75,7 @@ post-patch: cd ${WRKDIR} && /usr/bin/tar zxf ${_DISTDIR}/${SSP_PATCH} ${CP} ${WRKDIR}/protector.c ${WRKDIR}/protector.h ${WRKDIR}/${DISTNAME}/gcc/ ${PATCH} -d ${WRKDIR}/${DISTNAME} --forward --quiet -E < ${WRKDIR}/protector.dif + ${PATCH} -d ${WRKDIR}/${DISTNAME} --forward --quiet -E < ${WRKDIR}/protectonly.dif .if (${OPSYS} != SunOS) post-build: @@ -86,7 +85,7 @@ post-build: -e 's#@@PREFIX@@#${PREFIX}#g' \ <$$FILE >${WRKDIR}/`basename $$FILE`; \ done - ${WRKSRC}/gcc/xgcc -B${WRKSRC}/gcc/ -O2 -fstack-protector -o ${WRKDIR}/buffer ${FILESDIR}/buffer.c + ${WRKSRC}/gcc/xgcc -B${WRKSRC}/gcc/ -O2 -o ${WRKDIR}/buffer ${FILESDIR}/buffer.c ulimit -c 0 && ${WRKDIR}/buffer abcdefghijklmnopqrstuvwxyz 2> ${WRKDIR}/output || true @if [ x"`cat ${WRKDIR}/output`" = "x: stack smashing attack in function main" ]; then \ echo "---- Stack protection succeeded."; \ diff --git a/lang/gcc-ssp/files/gcc.mk b/lang/gcc-ssp/files/gcc.mk index 8f674c8f85e..524d272f68b 100644 --- a/lang/gcc-ssp/files/gcc.mk +++ b/lang/gcc-ssp/files/gcc.mk @@ -1,8 +1,8 @@ # make configuration file for @@PKGBASENAME@@ -CC= @@PREFIX@@/@@PKGBASENAME@@/bin/cc -fstack-protector +CC= @@PREFIX@@/@@PKGBASENAME@@/bin/cc CPP= @@PREFIX@@/@@PKGBASENAME@@/bin/cpp -CXX= @@PREFIX@@/@@PKGBASENAME@@/bin/c++ -fstack-protector +CXX= @@PREFIX@@/@@PKGBASENAME@@/bin/c++ .if exists(/etc/mk.conf) .include "/etc/mk.conf" |