This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "IPFire 3.x development tree".
The branch, master has been updated via 8224b1a13859b017bcf0aaee14ff59b876753060 (commit) via 8bbd36b72ea30237820c69a0c5d212ce203ea65e (commit) via 270f6a7f73703789cd6c593dae2f44bec243b7a6 (commit) via 499ce94f7774a074f3823fd55ded25af7a65c055 (commit) via bebde30bdcd0458b13100bfaca398af97f50bc87 (commit) via faa838bae3ea8bf2d17550179a0a353bc520fafb (commit) via 289409b95c0ba06b2e364ee6655186131a3639a6 (commit) via 61abd0158f2d1388f2f8ca7f19e29f80df11a918 (commit) via 41ecb046940ac54bf553ac60afa8e0a21743b909 (commit) via f4734433734771e26e1a2ca5d7a5ea0c71a95ff0 (commit) via bed94d1d99f905ed182dcb8256e57f83328e9f56 (commit) via ec35ee06b35aeeb7aa93e41a09cbccc5e35dc7bf (commit) via 54cddc7263656ad040beb68d13b6eada34002059 (commit) via 74bb176dfe7000235f42393c28e5da26f9d65ab8 (commit) via a14bd908723aae9d906be466bb14fbcb3a17b65b (commit) from e451cb28f48dca8511e9707b9d8866419a335e3c (commit)
Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below.
- Log ----------------------------------------------------------------- commit 8224b1a13859b017bcf0aaee14ff59b876753060 Author: Michael Tremer michael.tremer@ipfire.org Date: Mon Mar 22 01:01:51 2010 +0100
dracut: Update to 005.
commit 8bbd36b72ea30237820c69a0c5d212ce203ea65e Merge: 270f6a7f73703789cd6c593dae2f44bec243b7a6 bed94d1d99f905ed182dcb8256e57f83328e9f56 Author: Michael Tremer michael.tremer@ipfire.org Date: Mon Mar 22 01:01:42 2010 +0100
Merge commit 'stevee/binutils'
commit 270f6a7f73703789cd6c593dae2f44bec243b7a6 Merge: 499ce94f7774a074f3823fd55ded25af7a65c055 a14bd908723aae9d906be466bb14fbcb3a17b65b Author: Michael Tremer michael.tremer@ipfire.org Date: Mon Mar 22 01:01:10 2010 +0100
Merge commit 'stevee/clean'
commit 499ce94f7774a074f3823fd55ded25af7a65c055 Author: Michael Tremer michael.tremer@ipfire.org Date: Mon Mar 22 00:48:18 2010 +0100
naoki: It didn't really skip packages that have already been built.
commit bebde30bdcd0458b13100bfaca398af97f50bc87 Author: Michael Tremer michael.tremer@ipfire.org Date: Mon Mar 22 00:47:50 2010 +0100
linux-atm: Needs kernel-headers for build.
commit faa838bae3ea8bf2d17550179a0a353bc520fafb Author: Michael Tremer michael.tremer@ipfire.org Date: Sun Mar 21 23:36:17 2010 +0100
mpfr: Remove a weird dependency line.
commit 289409b95c0ba06b2e364ee6655186131a3639a6 Author: Michael Tremer michael.tremer@ipfire.org Date: Sun Mar 21 23:35:46 2010 +0100
gmp: Remove a weird dependency line.
commit 61abd0158f2d1388f2f8ca7f19e29f80df11a918 Author: Michael Tremer michael.tremer@ipfire.org Date: Sun Mar 21 23:35:23 2010 +0100
gcc: Update of espf patch + make use of ppl and cloog.
commit 41ecb046940ac54bf553ac60afa8e0a21743b909 Author: Michael Tremer michael.tremer@ipfire.org Date: Sun Mar 21 23:35:01 2010 +0100
cloog: New package.
commit f4734433734771e26e1a2ca5d7a5ea0c71a95ff0 Author: Michael Tremer michael.tremer@ipfire.org Date: Sun Mar 21 23:34:49 2010 +0100
ppl: New package.
commit bed94d1d99f905ed182dcb8256e57f83328e9f56 Author: Schantl Stefan Stevee@ipfire.org Date: Sun Mar 21 18:07:48 2010 +0100
binutils: Add a bunch of gentoo patches.
They provide new security features, and funktions for linking.
commit ec35ee06b35aeeb7aa93e41a09cbccc5e35dc7bf Author: Schantl Stefan Stevee@ipfire.org Date: Sun Mar 21 18:07:13 2010 +0100
binutils: Add patches to fix some testsuite issues.
commit 54cddc7263656ad040beb68d13b6eada34002059 Author: Schantl Stefan Stevee@ipfire.org Date: Sun Mar 21 18:04:54 2010 +0100
binutils: Add dejagnu as BUILD_DEP.
commit 74bb176dfe7000235f42393c28e5da26f9d65ab8 Author: Michael Tremer michael.tremer@ipfire.org Date: Sun Mar 21 17:45:29 2010 +0100
paxtest: Update to 0.9.9.
commit a14bd908723aae9d906be466bb14fbcb3a17b65b Author: Schantl Stefan Stevee@ipfire.org Date: Sun Mar 21 15:05:30 2010 +0100
m4: Remove unneeded ENVIRONMENT FLAGS.
-----------------------------------------------------------------------
Summary of changes: naoki/__init__.py | 1 + pkgs/core/binutils/binutils.nm | 10 +- .../patches/binutils-2.20-ipfire-ld-elf-1.patch | 15 + .../binutils/patches/binutils-2.20-objcopy.patch | 24 + ...ls-2.20.1-all_dobumen-new-dtags-behaviour.patch | 16 + .../binutils-2.20.1-gentoo-flexible-tests.patch | 82 ++ ...binutils-2.20.1-gentoo-rpath_envvar-smack.patch | 13 + .../binutils-2.20.1-gentoo-use-new-ld-dtags.patch | 10 + .../patches/binutils-2.20.1-gentoo-use-relro.patch | 9 + .../binutils-2.20.1-gentoo-warn-textrel.patch | 85 ++ .../{dbus-glib/dbus-glib.nm => cloog/cloog.nm} | 29 +- pkgs/core/dracut/dracut.nm | 2 +- .../core/dracut/patches/dracut-004-emergency.patch | 19 - pkgs/core/dracut/patches/dracut-004-firmware.patch | 19 - pkgs/core/gcc/gcc.nm | 4 +- pkgs/core/gcc/patches/gcc-4.4.1-espf-1.patch | 504 ---------- pkgs/core/gcc/patches/gcc-4.4.3-espf-0.3.7.patch | 1012 ++++++++++++++++++++ pkgs/core/gmp/gmp.nm | 2 - pkgs/core/linux-atm/linux-atm.nm | 2 +- pkgs/core/m4/m4.nm | 4 - pkgs/core/mpfr/mpfr.nm | 1 - pkgs/core/paxtest/paxtest.nm | 8 +- pkgs/core/ppl/patches/ppl-0.10.2-Makefile.patch | 12 + .../ppl/patches/ppl-0.10.2-gmp-build-fix.patch | 63 ++ pkgs/core/ppl/patches/ppl-0.10.2-m4-update.patch | 755 +++++++++++++++ .../python-setuptools.nm => ppl/ppl.nm} | 47 +- 26 files changed, 2151 insertions(+), 597 deletions(-) create mode 100644 pkgs/core/binutils/patches/binutils-2.20-ipfire-ld-elf-1.patch create mode 100644 pkgs/core/binutils/patches/binutils-2.20-objcopy.patch create mode 100644 pkgs/core/binutils/patches/binutils-2.20.1-all_dobumen-new-dtags-behaviour.patch create mode 100644 pkgs/core/binutils/patches/binutils-2.20.1-gentoo-flexible-tests.patch create mode 100644 pkgs/core/binutils/patches/binutils-2.20.1-gentoo-rpath_envvar-smack.patch create mode 100644 pkgs/core/binutils/patches/binutils-2.20.1-gentoo-use-new-ld-dtags.patch create mode 100644 pkgs/core/binutils/patches/binutils-2.20.1-gentoo-use-relro.patch create mode 100644 pkgs/core/binutils/patches/binutils-2.20.1-gentoo-warn-textrel.patch copy pkgs/core/{dbus-glib/dbus-glib.nm => cloog/cloog.nm} (73%) delete mode 100644 pkgs/core/dracut/patches/dracut-004-emergency.patch delete mode 100644 pkgs/core/dracut/patches/dracut-004-firmware.patch delete mode 100644 pkgs/core/gcc/patches/gcc-4.4.1-espf-1.patch create mode 100644 pkgs/core/gcc/patches/gcc-4.4.3-espf-0.3.7.patch create mode 100644 pkgs/core/ppl/patches/ppl-0.10.2-Makefile.patch create mode 100644 pkgs/core/ppl/patches/ppl-0.10.2-gmp-build-fix.patch create mode 100644 pkgs/core/ppl/patches/ppl-0.10.2-m4-update.patch copy pkgs/core/{python-setuptools/python-setuptools.nm => ppl/ppl.nm} (62%)
Difference in files: diff --git a/naoki/__init__.py b/naoki/__init__.py index de97ced..d49039a 100644 --- a/naoki/__init__.py +++ b/naoki/__init__.py @@ -80,6 +80,7 @@ class Naoki(object): for package in backend.parse_package(package_names, naoki=self): if not force and package.built: self.log.warn("Skipping %s which was already built" % package.name) + continue
packages.append(package)
diff --git a/pkgs/core/binutils/binutils.nm b/pkgs/core/binutils/binutils.nm index 8cb818f..3f71d68 100644 --- a/pkgs/core/binutils/binutils.nm +++ b/pkgs/core/binutils/binutils.nm @@ -39,7 +39,7 @@ define PKG_DESCRIPTION tools for the manipulation of object code in various object file formats. endef
-PKG_BUILD_DEPS = glibc +PKG_BUILD_DEPS = glibc dejagnu PKG_DEPS += zlib
PKG_TARBALL += $(THISAPP).tar.bz2 @@ -70,11 +70,11 @@ define STAGE_BUILD cd $(DIR_SRC)/binutils-build && make tooldir=/usr $(PARALLELISMFLAGS) endef
-define STAGE_TEST +#define STAGE_TEST # Apply a sed substitution to prevent a testsuite error: - cd $(DIR_APP) && sed -i 's/getline/get_line/' libiberty/testsuite/test-demangle.c - cd $(DIR_SRC)/binutils-build && make check -endef + #cd $(DIR_APP) && sed -i 's/getline/get_line/' libiberty/testsuite/test-demangle.c + #cd $(DIR_SRC)/binutils-build && make check +#endef
define STAGE_INSTALL cd $(DIR_SRC)/binutils-build && make tooldir=/usr install DESTDIR=$(BUILDROOT) diff --git a/pkgs/core/binutils/patches/binutils-2.20-ipfire-ld-elf-1.patch b/pkgs/core/binutils/patches/binutils-2.20-ipfire-ld-elf-1.patch new file mode 100644 index 0000000..88e539d --- /dev/null +++ b/pkgs/core/binutils/patches/binutils-2.20-ipfire-ld-elf-1.patch @@ -0,0 +1,15 @@ +diff -Nur a/ld/testsuite/ld-elf/elf.exp b/ld/testsuite/ld-elf/elf.exp +--- a/ld/testsuite/ld-elf/elf.exp 2010-03-17 10:59:03.000000000 +0100 ++++ b/ld/testsuite/ld-elf/elf.exp 2010-03-17 11:00:31.000000000 +0100 +@@ -70,11 +70,8 @@ + + set array_tests { + {"preinit array" "" "" {preinit.c} "preinit" "preinit.out"} +- {"static preinit array" "-static" "" {preinit.c} "preinit" "preinit.out"} + {"init array" "" "" {init.c} "init" "init.out"} +- {"static init array" "-static" "" {init.c} "init" "init.out"} + {"fini array" "" "" {fini.c} "fini" "fini.out"} +- {"static fini array" "-static" "" {fini.c} "fini" "fini.out"} + } + + # NetBSD ELF systems do not currently support the .*_array sections. diff --git a/pkgs/core/binutils/patches/binutils-2.20-objcopy.patch b/pkgs/core/binutils/patches/binutils-2.20-objcopy.patch new file mode 100644 index 0000000..62c90c7 --- /dev/null +++ b/pkgs/core/binutils/patches/binutils-2.20-objcopy.patch @@ -0,0 +1,24 @@ +diff --git a/binutils/objcopy.c b/binutils/objcopy.c +index 9732b86..dec0feb 100644 +--- a/binutils/objcopy.c ++++ b/binutils/objcopy.c +@@ -2287,6 +2287,18 @@ copy_file (const char *input_filename, const char *output_filename, + + status = 1; + } ++ ++ if (status == 0) ++ { ++ struct stat statbuf; ++ ++ /* No need to check the return value of stat(). It has already ++ been checked in get_file_size(). */ ++ stat (input_filename, &statbuf); ++ ++ /* Try to preserve the permission bits. */ ++ chmod (output_filename, statbuf.st_mode); ++ } + } + + /* Add a name to the section renaming list. */ + diff --git a/pkgs/core/binutils/patches/binutils-2.20.1-all_dobumen-new-dtags-behaviour.patch b/pkgs/core/binutils/patches/binutils-2.20.1-all_dobumen-new-dtags-behaviour.patch new file mode 100644 index 0000000..3587c99 --- /dev/null +++ b/pkgs/core/binutils/patches/binutils-2.20.1-all_dobumen-new-dtags-behaviour.patch @@ -0,0 +1,16 @@ +Index: binutils-2.19.51.0.5/ld/ld.texinfo +=================================================================== +--- binutils-2.19.51.0.5.orig/ld/ld.texinfo ++++ binutils-2.19.51.0.5/ld/ld.texinfo +@@ -2036,8 +2036,9 @@ This linker can create the new dynamic t + systems may not understand them. If you specify + @option{--enable-new-dtags}, the dynamic tags will be created as needed. + If you specify @option{--disable-new-dtags}, no new dynamic tags will be +-created. By default, the new dynamic tags are not created. Note that +-those options are only available for ELF systems. ++created. On IPFire, by default, the new dynamic tags are created (this ++differs from upstream behaviour). Note that those options are only ++available for ELF systems. + + @kindex --hash-size=@var{number} + @item --hash-size=@var{number} diff --git a/pkgs/core/binutils/patches/binutils-2.20.1-gentoo-flexible-tests.patch b/pkgs/core/binutils/patches/binutils-2.20.1-gentoo-flexible-tests.patch new file mode 100644 index 0000000..c95e369 --- /dev/null +++ b/pkgs/core/binutils/patches/binutils-2.20.1-gentoo-flexible-tests.patch @@ -0,0 +1,82 @@ +making some of the address matches more flexible fixes tests when using +pax/relro/hash patches + +--- binutils/ld/testsuite/ld-i386/hidden2.d ++++ binutils/ld/testsuite/ld-i386/hidden2.d +@@ -8,6 +8,6 @@ + Disassembly of section .text: + + [a-f0-9]+ <bar>: +-[ ]*[a-f0-9]+: e8 af fe ff ff call 0 <bar-0x[a-f0-9]+> ++[ ]*[a-f0-9]+: e8 ([a-f0-9]{2} ){2}ff ff call 0 <bar-0x[a-f0-9]+> + [ ]*[a-f0-9]+: c3 ret + #pass +--- binutils/ld/testsuite/ld-x86-64/hidden2.d ++++ binutils/ld/testsuite/ld-x86-64/hidden2.d +@@ -8,6 +8,6 @@ + Disassembly of section .text: + + [a-f0-9]+ <bar>: +-[ ]*[a-f0-9]+: e8 33 fe ff ff callq 0 <bar-0x[a-f0-9]+> ++[ ]*[a-f0-9]+: e8 ([a-f0-9]{2} ){2}ff ff callq 0 <bar-0x[a-f0-9]+> + [ ]*[a-f0-9]+: c3 retq + #pass +--- binutils/ld/testsuite/ld-x86-64/protected3.d ++++ binutils/ld/testsuite/ld-x86-64/protected3.d +@@ -8,6 +8,6 @@ + Disassembly of section .text: + + 0+[a-f0-9]+ <bar>: +-[ ]*[a-f0-9]+: 8b 05 ce 00 20 00 mov 0x[a-f0-9]+(%rip),%eax # [a-f0-9]+ <foo> ++[ ]*[a-f0-9]+: 8b 05 ([a-f0-9]{2} ){2}20 00 mov 0x[a-f0-9]+(%rip),%eax # [a-f0-9]+ <foo> + [ ]*[a-f0-9]+: c3 retq + #pass +--- binutils/ld/testsuite/ld-ifunc/ifunc-1-local-x86.d ++++ binutils/ld/testsuite/ld-ifunc/ifunc-1-local-x86.d +@@ -3,5 +3,5 @@ + #target: x86_64-*-* i?86-*-* + + #... +-[ \t0-9a-f]+:[ \t0-9a-f]+call[ \t0-9a-fq]+<*ABS*(+0x200|)@plt> ++[ \t0-9a-f]+:[ \t0-9a-f]+call[ \t0-9a-fq]+<*ABS*(+0x[a-f0-9]+|)@plt> + #pass +--- binutils/ld/testsuite/ld-ifunc/ifunc-1-x86.d ++++ binutils/ld/testsuite/ld-ifunc/ifunc-1-x86.d +@@ -3,5 +3,5 @@ + #target: x86_64-*-* i?86-*-* + + #... +-[ \t0-9a-f]+:[ \t0-9a-f]+call[ \t0-9a-fq]+<*ABS*(+0x220|)@plt> ++[ \t0-9a-f]+:[ \t0-9a-f]+call[ \t0-9a-fq]+<*ABS*(+0x[a-f0-9]+|)@plt> + #pass +--- binutils/ld/testsuite/ld-ifunc/ifunc-2-local-x86-64.d ++++ binutils/ld/testsuite/ld-ifunc/ifunc-2-local-x86-64.d +@@ -4,6 +4,6 @@ + #target: x86_64-*-* + + #... +-[ \t0-9a-f]+:[ \t0-9a-f]+call[ \t0-9a-fq]+<*ABS*+0x220@plt> +-[ \t0-9a-f]+:[ \t0-9a-f]+lea[ \t]+.*(%rip),%rax.*[ \t0-9a-fq]+<*ABS*+0x220@plt> ++[ \t0-9a-f]+:[ \t0-9a-f]+call[ \t0-9a-fq]+<*ABS*+0x[a-f0-9]+@plt> ++[ \t0-9a-f]+:[ \t0-9a-f]+lea[ \t]+.*(%rip),%rax.*[ \t0-9a-fq]+<*ABS*+0x[a-f0-9]+@plt> + #pass +--- binutils/ld/testsuite/ld-ifunc/ifunc-2-x86-64.d ++++ binutils/ld/testsuite/ld-ifunc/ifunc-2-x86-64.d +@@ -4,6 +4,6 @@ + #target: x86_64-*-* + + #... +-[ \t0-9a-f]+:[ \t0-9a-f]+call[ \t0-9a-fq]+<*ABS*+0x220@plt> +-[ \t0-9a-f]+:[ \t0-9a-f]+lea[ \t]+.*(%rip),%rax.*[ \t0-9a-fq]+<*ABS*+0x220@plt> ++[ \t0-9a-f]+:[ \t0-9a-f]+call[ \t0-9a-fq]+<*ABS*+0x[a-f0-9]+@plt> ++[ \t0-9a-f]+:[ \t0-9a-f]+lea[ \t]+.*(%rip),%rax.*[ \t0-9a-fq]+<*ABS*+0x[a-f0-9]+@plt> + #pass +--- binutils/ld/testsuite/ld-ifunc/ifunc-3a-x86.d ++++ binutils/ld/testsuite/ld-ifunc/ifunc-3a-x86.d +@@ -4,5 +4,5 @@ + #target: x86_64-*-* i?86-*-* + + #... +-[ \t0-9a-f]+:[ \t0-9a-f]+call[ \t0-9a-fq]+<*ABS*(+0x258|)@plt> ++[ \t0-9a-f]+:[ \t0-9a-f]+call[ \t0-9a-fq]+<*ABS*(+0x[a-f0-9]+|)@plt> + #pass diff --git a/pkgs/core/binutils/patches/binutils-2.20.1-gentoo-rpath_envvar-smack.patch b/pkgs/core/binutils/patches/binutils-2.20.1-gentoo-rpath_envvar-smack.patch new file mode 100644 index 0000000..2e90f0c --- /dev/null +++ b/pkgs/core/binutils/patches/binutils-2.20.1-gentoo-rpath_envvar-smack.patch @@ -0,0 +1,13 @@ +http://sourceware.org/ml/binutils/2007-07/msg00401.html +http://sourceware.org/bugzilla/show_bug.cgi?id=4970 + +--- a/configure ++++ b/configure +@@ -5601,6 +5601,7 @@ case "${host}" in + *-*-mingw* | *-*-cygwin ) RPATH_ENVVAR=PATH ;; + *) RPATH_ENVVAR=LD_LIBRARY_PATH ;; + esac ++RPATH_ENVVAR="cant_touch_this_nah_nah_nah" + + # On systems where the dynamic library environment variable is PATH, + if test "$RPATH_ENVVAR" = PATH; then diff --git a/pkgs/core/binutils/patches/binutils-2.20.1-gentoo-use-new-ld-dtags.patch b/pkgs/core/binutils/patches/binutils-2.20.1-gentoo-use-new-ld-dtags.patch new file mode 100644 index 0000000..84e20f7 --- /dev/null +++ b/pkgs/core/binutils/patches/binutils-2.20.1-gentoo-use-new-ld-dtags.patch @@ -0,0 +1,10 @@ +--- binutils/ld/ldmain.c ++++ binutils/ld/ldmain.c +@@ -296,6 +296,7 @@ main (int argc, char **argv) + + link_info.allow_undefined_version = TRUE; + link_info.keep_memory = TRUE; ++ link_info.new_dtags = TRUE; + link_info.combreloc = TRUE; + link_info.strip_discarded = TRUE; + link_info.callbacks = &link_callbacks; diff --git a/pkgs/core/binutils/patches/binutils-2.20.1-gentoo-use-relro.patch b/pkgs/core/binutils/patches/binutils-2.20.1-gentoo-use-relro.patch new file mode 100644 index 0000000..db3276b --- /dev/null +++ b/pkgs/core/binutils/patches/binutils-2.20.1-gentoo-use-relro.patch @@ -0,0 +1,9 @@ +background: +http://www.airs.com/blog/archives/189 + +--- binutils/ld/ldmain.c ++++ binutils/ld/ldmain.c +@@ -293,2 +293,3 @@ main (int argc, char **argv) + link_info.combreloc = TRUE; ++ link_info.relro = TRUE; + link_info.strip_discarded = TRUE; diff --git a/pkgs/core/binutils/patches/binutils-2.20.1-gentoo-warn-textrel.patch b/pkgs/core/binutils/patches/binutils-2.20.1-gentoo-warn-textrel.patch new file mode 100644 index 0000000..c8783a2 --- /dev/null +++ b/pkgs/core/binutils/patches/binutils-2.20.1-gentoo-warn-textrel.patch @@ -0,0 +1,85 @@ +textrels are bad for forcing copy-on-write (this affects everyone), +and for security/runtime code generation, this affects security ppl. +But in either case, it doesn't matter who needs textrels, it's +the very fact that they're needed at all. + +2006-06-10 Ned Ludd solar@gentoo.org, Mike Frysinger vapier@gentoo.org + + * bfd/elflink.c (bfd_elf_final_link): Check all objects for TEXTRELs. + * ld/ldmain.c (main): Change textrel warning default to true. + * ld/testsuite/lib/ld-lib.exp (default_ld_simple_link): Scrub TEXTREL + warnings from ld output. + +--- binutils/bfd/elflink.c ++++ binutils/bfd/elflink.c +@@ -8652,14 +8652,12 @@ + goto error_return; + + /* Check for DT_TEXTREL (late, in case the backend removes it). */ +- if (info->warn_shared_textrel && info->shared) ++ o = bfd_get_section_by_name (dynobj, ".dynamic"); ++ if (info->warn_shared_textrel && o != NULL) + { + bfd_byte *dyncon, *dynconend; + + /* Fix up .dynamic entries. */ +- o = bfd_get_section_by_name (dynobj, ".dynamic"); +- BFD_ASSERT (o != NULL); +- + dyncon = o->contents; + dynconend = o->contents + o->size; + for (; dyncon < dynconend; dyncon += bed->s->sizeof_dyn) +@@ -8702,7 +8702,7 @@ bfd_elf_final_link (bfd *abfd, struct bf + if (dyn.d_tag == DT_TEXTREL) + { + info->callbacks->einfo +- (_("%P: warning: creating a DT_TEXTREL in a shared object.\n")); ++ (_("%P: warning: creating a DT_TEXTREL in object.\n")); + break; + } + } +--- binutils/ld/ldmain.c ++++ binutils/ld/ldmain.c +@@ -282,2 +282,3 @@ + link_info.spare_dynamic_tags = 5; ++ link_info.warn_shared_textrel = TRUE; + link_info.sharable_sections = FALSE; +--- binutils/ld/testsuite/lib/ld-lib.exp ++++ binutils/ld/testsuite/lib/ld-lib.exp +@@ -181,6 +181,10 @@ proc default_ld_simple_link { ld target + # symbol, since the default linker script might use ENTRY. + regsub -all "(^|\n)([^\n]*: warning: cannot find entry symbol[^\n]*\n?)" $exec_output "\1" exec_output + ++ # Gentoo tweak: ++ # We want to ignore TEXTREL warnings since we force enable them by default ++ regsub -all "^.*ld-new: warning: creating a DT_TEXTREL in object." $exec_output "\1" exec_output ++ + if [string match "" $exec_output] then { + return 1 + } else { +@@ -899,6 +903,10 @@ + remote_file build delete "ld.tmp" + set cmdret [lindex $cmdret 0] + ++ # Gentoo tweak: ++ # We want to ignore TEXTREL warnings since we force enable them by default ++ regsub -all "^.*ld-new: warning: creating a DT_TEXTREL in object." $comp_output "\1" comp_output ++ + if { $cmdret == 0 && $run_objcopy } { + set infile $objfile + set objfile "tmpdir/dump1" + +this sucks, but the warn test explicitly checks for textrels, and we +change/filter that output with the above hunks + +--- binutils/ld/testsuite/ld-i386/i386.exp ++++ binutils/ld/testsuite/ld-i386/i386.exp +@@ -176,7 +176,7 @@ + run_dump_test "pcrel16" + run_dump_test "pcrel16abs" + run_dump_test "alloc" +-run_dump_test "warn1" ++#run_dump_test "warn1" + run_dump_test "tlsgd2" + run_dump_test "tlsie2" + run_dump_test "tlsie3" diff --git a/pkgs/core/cloog/cloog.nm b/pkgs/core/cloog/cloog.nm new file mode 100644 index 0000000..51daae2 --- /dev/null +++ b/pkgs/core/cloog/cloog.nm @@ -0,0 +1,55 @@ +############################################################################### +# # +# IPFire.org - A linux based firewall # +# Copyright (C) 2007, 2008 Michael Tremer & Christian Schmidt # +# # +# This program is free software: you can redistribute it and/or modify # +# it under the terms of the GNU General Public License as published by # +# the Free Software Foundation, either version 3 of the License, or # +# (at your option) any later version. # +# # +# This program is distributed in the hope that it will be useful, # +# but WITHOUT ANY WARRANTY; without even the implied warranty of # +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # +# GNU General Public License for more details. # +# # +# You should have received a copy of the GNU General Public License # +# along with this program. If not, see http://www.gnu.org/licenses/. # +# # +############################################################################### + +############################################################################### +# Definitions +############################################################################### + +include $(PKGROOT)/Include + +PKG_NAME = cloog +PKG_VER = 0.15.8 +PKG_REL = 0 + +PKG_MAINTAINER = Michael Tremer michael.tremer@ipfire.org +PKG_GROUP = System/Libraries +PKG_URL = http://www.cloog.org +PKG_LICENSE = GPLv2+ +PKG_SUMMARY = The Chunky Loop Generator. + +PKG_BUILD_DEPS+= autoconf automake m4 +PKG_DEPS += gmp ppl + +define PKG_DESCRIPTION + CLooG is a software which generates loops for scanning Z-polyhedra. That is, \ + CLooG finds the code or pseudo-code where each integral point of one or more \ + parametrized polyhedron or parametrized polyhedra union is reached. CLooG is \ + designed to avoid control overhead and to produce a very efficient code. +endef + +PKG_TARBALL = $(PKG_NAME)-ppl-$(PKG_VER).tar.gz +DIR_APP = $(DIR_SRC)/$(PKG_NAME)-ppl-$(PKG_VER) + +CONFIGURE_OPTIONS += \ + --with-ppl + +define STAGE_TEST + cd $(DIR_APP) && make check +endef diff --git a/pkgs/core/dracut/dracut.nm b/pkgs/core/dracut/dracut.nm index 78cd111..e7aa89a 100644 --- a/pkgs/core/dracut/dracut.nm +++ b/pkgs/core/dracut/dracut.nm @@ -25,7 +25,7 @@ include $(PKGROOT)/Include
PKG_NAME = dracut -PKG_VER = 004 +PKG_VER = 005 PKG_REL = 0
PKG_MAINTAINER = diff --git a/pkgs/core/dracut/patches/dracut-004-emergency.patch b/pkgs/core/dracut/patches/dracut-004-emergency.patch deleted file mode 100644 index 4f1d67f..0000000 --- a/pkgs/core/dracut/patches/dracut-004-emergency.patch +++ /dev/null @@ -1,19 +0,0 @@ -commit 5db587d7c118afc47b50b4872100b508c84646fa -Author: Harald Hoyer harald@redhat.com -Date: Wed Jan 20 16:04:55 2010 +0100 - - init: fixed emergency_shell argument parsing - -diff --git a/modules.d/99base/init b/modules.d/99base/init -index 8dc00a9..ab033a7 100755 ---- a/modules.d/99base/init -+++ b/modules.d/99base/init -@@ -35,7 +35,7 @@ wait_for_loginit() - - emergency_shell() - { -- if [ $1 = "-n" ]; then -+ if [ "$1" = "-n" ]; then - _rdshell_name=$2 - shift 2 - else diff --git a/pkgs/core/dracut/patches/dracut-004-firmware.patch b/pkgs/core/dracut/patches/dracut-004-firmware.patch deleted file mode 100644 index b838f83..0000000 --- a/pkgs/core/dracut/patches/dracut-004-firmware.patch +++ /dev/null @@ -1,19 +0,0 @@ -diff -up dracut-004/modules.d/95udev-rules/install.fw dracut-004/modules.d/95udev-rules/install ---- dracut-004/modules.d/95udev-rules/install.fw 2010-01-29 16:40:11.000000000 +0100 -+++ dracut-004/modules.d/95udev-rules/install 2010-01-29 16:40:25.000000000 +0100 -@@ -15,7 +15,6 @@ inst_rules "$moddir/01-ignore.rules" - - # for firmware loading - inst_rules 50-firmware.rules --dracut_install /lib/udev/firmware.sh - dracut_install cat uname - - if [ ! -x /lib/udev/vol_id ]; then -@@ -31,6 +30,7 @@ ata_id \ - cdrom_id \ - create_floppy_devices \ - edd_id \ -+firmware \ - firmware.sh \ - fw_unit_symlinks.sh \ - hid2hci \ diff --git a/pkgs/core/gcc/gcc.nm b/pkgs/core/gcc/gcc.nm index 3ab971a..8119921 100644 --- a/pkgs/core/gcc/gcc.nm +++ b/pkgs/core/gcc/gcc.nm @@ -40,7 +40,7 @@ define PKG_DESCRIPTION endef
PKG_BUILD_DEPS = -PKG_DEPS += binutils glibc gmp kernel-headers libffi mpfr +PKG_DEPS += binutils cloog glibc gmp kernel-headers libffi mpfr ppl
CFLAGS = -D__USE_XOPEN2K8 -pipe CXXFLAGS = @@ -50,7 +50,7 @@ ifeq "$(MACHINE)" "i586" endif
ifeq "$(MACHINE)" "x86_64" - CONFIGURE_ARGS = --without-cloog --without-ppl --disable-multilib + CONFIGURE_ARGS = --disable-multilib else CONFIG_CPU = --with-cpu=$(TARGET_MACHINE) --with-arch=$(TARGET_MACHINE) endif diff --git a/pkgs/core/gcc/patches/gcc-4.4.1-espf-1.patch b/pkgs/core/gcc/patches/gcc-4.4.1-espf-1.patch deleted file mode 100644 index e531e13..0000000 --- a/pkgs/core/gcc/patches/gcc-4.4.1-espf-1.patch +++ /dev/null @@ -1,504 +0,0 @@ -diff -Nur gcc-4.4.0_vanilla/gcc/config.in gcc-4.4.0/gcc/config.in ---- gcc-4.4.0_vanilla/gcc/config.in 2009-04-21 11:08:08.000000000 +0200 -+++ gcc-4.4.0/gcc/config.in 2009-07-11 12:35:50.000000000 +0200 -@@ -65,6 +65,12 @@ - #endif - - -+/* Define to 1 to enable espf. */ -+#ifndef USED_FOR_TARGET -+#undef ENABLE_ESPF -+#endif -+ -+ - /* Define to 1 to enable fixed-point arithmetic extension to C. */ - #ifndef USED_FOR_TARGET - #undef ENABLE_FIXED_POINT -@@ -101,6 +107,12 @@ - #endif - - -+/* Define to 1 to enable libssp. */ -+#ifndef USED_FOR_TARGET -+#undef ENABLE_LIBSSP -+#endif -+ -+ - /* Define to 1 if translation of program messages to the user's native - language is requested. */ - #ifndef USED_FOR_TARGET -@@ -1465,6 +1477,12 @@ - #endif - - -+/* Define if your target C library provides fortify_sources level 2 support */ -+#ifndef USED_FOR_TARGET -+#undef TARGET_LIBC_PROVIDES_FORTIFY2 -+#endif -+ -+ - /* Define if your target C library provides stack protector support */ - #ifndef USED_FOR_TARGET - #undef TARGET_LIBC_PROVIDES_SSP -diff -Nur gcc-4.4.0_vanilla/gcc/configure gcc-4.4.0/gcc/configure ---- gcc-4.4.0_vanilla/gcc/configure 2009-03-24 18:46:03.000000000 +0100 -+++ gcc-4.4.0/gcc/configure 2009-07-11 12:35:57.000000000 +0200 -@@ -458,7 +458,7 @@ - # include <unistd.h> - #endif" - --ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS build build_cpu build_vendor build_os host host_cpu host_vendor host_os target target_cpu target_vendor target_os target_noncanonical build_libsubdir build_subdir host_subdir target_subdir GENINSRC CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT GNATBIND ac_ct_GNATBIND GNATMAKE ac_ct_GNATMAKE NO_MINUS_C_MINUS_O OUTPUT_OPTION CPP EGREP loose_warn strict_warn warn_cflags nocommon_flag TREEBROWSER valgrind_path valgrind_path_defines valgrind_command coverage_flags enable_multilib enable_decimal_float enable_fixed_point enable_shared TARGET_SYSTEM_ROOT TARGET_SYSTEM_ROOT_DEFINE CROSS_SYSTEM_HEADER_DIR onestep PKGVERSION REPORT_BUGS_TO REPORT_BUGS_TEXI datarootdir docdir htmldir SET_MAKE AWK LN_S LN RANLIB ac_ct_RANLIB ranlib_flags INSTALL INSTALL_PROGRAM INSTALL_DATA make_compare_target have_mktemp_command MAKEINFO BUILD_INFO GENERATED_MANPAGES FLEX BISON NM AR COLLECT2_LIBS GNAT_LIBEXC LDEXP_LIB TARGET_GETGROUPS_T LIBICONV LTLIBICONV LIBICONV_DEP manext objext gthread_flags extra_modes_file extra_opt_files USE_NLS LIBINTL LIBINTL_DEP INCINTL XGETTEXT GMSGFMT POSUB CATALOGS DATADIRNAME INSTOBJEXT GENCAT CATOBJEXT CROSS ALL SYSTEM_HEADER_DIR inhibit_libc CC_FOR_BUILD BUILD_CFLAGS BUILD_LDFLAGS STMP_FIXINC STMP_FIXPROTO collect2 LIBTOOL SED FGREP GREP LD DUMPBIN ac_ct_DUMPBIN OBJDUMP ac_ct_OBJDUMP ac_ct_AR STRIP ac_ct_STRIP lt_ECHO DSYMUTIL ac_ct_DSYMUTIL NMEDIT ac_ct_NMEDIT LIPO ac_ct_LIPO OTOOL ac_ct_OTOOL OTOOL64 ac_ct_OTOOL64 objdir enable_fast_install gcc_cv_as ORIGINAL_AS_FOR_TARGET gcc_cv_ld ORIGINAL_LD_FOR_TARGET gcc_cv_nm ORIGINAL_NM_FOR_TARGET gcc_cv_objdump gcc_cv_readelf libgcc_visibility GGC zlibdir zlibinc MAINT gcc_tooldir dollar slibdir subdirs srcdir all_compilers all_gtfiles all_lang_makefrags all_lang_makefiles all_languages all_selected_languages build_exeext build_install_headers_dir build_xm_file_list build_xm_include_list build_xm_defines build_file_translate check_languages cpp_install_dir xmake_file tmake_file extra_gcc_objs extra_headers_list extra_objs extra_parts extra_passes extra_programs float_h_file gcc_config_arguments gcc_gxx_include_dir host_exeext host_xm_file_list host_xm_include_list host_xm_defines out_host_hook_obj install lang_opt_files lang_specs_files lang_tree_files local_prefix md_file objc_boehm_gc out_file out_object_file thread_file tm_file_list tm_include_list tm_defines tm_p_file_list tm_p_include_list xm_file_list xm_include_list xm_defines c_target_objs cxx_target_objs fortran_target_objs target_cpu_default GMPLIBS GMPINC PPLLIBS PPLINC CLOOGLIBS CLOOGINC LIBOBJS LTLIBOBJS' -+ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS build build_cpu build_vendor build_os host host_cpu host_vendor host_os target target_cpu target_vendor target_os target_noncanonical build_libsubdir build_subdir host_subdir target_subdir GENINSRC CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT GNATBIND ac_ct_GNATBIND GNATMAKE ac_ct_GNATMAKE NO_MINUS_C_MINUS_O OUTPUT_OPTION CPP EGREP loose_warn strict_warn warn_cflags nocommon_flag TREEBROWSER valgrind_path valgrind_path_defines valgrind_command coverage_flags enable_multilib enable_decimal_float enable_fixed_point enable_shared TARGET_SYSTEM_ROOT TARGET_SYSTEM_ROOT_DEFINE CROSS_SYSTEM_HEADER_DIR onestep PKGVERSION REPORT_BUGS_TO REPORT_BUGS_TEXI datarootdir docdir htmldir SET_MAKE AWK LN_S LN RANLIB ac_ct_RANLIB ranlib_flags INSTALL INSTALL_PROGRAM INSTALL_DATA make_compare_target have_mktemp_command MAKEINFO BUILD_INFO GENERATED_MANPAGES FLEX BISON NM AR COLLECT2_LIBS GNAT_LIBEXC LDEXP_LIB TARGET_GETGROUPS_T LIBICONV LTLIBICONV LIBICONV_DEP manext objext gthread_flags extra_modes_file extra_opt_files USE_NLS LIBINTL LIBINTL_DEP INCINTL XGETTEXT GMSGFMT POSUB CATALOGS DATADIRNAME INSTOBJEXT GENCAT CATOBJEXT CROSS ALL SYSTEM_HEADER_DIR inhibit_libc CC_FOR_BUILD BUILD_CFLAGS BUILD_LDFLAGS STMP_FIXINC STMP_FIXPROTO collect2 LIBTOOL SED FGREP GREP LD DUMPBIN ac_ct_DUMPBIN OBJDUMP ac_ct_OBJDUMP ac_ct_AR STRIP ac_ct_STRIP lt_ECHO DSYMUTIL ac_ct_DSYMUTIL NMEDIT ac_ct_NMEDIT LIPO ac_ct_LIPO OTOOL ac_ct_OTOOL OTOOL64 ac_ct_OTOOL64 objdir enable_fast_install gcc_cv_as ORIGINAL_AS_FOR_TARGET gcc_cv_ld ORIGINAL_LD_FOR_TARGET gcc_cv_nm ORIGINAL_NM_FOR_TARGET gcc_cv_objdump gcc_cv_readelf libgcc_visibility enable_espf GGC zlibdir zlibinc MAINT gcc_tooldir dollar slibdir subdirs srcdir all_compilers all_gtfiles all_lang_makefrags all_lang_makefiles all_languages all_selected_languages build_exeext build_install_headers_dir build_xm_file_list build_xm_include_list build_xm_defines build_file_translate check_languages cpp_install_dir xmake_file tmake_file extra_gcc_objs extra_headers_list extra_objs extra_parts extra_passes extra_programs float_h_file gcc_config_arguments gcc_gxx_include_dir host_exeext host_xm_file_list host_xm_include_list host_xm_defines out_host_hook_obj install lang_opt_files lang_specs_files lang_tree_files local_prefix md_file objc_boehm_gc out_file out_object_file thread_file tm_file_list tm_include_list tm_defines tm_p_file_list tm_p_include_list xm_file_list xm_include_list xm_defines c_target_objs cxx_target_objs fortran_target_objs target_cpu_default GMPLIBS GMPINC PPLLIBS PPLINC CLOOGLIBS CLOOGINC LIBOBJS LTLIBOBJS' - ac_subst_files='language_hooks' - ac_pwd=`pwd` - -@@ -1078,6 +1078,11 @@ - --enable-fast-install[=PKGS] - optimize for fast installation [default=yes] - --disable-libtool-lock avoid locking (might break parallel builds) -+ --enable-espf -+ Enable Stack protector, Position independent executable and -+ Fortify_sources as default if we have suppot for it when compiling -+ and link with -z relro and -z now as default. -+ Linux targets supported i*86, x86_64 - --enable-maintainer-mode - enable make rules and dependencies not useful - (and sometimes confusing) to the casual installer -@@ -24177,6 +24182,50 @@ - ;; - esac - -+echo "$as_me:$LINENO: checking linker -z now support" >&5 -+echo $ECHO_N "checking linker -z now support... $ECHO_C" >&6 -+if test "${gcc_cv_ld_now+set}" = set; then -+ echo $ECHO_N "(cached) $ECHO_C" >&6 -+else -+ gcc_cv_ld_now=no -+if test $in_tree_ld = yes ; then -+ if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 16 -o "$gcc_cv_gld_major_version" -gt 2 \ -+ && test $in_tree_ld_is_elf = yes; then -+ gcc_cv_ld_now=yes -+ fi -+elif test x$gcc_cv_ld != x; then -+ # Check if linker supports -z now options -+ if $gcc_cv_ld --help 2>/dev/null | grep now > /dev/null; then -+ gcc_cv_ld_now=yes -+ fi -+fi -+ -+fi -+echo "$as_me:$LINENO: result: $gcc_cv_ld_now" >&5 -+echo "${ECHO_T}$gcc_cv_ld_now" >&6 -+ -+echo "$as_me:$LINENO: checking linker -z relro support" >&5 -+echo $ECHO_N "checking linker -z relro support... $ECHO_C" >&6 -+if test "${gcc_cv_ld_relro+set}" = set; then -+ echo $ECHO_N "(cached) $ECHO_C" >&6 -+else -+ gcc_cv_ld_relro=no -+if test $in_tree_ld = yes ; then -+ if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 16 -o "$gcc_cv_gld_major_version" -gt 2 \ -+ && test $in_tree_ld_is_elf = yes; then -+ gcc_cv_ld_relro=yes -+ fi -+elif test x$gcc_cv_ld != x; then -+ # Check if linker supports -z relro and -z norelro options -+ if $gcc_cv_ld --help 2>/dev/null | grep relro > /dev/null; then -+ gcc_cv_ld_relro=yes -+ fi -+fi -+ -+fi -+echo "$as_me:$LINENO: result: $gcc_cv_ld_relro" >&5 -+echo "${ECHO_T}$gcc_cv_ld_relro" >&6 -+ - echo "$as_me:$LINENO: checking linker --sysroot support" >&5 - echo $ECHO_N "checking linker --sysroot support... $ECHO_C" >&6 - if test "${gcc_cv_ld_sysroot+set}" = set; then -@@ -24213,6 +24262,49 @@ - - fi - -+# Test for fortify_sources support level 2 in target C library. -+echo "$as_me:$LINENO: checking for FORTIFY_SOURCES level 2 in target C library" >&5 -+echo $ECHO_N "checking for FORTIFY_SOURCES level 2 in target C library... $ECHO_C" >&6 -+if test "${gcc_cv_libc_provides_fortify2+set}" = set; then -+ echo $ECHO_N "(cached) $ECHO_C" >&6 -+else -+ gcc_cv_libc_provides_fortify2=no -+ case "$target" in -+ *-*-linux* | *-*-kfreebsd*-gnu | *-*-knetbsd*-gnu) -+ if test x$host != x$target || test "x$TARGET_SYSTEM_ROOT" != x; then -+ if test "x$with_sysroot" = x; then -+ glibc_header_dir="${exec_prefix}/${target_noncanonical}/sys-include" -+ elif test "x$with_build_sysroot" != "x"; then -+ glibc_header_dir="${with_build_sysroot}/usr/include" -+ elif test "x$with_sysroot" = xyes; then -+ glibc_header_dir="${exec_prefix}/${target_noncanonical}/sys-root/usr/include" -+ else -+ glibc_header_dir="${with_sysroot}/usr/include" -+ fi -+ else -+ glibc_header_dir=/usr/include -+ fi -+ # grep __USE_FORTIFY_LEVEL 2 in $glibc_header_dir/features.h -+ if test -f $glibc_header_dir/features.h \ -+ && grep '__USE_FORTIFY_LEVEL 2' $glibc_header_dir/features.h > /dev/null; then -+ gcc_cv_libc_provides_fortify2=yes -+ else -+ gcc_cv_libc_provides_fortify2=no -+ fi -+ ;; -+ *) gcc_cv_libc_provides_fortify2=no ;; -+ esac -+fi -+echo "$as_me:$LINENO: result: $gcc_cv_libc_provides_fortify2" >&5 -+echo "${ECHO_T}$gcc_cv_libc_provides_fortify2" >&6 -+if test x$gcc_cv_libc_provides_fortify2 = xyes; then -+ -+cat >>confdefs.h <<_ACEOF -+#define TARGET_LIBC_PROVIDES_FORTIFY2 1 -+_ACEOF -+ -+fi -+ - # Test for stack protector support in target C library. - echo "$as_me:$LINENO: checking __stack_chk_fail in target C library" >&5 - echo $ECHO_N "checking __stack_chk_fail in target C library... $ECHO_C" >&6 -@@ -24375,6 +24467,42 @@ - - fi - -+if test x"$enable_libssp" = xyes; then -+ -+cat >>confdefs.h <<_ACEOF -+#define ENABLE_LIBSSP 1 -+_ACEOF -+ -+fi -+ -+# Check whether --enable-espf was given and we have -z now and -z relro support. -+# Check whether --enable-espf or --disable-espf was given. -+if test "${enable_espf+set}" = set; then -+ enableval="$enable_espf" -+ -+ case $target in -+ i?86*-*-linux* | x86_64*-*-linux*) -+ if test x$gcc_cv_ld_relro = xyes && test x"$gcc_cv_ld_now" = xyes; then -+ enable_espf=yes -+ else -+ enable_espf=no -+ fi -+ ;; -+ *) -+ enable_espf=no -+ ;; -+ esac -+ -+fi; -+if test x$enable_espf = xyes; then -+ -+cat >>confdefs.h <<_ACEOF -+#define ENABLE_ESPF 1 -+_ACEOF -+ -+fi -+ -+ - # Check if TFmode long double should be used by default or not. - # Some glibc targets used DFmode long double, but with glibc 2.4 - # and later they can use TFmode. -@@ -25581,6 +25709,7 @@ - s,@gcc_cv_objdump@,$gcc_cv_objdump,;t t - s,@gcc_cv_readelf@,$gcc_cv_readelf,;t t - s,@libgcc_visibility@,$libgcc_visibility,;t t -+s,@enable_espf@,$enable_espf,;t t - s,@GGC@,$GGC,;t t - s,@zlibdir@,$zlibdir,;t t - s,@zlibinc@,$zlibinc,;t t -diff -Nur gcc-4.4.0_vanilla/gcc/espf.h gcc-4.4.0/gcc/espf.h ---- gcc-4.4.0_vanilla/gcc/espf.h 1970-01-01 01:00:00.000000000 +0100 -+++ gcc-4.4.0/gcc/espf.h 2009-07-11 12:36:43.000000000 +0200 -@@ -0,0 +1,104 @@ -+#ifndef GCC_ESPF_H -+#define GCC_ESPF_H -+/* Version 0.2.20090614.1 (C) 2009 by Magnus Granberg zorry@ume.nu */ -+/* Gentoo espf.h patch Version 20090614.1 (C) 2009 by Magnus Granberg zorry@ume.nu */ -+ -+/* FIXME: -+ 1. Fix so that we can have -fPIE or -fpie options. -+*/ -+/* This file add's -fstack-protector-all, -Fpie|-fpie, -pie, -D_FORTIFY_SOURCES=2, -z relro, -z now, -Wformat -+ and -Wformat-security as default if the define's and the spec allow it. -+ -+ On Gentoo -+ Added a hack for gcc-specs-* in toolchain-funcs.eclass to support older hardened GCC patches and -+ we don't need to change the code on gcc-specs-*. -+ This will add some unsupported upstream commands options as -nopie and -z nonow. -+ -D__KERNEL__ is added so we don't have -fPIE|-fpie and -fstack-protector-all when building kernels. -+ ESPF_CC1_SPEC is added to CC1_SPEC. -+ -D_FORTIFY_SOURCES=2 is added with gentoo's patchset as default so no need to set it hear. -+ -Wformat* is added with gentoo's patchset as default so no need to set it hear. -+ -z relro is set by binutils as default so no need to set it hear. -+*/ -+ -+#ifdef ENABLE_ESPF -+ -+ /* Hack to support gcc-specs-* in toolchain-funcs.eclass */ -+ #define ESPF_CC1_SPEC "%{!fno-stack-protector: %{!fno-stack-protector-all: %{!nopie: %{!fstrict-overflow: }}}}" -+ -+ /* This will add -Wformat -Wformat-security -Wstack-protector in espf_cc1_options_warnings and -fstack-protector-all in -+ espf_cc1_options_ssp and incompatible pie commands in espf_cc1_options_pie_incompatible. -+ ESPF_CC1_OPTIONS_SPEC is added to CC1_OPTIONS_SPEC in gcc/gcc.c */ -+ #define ESPF_CC1_OPTIONS_SPEC "%(espf_cc1_options_ssp) %(espf_cc1_options_pie_incompatible)" -+ -+ /* This will add -z now if we don't have -z nonow or -z lazy -+ ESPF_LINK_SPEC is added to LINK_COMMAND_SPEC in gcc/gcc.c */ -+ #define ESPF_LINK_SPEC "%{!now:%{!lazy:%{!nonow:-z now}}}" -+ -+ /* This will add -fstack-protector-all if we don't have -D__KERNEL__ -nostdlib -nodefaultlibs -fno-stack-protector -fstack-protector -+ -fstack-protector-all and we have ENABLE_LIBSSP or TARGET_LIBC_PROVIDES_SSP defined. */ -+ #if defined (ENABLE_LIBSSP) || defined (TARGET_LIBC_PROVIDES_SSP) -+ #define ESPF_CC1_OPTIONS_SSP_SPEC \ -+ "%{!D__KERNEL__:%{!nostdlib:%{!nodefaultlibs: %{!fno-stack-protector: \ -+ %{!fstack-protector:%{!fstack-protector-all:-fstack-protector-all}}}}}}" -+ #else -+ #define ESPF_CC1_OPTIONS_SSP_SPEC "" -+ #endif -+ -+ /* If HAVE_LD_PIE not defined we will not add any -pie -fPIE commands and incompatible pie check */ -+ #ifdef HAVE_LD_PIE -+ -+ /* This will add -fPIE if we don't have -D__KERNEL__ -pie -fpic -fPIC -fpie -fPIE -fno-pic -fno-PIC -fno-pie -fno-PIE -+ -shared -static -nostdlib -nostartfiles -nopie -+ We use ESPF_COMPILER_COMMAND_SPEC to add -fPIE before do_spec (compiler_command_spec) is run in gcc/gcc.c main() */ -+ #define ESPF_COMPILER_COMMAND_SPEC "%(espf_compiler_command_pie)" -+ #define ESPF_COMPILER_COMMAND_PIE_SPEC \ -+ "%{!D__KERNEL__:%{!pie: %{!fpic:%{!fPIC:%{!fpie:%{!fPIE: %{!fno-pic:%{!fno-PIC:%{!fno-pie:%{!fno-PIE: \ -+ %{!shared: %{!static: %{!nostdlib: %{!nostartfiles:%{!nopie:-fPIE}} } }}}} }}}} }}}}" -+ -+ /* This adds some incompatible rules for -pie and -shared -+ We can't have -shared when -static -pie -fPIE -fpie -fno-PIC -fno-pic -+ and -pie when -static -pg -p -profile */ -+ #define ESPF_CC1_OPTIONS_PIE_INCOMPATIBLE_SPEC \ -+ "%{shared:%{static|pie|fPIE|fpie|fno-PIC|fno-pic:%e-shared and -static|pie|fPIE|fpie|fno-PIC|fno-pic are incompatible}} \ -+ %{pie:%{static|pg|p|profile:%e-pie and -static|pg|p|profile are incompatible}}" -+ -+ /* This will add -pie if we don't have -pie A -fno-pic -fno-PIC -fno-pie -fno-PIE -shared -static -r -+ -nostdlib -nostartfiles -nopie -+ We use ESPF_LINK_COMMAND_SPEC to add -pie before do_spec (link_command_spec) is run in gcc/gcc.c main() */ -+ #define ESPF_LINK_COMMAND_SPEC "%(espf_link_command_pie)" -+ #define ESPF_LINK_COMMAND_PIE_SPEC \ -+ "%{!pie:%{!A:%{!fno-pie:%{!fno-PIE:%{!fno-pic:%{!fno-PIC:%{!shared:%{!static:%{!r: \ -+ %{!nostdlib:%{!nostartfiles:%{!nopie:-pie}}}}}}}}}}}}" -+ #else -+ #define ESPF_COMPILER_COMMAND_SPEC "" -+ #define ESPF_CC1_OPTIONS_PIE_INCOMPATIBLE_SPEC "" -+ #define ESPF_LINK_COMMAND_SPEC "" -+ #endif -+ -+ /* We add extra spec name's to the EXTRA_SPECS list */ -+ #define ESPF_EXTRA_SPECS \ -+ { "espf_link", ESPF_LINK_SPEC }, \ -+ { "espf_link_command", ESPF_LINK_COMMAND_SPEC }, \ -+ { "espf_link_command_pie", ESPF_LINK_COMMAND_PIE_SPEC }, \ -+ { "espf_compiler_command", ESPF_COMPILER_COMMAND_SPEC }, \ -+ { "espf_compiler_command_pie", ESPF_COMPILER_COMMAND_PIE_SPEC }, \ -+ { "espf_cc1", ESPF_CC1_SPEC }, \ -+ { "espf_cc1_options", ESPF_CC1_OPTIONS_SPEC }, \ -+ { "espf_cc1_options_ssp", ESPF_CC1_OPTIONS_SSP_SPEC }, \ -+ { "espf_cc1_options_pie_incompatible", ESPF_CC1_OPTIONS_PIE_INCOMPATIBLE_SPEC } -+ -+ static const char *cc1_spec = CC1_SPEC ESPF_CC1_SPEC; -+ static const char *espf_compiler_command_spec = ESPF_COMPILER_COMMAND_SPEC; -+ static const char *espf_link_command_spec = ESPF_LINK_COMMAND_SPEC; -+ -+#else -+ -+ #define ESPF_CC1_OPTIONS_SPEC "" -+ #define ESPF_LINK_SPEC "" -+ #define ESPF_EXTRA_SPECS \ -+ { "espf_cc1_options", ESPF_CC1_OPTIONS_SPEC }, \ -+ { "espf_link", ESPF_LINK_SPEC } -+ -+#endif -+ -+#endif /* End GCC_ESPF_H */ -diff -Nur gcc-4.4.0_vanilla/gcc/gcc.c gcc-4.4.0/gcc/gcc.c ---- gcc-4.4.0_vanilla/gcc/gcc.c 2009-03-17 22:25:59.000000000 +0100 -+++ gcc-4.4.0/gcc/gcc.c 2009-07-11 12:36:43.000000000 +0200 -@@ -83,6 +83,7 @@ - #include "gcc.h" - #include "flags.h" - #include "opts.h" -+#include "espf.h" /* for espf support */ - - /* By default there is no special suffix for target executables. */ - /* FIXME: when autoconf is fixed, remove the host check - dj */ -@@ -726,7 +727,7 @@ - #ifndef LINK_COMMAND_SPEC - #define LINK_COMMAND_SPEC "\ - %{!fsyntax-only:%{!c:%{!M:%{!MM:%{!E:%{!S:\ -- %(linker) %l " LINK_PIE_SPEC "%X %{o*} %{A} %{d} %{e*} %{m} %{N} %{n} %{r}\ -+ %(linker) %l " LINK_PIE_SPEC " %(espf_link) %X %{o*} %{A} %{d} %{e*} %{m} %{N} %{n} %{r}\ - %{s} %{t} %{u*} %{x} %{z} %{Z} %{!A:%{!nostdlib:%{!nostartfiles:%S}}}\ - %{static:} %{L*} %(mfwrap) %(link_libgcc) %o\ - %{fopenmp|ftree-parallelize-loops=*:%:include(libgomp.spec)%(link_gomp)} %(mflib)\ -@@ -758,7 +759,9 @@ - - static const char *asm_debug; - static const char *cpp_spec = CPP_SPEC; -+#ifndef ENABLE_ESPF - static const char *cc1_spec = CC1_SPEC; -+#endif - static const char *cc1plus_spec = CC1PLUS_SPEC; - static const char *link_gcc_c_sequence_spec = LINK_GCC_C_SEQUENCE_SPEC; - static const char *link_ssp_spec = LINK_SSP_SPEC; -@@ -826,6 +829,7 @@ - /* NB: This is shared amongst all front-ends, except for Ada. */ - static const char *cc1_options = - "%{pg:%{fomit-frame-pointer:%e-pg and -fomit-frame-pointer are incompatible}}\ -+ %(espf_cc1_options)\ - %1 %{!Q:-quiet} -dumpbase %B %{d*} %{m*} %{a*}\ - %{c|S:%{o*:-auxbase-strip %*}%{!o*:-auxbase %b}}%{!c:%{!S:-auxbase %b}}\ - %{g*} %{O*} %{W*&pedantic*} %{w} %{std*&ansi&trigraphs}\ -@@ -1628,7 +1632,7 @@ - const char *const ptr; - }; - --static const struct spec_list_1 extra_specs_1[] = { EXTRA_SPECS }; -+static const struct spec_list_1 extra_specs_1[] = { ESPF_EXTRA_SPECS, EXTRA_SPECS }; - static struct spec_list *extra_specs = (struct spec_list *) 0; - #endif - -@@ -6782,6 +6786,12 @@ - - if (input_file_compiler) - { -+ -+#ifdef ENABLE_ESPF -+ /* We add -fpie or -fPIE as default if the spec allow it */ -+ do_self_spec (espf_compiler_command_spec); -+#endif -+ - /* Ok, we found an applicable compiler. Run its spec. */ - - if (input_file_compiler->spec[0] == '#') -@@ -6873,6 +6883,10 @@ - " to the linker.\n\n")); - fflush (stdout); - } -+#ifdef ENABLE_ESPF -+ /* We add -pie as default if the spec allow it */ -+ do_self_spec (espf_link_command_spec); -+#endif - value = do_spec (link_command_spec); - if (value < 0) - error_count = 1; -diff -Nur gcc-4.4.0_vanilla/gcc/Makefile.in gcc-4.4.0/gcc/Makefile.in ---- gcc-4.4.0_vanilla/gcc/Makefile.in 2009-03-25 13:00:32.000000000 +0100 -+++ gcc-4.4.0/gcc/Makefile.in 2009-07-11 12:36:10.000000000 +0200 -@@ -580,13 +580,23 @@ - INHIBIT_LIBC_CFLAGS = -Dinhibit_libc - endif - -+# Doesn't compile with PIE or SSP -+enable_espf = @enable_espf@ -+ifeq ($(enable_espf),yes) -+ESPF_NOPIE_CFLAGS = -fno-PIE -+ESPF_NOSSP_CFLAGS = -fno-stack-protector -+else -+ESPF_NOPIE_CFLAGS= -+ESPF_NOSSP_CFLAGS= -+endif -+ - # Options to use when compiling libgcc2.a. - # - LIBGCC2_DEBUG_CFLAGS = -g - LIBGCC2_CFLAGS = -O2 $(LIBGCC2_INCLUDES) $(GCC_CFLAGS) $(TARGET_LIBGCC2_CFLAGS) \ - $(LIBGCC2_DEBUG_CFLAGS) $(GTHREAD_FLAGS) \ - -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED \ -- $(INHIBIT_LIBC_CFLAGS) -+ $(INHIBIT_LIBC_CFLAGS) $(ESPF_NOSSP_CFLAGS) - - # Additional options to use when compiling libgcc2.a. - # Some targets override this to -isystem include -@@ -599,7 +609,7 @@ - CRTSTUFF_CFLAGS = -O2 $(GCC_CFLAGS) $(INCLUDES) $(MULTILIB_CFLAGS) -g0 \ - -finhibit-size-directive -fno-inline-functions -fno-exceptions \ - -fno-zero-initialized-in-bss -fno-toplevel-reorder -fno-tree-vectorize \ -- $(INHIBIT_LIBC_CFLAGS) -+ $(INHIBIT_LIBC_CFLAGS) $(ESPF_NOSSP_CFLAGS) - - # Additional sources to handle exceptions; overridden by targets as needed. - LIB2ADDEH = $(srcdir)/unwind-dw2.c $(srcdir)/unwind-dw2-fde.c \ -@@ -1719,7 +1729,7 @@ - echo LIBGCC_SYNC = '$(LIBGCC_SYNC)' >> tmp-libgcc.mvars - echo LIBGCC_SYNC_CFLAGS = '$(LIBGCC_SYNC_CFLAGS)' >> tmp-libgcc.mvars - echo CRTSTUFF_CFLAGS = '$(CRTSTUFF_CFLAGS)' >> tmp-libgcc.mvars -- echo CRTSTUFF_T_CFLAGS = '$(CRTSTUFF_T_CFLAGS)' >> tmp-libgcc.mvars -+ echo CRTSTUFF_T_CFLAGS = '$(CRTSTUFF_T_CFLAGS) $(ESPF_NOPIE_CFLAGS)' >> tmp-libgcc.mvars - echo CRTSTUFF_T_CFLAGS_S = '$(CRTSTUFF_T_CFLAGS_S)' >> tmp-libgcc.mvars - - mv tmp-libgcc.mvars libgcc.mvars -@@ -1754,12 +1764,14 @@ - $(T)crtbegin.o: crtstuff.c $(GCC_PASSES) $(TCONFIG_H) auto-host.h \ - gbl-ctors.h stmp-int-hdrs tsystem.h coretypes.h $(TM_H) - $(GCC_FOR_TARGET) $(CRTSTUFF_CFLAGS) $(CRTSTUFF_T_CFLAGS) \ -+ $(ESPF_NOPIE_CFLAGS) \ - -c $(srcdir)/crtstuff.c -DCRT_BEGIN \ - -o $(T)crtbegin$(objext) - - $(T)crtend.o: crtstuff.c $(GCC_PASSES) $(TCONFIG_H) auto-host.h \ - gbl-ctors.h stmp-int-hdrs tsystem.h coretypes.h $(TM_H) - $(GCC_FOR_TARGET) $(CRTSTUFF_CFLAGS) $(CRTSTUFF_T_CFLAGS) \ -+ $(ESPF_NOPIE_CFLAGS) \ - -c $(srcdir)/crtstuff.c -DCRT_END \ - -o $(T)crtend$(objext) - -@@ -1780,6 +1792,7 @@ - $(T)crtbeginT.o: crtstuff.c $(GCC_PASSES) $(TCONFIG_H) auto-host.h \ - gbl-ctors.h stmp-int-hdrs tsystem.h coretypes.h $(TM_H) - $(GCC_FOR_TARGET) $(CRTSTUFF_CFLAGS) $(CRTSTUFF_T_CFLAGS) \ -+ $(ESPF_NOPIE_CFLAGS) \ - -c $(srcdir)/crtstuff.c -DCRT_BEGIN -DCRTSTUFFT_O \ - -o $(T)crtbeginT$(objext) - -@@ -3057,7 +3070,7 @@ - output.h $(INSN_ATTR_H) $(SYSTEM_H) $(TOPLEV_H) $(TARGET_H) libfuncs.h \ - $(TARGET_DEF_H) $(FUNCTION_H) $(SCHED_INT_H) $(TM_P_H) $(EXPR_H) \ - langhooks.h $(GGC_H) $(OPTABS_H) $(REAL_H) tm-constrs.h $(GIMPLE_H) -- $(CC) -c $(ALL_CFLAGS) $(ALL_CPPFLAGS) \ -+ $(CC) -c $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(ESPF_NOSSP_CFLAGS)\ - $(out_file) $(OUTPUT_OPTION) - - # Build auxiliary files that support ecoff format. -diff -Nur gcc-4.4.0_vanilla/gcc/opts.c gcc-4.4.0/gcc/opts.c ---- gcc-4.4.0_vanilla/gcc/opts.c 2009-03-28 18:28:45.000000000 +0100 -+++ gcc-4.4.0/gcc/opts.c 2009-07-11 12:36:31.000000000 +0200 -@@ -897,7 +897,9 @@ - #endif - flag_regmove = opt2; - flag_strict_aliasing = opt2; -+#ifndef ENABLE_ESPF - flag_strict_overflow = opt2; -+#endif - flag_delete_null_pointer_checks = opt2; - flag_reorder_blocks = opt2; - flag_reorder_functions = opt2; -diff -Nur gcc-4.4.0_vanilla/gcc/varasm.c gcc-4.4.0/gcc/varasm.c ---- gcc-4.4.0_vanilla/gcc/varasm.c 2009-03-17 21:18:21.000000000 +0100 -+++ gcc-4.4.0/gcc/varasm.c 2009-07-11 12:36:25.000000000 +0200 -@@ -5607,7 +5607,11 @@ - bool is_local; - - is_local = targetm.binds_local_p (decl); -- if (!flag_shlib) -+ #ifdef ENABLE_ESPF -+ if (!flag_pic) -+ #else -+ if (!flag_shlib) -+ #endif - { - if (is_local) - kind = TLS_MODEL_LOCAL_EXEC; diff --git a/pkgs/core/gcc/patches/gcc-4.4.3-espf-0.3.7.patch b/pkgs/core/gcc/patches/gcc-4.4.3-espf-0.3.7.patch new file mode 100644 index 0000000..c92951d --- /dev/null +++ b/pkgs/core/gcc/patches/gcc-4.4.3-espf-0.3.7.patch @@ -0,0 +1,1012 @@ +diff -Nur gcc-4.4.3.vanilla/configure gcc-4.4.3/configure +--- gcc-4.4.3.vanilla/configure 2009-04-25 06:10:29.000000000 +0200 ++++ gcc-4.4.3/configure 2010-03-21 16:37:45.000000000 +0100 +@@ -272,7 +272,7 @@ + PACKAGE_BUGREPORT= + + ac_unique_file="move-if-change" +-ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS TOPLEVEL_CONFIGURE_ARGUMENTS build build_cpu build_vendor build_os build_noncanonical host_noncanonical target_noncanonical host host_cpu host_vendor host_os target target_cpu target_vendor target_os INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA LN LN_S build_libsubdir build_subdir host_subdir target_subdir CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT CXX CXXFLAGS ac_ct_CXX GNATBIND ac_ct_GNATBIND GNATMAKE ac_ct_GNATMAKE do_compare gmplibs gmpinc extra_mpfr_configure_flags ppllibs pplinc clooglibs clooginc stage1_languages SYSROOT_CFLAGS_FOR_TARGET DEBUG_PREFIX_CFLAGS_FOR_TARGET CFLAGS_FOR_TARGET CXXFLAGS_FOR_TARGET RPATH_ENVVAR GCC_SHLIB_SUBDIR tooldir build_tooldir CONFIGURE_GDB_TK GDB_TK INSTALL_GDB_TK build_configargs build_configdirs host_configargs configdirs target_configargs AR_FOR_BUILD AS_FOR_BUILD CC_FOR_BUILD CFLAGS_FOR_BUILD CXXFLAGS_FOR_BUILD CXX_FOR_BUILD DLLTOOL_FOR_BUILD GCJ_FOR_BUILD GFORTRAN_FOR_BUILD LDFLAGS_FOR_BUILD LD_FOR_BUILD NM_FOR_BUILD RANLIB_FOR_BUILD WINDMC_FOR_BUILD WINDRES_FOR_BUILD config_shell YACC BISON M4 LEX FLEX MAKEINFO EXPECT RUNTEST AR AS DLLTOOL LD LIPO NM RANLIB STRIP WINDRES WINDMC OBJCOPY OBJDUMP CC_FOR_TARGET CXX_FOR_TARGET GCC_FOR_TARGET GCJ_FOR_TARGET GFORTRAN_FOR_TARGET AR_FOR_TARGET AS_FOR_TARGET DLLTOOL_FOR_TARGET LD_FOR_TARGET LIPO_FOR_TARGET NM_FOR_TARGET OBJDUMP_FOR_TARGET RANLIB_FOR_TARGET STRIP_FOR_TARGET WINDRES_FOR_TARGET WINDMC_FOR_TARGET RAW_CXX_FOR_TARGET FLAGS_FOR_TARGET COMPILER_AS_FOR_TARGET COMPILER_LD_FOR_TARGET COMPILER_NM_FOR_TARGET MAINTAINER_MODE_TRUE MAINTAINER_MODE_FALSE MAINT stage1_cflags stage1_checking stage2_werror_flag datarootdir docdir pdfdir htmldir LIBOBJS LTLIBOBJS' ++ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS TOPLEVEL_CONFIGURE_ARGUMENTS build build_cpu build_vendor build_os build_noncanonical host_noncanonical target_noncanonical host host_cpu host_vendor host_os target target_cpu target_vendor target_os INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA LN LN_S build_libsubdir build_subdir host_subdir target_subdir enable_espf CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT CXX CXXFLAGS ac_ct_CXX GNATBIND ac_ct_GNATBIND GNATMAKE ac_ct_GNATMAKE do_compare gmplibs gmpinc extra_mpfr_configure_flags ppllibs pplinc clooglibs clooginc stage1_languages SYSROOT_CFLAGS_FOR_TARGET DEBUG_PREFIX_CFLAGS_FOR_TARGET CFLAGS_FOR_TARGET CXXFLAGS_FOR_TARGET RPATH_ENVVAR GCC_SHLIB_SUBDIR tooldir build_tooldir CONFIGURE_GDB_TK GDB_TK INSTALL_GDB_TK build_configargs build_configdirs host_configargs configdirs target_configargs AR_FOR_BUILD AS_FOR_BUILD CC_FOR_BUILD CFLAGS_FOR_BUILD CXXFLAGS_FOR_BUILD CXX_FOR_BUILD DLLTOOL_FOR_BUILD GCJ_FOR_BUILD GFORTRAN_FOR_BUILD LDFLAGS_FOR_BUILD LD_FOR_BUILD NM_FOR_BUILD RANLIB_FOR_BUILD WINDMC_FOR_BUILD WINDRES_FOR_BUILD config_shell YACC BISON M4 LEX FLEX MAKEINFO EXPECT RUNTEST AR AS DLLTOOL LD LIPO NM RANLIB STRIP WINDRES WINDMC OBJCOPY OBJDUMP CC_FOR_TARGET CXX_FOR_TARGET GCC_FOR_TARGET GCJ_FOR_TARGET GFORTRAN_FOR_TARGET AR_FOR_TARGET AS_FOR_TARGET DLLTOOL_FOR_TARGET LD_FOR_TARGET LIPO_FOR_TARGET NM_FOR_TARGET OBJDUMP_FOR_TARGET RANLIB_FOR_TARGET STRIP_FOR_TARGET WINDRES_FOR_TARGET WINDMC_FOR_TARGET RAW_CXX_FOR_TARGET FLAGS_FOR_TARGET COMPILER_AS_FOR_TARGET COMPILER_LD_FOR_TARGET COMPILER_NM_FOR_TARGET MAINTAINER_MODE_TRUE MAINTAINER_MODE_FALSE MAINT stage1_cflags stage1_checking stage2_werror_flag datarootdir docdir pdfdir htmldir LIBOBJS LTLIBOBJS' + ac_subst_files='serialization_dependencies host_makefile_frag target_makefile_frag alphaieee_frag ospace_frag' + ac_pwd=`pwd` + +@@ -934,6 +934,11 @@ + --enable-FEATURE[=ARG] include FEATURE [ARG=yes] + --enable-gold use gold instead of ld + --enable-libada build libada directory ++ --enable-espf ++ Enable Stack protector, Position independent executable and ++ Fortify_sources as default if we have suppot for it when compiling ++ and link with -z relro and -z now as default. ++ Linux targets supported i*86, x86_64, powerpc*, ia64 and arm* + --enable-libssp build libssp directory + --disable-ppl-version-check disable check for PPL version + --disable-cloog-version-check disable check for CLooG version +@@ -2145,6 +2150,25 @@ + noconfigdirs="$noconfigdirs gnattools" + fi + ++# Check whether --enable-espf was given and target have the support. ++# Check whether --enable-espf or --disable-espf was given. ++if test "${enable_espf+set}" = set; then ++ enableval="$enable_espf" ++ ++ case $target in ++ i?86*-*-linux* | x86_64*-*-linux* | powerpc-*-linux* | powerpc64-*-linux* | arm*-*-linux* | ia64-*-linux*) ++ enable_espf=yes ++ ;; ++ *) ++ { { echo "$as_me:$LINENO: error: *** --enable-espf is not supported on this $target target." >&5 ++echo "$as_me: error: *** --enable-espf is not supported on this $target target." >&2;} ++ { (exit 1); exit 1; }; } ++ ;; ++ esac ++ ++fi; ++ ++ + # Check whether --enable-libssp or --disable-libssp was given. + if test "${enable_libssp+set}" = set; then + enableval="$enable_libssp" +@@ -12433,6 +12457,9 @@ + *) stage1_cflags="-g -J" ;; + esac ;; + esac ++if test x$enable_espf = xyes; then ++ stage1_cflags="$stage1_cflags -fno-stack-protector" ++fi + + # This is aimed to mimic bootstrap with a non-GCC compiler to catch problems. + if test "$GCC" = yes; then +@@ -13236,6 +13263,7 @@ + s,@build_subdir@,$build_subdir,;t t + s,@host_subdir@,$host_subdir,;t t + s,@target_subdir@,$target_subdir,;t t ++s,@enable_espf@,$enable_espf,;t t + s,@CC@,$CC,;t t + s,@CFLAGS@,$CFLAGS,;t t + s,@LDFLAGS@,$LDFLAGS,;t t +diff -Nur gcc-4.4.3.vanilla/gcc/config/i386/linux64.h gcc-4.4.3/gcc/config/i386/linux64.h +--- gcc-4.4.3.vanilla/gcc/config/i386/linux64.h 2009-04-10 01:23:07.000000000 +0200 ++++ gcc-4.4.3/gcc/config/i386/linux64.h 2010-03-21 16:37:45.000000000 +0100 +@@ -113,7 +113,7 @@ + /* This macro may be overridden in i386/k*bsd-gnu.h. */ + #define REG_NAME(reg) reg + +-#ifdef TARGET_LIBC_PROVIDES_SSP ++#if defined TARGET_LIBC_PROVIDES_SSP && !defined __UCLIBC__ + /* i386 glibc provides __stack_chk_guard in %gs:0x14, + x86_64 glibc provides it in %fs:0x28. */ + #define TARGET_THREAD_SSP_OFFSET (TARGET_64BIT ? 0x28 : 0x14) +diff -Nur gcc-4.4.3.vanilla/gcc/config/i386/linux.h gcc-4.4.3/gcc/config/i386/linux.h +--- gcc-4.4.3.vanilla/gcc/config/i386/linux.h 2009-05-21 15:21:30.000000000 +0200 ++++ gcc-4.4.3/gcc/config/i386/linux.h 2010-03-21 16:37:45.000000000 +0100 +@@ -210,7 +210,7 @@ + /* This macro may be overridden in i386/k*bsd-gnu.h. */ + #define REG_NAME(reg) reg + +-#ifdef TARGET_LIBC_PROVIDES_SSP ++#if defined TARGET_LIBC_PROVIDES_SSP && !defined __UCLIBC__ + /* i386 glibc provides __stack_chk_guard in %gs:0x14. */ + #define TARGET_THREAD_SSP_OFFSET 0x14 + #endif +diff -Nur gcc-4.4.3.vanilla/gcc/config/linux.h gcc-4.4.3/gcc/config/linux.h +--- gcc-4.4.3.vanilla/gcc/config/linux.h 2009-04-10 01:23:07.000000000 +0200 ++++ gcc-4.4.3/gcc/config/linux.h 2010-03-21 16:37:45.000000000 +0100 +@@ -43,7 +43,11 @@ + object constructed before entering `main'. */ + + #undef STARTFILE_SPEC +-#if defined HAVE_LD_PIE ++#if defined (HAVE_LD_PIE) && defined (ENABLE_CRTBEGINTS) ++#define STARTFILE_SPEC \ ++ "%{!shared: %{pg|p|profile:gcrt1.o%s;pie:Scrt1.o%s;:crt1.o%s}} crti.o%s \ ++ %{static:%{pie:crtbeginTS.o%s;:crtbeginT.o%s}} %{!static:%{shared|pie:crtbeginS.o%s;:crtbegin.o%s}}" ++#elif defined (HAVE_LD_PIE) && ! defined (ENABLE_CRTBEGINTS) + #define STARTFILE_SPEC \ + "%{!shared: %{pg|p|profile:gcrt1.o%s;pie:Scrt1.o%s;:crt1.o%s}} \ + crti.o%s %{static:crtbeginT.o%s;shared|pie:crtbeginS.o%s;:crtbegin.o%s}" +diff -Nur gcc-4.4.3.vanilla/gcc/config/rs6000/linux64.h gcc-4.4.3/gcc/config/rs6000/linux64.h +--- gcc-4.4.3.vanilla/gcc/config/rs6000/linux64.h 2009-04-10 01:23:07.000000000 +0200 ++++ gcc-4.4.3/gcc/config/rs6000/linux64.h 2010-03-21 16:37:45.000000000 +0100 +@@ -156,7 +156,7 @@ + #endif + + #define ASM_SPEC32 "-a32 %{n} %{T} %{Ym,*} %{Yd,*} \ +-%{mrelocatable} %{mrelocatable-lib} %{fpic:-K PIC} %{fPIC:-K PIC} \ ++%{mrelocatable} %{mrelocatable-lib} %{fpic|fPIC|fpie|fPIE:-K PIC} \ + %{memb} %{!memb: %{msdata: -memb} %{msdata=eabi: -memb}} \ + %{!mlittle: %{!mlittle-endian: %{!mbig: %{!mbig-endian: \ + %{mcall-freebsd: -mbig} \ +@@ -520,7 +520,7 @@ + + #define MD_UNWIND_SUPPORT "config/rs6000/linux-unwind.h" + +-#ifdef TARGET_LIBC_PROVIDES_SSP ++#if defined TARGET_LIBC_PROVIDES_SSP && !defined __UCLIBC__ + /* ppc32 glibc provides __stack_chk_guard in -0x7008(2), + ppc64 glibc provides it at -0x7010(13). */ + #define TARGET_THREAD_SSP_OFFSET (TARGET_64BIT ? -0x7010 : -0x7008) +diff -Nur gcc-4.4.3.vanilla/gcc/config/rs6000/linux.h gcc-4.4.3/gcc/config/rs6000/linux.h +--- gcc-4.4.3.vanilla/gcc/config/rs6000/linux.h 2007-08-02 12:49:31.000000000 +0200 ++++ gcc-4.4.3/gcc/config/rs6000/linux.h 2010-03-21 16:37:45.000000000 +0100 +@@ -117,7 +117,7 @@ + + #define MD_UNWIND_SUPPORT "config/rs6000/linux-unwind.h" + +-#ifdef TARGET_LIBC_PROVIDES_SSP ++#if defined TARGET_LIBC_PROVIDES_SSP && !defined __UCLIBC__ + /* ppc32 glibc provides __stack_chk_guard in -0x7008(2). */ + #define TARGET_THREAD_SSP_OFFSET -0x7008 + #endif +diff -Nur gcc-4.4.3.vanilla/gcc/config/rs6000/sysv4.h gcc-4.4.3/gcc/config/rs6000/sysv4.h +--- gcc-4.4.3.vanilla/gcc/config/rs6000/sysv4.h 2009-04-10 01:23:07.000000000 +0200 ++++ gcc-4.4.3/gcc/config/rs6000/sysv4.h 2010-03-21 16:37:45.000000000 +0100 +@@ -883,7 +883,12 @@ + %{!mnewlib: %{pthread:-lpthread} %{shared:-lc} \ + %{!shared: %{profile:-lc_p} %{!profile:-lc}}}" + +-#ifdef HAVE_LD_PIE ++#if defined (HAVE_LD_PIE) && defined (ENABLE_CRTBEGINTS) ++#define STARTFILE_LINUX_SPEC \ ++ "%{!shared: %{pg|p|profile:gcrt1.o%s;pie:Scrt1.o%s;:crt1.o%s}} \ ++ %{mnewlib:ecrti.o%s;:crti.o%s} \ ++ {static:%{pie:crtbeginTS.o%s;:crtbeginT.o%s}} %{!static:%{shared|pie:crtbeginS.o%s;:crtbegin.o%s}}" ++#elif defined (HAVE_LD_PIE) && ! defined (ENABLE_CRTBEGINTS) + #define STARTFILE_LINUX_SPEC "\ + %{!shared: %{pg|p|profile:gcrt1.o%s;pie:Scrt1.o%s;:crt1.o%s}} \ + %{mnewlib:ecrti.o%s;:crti.o%s} \ +diff -Nur gcc-4.4.3.vanilla/gcc/config/s390/linux.h gcc-4.4.3/gcc/config/s390/linux.h +--- gcc-4.4.3.vanilla/gcc/config/s390/linux.h 2007-08-02 12:49:31.000000000 +0200 ++++ gcc-4.4.3/gcc/config/s390/linux.h 2010-03-21 16:37:45.000000000 +0100 +@@ -93,7 +93,7 @@ + + #define MD_UNWIND_SUPPORT "config/s390/linux-unwind.h" + +-#ifdef TARGET_LIBC_PROVIDES_SSP ++#if defined TARGET_LIBC_PROVIDES_SSP && !defined __UCLIBC__ + /* s390 glibc provides __stack_chk_guard in 0x14(tp), + s390x glibc provides it at 0x28(tp). */ + #define TARGET_THREAD_SSP_OFFSET (TARGET_64BIT ? 0x28 : 0x14) +diff -Nur gcc-4.4.3.vanilla/gcc/config/sparc/linux64.h gcc-4.4.3/gcc/config/sparc/linux64.h +--- gcc-4.4.3.vanilla/gcc/config/sparc/linux64.h 2009-02-20 16:20:38.000000000 +0100 ++++ gcc-4.4.3/gcc/config/sparc/linux64.h 2010-03-21 16:37:45.000000000 +0100 +@@ -297,7 +297,7 @@ + #undef NEED_INDICATE_EXEC_STACK + #define NEED_INDICATE_EXEC_STACK 1 + +-#ifdef TARGET_LIBC_PROVIDES_SSP ++#if defined TARGET_LIBC_PROVIDES_SSP && !defined __UCLIBC__ + /* sparc glibc provides __stack_chk_guard in [%g7 + 0x14], + sparc64 glibc provides it at [%g7 + 0x28]. */ + #define TARGET_THREAD_SSP_OFFSET (TARGET_ARCH64 ? 0x28 : 0x14) +diff -Nur gcc-4.4.3.vanilla/gcc/config/sparc/linux.h gcc-4.4.3/gcc/config/sparc/linux.h +--- gcc-4.4.3.vanilla/gcc/config/sparc/linux.h 2009-02-20 16:20:38.000000000 +0100 ++++ gcc-4.4.3/gcc/config/sparc/linux.h 2010-03-21 16:37:45.000000000 +0100 +@@ -164,7 +164,7 @@ + #undef NEED_INDICATE_EXEC_STACK + #define NEED_INDICATE_EXEC_STACK 1 + +-#ifdef TARGET_LIBC_PROVIDES_SSP ++#if defined TARGET_LIBC_PROVIDES_SSP && !defined __UCLIBC__ + /* sparc glibc provides __stack_chk_guard in [%g7 + 0x14]. */ + #define TARGET_THREAD_SSP_OFFSET 0x14 + #endif +diff -Nur gcc-4.4.3.vanilla/gcc/config.in gcc-4.4.3/gcc/config.in +--- gcc-4.4.3.vanilla/gcc/config.in 2010-01-21 11:29:37.000000000 +0100 ++++ gcc-4.4.3/gcc/config.in 2010-03-21 16:37:45.000000000 +0100 +@@ -46,6 +46,12 @@ + #endif + + ++/* Define to 1 to enable crtbeginTS.o. */ ++#ifndef USED_FOR_TARGET ++#undef ENABLE_CRTBEGINTS ++#endif ++ ++ + /* Define to 1 to specify that we are using the BID decimal floating point + format instead of DPD */ + #ifndef USED_FOR_TARGET +@@ -65,6 +71,12 @@ + #endif + + ++/* Define to 1 to enable espf. */ ++#ifndef USED_FOR_TARGET ++#undef ENABLE_ESPF ++#endif ++ ++ + /* Define to 1 to enable fixed-point arithmetic extension to C. */ + #ifndef USED_FOR_TARGET + #undef ENABLE_FIXED_POINT +diff -Nur gcc-4.4.3.vanilla/gcc/configure gcc-4.4.3/gcc/configure +--- gcc-4.4.3.vanilla/gcc/configure 2009-10-19 14:15:27.000000000 +0200 ++++ gcc-4.4.3/gcc/configure 2010-03-21 16:37:45.000000000 +0100 +@@ -458,7 +458,7 @@ + # include <unistd.h> + #endif" + +-ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS build build_cpu build_vendor build_os host host_cpu host_vendor host_os target target_cpu target_vendor target_os target_noncanonical build_libsubdir build_subdir host_subdir target_subdir GENINSRC CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT GNATBIND ac_ct_GNATBIND GNATMAKE ac_ct_GNATMAKE NO_MINUS_C_MINUS_O OUTPUT_OPTION CPP EGREP loose_warn strict_warn warn_cflags nocommon_flag TREEBROWSER valgrind_path valgrind_path_defines valgrind_command coverage_flags enable_multilib enable_decimal_float enable_fixed_point enable_shared TARGET_SYSTEM_ROOT TARGET_SYSTEM_ROOT_DEFINE CROSS_SYSTEM_HEADER_DIR onestep PKGVERSION REPORT_BUGS_TO REPORT_BUGS_TEXI datarootdir docdir htmldir SET_MAKE AWK LN_S LN RANLIB ac_ct_RANLIB ranlib_flags INSTALL INSTALL_PROGRAM INSTALL_DATA make_compare_target have_mktemp_command MAKEINFO BUILD_INFO GENERATED_MANPAGES FLEX BISON NM AR COLLECT2_LIBS GNAT_LIBEXC LDEXP_LIB TARGET_GETGROUPS_T LIBICONV LTLIBICONV LIBICONV_DEP manext objext gthread_flags extra_modes_file extra_opt_files USE_NLS LIBINTL LIBINTL_DEP INCINTL XGETTEXT GMSGFMT POSUB CATALOGS DATADIRNAME INSTOBJEXT GENCAT CATOBJEXT CROSS ALL SYSTEM_HEADER_DIR inhibit_libc CC_FOR_BUILD BUILD_CFLAGS BUILD_LDFLAGS STMP_FIXINC STMP_FIXPROTO collect2 LIBTOOL SED FGREP GREP LD DUMPBIN ac_ct_DUMPBIN OBJDUMP ac_ct_OBJDUMP ac_ct_AR STRIP ac_ct_STRIP lt_ECHO DSYMUTIL ac_ct_DSYMUTIL NMEDIT ac_ct_NMEDIT LIPO ac_ct_LIPO OTOOL ac_ct_OTOOL OTOOL64 ac_ct_OTOOL64 objdir enable_fast_install gcc_cv_as ORIGINAL_AS_FOR_TARGET gcc_cv_ld ORIGINAL_LD_FOR_TARGET gcc_cv_nm ORIGINAL_NM_FOR_TARGET gcc_cv_objdump gcc_cv_readelf libgcc_visibility GGC zlibdir zlibinc MAINT gcc_tooldir dollar slibdir subdirs srcdir all_compilers all_gtfiles all_lang_makefrags all_lang_makefiles all_languages all_selected_languages build_exeext build_install_headers_dir build_xm_file_list build_xm_include_list build_xm_defines build_file_translate check_languages cpp_install_dir xmake_file tmake_file extra_gcc_objs extra_headers_list extra_objs extra_parts extra_passes extra_programs float_h_file gcc_config_arguments gcc_gxx_include_dir host_exeext host_xm_file_list host_xm_include_list host_xm_defines out_host_hook_obj install lang_opt_files lang_specs_files lang_tree_files local_prefix md_file objc_boehm_gc out_file out_object_file thread_file tm_file_list tm_include_list tm_defines tm_p_file_list tm_p_include_list xm_file_list xm_include_list xm_defines c_target_objs cxx_target_objs fortran_target_objs target_cpu_default GMPLIBS GMPINC PPLLIBS PPLINC CLOOGLIBS CLOOGINC LIBOBJS LTLIBOBJS' ++ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS build build_cpu build_vendor build_os host host_cpu host_vendor host_os target target_cpu target_vendor target_os target_noncanonical build_libsubdir build_subdir host_subdir target_subdir GENINSRC CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT GNATBIND ac_ct_GNATBIND GNATMAKE ac_ct_GNATMAKE NO_MINUS_C_MINUS_O OUTPUT_OPTION CPP EGREP loose_warn strict_warn warn_cflags nocommon_flag TREEBROWSER valgrind_path valgrind_path_defines valgrind_command coverage_flags enable_multilib enable_decimal_float enable_fixed_point enable_shared TARGET_SYSTEM_ROOT TARGET_SYSTEM_ROOT_DEFINE CROSS_SYSTEM_HEADER_DIR onestep PKGVERSION REPORT_BUGS_TO REPORT_BUGS_TEXI datarootdir docdir htmldir SET_MAKE AWK LN_S LN RANLIB ac_ct_RANLIB ranlib_flags INSTALL INSTALL_PROGRAM INSTALL_DATA make_compare_target have_mktemp_command MAKEINFO BUILD_INFO GENERATED_MANPAGES FLEX BISON NM AR COLLECT2_LIBS GNAT_LIBEXC LDEXP_LIB TARGET_GETGROUPS_T LIBICONV LTLIBICONV LIBICONV_DEP manext objext gthread_flags extra_modes_file extra_opt_files USE_NLS LIBINTL LIBINTL_DEP INCINTL XGETTEXT GMSGFMT POSUB CATALOGS DATADIRNAME INSTOBJEXT GENCAT CATOBJEXT CROSS ALL SYSTEM_HEADER_DIR inhibit_libc CC_FOR_BUILD BUILD_CFLAGS BUILD_LDFLAGS STMP_FIXINC STMP_FIXPROTO collect2 LIBTOOL SED FGREP GREP LD DUMPBIN ac_ct_DUMPBIN OBJDUMP ac_ct_OBJDUMP ac_ct_AR STRIP ac_ct_STRIP lt_ECHO DSYMUTIL ac_ct_DSYMUTIL NMEDIT ac_ct_NMEDIT LIPO ac_ct_LIPO OTOOL ac_ct_OTOOL OTOOL64 ac_ct_OTOOL64 objdir enable_fast_install gcc_cv_as ORIGINAL_AS_FOR_TARGET gcc_cv_ld ORIGINAL_LD_FOR_TARGET gcc_cv_nm ORIGINAL_NM_FOR_TARGET gcc_cv_objdump gcc_cv_readelf libgcc_visibility enable_espf enable_crtbeginTS GGC zlibdir zlibinc MAINT gcc_tooldir dollar slibdir subdirs srcdir all_compilers all_gtfiles all_lang_makefrags all_lang_makefiles all_languages all_selected_languages build_exeext build_install_headers_dir build_xm_file_list build_xm_include_list build_xm_defines build_file_translate check_languages cpp_install_dir xmake_file tmake_file extra_gcc_objs extra_headers_list extra_objs extra_parts extra_passes extra_programs float_h_file gcc_config_arguments gcc_gxx_include_dir host_exeext host_xm_file_list host_xm_include_list host_xm_defines out_host_hook_obj install lang_opt_files lang_specs_files lang_tree_files local_prefix md_file objc_boehm_gc out_file out_object_file thread_file tm_file_list tm_include_list tm_defines tm_p_file_list tm_p_include_list xm_file_list xm_include_list xm_defines c_target_objs cxx_target_objs fortran_target_objs target_cpu_default GMPLIBS GMPINC PPLLIBS PPLINC CLOOGLIBS CLOOGINC LIBOBJS LTLIBOBJS' + ac_subst_files='language_hooks' + ac_pwd=`pwd` + +@@ -24213,6 +24213,50 @@ + ;; + esac + ++echo "$as_me:$LINENO: checking linker -z now support" >&5 ++echo $ECHO_N "checking linker -z now support... $ECHO_C" >&6 ++if test "${gcc_cv_ld_now+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ gcc_cv_ld_now=no ++if test $in_tree_ld = yes ; then ++ if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 16 -o "$gcc_cv_gld_major_version" -gt 2 \ ++ && test $in_tree_ld_is_elf = yes; then ++ gcc_cv_ld_now=yes ++ fi ++elif test x$gcc_cv_ld != x; then ++ # Check if linker supports -z now options ++ if $gcc_cv_ld --help 2>/dev/null | grep now > /dev/null; then ++ gcc_cv_ld_now=yes ++ fi ++fi ++ ++fi ++echo "$as_me:$LINENO: result: $gcc_cv_ld_now" >&5 ++echo "${ECHO_T}$gcc_cv_ld_now" >&6 ++ ++echo "$as_me:$LINENO: checking linker -z relro support" >&5 ++echo $ECHO_N "checking linker -z relro support... $ECHO_C" >&6 ++if test "${gcc_cv_ld_relro+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ gcc_cv_ld_relro=no ++if test $in_tree_ld = yes ; then ++ if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 16 -o "$gcc_cv_gld_major_version" -gt 2 \ ++ && test $in_tree_ld_is_elf = yes; then ++ gcc_cv_ld_relro=yes ++ fi ++elif test x$gcc_cv_ld != x; then ++ # Check if linker supports -z relro and -z norelro options ++ if $gcc_cv_ld --help 2>/dev/null | grep relro > /dev/null; then ++ gcc_cv_ld_relro=yes ++ fi ++fi ++ ++fi ++echo "$as_me:$LINENO: result: $gcc_cv_ld_relro" >&5 ++echo "${ECHO_T}$gcc_cv_ld_relro" >&6 ++ + echo "$as_me:$LINENO: checking linker --sysroot support" >&5 + echo $ECHO_N "checking linker --sysroot support... $ECHO_C" >&6 + if test "${gcc_cv_ld_sysroot+set}" = set; then +@@ -24411,6 +24455,66 @@ + + fi + ++if test x$enable_espf = xyes; then ++ case $target in ++ ia64*-*-linux*) ++ if test x$gcc_cv_ld_now = xyes; then ++ enable_espf_ld=yes ++ else ++ enable_espf_ld=no ++ fi ++ ;; ++ *-*-linux*) ++ if test x$gcc_cv_ld_relro = xyes && test x$gcc_cv_ld_now = xyes; then ++ enable_espf_ld=yes ++ else ++ enable_espf_ld=no ++ fi ++ ;; ++ *) ++ enable_espf_ld=no ++ ;; ++ esac ++else ++ enable_espf_ld=no ++fi ++if test x$enable_espf_ld = xyes; then ++cat >>confdefs.h <<_ACEOF ++#define ENABLE_ESPF 1 ++_ACEOF ++fi ++if test x$enable_espf = xyes && test x$enable_espf_ld = xno; then ++ { { echo "$as_me:$LINENO: error: *** --enable-espf Need a linker that support -z now and -z relro." >&5 ++echo "$as_me: error: *** --enable-espf Need a linker that support -z now and -z relro." >&2;} ++ { (exit 1); exit 1; }; } ++fi ++ ++echo "$as_me:$LINENO: checking for crtbeginTS.o support" >&5 ++echo $ECHO_N "checking for crtbeginTS.o support... $ECHO_C" >&6 ++if test "${enable_crtbeginTS+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ enable_crtbeginTS=no ++ case "$target" in ++ ia64*-*-linux*) ++ enable_crtbeginTS=no ;; ++ *-*-linux*) ++ if test x$enable_espf = xyes && test x$gcc_cv_ld_pie = xyes && test x$lt_cv_prog_compiler_static_works = xyes; then ++ enable_crtbeginTS=yes ++ fi ++ ;; ++ *) enable_crtbeginTS=no ;; ++ esac ++fi ++echo "$as_me:$LINENO: result: $enable_crtbeginTS" >&5 ++echo "${ECHO_T}$enable_crtbeginTS" >&6 ++ ++if test x$enable_crtbeginTS = xyes; then ++cat >>confdefs.h <<_ACEOF ++#define ENABLE_CRTBEGINTS 1 ++_ACEOF ++fi ++ + # Check if TFmode long double should be used by default or not. + # Some glibc targets used DFmode long double, but with glibc 2.4 + # and later they can use TFmode. +@@ -25617,6 +25721,8 @@ + s,@gcc_cv_objdump@,$gcc_cv_objdump,;t t + s,@gcc_cv_readelf@,$gcc_cv_readelf,;t t + s,@libgcc_visibility@,$libgcc_visibility,;t t ++s,@enable_espf@,$enable_espf,;t t ++s,@enable_crtbeginTS@,$enable_crtbeginTS,;t t + s,@GGC@,$GGC,;t t + s,@zlibdir@,$zlibdir,;t t + s,@zlibinc@,$zlibinc,;t t +diff -Nur gcc-4.4.3.vanilla/gcc/cp/lang-specs.h gcc-4.4.3/gcc/cp/lang-specs.h +--- gcc-4.4.3.vanilla/gcc/cp/lang-specs.h 2007-08-06 13:10:19.000000000 +0200 ++++ gcc-4.4.3/gcc/cp/lang-specs.h 2010-03-21 16:37:45.000000000 +0100 +@@ -47,7 +47,7 @@ + %(cpp_options) %2 -o %{save-temps:%b.ii} %{!save-temps:%g.ii} \n}\ + cc1plus %{save-temps|no-integrated-cpp:-fpreprocessed %{save-temps:%b.ii} %{!save-temps:%g.ii}}\ + %{!save-temps:%{!no-integrated-cpp:%(cpp_unique_options)}}\ +- %(cc1_options) %2 %{+e1*}\ ++ %(cc1_options) %(espf_options) %2 %{+e1*}\ + %{!fsyntax-only:-o %g.s %{!o*:--output-pch=%i.gch} %W{o*:--output-pch=%*}%V}}}}", + CPLUSPLUS_CPP_SPEC, 0, 0}, + {"@c++", +@@ -57,11 +57,11 @@ + %(cpp_options) %2 -o %{save-temps:%b.ii} %{!save-temps:%g.ii} \n}\ + cc1plus %{save-temps|no-integrated-cpp:-fpreprocessed %{save-temps:%b.ii} %{!save-temps:%g.ii}}\ + %{!save-temps:%{!no-integrated-cpp:%(cpp_unique_options)}}\ +- %(cc1_options) %2 %{+e1*}\ ++ %(cc1_options) %(espf_options) %2 %{+e1*}\ + %{!fsyntax-only:%(invoke_as)}}}}", + CPLUSPLUS_CPP_SPEC, 0, 0}, + {".ii", "@c++-cpp-output", 0, 0, 0}, + {"@c++-cpp-output", + "%{!M:%{!MM:%{!E:\ +- cc1plus -fpreprocessed %i %(cc1_options) %2 %{+e*}\ ++ cc1plus -fpreprocessed %i %(cc1_options) %(espf_options) %2 %{+e*}\ + %{!fsyntax-only:%(invoke_as)}}}}", 0, 0, 0}, +diff -Nur gcc-4.4.3.vanilla/gcc/doc/invoke.texi gcc-4.4.3/gcc/doc/invoke.texi +--- gcc-4.4.3.vanilla/gcc/doc/invoke.texi 2009-10-21 17:44:23.000000000 +0200 ++++ gcc-4.4.3/gcc/doc/invoke.texi 2010-03-21 16:37:45.000000000 +0100 +@@ -7155,6 +7155,11 @@ + @opindex fstack-protector-all + Like @option{-fstack-protector} except that all functions are protected. + ++NOTE: When --enable-espf this option is enabled by default ++for C, C++, ObjC, ObjC++, if neither @option{-fno-stack-protector} ++or @option{-nostdlib} or @option{-nodefaultlibs} or ++@option{-fstack-protector} are found. ++ + @item -fsection-anchors + @opindex fsection-anchors + Try to reduce the number of symbolic address calculations by using +@@ -7982,6 +7987,12 @@ + that were used to generate code (@option{-fpie}, @option{-fPIE}, + or model suboptions) when you specify this option. + ++NOTE: When --enable-espf this option is enabled by default ++for C, C++, ObjC, ObjC++, if neither @option{-fno-pie} or @option{-fno-PIE} ++or @option{-fno-pic} or @option{-fno-PIC} or @option{-nostdlib} or ++@option{-nostartfiles} or @option{-shared} or @option{-pg} or @option{-p} ++are found. ++ + @item -rdynamic + @opindex rdynamic + Pass the flag @option{-export-dynamic} to the ELF linker, on targets +@@ -15906,6 +15917,11 @@ + @code{__pie__} and @code{__PIE__}. The macros have the value 1 + for @option{-fpie} and 2 for @option{-fPIE}. + ++NOTE: When --enable-espf this option is enabled by default ++for C, C++, ObjC, ObjC++, if neither @option{-fno-pie} or @option{-fno-PIE} ++or @option{-fno-pic} or @option{-fno-PIC} or @option{-nostdlib} or ++@option{-nostartfiles} or @option{-shared} are found. ++ + @item -fno-jump-tables + @opindex fno-jump-tables + Do not use jump tables for switch statements even where it would be +diff -Nur gcc-4.4.3.vanilla/gcc/espf.h gcc-4.4.3/gcc/espf.h +--- gcc-4.4.3.vanilla/gcc/espf.h 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-4.4.3/gcc/espf.h 2010-03-21 16:37:45.000000000 +0100 +@@ -0,0 +1,149 @@ ++/* Copyright (C) 2010 Gentoo Foundation Inc. ++ * License terms see GNU GENERAL PUBLIC LICENSE Version 3. ++ * Version 20100210.1 ++ * Magnus Granberg (Zorry) zorry@ume.nu */ ++#ifndef GCC_ESPF_H ++#define GCC_ESPF_H ++ ++/* This file will add -fstack-protector, -fPIE, -pie and -D_FORTIFY_SOURCES=2 ++ as default if the defines and the spec allow it. ++ ++ On Gentoo ++ Added a hack for gcc-specs-* in toolchain-funcs.eclass and _filter-hardened in flag-o-matic.eclass ++ to support older hardened GCC patches and we don't need to change the code on gcc-specs-* and _filter-hardened. ++ We use -fstack-protector-all instead of -fstack-protector ++ This will add some unsupported upstream commands options as -nopie. ++ -D__KERNEL__ is added so we don't have -fPIE and -fstack-protector-all when building kernels. ++ ESPF_CC1_SPEC is added to CC1_SPEC. ++ -D_FORTIFY_SOURCES=2 is added with gentoo's patchset as default so no need to set it hear. ++ ESPF_LINK_SPEC is added so we can disable -z now in -vanilla spec. ++ ESPF_CC1_STRICT_SPEC is added so we don't use gcc/opts.c to disable it. ++ ESPF_OPTIONS_PIE_CHECK_SPEC check for -pie, -p, -pg, -profile, -static and -shared. ++ ENABLE_CRTBEGINTS add support for crtbeginTS.o, build -static with -fPIE or -fpie. ++*/ ++#ifdef ENABLE_ESPF ++ ++ /* Hack to support gcc-specs-* in toolchain-funcs.eclass and _filter-hardened in flag-o-matic.eclass */ ++ /* IA64 arch don't support -fstack-protector* */ ++ #define ESPF_CC1_SPEC " %(espf_cc1_ssp) %(espf_cc1_pie) %(espf_cc1_strict)" ++ #ifndef __ia64 ++ #define ESPF_CC1_SSP_SPEC "%{!fno-stack-protector: %{!fno-stack-protector-all: }}" ++ #else ++ #define ESPF_CC1_SSP_SPEC "" ++ #endif ++ #define ESPF_CC1_PIE_SPEC "%{!nopie: }" ++ #define ESPF_CC1_STRICT_SPEC "%{!fstrict-overflow:%{!fno-strict-overflow: -fno-strict-overflow}}" ++ ++ /* ESPF_LINK_SPEC is added to case '%X': in do_spec_1() gcc/gcc.c ++ -z now will be added if we don't have -vanilla spec */ ++ #define ESPF_LINK_SPEC "%(espf_link_now)" ++ #define ESPF_LINK_NOW_SPEC "%{!now:-z now}" ++ /* ESPF_OPTIONS_SPEC is added to the compiler spec in gcc/gcc.c */ ++ ++ #define ESPF_OPTIONS_SPEC "%(espf_options_ssp)" ++ ++ /* ESPF_CPP_OPTIONS_SPEC is added to the cpp_options spec in gcc/gcc.c ++ For precompiling headers. */ ++ #define ESPF_CPP_OPTIONS_SPEC "%(espf_options_ssp)" ++ ++ /* This will add -fstack-protector-all if we don't have -nostdlib -nodefaultlibs -fno-stack-protector -fstack-protector ++ -fstack-protector-all and we have TARGET_LIBC_PROVIDES_SSP defined and not __ia64 defined. */ ++ /* IA64 arch don't support -fstack-protector* */ ++ #if defined (TARGET_LIBC_PROVIDES_SSP) && !defined (__ia64) ++ #define ESPF_OPTIONS_SSP_SPEC \ ++ "%{!D__KERNEL__:%{!nostdlib:%{!nodefaultlibs: %{!fno-stack-protector: \ ++ %{!fstack-protector:%{!fstack-protector-all:-fstack-protector-all}}}}}}" ++ #else ++ #define ESPF_OPTIONS_SSP_SPEC "" ++ #endif ++ ++ /* If HAVE_LD_PIE not defined we will not add any -fPIE -pie */ ++ #ifdef HAVE_LD_PIE ++ ++ /* We use ESPF_COMMAND_OPTIONS_SPEC to add pie command-line options. */ ++ #define ESPF_COMMAND_OPTIONS_SPEC "%{!D__KERNEL__:%{!nopie:%(espf_options_pie) %(espf_link_pie)}}" ++ ++ /* This will add -fPIE if we don't have -pie -fpic -fPIC -fpie -fPIE -fno-pic -fno-PIC -fno-pie -fno-PIE -shared -static ++ -nostdlib -nostartfiles. */ ++ /* With ENABLE_CRTBEGINTS we don't need to check for -static */ ++ #ifdef ENABLE_CRTBEGINTS ++ #define ESPF_OPTIONS_PIE_SPEC \ ++ "%{!pie: %{!fpic:%{!fPIC:%{!fpie:%{!fPIE: %{!fno-pic:%{!fno-PIC:%{!fno-pie:%{!fno-PIE: \ ++ %{!shared: %{!nostdlib: %{!nostartfiles:-fPIE}} } }}}} }}}} }" ++ #else ++ #define ESPF_OPTIONS_PIE_SPEC \ ++ "%{!pie: %{!fpic:%{!fPIC:%{!fpie:%{!fPIE: %{!fno-pic:%{!fno-PIC:%{!fno-pie:%{!fno-PIE: \ ++ %{!shared: %{!static: %{!nostdlib: %{!nostartfiles:-fPIE}} } }}}} }}}} }}" ++ #endif ++ ++ /* This will add -pie if we don't have -pie -A -fno-pic -fno-PIC -fno-pie -fno-PIE -shared -static -r -nostdlib ++ -nostartfiles */ ++ /* With ENABLE_CRTBEGINTS we don't need to check for -static ++ and we add -pie only to get the start and endfiles. -pie will not go to the linker. */ ++ #ifdef ENABLE_CRTBEGINTS ++ #define ESPF_LINK_PIE_SPEC \ ++ "%{!pie:%{!A:%{!fno-pie:%{!fno-PIE:%{!fno-pic:%{!fno-PIC:%{!shared:%{!r: \ ++ %{!nostdlib:%{!nostartfiles:-pie}}}}}}}}}}" ++ #else ++ #define ESPF_LINK_PIE_SPEC \ ++ "%{!pie:%{!A:%{!fno-pie:%{!fno-PIE:%{!fno-pic:%{!fno-PIC:%{!shared:%{!static:%{!r: \ ++ %{!nostdlib:%{!nostartfiles:-pie}}}}}}}}}}}" ++ #endif ++ ++ /* This will check if shared is set when -static -pie -fPIE -fpie -fno-PIC -fno-pic, -pie is set when -static -pg -p -profile. ++ If set it will make gcc print out "-shared and -static|pie|fPIE|fpie|fno-PIC|fno-pic are incompatible" or ++ "-pie and pg|p|profile are incompatible" */ ++ /* With ENABLE_CRTBEGINTS we don't need to check for -static */ ++ #ifdef ENABLE_CRTBEGINTS ++ #define ESPF_OPTIONS_PIE_CHECK_SPEC \ ++ "%{shared:%{static|pie|fPIE|fpie|fno-PIC|fno-pic:%e-shared and -static|pie|fPIE|fpie|fno-PIC|fno-pic are incompatible}} \ ++ %{pie:%{pg|p|profile:%e-pie and -pg|p|profile are incompatible}}" ++ #else ++ #define ESPF_OPTIONS_PIE_CHECK_SPEC \ ++ "%{shared:%{static|pie|fPIE|fpie|fno-PIC|fno-pic:%e-shared and -static|pie|fPIE|fpie|fno-PIC|fno-pic are incompatible}} \ ++ %{pie:%{static|pg|p|profile:%e-pie and -static|pg|p|profile are incompatible}}" ++ #endif ++ ++ /* We don't pass -pie to the linker when -static */ ++ #ifdef ENABLE_CRTBEGINTS ++ #define LINK_PIE_SPEC "%{!static:%{pie:-pie}} " ++ #endif ++ ++ #else ++ #define ESPF_OPTIONS_PIE_SPEC "" ++ #define ESPF_OPTIONS_PIE_CHECK_SPEC "" ++ #define ESPF_LINK_PIE_SPEC "" ++ #endif ++ ++ /* We add extra spec name's to the EXTRA_SPECS list */ ++ #define ESPF_EXTRA_SPECS \ ++ { "espf_cc1", ESPF_CC1_SPEC }, \ ++ { "espf_cc1_pie", ESPF_CC1_PIE_SPEC }, \ ++ { "espf_cc1_ssp", ESPF_CC1_SSP_SPEC }, \ ++ { "espf_cc1_strict", ESPF_CC1_STRICT_SPEC }, \ ++ { "espf_link", ESPF_LINK_SPEC }, \ ++ { "espf_link_now", ESPF_LINK_NOW_SPEC }, \ ++ { "espf_link_pie", ESPF_LINK_PIE_SPEC }, \ ++ { "espf_command_options", ESPF_COMMAND_OPTIONS_SPEC }, \ ++ { "espf_cpp_options", ESPF_CPP_OPTIONS_SPEC }, \ ++ { "espf_options", ESPF_OPTIONS_SPEC }, \ ++ { "espf_options_pie", ESPF_OPTIONS_PIE_SPEC }, \ ++ { "espf_options_pie_check", ESPF_OPTIONS_PIE_CHECK_SPEC }, \ ++ { "espf_options_ssp", ESPF_OPTIONS_SSP_SPEC } ++ ++ static const char *espf_command_options_spec = ESPF_COMMAND_OPTIONS_SPEC; ++ static const char *espf_link_spec = ESPF_LINK_SPEC; ++ static const char *cc1_spec = CC1_SPEC ESPF_CC1_SPEC; ++ ++#else /* If not ESPF_ENABLE defined do this. */ ++ ++ #define ESPF_OPTIONS_SPEC "" ++ #define ESPF_CPP_OPTIONS_SPEC "" ++ ++ /* We add extra spec name's to the EXTRA_SPECS list */ ++ #define ESPF_EXTRA_SPECS \ ++ { "espf_options", ESPF_OPTIONS_SPEC }, \ ++ { "espf_cpp_options", ESPF_CPP_OPTIONS_SPEC } ++ ++#endif ++#endif /* End GCC_ESPF_H */ +diff -Nur gcc-4.4.3.vanilla/gcc/gcc.c gcc-4.4.3/gcc/gcc.c +--- gcc-4.4.3.vanilla/gcc/gcc.c 2010-01-09 01:05:06.000000000 +0100 ++++ gcc-4.4.3/gcc/gcc.c 2010-03-21 16:37:45.000000000 +0100 +@@ -83,6 +83,7 @@ + #include "gcc.h" + #include "flags.h" + #include "opts.h" ++#include "espf.h" /* for --enable-espf support */ + + /* By default there is no special suffix for target executables. */ + /* FIXME: when autoconf is fixed, remove the host check - dj */ +@@ -758,7 +759,9 @@ + + static const char *asm_debug; + static const char *cpp_spec = CPP_SPEC; ++#ifndef ENABLE_ESPF + static const char *cc1_spec = CC1_SPEC; ++#endif + static const char *cc1plus_spec = CC1PLUS_SPEC; + static const char *link_gcc_c_sequence_spec = LINK_GCC_C_SEQUENCE_SPEC; + static const char *link_ssp_spec = LINK_SSP_SPEC; +@@ -817,7 +820,7 @@ + static const char *cpp_options = + "%(cpp_unique_options) %1 %{m*} %{std*&ansi&trigraphs} %{W*&pedantic*} %{w}\ + %{f*} %{g*:%{!g0:%{g*} %{!fno-working-directory:-fworking-directory}}} %{O*}\ +- %{undef} %{save-temps:-fpch-preprocess}"; ++ %{undef} %{save-temps:-fpch-preprocess} %(espf_cpp_options)"; + + /* This contains cpp options which are not passed when the preprocessor + output will be used by another program. */ +@@ -825,6 +828,9 @@ + + /* NB: This is shared amongst all front-ends, except for Ada. */ + static const char *cc1_options = ++#ifdef ENABLE_ESPF ++"%(espf_options_pie_check)" ++#endif + "%{pg:%{fomit-frame-pointer:%e-pg and -fomit-frame-pointer are incompatible}}\ + %1 %{!Q:-quiet} -dumpbase %B %{d*} %{m*} %{a*}\ + %{c|S:%{o*:-auxbase-strip %*}%{!o*:-auxbase %b}}%{!c:%{!S:-auxbase %b}}\ +@@ -999,15 +1005,15 @@ + %{save-temps|traditional-cpp|no-integrated-cpp:%(trad_capable_cpp) \ + %(cpp_options) -o %{save-temps:%b.i} %{!save-temps:%g.i} \n\ + cc1 -fpreprocessed %{save-temps:%b.i} %{!save-temps:%g.i} \ +- %(cc1_options)}\ ++ %(cc1_options) %(espf_options)}\ + %{!save-temps:%{!traditional-cpp:%{!no-integrated-cpp:\ +- cc1 %(cpp_unique_options) %(cc1_options)}}}\ ++ cc1 %(cpp_unique_options) %(cc1_options) %(espf_options)}}}\ + %{!fsyntax-only:%(invoke_as)}} \ + %{combine:\ + %{save-temps|traditional-cpp|no-integrated-cpp:%(trad_capable_cpp) \ + %(cpp_options) -o %{save-temps:%b.i} %{!save-temps:%g.i}}\ + %{!save-temps:%{!traditional-cpp:%{!no-integrated-cpp:\ +- cc1 %(cpp_unique_options) %(cc1_options)}}\ ++ cc1 %(cpp_unique_options) %(cc1_options) %(espf_options)}}\ + %{!fsyntax-only:%(invoke_as)}}}}}}", 0, 1, 1}, + {"-", + "%{!E:%e-E or -x required when input is from standard input}\ +@@ -1030,7 +1036,7 @@ + %W{o*:--output-pch=%*}%V}}}}}}", 0, 0, 0}, + {".i", "@cpp-output", 0, 1, 0}, + {"@cpp-output", +- "%{!M:%{!MM:%{!E:cc1 -fpreprocessed %i %(cc1_options) %{!fsyntax-only:%(invoke_as)}}}}", 0, 1, 0}, ++ "%{!M:%{!MM:%{!E:cc1 -fpreprocessed %i %(cc1_options) %(espf_options) %{!fsyntax-only:%(invoke_as)}}}}", 0, 1, 0}, + {".s", "@assembler", 0, 1, 0}, + {"@assembler", + "%{!M:%{!MM:%{!E:%{!S:as %(asm_debug) %(asm_options) %i %A }}}}", 0, 1, 0}, +@@ -1619,18 +1625,23 @@ + INIT_STATIC_SPEC ("sysroot_hdrs_suffix_spec", &sysroot_hdrs_suffix_spec), + }; + +-#ifdef EXTRA_SPECS /* additional specs needed */ ++/* EXTRA_SPECS needs to be defined */ ++#ifndef EXTRA_SPECS ++#define EXTRA_SPECS ++#endif ++ ++/* EXTRA_SPECS and ESPF_EXTRA_SPECS add additional specs */ + /* Structure to keep track of just the first two args of a spec_list. +- That is all that the EXTRA_SPECS macro gives us. */ ++ That is all that the EXTRA_SPECS and ESPF_EXTRA_SPECS macro gives us. */ + struct spec_list_1 + { + const char *const name; + const char *const ptr; + }; + +-static const struct spec_list_1 extra_specs_1[] = { EXTRA_SPECS }; ++/* ESPF_EXTRA_SPECS before EXTRA_SPECS */ ++static const struct spec_list_1 extra_specs_1[] = { ESPF_EXTRA_SPECS, EXTRA_SPECS }; + static struct spec_list *extra_specs = (struct spec_list *) 0; +-#endif + + /* List of dynamically allocates specs that have been defined so far. */ + +@@ -1715,7 +1726,6 @@ + if (verbose_flag) + notice ("Using built-in specs.\n"); + +-#ifdef EXTRA_SPECS + extra_specs = XCNEWVEC (struct spec_list, ARRAY_SIZE (extra_specs_1)); + + for (i = ARRAY_SIZE (extra_specs_1) - 1; i >= 0; i--) +@@ -1728,7 +1738,6 @@ + sl->ptr_spec = &sl->ptr; + next = sl; + } +-#endif + + for (i = ARRAY_SIZE (static_specs) - 1; i >= 0; i--) + { +@@ -5233,6 +5242,11 @@ + /* Make each accumulated option a separate argument. */ + do_spec_1 (" ", 0, NULL); + } ++#ifdef ENABLE_ESPF ++ value = do_spec_1 (espf_link_spec, 0, NULL); ++ if (value != 0) ++ return value; ++#endif + break; + + /* Dump out the options accumulated previously using -Wa,. */ +@@ -6495,6 +6509,12 @@ + gcc_exec_prefix = concat (gcc_exec_prefix, spec_machine, dir_separator_str, + spec_version, dir_separator_str, NULL); + ++#ifdef ENABLE_ESPF ++ /* Process ESPF_COMMAND_OPTIONS_SPEC, adding any new options to the end ++ of the command line. */ ++ do_self_spec (espf_command_options_spec); ++#endif ++ + /* Now we have the specs. + Set the `valid' bits for switches that match anything in any spec. */ + +diff -Nur gcc-4.4.3.vanilla/gcc/Makefile.in gcc-4.4.3/gcc/Makefile.in +--- gcc-4.4.3.vanilla/gcc/Makefile.in 2009-07-25 19:53:35.000000000 +0200 ++++ gcc-4.4.3/gcc/Makefile.in 2010-03-21 16:37:45.000000000 +0100 +@@ -580,13 +580,24 @@ + INHIBIT_LIBC_CFLAGS = -Dinhibit_libc + endif + ++# We don't want __stack_chk_fail in crt* and libgcc2.a. ++# We don't want to compile crtbegin, crtend and crtbeginT with -fPIE. ++enable_espf = @enable_espf@ ++ifeq ($(enable_espf),yes) ++ESPF_NOPIE_CFLAGS = -fno-PIE ++ESPF_NOSSP_CFLAGS = -fno-stack-protector ++else ++ESPF_NOPIE_CFLAGS= ++ESPF_NOSSP_CFLAGS= ++endif ++ + # Options to use when compiling libgcc2.a. + # + LIBGCC2_DEBUG_CFLAGS = -g + LIBGCC2_CFLAGS = -O2 $(LIBGCC2_INCLUDES) $(GCC_CFLAGS) $(TARGET_LIBGCC2_CFLAGS) \ + $(LIBGCC2_DEBUG_CFLAGS) $(GTHREAD_FLAGS) \ + -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED \ +- $(INHIBIT_LIBC_CFLAGS) ++ $(INHIBIT_LIBC_CFLAGS) $(ESPF_NOSSP_CFLAGS) + + # Additional options to use when compiling libgcc2.a. + # Some targets override this to -isystem include +@@ -599,7 +610,7 @@ + CRTSTUFF_CFLAGS = -O2 $(GCC_CFLAGS) $(INCLUDES) $(MULTILIB_CFLAGS) -g0 \ + -finhibit-size-directive -fno-inline-functions -fno-exceptions \ + -fno-zero-initialized-in-bss -fno-toplevel-reorder -fno-tree-vectorize \ +- $(INHIBIT_LIBC_CFLAGS) ++ $(INHIBIT_LIBC_CFLAGS) $(ESPF_NOSSP_CFLAGS) + + # Additional sources to handle exceptions; overridden by targets as needed. + LIB2ADDEH = $(srcdir)/unwind-dw2.c $(srcdir)/unwind-dw2-fde.c \ +@@ -629,6 +640,12 @@ + # The rules for compiling them should be in the t-* file for the machine. + EXTRA_PARTS = @extra_parts@ + ++# We add crtbeginTS.o to the EXTRA_PARTS list if enable_crtbeginTS = yes ++enable_crtbeginTS = @enable_crtbeginTS@ ++ifeq ($(enable_crtbeginTS),yes) ++EXTRA_PARTS += crtbeginTS.o ++endif ++ + # List of extra object files that should be compiled and linked with + # compiler proper (cc1, cc1obj, cc1plus). + EXTRA_OBJS = @extra_objs@ +@@ -1719,8 +1736,9 @@ + echo LIBGCC_SYNC = '$(LIBGCC_SYNC)' >> tmp-libgcc.mvars + echo LIBGCC_SYNC_CFLAGS = '$(LIBGCC_SYNC_CFLAGS)' >> tmp-libgcc.mvars + echo CRTSTUFF_CFLAGS = '$(CRTSTUFF_CFLAGS)' >> tmp-libgcc.mvars +- echo CRTSTUFF_T_CFLAGS = '$(CRTSTUFF_T_CFLAGS)' >> tmp-libgcc.mvars ++ echo CRTSTUFF_T_CFLAGS = '$(CRTSTUFF_T_CFLAGS) $(ESPF_NOPIE_CFLAGS)' >> tmp-libgcc.mvars + echo CRTSTUFF_T_CFLAGS_S = '$(CRTSTUFF_T_CFLAGS_S)' >> tmp-libgcc.mvars ++ echo enable_crtbeginTS = '$(enable_crtbeginTS)' >> tmp-libgcc.mvars + + mv tmp-libgcc.mvars libgcc.mvars + +@@ -1754,12 +1772,14 @@ + $(T)crtbegin.o: crtstuff.c $(GCC_PASSES) $(TCONFIG_H) auto-host.h \ + gbl-ctors.h stmp-int-hdrs tsystem.h coretypes.h $(TM_H) + $(GCC_FOR_TARGET) $(CRTSTUFF_CFLAGS) $(CRTSTUFF_T_CFLAGS) \ ++ $(ESPF_NOPIE_CFLAGS) \ + -c $(srcdir)/crtstuff.c -DCRT_BEGIN \ + -o $(T)crtbegin$(objext) + + $(T)crtend.o: crtstuff.c $(GCC_PASSES) $(TCONFIG_H) auto-host.h \ + gbl-ctors.h stmp-int-hdrs tsystem.h coretypes.h $(TM_H) + $(GCC_FOR_TARGET) $(CRTSTUFF_CFLAGS) $(CRTSTUFF_T_CFLAGS) \ ++ $(ESPF_NOPIE_CFLAGS) \ + -c $(srcdir)/crtstuff.c -DCRT_END \ + -o $(T)crtend$(objext) + +@@ -1780,9 +1800,19 @@ + $(T)crtbeginT.o: crtstuff.c $(GCC_PASSES) $(TCONFIG_H) auto-host.h \ + gbl-ctors.h stmp-int-hdrs tsystem.h coretypes.h $(TM_H) + $(GCC_FOR_TARGET) $(CRTSTUFF_CFLAGS) $(CRTSTUFF_T_CFLAGS) \ ++ $(ESPF_NOPIE_CFLAGS) \ + -c $(srcdir)/crtstuff.c -DCRT_BEGIN -DCRTSTUFFT_O \ + -o $(T)crtbeginT$(objext) + ++# This is a version of crtbegin for -static -fPIE links if espf is enable. ++ifeq ($(enable_crtbeginTS),yes) ++$(T)crtbeginTS.o: crtstuff.c $(GCC_PASSES) $(TCONFIG_H) auto-host.h \ ++ gbl-ctors.h stmp-int-hdrs tsystem.h coretypes.h $(TM_H) ++ $(GCC_FOR_TARGET) $(CRTSTUFF_CFLAGS) $(CRTSTUFF_T_CFLAGS_S) \ ++ -c $(srcdir)/crtstuff.c -DCRT_BEGIN -DCRTSTUFFT_O -DCRTSTUFFS_O \ ++ -o $(T)crtbeginTS$(objext) ++endif ++ + # Compile the start modules crt0.o and mcrt0.o that are linked with + # every program + $(T)crt0.o: s-crt0 ; @true +@@ -3058,7 +3088,7 @@ + output.h $(INSN_ATTR_H) $(SYSTEM_H) $(TOPLEV_H) $(TARGET_H) libfuncs.h \ + $(TARGET_DEF_H) $(FUNCTION_H) $(SCHED_INT_H) $(TM_P_H) $(EXPR_H) \ + langhooks.h $(GGC_H) $(OPTABS_H) $(REAL_H) tm-constrs.h $(GIMPLE_H) +- $(CC) -c $(ALL_CFLAGS) $(ALL_CPPFLAGS) \ ++ $(CC) -c $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(ESPF_NOSSP_CFLAGS)\ + $(out_file) $(OUTPUT_OPTION) + + # Build auxiliary files that support ecoff format. +diff -Nur gcc-4.4.3.vanilla/gcc/objc/lang-specs.h gcc-4.4.3/gcc/objc/lang-specs.h +--- gcc-4.4.3.vanilla/gcc/objc/lang-specs.h 2007-08-02 12:37:36.000000000 +0200 ++++ gcc-4.4.3/gcc/objc/lang-specs.h 2010-03-21 16:37:45.000000000 +0100 +@@ -30,13 +30,13 @@ + %{traditional|ftraditional|traditional-cpp:\ + %eGNU Objective C no longer supports traditional compilation}\ + %{save-temps|no-integrated-cpp:cc1obj -E %(cpp_options) -o %{save-temps:%b.mi} %{!save-temps:%g.mi} \n\ +- cc1obj -fpreprocessed %{save-temps:%b.mi} %{!save-temps:%g.mi} %(cc1_options) %{print-objc-runtime-info} %{gen-decls}}\ ++ cc1obj -fpreprocessed %{save-temps:%b.mi} %{!save-temps:%g.mi} %(cc1_options) %(espf_options) %{print-objc-runtime-info} %{gen-decls}}\ + %{!save-temps:%{!no-integrated-cpp:\ +- cc1obj %(cpp_unique_options) %(cc1_options) %{print-objc-runtime-info} %{gen-decls}}}\ ++ cc1obj %(cpp_unique_options) %(cc1_options) %(espf_options) %{print-objc-runtime-info} %{gen-decls}}}\ + %{!fsyntax-only:%(invoke_as)}}}}", 0, 0, 0}, + {".mi", "@objc-cpp-output", 0, 0, 0}, + {"@objc-cpp-output", +- "%{!M:%{!MM:%{!E:cc1obj -fpreprocessed %i %(cc1_options) %{print-objc-runtime-info} %{gen-decls}\ ++ "%{!M:%{!MM:%{!E:cc1obj -fpreprocessed %i %(cc1_options) %(espf_options) %{print-objc-runtime-info} %{gen-decls}\ + %{!fsyntax-only:%(invoke_as)}}}}", 0, 0, 0}, + {"@objective-c-header", + "%{E|M|MM:cc1obj -E %{traditional|ftraditional|traditional-cpp:-traditional-cpp}\ +@@ -45,10 +45,10 @@ + %{traditional|ftraditional|traditional-cpp:\ + %eGNU Objective C no longer supports traditional compilation}\ + %{save-temps|no-integrated-cpp:cc1obj -E %(cpp_options) -o %{save-temps:%b.mi} %{!save-temps:%g.mi} \n\ +- cc1obj -fpreprocessed %b.mi %(cc1_options) %{print-objc-runtime-info} %{gen-decls}\ ++ cc1obj -fpreprocessed %b.mi %(cc1_options) %(espf_options) %{print-objc-runtime-info} %{gen-decls}\ + -o %g.s %{!o*:--output-pch=%i.gch}\ + %W{o*:--output-pch=%*}%V}\ + %{!save-temps:%{!no-integrated-cpp:\ +- cc1obj %(cpp_unique_options) %(cc1_options) %{print-objc-runtime-info} %{gen-decls}\ ++ cc1obj %(cpp_unique_options) %(cc1_options) %(espf_options) %{print-objc-runtime-info} %{gen-decls}\ + -o %g.s %{!o*:--output-pch=%i.gch}\ + %W{o*:--output-pch=%*}%V}}}}}", 0, 0, 0}, +diff -Nur gcc-4.4.3.vanilla/gcc/objcp/lang-specs.h gcc-4.4.3/gcc/objcp/lang-specs.h +--- gcc-4.4.3.vanilla/gcc/objcp/lang-specs.h 2007-08-02 12:38:44.000000000 +0200 ++++ gcc-4.4.3/gcc/objcp/lang-specs.h 2010-03-21 16:37:45.000000000 +0100 +@@ -36,7 +36,7 @@ + %(cpp_options) %2 -o %{save-temps:%b.mii} %{!save-temps:%g.mii} \n}\ + cc1objplus %{save-temps|no-integrated-cpp:-fpreprocessed %{save-temps:%b.mii} %{!save-temps:%g.mii}}\ + %{!save-temps:%{!no-integrated-cpp:%(cpp_unique_options)}}\ +- %(cc1_options) %2 %{+e1*}\ ++ %(cc1_options) %(espf_options) %2 %{+e1*}\ + -o %g.s %{!o*:--output-pch=%i.gch} %W{o*:--output-pch=%*}%V}}}", + CPLUSPLUS_CPP_SPEC, 0, 0}, + {"@objective-c++", +@@ -46,15 +46,15 @@ + %(cpp_options) %2 -o %{save-temps:%b.mii} %{!save-temps:%g.mii} \n}\ + cc1objplus %{save-temps|no-integrated-cpp:-fpreprocessed %{save-temps:%b.mii} %{!save-temps:%g.mii}}\ + %{!save-temps:%{!no-integrated-cpp:%(cpp_unique_options)}}\ +- %(cc1_options) %2 %{+e1*}\ ++ %(cc1_options) %(espf_options) %2 %{+e1*}\ + %{!fsyntax-only:%(invoke_as)}}}}", + CPLUSPLUS_CPP_SPEC, 0, 0}, + {".mii", "@objective-c++-cpp-output", 0, 0, 0}, + {"@objective-c++-cpp-output", + "%{!M:%{!MM:%{!E:\ +- cc1objplus -fpreprocessed %i %(cc1_options) %2 %{+e*}\ ++ cc1objplus -fpreprocessed %i %(cc1_options) %(espf_options) %2 %{+e*}\ + %{!fsyntax-only:%(invoke_as)}}}}", 0, 0, 0}, + {"@objc++-cpp-output", + "%{!M:%{!MM:%{!E:\ +- cc1objplus -fpreprocessed %i %(cc1_options) %2 %{+e*}\ ++ cc1objplus -fpreprocessed %i %(cc1_options) %(espf_options) %2 %{+e*}\ + %{!fsyntax-only:%(invoke_as)}}}}", 0, 0, 0}, +diff -Nur gcc-4.4.3.vanilla/gcc/varasm.c gcc-4.4.3/gcc/varasm.c +--- gcc-4.4.3.vanilla/gcc/varasm.c 2010-01-20 12:27:49.000000000 +0100 ++++ gcc-4.4.3/gcc/varasm.c 2010-03-21 16:37:45.000000000 +0100 +@@ -5679,7 +5679,11 @@ + bool is_local; + + is_local = targetm.binds_local_p (decl); +- if (!flag_shlib) ++ #ifdef ENABLE_ESPF ++ if (!flag_pic) ++ #else ++ if (!flag_shlib) ++ #endif + { + if (is_local) + kind = TLS_MODEL_LOCAL_EXEC; +diff -Nur gcc-4.4.3.vanilla/libgcc/Makefile.in gcc-4.4.3/libgcc/Makefile.in +--- gcc-4.4.3.vanilla/libgcc/Makefile.in 2009-04-10 01:23:07.000000000 +0200 ++++ gcc-4.4.3/libgcc/Makefile.in 2010-03-21 16:37:45.000000000 +0100 +@@ -280,6 +280,12 @@ + gen-hide-list = echo > $@ + endif + ++# We add crtbeginTS.o to the EXTRA_PARTS list if enable_crtbeginTS = yes ++enable_libgcc_crtbeginTS = $(enable_crtbeginTS) ++ifeq ($(enable_libgcc_crtbeginTS),yes) ++EXTRA_PARTS += crtbeginTS.o ++endif ++ + ifneq ($(EXTRA_PARTS),) + extra-parts = libgcc-extra-parts + INSTALL_PARTS = $(EXTRA_PARTS) +@@ -831,6 +837,13 @@ + crtbeginT.o: $(gcc_srcdir)/crtstuff.c + $(crt_compile) $(CRTSTUFF_T_CFLAGS) \ + -c $(gcc_srcdir)/crtstuff.c -DCRT_BEGIN -DCRTSTUFFT_O ++ ++# This is a version of crtbegin for -static -fPIE links. ++ifeq ($(enable_libgcc_crtbeginTS),yes) ++crtbeginTS.o: $(gcc_srcdir)/crtstuff.c ++ $(crt_compile) $(CRTSTUFF_T_CFLAGS_S) \ ++ -c $(gcc_srcdir)/crtstuff.c -DCRT_BEGIN -DCRTSTUFFT_O -DCRTSTUFFS_O ++endif + endif + + # Build extra startfiles in the libgcc directory. +diff -Nur gcc-4.4.3.vanilla/libmudflap/configure gcc-4.4.3/libmudflap/configure +--- gcc-4.4.3.vanilla/libmudflap/configure 2009-03-01 18:49:31.000000000 +0100 ++++ gcc-4.4.3/libmudflap/configure 2010-03-21 16:37:45.000000000 +0100 +@@ -458,7 +458,7 @@ + # include <unistd.h> + #endif" + +-ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS build build_cpu build_vendor build_os host host_cpu host_vendor host_os target target_cpu target_vendor target_os target_noncanonical INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA CYGPATH_W PACKAGE VERSION ACLOCAL AUTOCONF AUTOMAKE AUTOHEADER MAKEINFO install_sh STRIP ac_ct_STRIP INSTALL_STRIP_PROGRAM mkdir_p AWK SET_MAKE am__leading_dot AMTAR am__tar am__untar MAINTAINER_MODE_TRUE MAINTAINER_MODE_FALSE MAINT multi_basedir CC ac_ct_CC EXEEXT OBJEXT DEPDIR am__include am__quote AMDEP_TRUE AMDEP_FALSE AMDEPBACKSLASH CCDEPMODE am__fastdepCC_TRUE am__fastdepCC_FALSE CFLAGS CPP CPPFLAGS EGREP LIBTOOL SED FGREP GREP LD DUMPBIN ac_ct_DUMPBIN NM LN_S OBJDUMP ac_ct_OBJDUMP AR ac_ct_AR RANLIB ac_ct_RANLIB lt_ECHO DSYMUTIL ac_ct_DSYMUTIL NMEDIT ac_ct_NMEDIT LIPO ac_ct_LIPO OTOOL ac_ct_OTOOL OTOOL64 ac_ct_OTOOL64 enable_shared enable_static MF_HAVE_STDINT_H MF_HAVE_UINTPTR_T LIBMUDFLAPTH_TRUE LIBMUDFLAPTH_FALSE build_libmudflapth toolexecdir toolexeclibdir ac_ct_NM SECTION_FLAGS LIBOBJS LTLIBOBJS' ++ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS build build_cpu build_vendor build_os host host_cpu host_vendor host_os target target_cpu target_vendor target_os target_noncanonical INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA CYGPATH_W PACKAGE VERSION ACLOCAL AUTOCONF AUTOMAKE AUTOHEADER MAKEINFO install_sh STRIP ac_ct_STRIP INSTALL_STRIP_PROGRAM mkdir_p AWK SET_MAKE am__leading_dot AMTAR am__tar am__untar enable_espf MAINTAINER_MODE_TRUE MAINTAINER_MODE_FALSE MAINT multi_basedir CC ac_ct_CC EXEEXT OBJEXT DEPDIR am__include am__quote AMDEP_TRUE AMDEP_FALSE AMDEPBACKSLASH CCDEPMODE am__fastdepCC_TRUE am__fastdepCC_FALSE CFLAGS CPP CPPFLAGS EGREP LIBTOOL SED FGREP GREP LD DUMPBIN ac_ct_DUMPBIN NM LN_S OBJDUMP ac_ct_OBJDUMP AR ac_ct_AR RANLIB ac_ct_RANLIB lt_ECHO DSYMUTIL ac_ct_DSYMUTIL NMEDIT ac_ct_NMEDIT LIPO ac_ct_LIPO OTOOL ac_ct_OTOOL OTOOL64 ac_ct_OTOOL64 enable_shared enable_static MF_HAVE_STDINT_H MF_HAVE_UINTPTR_T LIBMUDFLAPTH_TRUE LIBMUDFLAPTH_FALSE build_libmudflapth toolexecdir toolexeclibdir ac_ct_NM SECTION_FLAGS LIBOBJS LTLIBOBJS' + ac_subst_files='' + ac_pwd=`pwd` + +@@ -14017,6 +14017,7 @@ + s,@AMTAR@,$AMTAR,;t t + s,@am__tar@,$am__tar,;t t + s,@am__untar@,$am__untar,;t t ++s,@enable_espf@,$enable_espf,;t t + s,@MAINTAINER_MODE_TRUE@,$MAINTAINER_MODE_TRUE,;t t + s,@MAINTAINER_MODE_FALSE@,$MAINTAINER_MODE_FALSE,;t t + s,@MAINT@,$MAINT,;t t +diff -Nur gcc-4.4.3.vanilla/libmudflap/Makefile.in gcc-4.4.3/libmudflap/Makefile.in +--- gcc-4.4.3.vanilla/libmudflap/Makefile.in 2008-09-26 18:37:32.000000000 +0200 ++++ gcc-4.4.3/libmudflap/Makefile.in 2010-03-21 16:37:45.000000000 +0100 +@@ -253,10 +253,18 @@ + MAINT_CHARSET = latin1 + SUBDIRS = testsuite + ++# Some stuff don't compile with PIE or SSP ++enable_espf = @enable_espf@ ++ifeq ($(enable_espf),yes) ++NO_ESPF_CFLAGS = -fno-stack-protector -U_FORTIFY_SOURCE ++else ++NO_ESPF_CFLAGS = ++endif ++ + # May be used by various substitution variables. + gcc_version := $(shell cat $(top_srcdir)/../gcc/BASE-VER) +-AM_CFLAGS = -Wall $(SECTION_FLAGS) +-@LIBMUDFLAPTH_FALSE@libmudflapth = ++AM_CFLAGS = -Wall $(SECTION_FLAGS) $(NO_ESPF_CFLAGS) ++@LIBMUDFLAPTH_FALSE@libmudflapth = + @LIBMUDFLAPTH_TRUE@libmudflapth = libmudflapth.la + toolexeclib_LTLIBRARIES = libmudflap.la $(libmudflapth) + libsubincludedir = $(libdir)/gcc/$(target_noncanonical)/$(gcc_version)/include +diff -Nur gcc-4.4.3.vanilla/Makefile.in gcc-4.4.3/Makefile.in +--- gcc-4.4.3.vanilla/Makefile.in 2009-04-25 06:10:29.000000000 +0200 ++++ gcc-4.4.3/Makefile.in 2010-03-21 16:37:45.000000000 +0100 +@@ -305,9 +305,17 @@ + BUILD_PREFIX = @BUILD_PREFIX@ + BUILD_PREFIX_1 = @BUILD_PREFIX_1@ + ++# Some stuff don't compile with SSP ++enable_espf = @enable_espf@ ++ifeq ($(enable_espf),yes) ++ESPF_NOSSP_CFLAGS = -fno-stack-protector ++else ++ESPF_NOSSP_CFLAGS= ++endif ++ + # Flags to pass to stage2 and later makes. They are defined + # here so that they can be overridden by Makefile fragments. +-BOOT_CFLAGS= -g -O2 ++BOOT_CFLAGS= -g -O2 $(ESPF_NOSSP_CFLAGS) + BOOT_LDFLAGS= + BOOT_ADAFLAGS=-gnatpg -gnata + +@@ -350,9 +358,9 @@ + + CFLAGS = @CFLAGS@ + LDFLAGS = @LDFLAGS@ +-LIBCFLAGS = $(CFLAGS) ++LIBCFLAGS = $(CFLAGS) $(ESPF_NOSSP_CFLAGS) + CXXFLAGS = @CXXFLAGS@ +-LIBCXXFLAGS = $(CXXFLAGS) -fno-implicit-templates ++LIBCXXFLAGS = $(CXXFLAGS) -fno-implicit-templates $(ESPF_NOSSP_CFLAGS) + + # Only build the C compiler for stage1, because that is the only one that + # we can guarantee will build with the native compiler, and also it is the diff --git a/pkgs/core/gmp/gmp.nm b/pkgs/core/gmp/gmp.nm index 4e398b1..7f71dff 100644 --- a/pkgs/core/gmp/gmp.nm +++ b/pkgs/core/gmp/gmp.nm @@ -34,8 +34,6 @@ PKG_URL = http://gmplib.org/ PKG_LICENSE = LGPLv3+ PKG_SUMMARY = A GNU arbitrary precision library.
-PKG_BUILD_DEPS:= $(filter-out gcc,$(PKG_BUILD_DEPS)) - define PKG_DESCRIPTION The gmp package contains GNU MP, a library for arbitrary precision \ arithmetic, signed integers operations, rational numbers and floating \ diff --git a/pkgs/core/linux-atm/linux-atm.nm b/pkgs/core/linux-atm/linux-atm.nm index d0a6cfa..2fc8a3f 100644 --- a/pkgs/core/linux-atm/linux-atm.nm +++ b/pkgs/core/linux-atm/linux-atm.nm @@ -34,7 +34,7 @@ PKG_URL = http://linux-atm.sourceforge.net/ PKG_LICENSE = BSD and GPLv2 and GPLv2+ and LGPLv2+ and MIT PKG_SUMMARY = Tools to support ATM networking under Linux.
-PKG_BUILD_DEPS+= flex +PKG_BUILD_DEPS+= flex kernel-headers
define PKG_DESCRIPTION This package contains header files and libraries for development \ diff --git a/pkgs/core/m4/m4.nm b/pkgs/core/m4/m4.nm index ee51012..e5157e6 100644 --- a/pkgs/core/m4/m4.nm +++ b/pkgs/core/m4/m4.nm @@ -45,10 +45,6 @@ endef
PKG_TARBALL = $(THISAPP).tar.bz2
-CONFIGURE_ENVIRONMENT += \ - CPPFLAGS="-D_GNU_SOURCE" \ - gl_cv_func_printf_directive_n=no \ - define STAGE_TEST cd $(DIR_APP) && make check endef diff --git a/pkgs/core/mpfr/mpfr.nm b/pkgs/core/mpfr/mpfr.nm index bca905d..29d1eba 100644 --- a/pkgs/core/mpfr/mpfr.nm +++ b/pkgs/core/mpfr/mpfr.nm @@ -34,7 +34,6 @@ PKG_URL = http://www.mpfr.org/ PKG_LICENSE = LGPLv2+ and GPLv2+ and GFDL PKG_SUMMARY = A C library for multiple-precision floating-point computations.
-PKG_BUILD_DEPS:= $(filter-out gcc,$(PKG_BUILD_DEPS)) PKG_DEPS += gmp
define PKG_DESCRIPTION diff --git a/pkgs/core/paxtest/paxtest.nm b/pkgs/core/paxtest/paxtest.nm index dd7c392..3adbadc 100644 --- a/pkgs/core/paxtest/paxtest.nm +++ b/pkgs/core/paxtest/paxtest.nm @@ -25,7 +25,7 @@ include $(PKGROOT)/Include
PKG_NAME = paxtest -PKG_VER = 0.9.7-pre4 +PKG_VER = 0.9.9 PKG_REL = 0
PKG_MAINTAINER = @@ -39,18 +39,18 @@ define PKG_DESCRIPTION and checks if it all works correctly. endef
-PKG_TARBALL = $(THISAPP).tar.gz +PKG_TARBALL = $(THISAPP).tgz
define QUALITY_AGENT_WHITELIST_EXECSTACK /usr/lib/paxtest endef
define STAGE_BUILD - cd $(DIR_APP) && make -f Makefile.generic RUNDIR=/usr/lib/paxtest \ + cd $(DIR_APP) && make -f Makefile.psm RUNDIR=/usr/lib/paxtest \ $(PARALLELISMFLAGS) endef
define STAGE_INSTALL - cd $(DIR_APP) && make -f Makefile.generic install DESTDIR=$(BUILDROOT) \ + cd $(DIR_APP) && make -f Makefile.psm install DESTDIR=$(BUILDROOT) \ RUNDIR=/usr/lib/paxtest BINDIR=/usr/bin endef diff --git a/pkgs/core/ppl/patches/ppl-0.10.2-Makefile.patch b/pkgs/core/ppl/patches/ppl-0.10.2-Makefile.patch new file mode 100644 index 0000000..307e5c7 --- /dev/null +++ b/pkgs/core/ppl/patches/ppl-0.10.2-Makefile.patch @@ -0,0 +1,12 @@ +diff -ur ppl-0.10.1/Watchdog/doc/Makefile.in ppl-0.10.1-patched/Watchdog/doc/Makefile.in +--- ppl-0.10.1/Watchdog/doc/Makefile.in 2000-04-11 10:36:59.000000000 +0100 ++++ ppl-0.10.1-patched/Watchdog/doc/Makefile.in 2009-04-11 17:53:10.000000000 +0100 +@@ -163,7 +163,7 @@ + debug_flag = @debug_flag@ + + # All the documentation in docdir. +-docdir = @docdir@ ++docdir = @docdir@/pwl + dvidir = @dvidir@ + exec_prefix = @exec_prefix@ + host = @host@ diff --git a/pkgs/core/ppl/patches/ppl-0.10.2-gmp-build-fix.patch b/pkgs/core/ppl/patches/ppl-0.10.2-gmp-build-fix.patch new file mode 100644 index 0000000..a951fc2 --- /dev/null +++ b/pkgs/core/ppl/patches/ppl-0.10.2-gmp-build-fix.patch @@ -0,0 +1,63 @@ +X-Git-Url: http://www.cs.unipr.it/git/gitweb.cgi?p=ppl%2Fppl.git;a=blobdiff_plain;f=m4%... + +diff --git a/m4/ac_check_gmp.m4 b/m4/ac_check_gmp.m4 +index 4dc3bc8..15acb18 100644 +--- a/m4/ac_check_gmp.m4 ++++ b/m4/ac_check_gmp.m4 +@@ -1,5 +1,5 @@ + dnl A function to check for the existence and usability of GMP. +-dnl Copyright (C) 2001-2009 Roberto Bagnara bagnara@cs.unipr.it ++dnl Copyright (C) 2001-2010 Roberto Bagnara bagnara@cs.unipr.it + dnl + dnl This file is part of the Parma Polyhedra Library (PPL). + dnl +@@ -32,6 +32,23 @@ else + fi + fi + ++AC_ARG_WITH(gmp-build, ++ AS_HELP_STRING([--with-gmp-build=DIR], ++ [use a non-installed build of GMP in DIR]), ++ gmp_build_dir=$with_gmp_build ++ if test -z "$with_libgmp_prefix" ++ then ++ CPPFLAGS="$CPPFLAGS -I$gmp_build_dir -I$gmp_build_dir/tune" ++ LDFLAGS="$LDFLAGS -L$gmp_build_dir -L$gmp_build_dir/.libs" ++ LDFLAGS="$LDFLAGS -L$gmp_build_dir/tune" ++ else ++ AC_MSG_ERROR([cannot use --with-gmp-build and --with-gmp-prefix together]) ++ fi) ++ ++dnl Both libgmp and libbmpxx come from the gmp package. ++AC_LIB_FROMPACKAGE([gmp], [gmp]) ++AC_LIB_FROMPACKAGE([gmpxx], [gmp]) ++ + dnl Check how to link with libgmp. + AC_LIB_LINKFLAGS([gmp]) + +@@ -54,6 +71,10 @@ AC_RUN_IFELSE([AC_LANG_SOURCE([[ + #GMP version 4.1.3 or higher is required + #endif + ++#ifndef BITS_PER_MP_LIMB ++#define BITS_PER_MP_LIMB GMP_LIMB_BITS ++#endif ++ + int + main() { + std::string header_version; +@@ -80,11 +101,11 @@ main() { + return 1; + } + +- if (sizeof(mp_limb_t)*CHAR_BIT != GMP_LIMB_BITS +- || GMP_LIMB_BITS != mp_bits_per_limb) { ++ if (sizeof(mp_limb_t)*CHAR_BIT != BITS_PER_MP_LIMB ++ || BITS_PER_MP_LIMB != mp_bits_per_limb) { + std::cerr + << "GMP header (gmp.h) and library (ligmp.*) bits-per-limb mismatch:\n" +- << "header gives " << __GMP_BITS_PER_MP_LIMB << ";\n" ++ << "header gives " << BITS_PER_MP_LIMB << ";\n" + << "library gives " << mp_bits_per_limb << ".\n" + << "This probably means you are on a bi-arch system and\n" + << "you are compiling with the wrong header or linking with\n" diff --git a/pkgs/core/ppl/patches/ppl-0.10.2-m4-update.patch b/pkgs/core/ppl/patches/ppl-0.10.2-m4-update.patch new file mode 100644 index 0000000..b233ede --- /dev/null +++ b/pkgs/core/ppl/patches/ppl-0.10.2-m4-update.patch @@ -0,0 +1,755 @@ +From e3460918400e04cf24fda33ff0cf9d18a95840b8 Mon Sep 17 00:00:00 2001 +From: Roberto Bagnara bagnara@cs.unipr.it +Date: Tue, 12 May 2009 15:49:10 +0200 +Subject: [PATCH] Updated from Gnulib. + +--- + m4/lib-ld.m4 | 14 +- + m4/lib-link.m4 | 352 +++++++++++++++++++++++++++++++++++++++++++----------- + m4/lib-prefix.m4 | 81 ++++++++++++- + 3 files changed, 363 insertions(+), 84 deletions(-) + +diff --git a/m4/lib-ld.m4 b/m4/lib-ld.m4 +index 96c4e2c..e4863f2 100644 +--- a/m4/lib-ld.m4 ++++ b/m4/lib-ld.m4 +@@ -1,5 +1,5 @@ +-# lib-ld.m4 serial 3 (gettext-0.13) +-dnl Copyright (C) 1996-2003 Free Software Foundation, Inc. ++# lib-ld.m4 serial 4 (gettext-0.18) ++dnl Copyright (C) 1996-2003, 2009 Free Software Foundation, Inc. + dnl This file is free software; the Free Software Foundation + dnl gives unlimited permission to copy and/or distribute it, + dnl with or without modifications, as long as this notice is preserved. +@@ -10,7 +10,7 @@ dnl with libtool.m4. + + dnl From libtool-1.4. Sets the variable with_gnu_ld to yes or no. + AC_DEFUN([AC_LIB_PROG_LD_GNU], +-[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], acl_cv_prog_gnu_ld, ++[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], [acl_cv_prog_gnu_ld], + [# I'd rather use --version here, but apparently some GNU ld's only accept -v. + case `$LD -v 2>&1 </dev/null` in + *GNU* | *'with BFD'*) +@@ -23,7 +23,7 @@ with_gnu_ld=$acl_cv_prog_gnu_ld + + dnl From libtool-1.4. Sets the variable LD. + AC_DEFUN([AC_LIB_PROG_LD], +-[AC_ARG_WITH(gnu-ld, ++[AC_ARG_WITH([gnu-ld], + [ --with-gnu-ld assume the C compiler uses GNU ld [default=no]], + test "$withval" = no || with_gnu_ld=yes, with_gnu_ld=no) + AC_REQUIRE([AC_PROG_CC])dnl +@@ -77,7 +77,7 @@ elif test "$with_gnu_ld" = yes; then + else + AC_MSG_CHECKING([for non-GNU ld]) + fi +-AC_CACHE_VAL(acl_cv_path_LD, ++AC_CACHE_VAL([acl_cv_path_LD], + [if test -z "$LD"; then + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}" + for ac_dir in $PATH; do +@@ -101,9 +101,9 @@ else + fi]) + LD="$acl_cv_path_LD" + if test -n "$LD"; then +- AC_MSG_RESULT($LD) ++ AC_MSG_RESULT([$LD]) + else +- AC_MSG_RESULT(no) ++ AC_MSG_RESULT([no]) + fi + test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in $PATH]) + AC_LIB_PROG_LD_GNU +diff --git a/m4/lib-link.m4 b/m4/lib-link.m4 +index ea0b0c4..2144203 100644 +--- a/m4/lib-link.m4 ++++ b/m4/lib-link.m4 +@@ -1,58 +1,66 @@ +-# lib-link.m4 serial 6 (gettext-0.14.3) +-dnl Copyright (C) 2001-2005 Free Software Foundation, Inc. ++# lib-link.m4 serial 19 (gettext-0.18) ++dnl Copyright (C) 2001-2009 Free Software Foundation, Inc. + dnl This file is free software; the Free Software Foundation + dnl gives unlimited permission to copy and/or distribute it, + dnl with or without modifications, as long as this notice is preserved. + + dnl From Bruno Haible. + +-AC_PREREQ(2.50) ++AC_PREREQ([2.54]) + + dnl AC_LIB_LINKFLAGS(name [, dependencies]) searches for libname and + dnl the libraries corresponding to explicit and implicit dependencies. + dnl Sets and AC_SUBSTs the LIB${NAME} and LTLIB${NAME} variables and + dnl augments the CPPFLAGS variable. ++dnl Sets and AC_SUBSTs the LIB${NAME}_PREFIX variable to nonempty if libname ++dnl was found in ${LIB${NAME}_PREFIX}/$acl_libdirstem. + AC_DEFUN([AC_LIB_LINKFLAGS], + [ + AC_REQUIRE([AC_LIB_PREPARE_PREFIX]) + AC_REQUIRE([AC_LIB_RPATH]) +- define([Name],[translit([$1],[./-], [___])]) +- define([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-], +- [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])]) ++ pushdef([Name],[translit([$1],[./-], [___])]) ++ pushdef([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-], ++ [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])]) + AC_CACHE_CHECK([how to link with lib[]$1], [ac_cv_lib[]Name[]_libs], [ + AC_LIB_LINKFLAGS_BODY([$1], [$2]) + ac_cv_lib[]Name[]_libs="$LIB[]NAME" + ac_cv_lib[]Name[]_ltlibs="$LTLIB[]NAME" + ac_cv_lib[]Name[]_cppflags="$INC[]NAME" ++ ac_cv_lib[]Name[]_prefix="$LIB[]NAME[]_PREFIX" + ]) + LIB[]NAME="$ac_cv_lib[]Name[]_libs" + LTLIB[]NAME="$ac_cv_lib[]Name[]_ltlibs" + INC[]NAME="$ac_cv_lib[]Name[]_cppflags" ++ LIB[]NAME[]_PREFIX="$ac_cv_lib[]Name[]_prefix" + AC_LIB_APPENDTOVAR([CPPFLAGS], [$INC]NAME) + AC_SUBST([LIB]NAME) + AC_SUBST([LTLIB]NAME) ++ AC_SUBST([LIB]NAME[_PREFIX]) + dnl Also set HAVE_LIB[]NAME so that AC_LIB_HAVE_LINKFLAGS can reuse the + dnl results of this search when this library appears as a dependency. + HAVE_LIB[]NAME=yes +- undefine([Name]) +- undefine([NAME]) ++ popdef([NAME]) ++ popdef([Name]) + ]) + +-dnl AC_LIB_HAVE_LINKFLAGS(name, dependencies, includes, testcode) ++dnl AC_LIB_HAVE_LINKFLAGS(name, dependencies, includes, testcode, [missing-message]) + dnl searches for libname and the libraries corresponding to explicit and + dnl implicit dependencies, together with the specified include files and +-dnl the ability to compile and link the specified testcode. If found, it +-dnl sets and AC_SUBSTs HAVE_LIB${NAME}=yes and the LIB${NAME} and +-dnl LTLIB${NAME} variables and augments the CPPFLAGS variable, and ++dnl the ability to compile and link the specified testcode. The missing-message ++dnl defaults to 'no' and may contain additional hints for the user. ++dnl If found, it sets and AC_SUBSTs HAVE_LIB${NAME}=yes and the LIB${NAME} ++dnl and LTLIB${NAME} variables and augments the CPPFLAGS variable, and + dnl #defines HAVE_LIB${NAME} to 1. Otherwise, it sets and AC_SUBSTs + dnl HAVE_LIB${NAME}=no and LIB${NAME} and LTLIB${NAME} to empty. ++dnl Sets and AC_SUBSTs the LIB${NAME}_PREFIX variable to nonempty if libname ++dnl was found in ${LIB${NAME}_PREFIX}/$acl_libdirstem. + AC_DEFUN([AC_LIB_HAVE_LINKFLAGS], + [ + AC_REQUIRE([AC_LIB_PREPARE_PREFIX]) + AC_REQUIRE([AC_LIB_RPATH]) +- define([Name],[translit([$1],[./-], [___])]) +- define([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-], +- [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])]) ++ pushdef([Name],[translit([$1],[./-], [___])]) ++ pushdef([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-], ++ [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])]) + + dnl Search for lib[]Name and define LIB[]NAME, LTLIB[]NAME and INC[]NAME + dnl accordingly. +@@ -67,12 +75,14 @@ AC_DEFUN([AC_LIB_HAVE_LINKFLAGS], + AC_CACHE_CHECK([for lib[]$1], [ac_cv_lib[]Name], [ + ac_save_LIBS="$LIBS" + LIBS="$LIBS $LIB[]NAME" +- AC_TRY_LINK([$3], [$4], [ac_cv_lib[]Name=yes], [ac_cv_lib[]Name=no]) ++ AC_TRY_LINK([$3], [$4], ++ [ac_cv_lib[]Name=yes], ++ [ac_cv_lib[]Name='m4_if([$5], [], [no], [[$5]])']) + LIBS="$ac_save_LIBS" + ]) + if test "$ac_cv_lib[]Name" = yes; then + HAVE_LIB[]NAME=yes +- AC_DEFINE([HAVE_LIB]NAME, 1, [Define if you have the $1 library.]) ++ AC_DEFINE([HAVE_LIB]NAME, 1, [Define if you have the lib[]$1 library.]) + AC_MSG_CHECKING([how to link with lib[]$1]) + AC_MSG_RESULT([$LIB[]NAME]) + else +@@ -82,17 +92,23 @@ AC_DEFUN([AC_LIB_HAVE_LINKFLAGS], + CPPFLAGS="$ac_save_CPPFLAGS" + LIB[]NAME= + LTLIB[]NAME= ++ LIB[]NAME[]_PREFIX= + fi + AC_SUBST([HAVE_LIB]NAME) + AC_SUBST([LIB]NAME) + AC_SUBST([LTLIB]NAME) +- undefine([Name]) +- undefine([NAME]) ++ AC_SUBST([LIB]NAME[_PREFIX]) ++ popdef([NAME]) ++ popdef([Name]) + ]) + + dnl Determine the platform dependent parameters needed to use rpath: +-dnl libext, shlibext, hardcode_libdir_flag_spec, hardcode_libdir_separator, +-dnl hardcode_direct, hardcode_minus_L. ++dnl acl_libext, ++dnl acl_shlibext, ++dnl acl_hardcode_libdir_flag_spec, ++dnl acl_hardcode_libdir_separator, ++dnl acl_hardcode_direct, ++dnl acl_hardcode_minus_L. + AC_DEFUN([AC_LIB_RPATH], + [ + dnl Tell automake >= 1.10 to complain if config.rpath is missing. +@@ -101,7 +117,7 @@ AC_DEFUN([AC_LIB_RPATH], + AC_REQUIRE([AC_LIB_PROG_LD]) dnl we use $LD, $with_gnu_ld + AC_REQUIRE([AC_CANONICAL_HOST]) dnl we use $host + AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT]) dnl we use $ac_aux_dir +- AC_CACHE_CHECK([for shared library run path origin], acl_cv_rpath, [ ++ AC_CACHE_CHECK([for shared library run path origin], [acl_cv_rpath], [ + CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \ + ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh + . ./conftest.sh +@@ -109,34 +125,66 @@ AC_DEFUN([AC_LIB_RPATH], + acl_cv_rpath=done + ]) + wl="$acl_cv_wl" +- libext="$acl_cv_libext" +- shlibext="$acl_cv_shlibext" +- hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec" +- hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator" +- hardcode_direct="$acl_cv_hardcode_direct" +- hardcode_minus_L="$acl_cv_hardcode_minus_L" ++ acl_libext="$acl_cv_libext" ++ acl_shlibext="$acl_cv_shlibext" ++ acl_libname_spec="$acl_cv_libname_spec" ++ acl_library_names_spec="$acl_cv_library_names_spec" ++ acl_hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec" ++ acl_hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator" ++ acl_hardcode_direct="$acl_cv_hardcode_direct" ++ acl_hardcode_minus_L="$acl_cv_hardcode_minus_L" + dnl Determine whether the user wants rpath handling at all. +- AC_ARG_ENABLE(rpath, ++ AC_ARG_ENABLE([rpath], + [ --disable-rpath do not hardcode runtime library paths], + :, enable_rpath=yes) + ]) + ++dnl AC_LIB_FROMPACKAGE(name, package) ++dnl declares that libname comes from the given package. The configure file ++dnl will then not have a --with-libname-prefix option but a ++dnl --with-package-prefix option. Several libraries can come from the same ++dnl package. This declaration must occur before an AC_LIB_LINKFLAGS or similar ++dnl macro call that searches for libname. ++AC_DEFUN([AC_LIB_FROMPACKAGE], ++[ ++ pushdef([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-], ++ [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])]) ++ define([acl_frompackage_]NAME, [$2]) ++ popdef([NAME]) ++ pushdef([PACK],[$2]) ++ pushdef([PACKUP],[translit(PACK,[abcdefghijklmnopqrstuvwxyz./-], ++ [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])]) ++ define([acl_libsinpackage_]PACKUP, ++ m4_ifdef([acl_libsinpackage_]PACKUP, [acl_libsinpackage_]PACKUP[[, ]],)[lib$1]) ++ popdef([PACKUP]) ++ popdef([PACK]) ++]) ++ + dnl AC_LIB_LINKFLAGS_BODY(name [, dependencies]) searches for libname and + dnl the libraries corresponding to explicit and implicit dependencies. + dnl Sets the LIB${NAME}, LTLIB${NAME} and INC${NAME} variables. ++dnl Also, sets the LIB${NAME}_PREFIX variable to nonempty if libname was found ++dnl in ${LIB${NAME}_PREFIX}/$acl_libdirstem. + AC_DEFUN([AC_LIB_LINKFLAGS_BODY], + [ +- define([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-], +- [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])]) ++ AC_REQUIRE([AC_LIB_PREPARE_MULTILIB]) ++ pushdef([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-], ++ [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])]) ++ pushdef([PACK],[m4_ifdef([acl_frompackage_]NAME, [acl_frompackage_]NAME, lib[$1])]) ++ pushdef([PACKUP],[translit(PACK,[abcdefghijklmnopqrstuvwxyz./-], ++ [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])]) ++ pushdef([PACKLIBS],[m4_ifdef([acl_frompackage_]NAME, [acl_libsinpackage_]PACKUP, lib[$1])]) ++ dnl Autoconf >= 2.61 supports dots in --with options. ++ pushdef([P_A_C_K],[m4_if(m4_version_compare(m4_defn([m4_PACKAGE_VERSION]),[2.61]),[-1],[translit(PACK,[.],[_])],PACK)]) + dnl By default, look in $includedir and $libdir. + use_additional=yes + AC_LIB_WITH_FINAL_PREFIX([ + eval additional_includedir="$includedir" + eval additional_libdir="$libdir" + ]) +- AC_LIB_ARG_WITH([lib$1-prefix], +-[ --with-lib$1-prefix[=DIR] search for lib$1 in DIR/include and DIR/lib +- --without-lib$1-prefix don't search for lib$1 in includedir and libdir], ++ AC_ARG_WITH(P_A_C_K[-prefix], ++[[ --with-]]P_A_C_K[[-prefix[=DIR] search for ]PACKLIBS[ in DIR/include and DIR/lib ++ --without-]]P_A_C_K[[-prefix don't search for ]PACKLIBS[ in includedir and libdir]], + [ + if test "X$withval" = "Xno"; then + use_additional=no +@@ -148,7 +196,11 @@ AC_DEFUN([AC_LIB_LINKFLAGS_BODY], + ]) + else + additional_includedir="$withval/include" +- additional_libdir="$withval/lib" ++ additional_libdir="$withval/$acl_libdirstem" ++ if test "$acl_libdirstem2" != "$acl_libdirstem" \ ++ && ! test -d "$withval/$acl_libdirstem"; then ++ additional_libdir="$withval/$acl_libdirstem2" ++ fi + fi + fi + ]) +@@ -157,6 +209,7 @@ AC_DEFUN([AC_LIB_LINKFLAGS_BODY], + LIB[]NAME= + LTLIB[]NAME= + INC[]NAME= ++ LIB[]NAME[]_PREFIX= + rpathdirs= + ltrpathdirs= + names_already_handled= +@@ -196,22 +249,55 @@ AC_DEFUN([AC_LIB_LINKFLAGS_BODY], + found_la= + found_so= + found_a= ++ eval libname="$acl_libname_spec" # typically: libname=lib$name ++ if test -n "$acl_shlibext"; then ++ shrext=".$acl_shlibext" # typically: shrext=.so ++ else ++ shrext= ++ fi + if test $use_additional = yes; then +- if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then +- found_dir="$additional_libdir" +- found_so="$additional_libdir/lib$name.$shlibext" +- if test -f "$additional_libdir/lib$name.la"; then +- found_la="$additional_libdir/lib$name.la" +- fi +- else +- if test -f "$additional_libdir/lib$name.$libext"; then +- found_dir="$additional_libdir" +- found_a="$additional_libdir/lib$name.$libext" +- if test -f "$additional_libdir/lib$name.la"; then +- found_la="$additional_libdir/lib$name.la" ++ dir="$additional_libdir" ++ dnl The same code as in the loop below: ++ dnl First look for a shared library. ++ if test -n "$acl_shlibext"; then ++ if test -f "$dir/$libname$shrext"; then ++ found_dir="$dir" ++ found_so="$dir/$libname$shrext" ++ else ++ if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then ++ ver=`(cd "$dir" && \ ++ for f in "$libname$shrext".*; do echo "$f"; done \ ++ | sed -e "s,^$libname$shrext\\.,," \ ++ | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \ ++ | sed 1q ) 2>/dev/null` ++ if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then ++ found_dir="$dir" ++ found_so="$dir/$libname$shrext.$ver" ++ fi ++ else ++ eval library_names="$acl_library_names_spec" ++ for f in $library_names; do ++ if test -f "$dir/$f"; then ++ found_dir="$dir" ++ found_so="$dir/$f" ++ break ++ fi ++ done + fi + fi + fi ++ dnl Then look for a static library. ++ if test "X$found_dir" = "X"; then ++ if test -f "$dir/$libname.$acl_libext"; then ++ found_dir="$dir" ++ found_a="$dir/$libname.$acl_libext" ++ fi ++ fi ++ if test "X$found_dir" != "X"; then ++ if test -f "$dir/$libname.la"; then ++ found_la="$dir/$libname.la" ++ fi ++ fi + fi + if test "X$found_dir" = "X"; then + for x in $LDFLAGS $LTLIB[]NAME; do +@@ -219,21 +305,46 @@ AC_DEFUN([AC_LIB_LINKFLAGS_BODY], + case "$x" in + -L*) + dir=`echo "X$x" | sed -e 's/^X-L//'` +- if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then +- found_dir="$dir" +- found_so="$dir/lib$name.$shlibext" +- if test -f "$dir/lib$name.la"; then +- found_la="$dir/lib$name.la" +- fi +- else +- if test -f "$dir/lib$name.$libext"; then ++ dnl First look for a shared library. ++ if test -n "$acl_shlibext"; then ++ if test -f "$dir/$libname$shrext"; then + found_dir="$dir" +- found_a="$dir/lib$name.$libext" +- if test -f "$dir/lib$name.la"; then +- found_la="$dir/lib$name.la" ++ found_so="$dir/$libname$shrext" ++ else ++ if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then ++ ver=`(cd "$dir" && \ ++ for f in "$libname$shrext".*; do echo "$f"; done \ ++ | sed -e "s,^$libname$shrext\\.,," \ ++ | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \ ++ | sed 1q ) 2>/dev/null` ++ if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then ++ found_dir="$dir" ++ found_so="$dir/$libname$shrext.$ver" ++ fi ++ else ++ eval library_names="$acl_library_names_spec" ++ for f in $library_names; do ++ if test -f "$dir/$f"; then ++ found_dir="$dir" ++ found_so="$dir/$f" ++ break ++ fi ++ done + fi + fi + fi ++ dnl Then look for a static library. ++ if test "X$found_dir" = "X"; then ++ if test -f "$dir/$libname.$acl_libext"; then ++ found_dir="$dir" ++ found_a="$dir/$libname.$acl_libext" ++ fi ++ fi ++ if test "X$found_dir" != "X"; then ++ if test -f "$dir/$libname.la"; then ++ found_la="$dir/$libname.la" ++ fi ++ fi + ;; + esac + if test "X$found_dir" != "X"; then +@@ -248,7 +359,9 @@ AC_DEFUN([AC_LIB_LINKFLAGS_BODY], + dnl Linking with a shared library. We attempt to hardcode its + dnl directory into the executable's runpath, unless it's the + dnl standard /usr/lib. +- if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then ++ if test "$enable_rpath" = no \ ++ || test "X$found_dir" = "X/usr/$acl_libdirstem" \ ++ || test "X$found_dir" = "X/usr/$acl_libdirstem2"; then + dnl No hardcoding is needed. + LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so" + else +@@ -267,12 +380,12 @@ AC_DEFUN([AC_LIB_LINKFLAGS_BODY], + ltrpathdirs="$ltrpathdirs $found_dir" + fi + dnl The hardcoding into $LIBNAME is system dependent. +- if test "$hardcode_direct" = yes; then ++ if test "$acl_hardcode_direct" = yes; then + dnl Using DIR/libNAME.so during linking hardcodes DIR into the + dnl resulting binary. + LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so" + else +- if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then ++ if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then + dnl Use an explicit option to hardcode DIR into the resulting + dnl binary. + LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so" +@@ -303,13 +416,13 @@ AC_DEFUN([AC_LIB_LINKFLAGS_BODY], + if test -z "$haveit"; then + LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-L$found_dir" + fi +- if test "$hardcode_minus_L" != no; then ++ if test "$acl_hardcode_minus_L" != no; then + dnl FIXME: Not sure whether we should use + dnl "-L$found_dir -l$name" or "-L$found_dir $found_so" + dnl here. + LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so" + else +- dnl We cannot use $hardcode_runpath_var and LD_RUN_PATH ++ dnl We cannot use $acl_hardcode_runpath_var and LD_RUN_PATH + dnl here, because this doesn't fit in flags passed to the + dnl compiler. So give up. No hardcoding. This affects only + dnl very old systems. +@@ -334,8 +447,18 @@ AC_DEFUN([AC_LIB_LINKFLAGS_BODY], + dnl Assume the include files are nearby. + additional_includedir= + case "$found_dir" in +- */lib | */lib/) +- basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'` ++ */$acl_libdirstem | */$acl_libdirstem/) ++ basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'` ++ if test "$name" = '$1'; then ++ LIB[]NAME[]_PREFIX="$basedir" ++ fi ++ additional_includedir="$basedir/include" ++ ;; ++ */$acl_libdirstem2 | */$acl_libdirstem2/) ++ basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem2/"'*$,,'` ++ if test "$name" = '$1'; then ++ LIB[]NAME[]_PREFIX="$basedir" ++ fi + additional_includedir="$basedir/include" + ;; + esac +@@ -396,9 +519,11 @@ AC_DEFUN([AC_LIB_LINKFLAGS_BODY], + dnl 3. if it's already present in $LDFLAGS or the already + dnl constructed $LIBNAME, + dnl 4. if it doesn't exist as a directory. +- if test "X$additional_libdir" != "X/usr/lib"; then ++ if test "X$additional_libdir" != "X/usr/$acl_libdirstem" \ ++ && test "X$additional_libdir" != "X/usr/$acl_libdirstem2"; then + haveit= +- if test "X$additional_libdir" = "X/usr/local/lib"; then ++ if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem" \ ++ || test "X$additional_libdir" = "X/usr/local/$acl_libdirstem2"; then + if test -n "$GCC"; then + case $host_os in + linux* | gnu* | k*bsd*-gnu) haveit=yes;; +@@ -497,18 +622,18 @@ AC_DEFUN([AC_LIB_LINKFLAGS_BODY], + done + done + if test "X$rpathdirs" != "X"; then +- if test -n "$hardcode_libdir_separator"; then ++ if test -n "$acl_hardcode_libdir_separator"; then + dnl Weird platform: only the last -rpath option counts, the user must + dnl pass all path elements in one option. We can arrange that for a + dnl single library, but not when more than one $LIBNAMEs are used. + alldirs= + for found_dir in $rpathdirs; do +- alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir" ++ alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$found_dir" + done +- dnl Note: hardcode_libdir_flag_spec uses $libdir and $wl. ++ dnl Note: acl_hardcode_libdir_flag_spec uses $libdir and $wl. + acl_save_libdir="$libdir" + libdir="$alldirs" +- eval flag="$hardcode_libdir_flag_spec" ++ eval flag="$acl_hardcode_libdir_flag_spec" + libdir="$acl_save_libdir" + LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$flag" + else +@@ -516,7 +641,7 @@ AC_DEFUN([AC_LIB_LINKFLAGS_BODY], + for found_dir in $rpathdirs; do + acl_save_libdir="$libdir" + libdir="$found_dir" +- eval flag="$hardcode_libdir_flag_spec" ++ eval flag="$acl_hardcode_libdir_flag_spec" + libdir="$acl_save_libdir" + LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$flag" + done +@@ -529,6 +654,11 @@ AC_DEFUN([AC_LIB_LINKFLAGS_BODY], + LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-R$found_dir" + done + fi ++ popdef([P_A_C_K]) ++ popdef([PACKLIBS]) ++ popdef([PACKUP]) ++ popdef([PACK]) ++ popdef([NAME]) + ]) + + dnl AC_LIB_APPENDTOVAR(VAR, CONTENTS) appends the elements of CONTENTS to VAR, +@@ -551,3 +681,81 @@ AC_DEFUN([AC_LIB_APPENDTOVAR], + fi + done + ]) ++ ++dnl For those cases where a variable contains several -L and -l options ++dnl referring to unknown libraries and directories, this macro determines the ++dnl necessary additional linker options for the runtime path. ++dnl AC_LIB_LINKFLAGS_FROM_LIBS([LDADDVAR], [LIBSVALUE], [USE-LIBTOOL]) ++dnl sets LDADDVAR to linker options needed together with LIBSVALUE. ++dnl If USE-LIBTOOL evaluates to non-empty, linking with libtool is assumed, ++dnl otherwise linking without libtool is assumed. ++AC_DEFUN([AC_LIB_LINKFLAGS_FROM_LIBS], ++[ ++ AC_REQUIRE([AC_LIB_RPATH]) ++ AC_REQUIRE([AC_LIB_PREPARE_MULTILIB]) ++ $1= ++ if test "$enable_rpath" != no; then ++ if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then ++ dnl Use an explicit option to hardcode directories into the resulting ++ dnl binary. ++ rpathdirs= ++ next= ++ for opt in $2; do ++ if test -n "$next"; then ++ dir="$next" ++ dnl No need to hardcode the standard /usr/lib. ++ if test "X$dir" != "X/usr/$acl_libdirstem" \ ++ && test "X$dir" != "X/usr/$acl_libdirstem2"; then ++ rpathdirs="$rpathdirs $dir" ++ fi ++ next= ++ else ++ case $opt in ++ -L) next=yes ;; ++ -L*) dir=`echo "X$opt" | sed -e 's,^X-L,,'` ++ dnl No need to hardcode the standard /usr/lib. ++ if test "X$dir" != "X/usr/$acl_libdirstem" \ ++ && test "X$dir" != "X/usr/$acl_libdirstem2"; then ++ rpathdirs="$rpathdirs $dir" ++ fi ++ next= ;; ++ *) next= ;; ++ esac ++ fi ++ done ++ if test "X$rpathdirs" != "X"; then ++ if test -n ""$3""; then ++ dnl libtool is used for linking. Use -R options. ++ for dir in $rpathdirs; do ++ $1="${$1}${$1:+ }-R$dir" ++ done ++ else ++ dnl The linker is used for linking directly. ++ if test -n "$acl_hardcode_libdir_separator"; then ++ dnl Weird platform: only the last -rpath option counts, the user ++ dnl must pass all path elements in one option. ++ alldirs= ++ for dir in $rpathdirs; do ++ alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$dir" ++ done ++ acl_save_libdir="$libdir" ++ libdir="$alldirs" ++ eval flag="$acl_hardcode_libdir_flag_spec" ++ libdir="$acl_save_libdir" ++ $1="$flag" ++ else ++ dnl The -rpath options are cumulative. ++ for dir in $rpathdirs; do ++ acl_save_libdir="$libdir" ++ libdir="$dir" ++ eval flag="$acl_hardcode_libdir_flag_spec" ++ libdir="$acl_save_libdir" ++ $1="${$1}${$1:+ }$flag" ++ done ++ fi ++ fi ++ fi ++ fi ++ fi ++ AC_SUBST([$1]) ++]) +diff --git a/m4/lib-prefix.m4 b/m4/lib-prefix.m4 +index 0d895ca..4b7ee33 100644 +--- a/m4/lib-prefix.m4 ++++ b/m4/lib-prefix.m4 +@@ -1,5 +1,5 @@ +-# lib-prefix.m4 serial 4 (gettext-0.14.2) +-dnl Copyright (C) 2001-2005 Free Software Foundation, Inc. ++# lib-prefix.m4 serial 7 (gettext-0.18) ++dnl Copyright (C) 2001-2005, 2008-2009 Free Software Foundation, Inc. + dnl This file is free software; the Free Software Foundation + dnl gives unlimited permission to copy and/or distribute it, + dnl with or without modifications, as long as this notice is preserved. +@@ -24,6 +24,7 @@ AC_DEFUN([AC_LIB_PREFIX], + AC_BEFORE([$0], [AC_LIB_LINKFLAGS]) + AC_REQUIRE([AC_PROG_CC]) + AC_REQUIRE([AC_CANONICAL_HOST]) ++ AC_REQUIRE([AC_LIB_PREPARE_MULTILIB]) + AC_REQUIRE([AC_LIB_PREPARE_PREFIX]) + dnl By default, look in $includedir and $libdir. + use_additional=yes +@@ -45,7 +46,7 @@ AC_DEFUN([AC_LIB_PREFIX], + ]) + else + additional_includedir="$withval/include" +- additional_libdir="$withval/lib" ++ additional_libdir="$withval/$acl_libdirstem" + fi + fi + ]) +@@ -87,7 +88,7 @@ AC_DEFUN([AC_LIB_PREFIX], + dnl 2. if it's already present in $LDFLAGS, + dnl 3. if it's /usr/local/lib and we are using GCC on Linux, + dnl 4. if it doesn't exist as a directory. +- if test "X$additional_libdir" != "X/usr/lib"; then ++ if test "X$additional_libdir" != "X/usr/$acl_libdirstem"; then + haveit= + for x in $LDFLAGS; do + AC_LIB_WITH_FINAL_PREFIX([eval x="$x"]) +@@ -97,7 +98,7 @@ AC_DEFUN([AC_LIB_PREFIX], + fi + done + if test -z "$haveit"; then +- if test "X$additional_libdir" = "X/usr/local/lib"; then ++ if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem"; then + if test -n "$GCC"; then + case $host_os in + linux*) haveit=yes;; +@@ -151,3 +152,73 @@ AC_DEFUN([AC_LIB_WITH_FINAL_PREFIX], + exec_prefix="$acl_save_exec_prefix" + prefix="$acl_save_prefix" + ]) ++ ++dnl AC_LIB_PREPARE_MULTILIB creates ++dnl - a variable acl_libdirstem, containing the basename of the libdir, either ++dnl "lib" or "lib64" or "lib/64", ++dnl - a variable acl_libdirstem2, as a secondary possible value for ++dnl acl_libdirstem, either the same as acl_libdirstem or "lib/sparcv9" or ++dnl "lib/amd64". ++AC_DEFUN([AC_LIB_PREPARE_MULTILIB], ++[ ++ dnl There is no formal standard regarding lib and lib64. ++ dnl On glibc systems, the current practice is that on a system supporting ++ dnl 32-bit and 64-bit instruction sets or ABIs, 64-bit libraries go under ++ dnl $prefix/lib64 and 32-bit libraries go under $prefix/lib. We determine ++ dnl the compiler's default mode by looking at the compiler's library search ++ dnl path. If at least one of its elements ends in /lib64 or points to a ++ dnl directory whose absolute pathname ends in /lib64, we assume a 64-bit ABI. ++ dnl Otherwise we use the default, namely "lib". ++ dnl On Solaris systems, the current practice is that on a system supporting ++ dnl 32-bit and 64-bit instruction sets or ABIs, 64-bit libraries go under ++ dnl $prefix/lib/64 (which is a symlink to either $prefix/lib/sparcv9 or ++ dnl $prefix/lib/amd64) and 32-bit libraries go under $prefix/lib. ++ AC_REQUIRE([AC_CANONICAL_HOST]) ++ acl_libdirstem=lib ++ acl_libdirstem2= ++ case "$host_os" in ++ solaris*) ++ dnl See Solaris 10 Software Developer Collection > Solaris 64-bit Developer's Guide > The Development Environment ++ dnl http://docs.sun.com/app/docs/doc/816-5138/dev-env?l=en&a=view. ++ dnl "Portable Makefiles should refer to any library directories using the 64 symbolic link." ++ dnl But we want to recognize the sparcv9 or amd64 subdirectory also if the ++ dnl symlink is missing, so we set acl_libdirstem2 too. ++ AC_CACHE_CHECK([for 64-bit host], [gl_cv_solaris_64bit], ++ [AC_EGREP_CPP([sixtyfour bits], [ ++#ifdef _LP64 ++sixtyfour bits ++#endif ++ ], [gl_cv_solaris_64bit=yes], [gl_cv_solaris_64bit=no]) ++ ]) ++ if test $gl_cv_solaris_64bit = yes; then ++ acl_libdirstem=lib/64 ++ case "$host_cpu" in ++ sparc*) acl_libdirstem2=lib/sparcv9 ;; ++ i*86 | x86_64) acl_libdirstem2=lib/amd64 ;; ++ esac ++ fi ++ ;; ++ *) ++ searchpath=`(LC_ALL=C $CC -print-search-dirs) 2>/dev/null | sed -n -e 's,^libraries: ,,p' | sed -e 's,^=,,'` ++ if test -n "$searchpath"; then ++ acl_save_IFS="${IFS= }"; IFS=":" ++ for searchdir in $searchpath; do ++ if test -d "$searchdir"; then ++ case "$searchdir" in ++ */lib64/ | */lib64 ) acl_libdirstem=lib64 ;; ++ */../ | */.. ) ++ # Better ignore directories of this form. They are misleading. ++ ;; ++ *) searchdir=`cd "$searchdir" && pwd` ++ case "$searchdir" in ++ */lib64 ) acl_libdirstem=lib64 ;; ++ esac ;; ++ esac ++ fi ++ done ++ IFS="$acl_save_IFS" ++ fi ++ ;; ++ esac ++ test -n "$acl_libdirstem2" || acl_libdirstem2="$acl_libdirstem" ++]) +-- +1.6.0.6 + diff --git a/pkgs/core/ppl/ppl.nm b/pkgs/core/ppl/ppl.nm new file mode 100644 index 0000000..a692b23 --- /dev/null +++ b/pkgs/core/ppl/ppl.nm @@ -0,0 +1,68 @@ +############################################################################### +# # +# IPFire.org - A linux based firewall # +# Copyright (C) 2007, 2008 Michael Tremer & Christian Schmidt # +# # +# This program is free software: you can redistribute it and/or modify # +# it under the terms of the GNU General Public License as published by # +# the Free Software Foundation, either version 3 of the License, or # +# (at your option) any later version. # +# # +# This program is distributed in the hope that it will be useful, # +# but WITHOUT ANY WARRANTY; without even the implied warranty of # +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # +# GNU General Public License for more details. # +# # +# You should have received a copy of the GNU General Public License # +# along with this program. If not, see http://www.gnu.org/licenses/. # +# # +############################################################################### + +############################################################################### +# Definitions +############################################################################### + +include $(PKGROOT)/Include + +PKG_NAME = ppl +PKG_VER = 0.10.2 +PKG_REL = 0 + +PKG_MAINTAINER = Michael Tremer michael.tremer@ipfire.org +PKG_GROUP = Development/Libraries +PKG_URL = http://www.cs.unipr.it/ppl/ +PKG_LICENSE = GPLv3+ +PKG_SUMMARY = The Parma Polyhedra Library: a library of numerical abstractions. + +PKG_BUILD_DEPS+= autoconf automake m4 +PKG_DEPS += gmp + +define PKG_DESCRIPTION + The Parma Polyhedra Library (PPL) is a library for the manipulation of \ + (not necessarily closed) convex polyhedra and other numerical \ + abstractions. The applications of convex polyhedra include program \ + analysis, optimized compilation, integer and combinatorial \ + optimization and statistical data-editing. The Parma Polyhedra \ + Library comes with several user friendly interfaces, is fully dynamic \ + (available virtual memory is the only limitation to the dimension of \ + anything), written in accordance to all the applicable standards, \ + exception-safe, rather efficient, thoroughly documented, and free \ + software. This package provides all what is necessary to run \ + applications using the PPL through its C and C++ interfaces. +endef + +PKG_TARBALL = $(THISAPP).tar.gz + +CONFIGURE_OPTIONS += \ + --enable-interfaces="c cxx" \ + --disable-debugging + +PARALLELISMFLAGS = + +define STAGE_PREPARE_CMDS + cd $(DIR_APP) && autoreconf -f +endef + +define STAGE_TEST + cd $(DIR_APP) && make check +endef
hooks/post-receive -- IPFire 3.x development tree