aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMagnus Granberg (Zorry) <zorry@gentoo.org>2010-04-23 16:49:23 +0200
committerMagnus Granberg (Zorry) <zorry@gentoo.org>2010-04-23 16:49:23 +0200
commit5bdbcd5ba754af65a96cf77210d5a8e5674005ef (patch)
tree3f0b1057361474c78ca9bd4240e26228b4f2f769 /gcc-4.4.3/piepatch
parentfix some typos in gcc-4.4.3/piepatch (diff)
downloadhardened-gccpatchset-5bdbcd5ba754af65a96cf77210d5a8e5674005ef.tar.gz
hardened-gccpatchset-5bdbcd5ba754af65a96cf77210d5a8e5674005ef.tar.bz2
hardened-gccpatchset-5bdbcd5ba754af65a96cf77210d5a8e5674005ef.zip
Updated pipatches to 0.4.1 in gcc 4.4.3
Diffstat (limited to 'gcc-4.4.3/piepatch')
-rw-r--r--gcc-4.4.3/piepatch/10_all_gcc44_configure.patch197
-rw-r--r--gcc-4.4.3/piepatch/11_all_gcc44_config.in.patch18
-rw-r--r--gcc-4.4.3/piepatch/12_all_gcc44_Makefile.in.patch38
-rw-r--r--gcc-4.4.3/piepatch/20_all_gcc44_gcc.c.patch8
-rw-r--r--gcc-4.4.3/piepatch/21_all_gcc44_decl-tls-model.patch6
-rw-r--r--gcc-4.4.3/piepatch/30_all_gcc44_esp.h.patch32
-rw-r--r--gcc-4.4.3/piepatch/33_all_gcc44_config_rs6000_linux64.h.patch4
-rw-r--r--gcc-4.4.3/piepatch/35_all_gcc44_config_crtbegints.patch6
-rw-r--r--gcc-4.4.3/piepatch/40_all_gcc44_cp_lang-specs.h.patch4
-rw-r--r--gcc-4.4.3/piepatch/41_all_gcc44_objc_lang-specs.h.patch4
-rw-r--r--gcc-4.4.3/piepatch/42_all_gcc44_objcp_lang-specs.h.patch4
-rw-r--r--gcc-4.4.3/piepatch/60_all_gcc44_invoke.texi.patch6
-rw-r--r--gcc-4.4.3/piepatch/README.Changelog18
-rw-r--r--gcc-4.4.3/piepatch/README.history115
14 files changed, 314 insertions, 146 deletions
diff --git a/gcc-4.4.3/piepatch/10_all_gcc44_configure.patch b/gcc-4.4.3/piepatch/10_all_gcc44_configure.patch
index 722a284..1cf7bd1 100644
--- a/gcc-4.4.3/piepatch/10_all_gcc44_configure.patch
+++ b/gcc-4.4.3/piepatch/10_all_gcc44_configure.patch
@@ -1,37 +1,41 @@
-2010-04-19 Magnus Granberg <zorry@gentoo.org>
+2010-04-22 Magnus Granberg <zorry@gentoo.org>
* configure Add --enable-esp. Add-fno-stack-protector
to stage1_cflags.
- * gcc/configure Check -z now and -z relro.
+ * gcc/configure Add --enable-esp. Check -z now and -z relro.
Check if we support -fstack-protector and define HAVE_GCC_SSP.
+ Check if we support -fPIE and -pie and define HAVE_GCC_LD_PIE.
Define ENABLE_ESP.
Check if we support crtbeginTS and define ENABLE_CRTBEGINTS.
* libmudflap/configure Add AC_SUBST enable_esp.
---- configure 2009-04-29 01:16:59.000000000 +0200
-+++ configure 2009-07-21 18:45:41.000000000 +0200
+--- a/configure 2009-04-29 01:16:59.000000000 +0200
++++ b/configure 2009-07-21 18:45:41.000000000 +0200
@@ -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_esp 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_esp_set 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 @@
+@@ -934,6 +934,14 @@
--enable-FEATURE[=ARG] include FEATURE [ARG=yes]
--enable-gold use gold instead of ld
--enable-libada build libada directory
-+ --enable-esp
-+ Enable Stack protector and Position independent executable
-+ as default if we have suppot for it when compiling
++ --enable-esp[=all]
++ Enable Stack protector, Position independent executable 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-esp=all will enable SSP and PIE
++ --enable-esp=nossp will disable SSP
++ --enable-esp=nopie will disable PIE
++ Linux targets supported i*86, x86_64, ppc*, sparc* 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 @@
+@@ -2145,6 +2153,30 @@
noconfigdirs="$noconfigdirs gnattools"
fi
@@ -41,8 +45,13 @@
+ enableval="$enable_esp"
+
+ case $target in
-+ i?86*-*-linux* | x86_64*-*-linux* | powerpc-*-linux* | powerpc64-*-linux* | arm*-*-linux* | ia64-*-linux*)
-+ enable_esp=yes
++ i?86*-*-linux* | x86_64*-*-linux* | ppc*-*-linux* | sparc*-*-linux* | arm*-*-linux*)
++ case ,${enable_esp}, in
++ ,,)
++ enable_esp_set=no ;;
++ ,nopie,|,nossp,|,all,)
++ enable_esp_set=yes ;;
++ esac
+ ;;
+ *)
+ { { echo "$as_me:$LINENO: error: *** --enable-esp is not supported on this $target target." >&5
@@ -61,31 +70,46 @@
*) stage1_cflags="-g -J" ;;
esac ;;
esac
-+if test x$enable_esp = xyes; then
++if test x$enable_esp_set = 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
-@@ -13234,6 +13262,7 @@
+@@ -13236,6 +13268,7 @@
s,@build_subdir@,$build_subdir,;t t
s,@host_subdir@,$host_subdir,;t t
s,@target_subdir@,$target_subdir,;t t
-+s,@enable_esp@,$enable_esp,;t t
++s,@enable_esp_set@,$enable_esp_set,;t t
s,@CC@,$CC,;t t
s,@CFLAGS@,$CFLAGS,;t t
s,@LDFLAGS@,$LDFLAGS,;t t
---- gcc/configure 2009-04-29 01:16:54.000000000 +0200
-+++ gcc/configure 2009-06-08 01:03:01.000000000 +0200
+--- a/gcc/configure 2009-04-29 01:16:54.000000000 +0200
++++ b/gcc/configure 2009-06-08 01:03:01.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_esp 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_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_esp_set 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`
+@@ -1078,6 +1076,14 @@
+ --enable-fast-install[=PKGS]
+ optimize for fast installation [default=yes]
+ --disable-libtool-lock avoid locking (might break parallel builds)
++ --enable-esp[=all]
++ Enable Stack protector, Position independent executable as
++ default if we have suppot for it when compiling
++ and link with -z relro and -z now as default.
++ --enable-esp=all will enable SSP and PIE
++ --enable-esp=nossp will disable SSP
++ --enable-esp=nopie will disable PIE
++ Linux targets supported i*86, x86_64, ppc*, sparc* and arm*
+ --enable-maintainer-mode
+ enable make rules and dependencies not useful
+ (and sometimes confusing) to the casual installer
@@ -24177,6 +24182,50 @@
;;
esac
@@ -137,10 +161,41 @@
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 +23737,146 @@
+@@ -24411,6 +23745,253 @@
fi
++# Check whether --enable-esp=(no|nopie|nossp|all) was given.
++# Check whether --enable-esp or --disable-esp was given.
++if test "${enable_esp+set}" = set; then
++ enableval="$enable_esp"
++
++ case ,${enable_esp}, in
++ ,no,|,,)
++ enable_esp_set=no
++ enable_esp_pie=no
++ enable_esp_ssp=no
++ ;;
++ ,nopie,)
++ enable_esp_set=yes
++ enable_esp_pie=no
++ enable_esp_ssp=yes
++ ;;
++ ,nossp,)
++ enable_esp_set=yes
++ enable_esp_pie=yes
++ enable_esp_ssp=no
++ ;;
++ ,all,)
++ enable_esp_set=yes
++ enable_esp_pie=yes
++ enable_esp_ssp=yes
++ ;;
++ esac
++
++fi;
++
++
+if test x$gcc_cv_libc_provides_ssp = xyes; then
+ echo "$as_me:$LINENO: checking whether $CC support -fstack-protector" >&5
+echo $ECHO_N "checking whether $CC support -fstack-protector... $ECHO_C" >&6
@@ -154,11 +209,15 @@
+#ifndef __SSP__
+#error
+#endif
++int
++main() {
++return 0 ;
++}
+
+_ACEOF
-+rm -f conftest.$ac_objext
-+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
-+ (eval $ac_compile) 2>conftest.er1
++rm -f conftest.$ac_objext conftest$ac_exeext
++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
++ (eval $ac_link) 2>conftest.er1
+ ac_status=$?
+ grep -v '^ *+' conftest.er1 >conftest.err
+ rm -f conftest.er1
@@ -172,7 +231,7 @@
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; } &&
-+ { ac_try='test -s conftest.$ac_objext'
++ { ac_try='test -s conftest$ac_exeext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
@@ -198,23 +257,92 @@
+
+gcc_cv_cc_stack_protector=no
+fi
-+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
++rm -f conftest.err conftest.$ac_objext \
++ conftest$ac_exeext conftest.$ac_ext
+ CFLAGS="$saved_CFLAGS"
+
+fi
+echo "$as_me:$LINENO: result: $gcc_cv_cc_stack_protector" >&5
+echo "${ECHO_T}$gcc_cv_cc_stack_protector" >&6
+fi
-+if test x$gcc_cv_cc_stack_protector = xyes; then
++if test x$gcc_cv_cc_stack_protector = xyes && test x$enable_esp_ssp = xyes; then
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_GCC_SSP 1
+_ACEOF
+
++ enable_esp_default_ssp=yes
++ echo "$as_me:$LINENO: result: Adding -fstack-protector as default compiler options... $enable_esp_default_ssp" >&5
++echo "${ECHO_T}Adding -fstack-protector as default compiler options... $enable_esp_default_ssp" >&6
+fi
+
++if test x$gcc_cv_ld_pie = xyes && test x$lt_cv_prog_compiler_pic_works = xyes; then
++ echo "$as_me:$LINENO: checking whether $CC support -fPIE and link with -pie" >&5
++echo $ECHO_N "checking whether $CC support -fPIE and and link with -pie... $ECHO_C" >&6
++if test "${gcc_cv_cc_ld_pie+set}" = set; then
++ echo $ECHO_N "(cached) $ECHO_C" >&6
++else
++
++ saved_CFLAGS="$CFLAGS"
++ CFLAGS="$CFLAGS -fPIE -pie"
++ cat >conftest.$ac_ext <<_ACEOF
++#ifndef __PIE__
++#error
++#endif
++int
++main() {
++ return 0;
++}
+
-+if test x$enable_esp = xyes ; then
++_ACEOF
++rm -f conftest.$ac_objext conftest$ac_exeext
++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
++ (eval $ac_link) 2>conftest.er1
++ ac_status=$?
++ grep -v '^ *+' conftest.er1 >conftest.err
++ rm -f conftest.er1
++ cat conftest.err >&5
++ echo "$as_me:$LINENO: \$? = $ac_status" >&5
++ (exit $ac_status); } &&
++ { ac_try='test -z "$ac_c_werror_flag"
++ || test ! -s conftest.err'
++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
++ (eval $ac_try) 2>&5
++ ac_status=$?
++ echo "$as_me:$LINENO: \$? = $ac_status" >&5
++ (exit $ac_status); }; } &&
++ { ac_try='test -s conftest$ac_exeext'
++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
++ (eval $ac_try) 2>&5
++ ac_status=$?
++ echo "$as_me:$LINENO: \$? = $ac_status" >&5
++ (exit $ac_status); }; }; then
++ gcc_cv_cc_ld_pie=yes
++else
++ echo "$as_me: failed program was:" >&5
++sed 's/^/| /' conftest.$ac_ext >&5
++
++gcc_cv_cc_ld_pie=no
++fi
++rm -f conftest.err conftest.$ac_objext \
++ conftest$ac_exeext conftest.$ac_ext
++ CFLAGS="$saved_CFLAGS"
++
++fi
++echo "$as_me:$LINENO: result: $gcc_cv_cc_ld_pie" >&5
++echo "${ECHO_T}$gcc_cv_cc_ld_pie" >&6
++fi
++if test x$gcc_cv_cc_ld_pie = xyes && test x$enable_esp_pie = xyes; then
++
++cat >>confdefs.h <<\_ACEOF
++#define HAVE_GCC_LD_PIE 1
++_ACEOF
++
++ enable_esp_default_pie=yes
++ echo "$as_me:$LINENO: result: Adding -fPIE as default compiler options and -pie as default linking options... $enable_esp_default_pie" >&5
++echo "${ECHO_T}Adding -fPIE as default compiler options and -pie as default linking options... $enable_esp_default_pie" >&6
++fi
++if test x$enable_esp_set = xyes ; then
+case $target in
+ ia64*-*-linux*)
+ if test x$gcc_cv_ld_now = xyes; then
@@ -235,7 +363,7 @@
+ ;;
+ esac
+else
-+ enable_esp_ld=no
++ enable_espf_ld=no
+fi
+if test x$enable_esp_ld = xyes; then
+
@@ -243,6 +371,9 @@
+#define ENABLE_ESP 1
+_ACEOF
+
++ enable_esp_default_nowrelro=yes
++ echo "$as_me:$LINENO: result: Adding -z now and -z relro as default linking options... $enable_esp_default_nowrelro" >&5
++echo "${ECHO_T}Adding -z now and -z relro as default linking options... $enable_esp_default_nowrelro" >&6
+fi
+if test x$enable_esp = xyes && test x$enable_esp_ld = xno; then
+ { { echo "$as_me:$LINENO: error: *** --enable-esp is not supported. You don't have -z,relro or -z,now support in the linker." >&5
@@ -256,12 +387,12 @@
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+
-+if test x$enable_esp = xyes ; then
++if test x$enable_esp_set = xyes ; then
+ case "$target" in
+ ia64*-*-linux*)
+ enable_crtbeginTS=no ;;
+ *-*-linux*)
-+ if test x$gcc_cv_ld_pie = xyes && test x$lt_cv_prog_compiler_static_works = xyes; then
++ if test x$enable_esp_default_pie = xyes && test x$lt_cv_prog_compiler_static_works = xyes; then
+ enable_crtbeginTS=yes
+ fi
+ ;;
@@ -288,13 +419,13 @@
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_esp@,$enable_esp,;t t
++s,@enable_esp_set@,$enable_esp_set,;t t
+s,@enable_crtbeginTS@,$enable_crtbeginTS,;t t
s,@GGC@,$GGC,;t t
s,@zlibdir@,$zlibdir,;t t
s,@zlibinc@,$zlibinc,;t t
---- libmudflap/configure 2009-04-29 01:16:55.000000000 +0200
-+++ libmudflap/configure 2009-07-21 18:28:52.000000000 +0200
+--- a/libmudflap/configure 2009-04-29 01:16:55.000000000 +0200
++++ b/libmudflap/configure 2009-07-21 18:28:52.000000000 +0200
@@ -458,7 +458,7 @@
# include <unistd.h>
#endif"
diff --git a/gcc-4.4.3/piepatch/11_all_gcc44_config.in.patch b/gcc-4.4.3/piepatch/11_all_gcc44_config.in.patch
index bbdd2f0..090cd44 100644
--- a/gcc-4.4.3/piepatch/11_all_gcc44_config.in.patch
+++ b/gcc-4.4.3/piepatch/11_all_gcc44_config.in.patch
@@ -1,10 +1,10 @@
-2010-04-19 Magnus Granberg <zorry@ume.nu>
+2010-04-22 Magnus Granberg <zorry@gentoo.org>
* gcc/config.in Add ENABLE_CRTBEGINTS ENABLE_ESP and
- HAVE_GCC_SSP
+ HAVE_GCC_SSP HAVE_GCC_LD_PIE
---- gcc/config.in 2009-04-21 11:08:08.000000000 +0200
-+++ gcc/config.in 2009-05-12 00:10:08.000000000 +0200
+--- a/gcc/config.in 2009-04-21 11:08:08.000000000 +0200
++++ b/gcc/config.in 2009-05-12 00:10:08.000000000 +0200
@@ -46,6 +46,12 @@
#endif
@@ -31,16 +31,22 @@
/* Define to 1 to enable fixed-point arithmetic extension to C. */
#ifndef USED_FOR_TARGET
#undef ENABLE_FIXED_POINT
-@@ -912,6 +924,12 @@
+@@ -912,6 +924,18 @@
#endif
-+/* Define to 1 if your compiler supports -fstack-protector */
++/* Define if your compiler supports SSP */
+#ifndef USED_FOR_TARGET
+#undef HAVE_GCC_SSP
+#endif
+
+
++/* Define if your compiler and linker supports PIE */
++#ifndef USED_FOR_TARGET
++#undef HAVE_GCC_LD_PIE
++#endif
++
++
/* Define to 1 if you have the `getchar_unlocked' function. */
#ifndef USED_FOR_TARGET
#undef HAVE_GETCHAR_UNLOCKED
diff --git a/gcc-4.4.3/piepatch/12_all_gcc44_Makefile.in.patch b/gcc-4.4.3/piepatch/12_all_gcc44_Makefile.in.patch
index 9c43a4f..250ab51 100644
--- a/gcc-4.4.3/piepatch/12_all_gcc44_Makefile.in.patch
+++ b/gcc-4.4.3/piepatch/12_all_gcc44_Makefile.in.patch
@@ -1,4 +1,4 @@
-2009-09-20 Magnus Granberg <zorry@ume.nu>
+2010-04-22 Magnus Granberg <zorry@gentoo.org>
* Makefile.in We add -fno-stack-protector to
BOOT_CFLAGS, LIBCFLAGS and LIBCXXFLAGS if enable_esp yes.
@@ -11,20 +11,20 @@
* libgcc/Makefile.in Add crtbeginTS.o to EXTRA_PARTS if enable_crtbeginTS yes
We add new file crtbeginTS.o if enable_crtbeginTS yes
-2009-07-21 Magnus Granberg <zorry@ume.nu>, Kees Cook <kees@outflux.net>
+2010-04-23 Magnus Granberg <zorry@gentoo.org>, Kees Cook <kees@outflux.net>
LP #344502
* libmudflap/Makefiles.in Add -fno-stack-protector -U_FORTIFY_SOURCE
- to AM_CFLAGS if enable_esp yes.
+ to AM_CFLAGS ifdef enable_esp.
---- Makefile.in 2009-04-14 10:57:33.000000000 +0200
-+++ Makefile.in 2009-07-21 05:29:54.000000000 +0200
+--- a/Makefile.in 2009-04-14 10:57:33.000000000 +0200
++++ b/Makefile.in 2009-07-21 05:29:54.000000000 +0200
@@ -305,9 +305,17 @@
BUILD_PREFIX = @BUILD_PREFIX@
BUILD_PREFIX_1 = @BUILD_PREFIX_1@
+# Some stuff don't compile with SSP
-+enable_esp = @enable_esp@
++enable_esp = @enable_esp_set@
+ifeq ($(enable_esp),yes)
+ESP_NOSSP_CFLAGS = -fno-stack-protector
+else
@@ -58,7 +58,7 @@
+# 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_esp = @enable_esp@
++enable_esp = @enable_esp_set@
+ifeq ($(enable_esp),yes)
+ESP_NOPIE_CFLAGS = -fno-PIE
+ESP_NOSSP_CFLAGS = -fno-stack-protector
@@ -134,7 +134,7 @@
-c $(srcdir)/crtstuff.c -DCRT_BEGIN -DCRTSTUFFT_O \
-o $(T)crtbeginT$(objext)
-+# This is a version of crtbegin for -static -fPIE links if esp is enable.
++# 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)
@@ -155,8 +155,8 @@
$(out_file) $(OUTPUT_OPTION)
# Build auxiliary files that support ecoff format.
---- libgcc/Makefile.in 2009-04-10 01:23:07.000000000 +0200
-+++ libgcc/Makefile.in 2009-09-08 03:42:47.000000000 +0200
+--- a/libgcc/Makefile.in 2009-04-10 01:23:07.000000000 +0200
++++ b/libgcc/Makefile.in 2009-09-08 03:42:47.000000000 +0200
@@ -280,6 +280,12 @@
gen-hide-list = echo > \$@
endif
@@ -184,26 +184,24 @@
endif
# Build extra startfiles in the libgcc directory.
---- libmudflap/Makefile.in 2009-04-29 01:16:56.000000000 +0200
-+++ libmudflap/Makefile.in 2009-07-21 05:41:56.000000000 +0200
-@@ -253,10 +253,18 @@
+--- a/libmudflap/Makefile.in 2009-04-29 01:16:56.000000000 +0200
++++ b/libmudflap/Makefile.in 2009-07-21 05:41:56.000000000 +0200
+@@ -253,9 +253,17 @@
MAINT_CHARSET = latin1
SUBDIRS = testsuite
-+# Some stuff don't compile with PIE or SSP
++# Some stuff don't compile with SSP and FORTIFY_SOURCE
+enable_esp = @enable_esp@
-+ifeq ($(enable_esp),yes)
-+NO_ESP_CFLAGS = -fno-stack-protector -U_FORTIFY_SOURCE
++ifdef enable_esp
++ NO_ESP_CFLAGS = -fno-stack-protector -U_FORTIFY_SOURCE
+else
-+NO_ESP_CFLAGS =
++ NO_ESP_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_ESP_CFLAGS)
-+@LIBMUDFLAPTH_FALSE@libmudflapth =
+ @LIBMUDFLAPTH_FALSE@libmudflapth =
@LIBMUDFLAPTH_TRUE@libmudflapth = libmudflapth.la
toolexeclib_LTLIBRARIES = libmudflap.la $(libmudflapth)
- libsubincludedir = $(libdir)/gcc/$(target_noncanonical)/$(gcc_version)/include
diff --git a/gcc-4.4.3/piepatch/20_all_gcc44_gcc.c.patch b/gcc-4.4.3/piepatch/20_all_gcc44_gcc.c.patch
index a4a0ce2..8b73fc8 100644
--- a/gcc-4.4.3/piepatch/20_all_gcc44_gcc.c.patch
+++ b/gcc-4.4.3/piepatch/20_all_gcc44_gcc.c.patch
@@ -2,7 +2,7 @@
* gcc/gcc.c include esp.h
static const char *cc1_spec We set that in esp.h if ENABLE_ESP.
- *cc1_options Add esp_options_pie_check if ENABLE_ESP.
+ *cc1_options Add espf_options_pie_check if ENABLE_ESP.
#ifdef EXTRA_SPECS: Add ESP_EXTRA_SPECS
main(): Add do_self_spec esp_command_options_spec()
@@ -14,8 +14,8 @@
* gcc/gcc.c default_compilers[] Add %(esp_options)
*cpp_unique_options Add %(esp_cpp_unique_options)
---- gcc/gcc.c.zorry 2009-04-29 01:17:00.000000000 +0200
-+++ gcc/gcc.c 2009-07-22 20:18:10.000000000 +0200
+--- a/gcc/gcc.c 2009-04-29 01:17:00.000000000 +0200
++++ b/gcc/gcc.c 2009-07-22 20:18:10.000000000 +0200
@@ -83,6 +83,7 @@
#include "gcc.h"
#include "flags.h"
@@ -58,7 +58,7 @@
%(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) %(esp_options)}\
++ %(cc1_options) %(espf_options)}\
%{!save-temps:%{!traditional-cpp:%{!no-integrated-cpp:\
- cc1 %(cpp_unique_options) %(cc1_options)}}}\
+ cc1 %(cpp_unique_options) %(cc1_options) %(esp_options)}}}\
diff --git a/gcc-4.4.3/piepatch/21_all_gcc44_decl-tls-model.patch b/gcc-4.4.3/piepatch/21_all_gcc44_decl-tls-model.patch
index 09438a0..f483849 100644
--- a/gcc-4.4.3/piepatch/21_all_gcc44_decl-tls-model.patch
+++ b/gcc-4.4.3/piepatch/21_all_gcc44_decl-tls-model.patch
@@ -1,10 +1,10 @@
-2009-06-13 Magnus Granberg <zorry@ume.nu>
+2009-06-13 Magnus Granberg <zorry@gentoo.org>
b.g.o #232601
* gcc/varasm.c (decl_tls_model): Check flag_pic instead of flag_shlib.
---- gcc/varasm.c 2009-03-17 21:18:21.000000000 +0100
-+++ gcc/varasm.c 2009-04-29 03:10:09.000000000 +0200
+--- a/gcc/varasm.c 2009-03-17 21:18:21.000000000 +0100
++++ b/gcc/varasm.c 2009-04-29 03:10:09.000000000 +0200
@@ -5607,7 +5607,11 @@
bool is_local;
diff --git a/gcc-4.4.3/piepatch/30_all_gcc44_esp.h.patch b/gcc-4.4.3/piepatch/30_all_gcc44_esp.h.patch
index bb32fba..6634a33 100644
--- a/gcc-4.4.3/piepatch/30_all_gcc44_esp.h.patch
+++ b/gcc-4.4.3/piepatch/30_all_gcc44_esp.h.patch
@@ -1,25 +1,25 @@
-2010-04-20 Magnus Granberg <zorry@gentoo.org>
+2010-04-22 Magnus Granberg <zorry@gentoo.org>
* gcc/esp.h New file to support --enable-esp
- Version 20100420.3
+ Version 20100422.1
---- gcc/esp.h 2010-04-09 16:14:00.000000000 +0200
-+++ gcc/esp.h 2010-04-20 00:35:27.000000000 +0200
-@@ -0,0 +1,143 @@
+--- a/gcc/esp.h 2010-04-09 16:14:00.000000000 +0200
++++ b/gcc/esp.h 2010-04-22 13:48:18.000000000 +0200
+@@ -0,0 +1,147 @@
+/* License terms see GNU GENERAL PUBLIC LICENSE Version 3.
-+ * Version 20100420.3
++ * Version 20100422.1
+ * Magnus Granberg (Zorry) <zorry@gentoo.org> */
+#ifndef GCC_ESP_H
+#define GCC_ESP_H
+
-+/* This file will add -fstack-protector-all, -fPIE, -pie and -z now
++/* This file will add -fstack-protector-all, -fPIE, -pie and -z now
+ as default if the defines and the spec allow it.
+ 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.
-+ 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.
++ This will add some unsupported upstream commands options as -nopie and -nonow.
++ -D__KERNEL__ is added so we don't have -fPIE, -pie and -fstack-protector-all when building kernels.
+ ESP_CC1_SPEC is added to CC1_SPEC.
-+ ESP_CC1_STRICT_SPEC is added so the compiler don't use -fstrict-overflow.
++ ESP_CC1_STRICT_SPEC is added so we don't disable the strict-overflow check.
+ ESP_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.
+*/
@@ -32,13 +32,17 @@
+ #else
+ #define ESP_CC1_SSP_SPEC ""
+ #endif
-+ #define ESP_CC1_PIE_SPEC "%{!nopie: }"
++ #ifdef HAVE_GCC_LD_PIE
++ #define ESP_CC1_PIE_SPEC "%{!nopie: }"
++ #else
++ #define ESP_CC1_PIE_SPEC ""
++ #endif
+ #define ESP_CC1_STRICT_SPEC "%{!fstrict-overflow:%{!fno-strict-overflow: -fno-strict-overflow}}"
+
+ /* ESP_LINK_SPEC is added to LINK_PIE_SPEC if esp is enable
+ -z now will be added if we don't have -vanilla spec */
+ #define ESP_LINK_SPEC "%(esp_link_now)"
-+ #define ESP_LINK_NOW_SPEC "%{!now:-z now}"
++ #define ESP_LINK_NOW_SPEC "%{!nonow:-z now}"
+
+ /* ESP_OPTIONS_SPEC is added to the compiler spec in gcc/gcc.c */
+ #define ESP_OPTIONS_SPEC "%(esp_options_ssp)"
@@ -57,8 +61,8 @@
+ #define ESP_OPTIONS_SSP_SPEC ""
+ #endif
+
-+ /* If HAVE_LD_PIE not defined we will not add any -fPIE -pie */
-+ #ifdef HAVE_LD_PIE
++ /* If HAVE_GCC_LD_PIE not defined we will not add any -fPIE -pie */
++ #ifdef HAVE_GCC_LD_PIE
+
+ /* We use ESP_COMMAND_OPTIONS_SPEC to add pie command-line options. */
+ #define ESP_COMMAND_OPTIONS_SPEC "%{!D__KERNEL__:%{!nopie:%(esp_options_pie) %(esp_link_pie)}}"
diff --git a/gcc-4.4.3/piepatch/33_all_gcc44_config_rs6000_linux64.h.patch b/gcc-4.4.3/piepatch/33_all_gcc44_config_rs6000_linux64.h.patch
index b9fed34..5a88bf6 100644
--- a/gcc-4.4.3/piepatch/33_all_gcc44_config_rs6000_linux64.h.patch
+++ b/gcc-4.4.3/piepatch/33_all_gcc44_config_rs6000_linux64.h.patch
@@ -3,8 +3,8 @@
* gcc/config/rs6000/linux64.h ASM_SPEC32 Change %{fpic:-K PIC} %{fPIC:-K PIC}
to %{fpic|fPIC|fpie|fPIE:-K PIC}
---- gcc/config/rs6000/linux64.h.psm 2009-04-10 01:23:07.000000000 +0200
-+++ gcc/config/rs6000/linux64.h 2009-09-23 12:34:26.000000000 +0200
+--- a/gcc/config/rs6000/linux64.h.psm 2009-04-10 01:23:07.000000000 +0200
++++ b/gcc/config/rs6000/linux64.h 2009-09-23 12:34:26.000000000 +0200
@@ -156,7 +156,7 @@
#endif
diff --git a/gcc-4.4.3/piepatch/35_all_gcc44_config_crtbegints.patch b/gcc-4.4.3/piepatch/35_all_gcc44_config_crtbegints.patch
index f1e6532..7f3d7bd 100644
--- a/gcc-4.4.3/piepatch/35_all_gcc44_config_crtbegints.patch
+++ b/gcc-4.4.3/piepatch/35_all_gcc44_config_crtbegints.patch
@@ -1,10 +1,10 @@
-2009-09-25 Magnus Granberg <zorry@ume.nu>
+2009-09-25 Magnus Granberg <zorry@gentoo.org>
* gcc/config/linux.h If ENABLE_CRTBEGINTS, -static and -pie use crtbegineTS.o.
* gcc/config/rs6000/sysv4.h If ENABLE_CRTBEGINTS, -static and -pie use crtbegineTS.o.
---- gcc/config/linux.h 2009-04-10 01:23:07.000000000 +0200
-+++ gcc/config/linux.h 2009-09-08 04:08:06.000000000 +0200
+--- a/gcc/config/linux.h 2009-04-10 01:23:07.000000000 +0200
++++ b/gcc/config/linux.h 2009-09-08 04:08:06.000000000 +0200
@@ -43,7 +43,11 @@
object constructed before entering `main'. */
diff --git a/gcc-4.4.3/piepatch/40_all_gcc44_cp_lang-specs.h.patch b/gcc-4.4.3/piepatch/40_all_gcc44_cp_lang-specs.h.patch
index 091f443..99175da 100644
--- a/gcc-4.4.3/piepatch/40_all_gcc44_cp_lang-specs.h.patch
+++ b/gcc-4.4.3/piepatch/40_all_gcc44_cp_lang-specs.h.patch
@@ -3,8 +3,8 @@
LP #346126
* gcc/cp/lang-specs.h compiler spec Add %(esp_options).
---- gcc/cp/lang-specs.h.orig 2009-03-23 01:21:54.000000000 +0100
-+++ gcc/cp/lang-specs.h 2009-03-23 01:22:16.000000000 +0100
+--- a/gcc/cp/lang-specs.h 2009-03-23 01:21:54.000000000 +0100
++++ b/gcc/cp/lang-specs.h 2009-03-23 01:22:16.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}}\
diff --git a/gcc-4.4.3/piepatch/41_all_gcc44_objc_lang-specs.h.patch b/gcc-4.4.3/piepatch/41_all_gcc44_objc_lang-specs.h.patch
index 418217e..181fae0 100644
--- a/gcc-4.4.3/piepatch/41_all_gcc44_objc_lang-specs.h.patch
+++ b/gcc-4.4.3/piepatch/41_all_gcc44_objc_lang-specs.h.patch
@@ -3,8 +3,8 @@
LP #346126
* gcc/objc/lang-specs.h compiler spec Add %(esp_options).
---- gcc/objc/lang-specs.h 2009-03-23 01:21:54.000000000 +0100
-+++ gcc/objc/lang-specs.h 2009-03-23 01:22:16.000000000 +0100
+--- a/gcc/objc/lang-specs.h 2009-03-23 01:21:54.000000000 +0100
++++ b/gcc/objc/lang-specs.h 2009-03-23 01:22:16.000000000 +0100
@@ -30,13 +30,13 @@
%{traditional|ftraditional|traditional-cpp:\
%eGNU Objective C no longer supports traditional compilation}\
diff --git a/gcc-4.4.3/piepatch/42_all_gcc44_objcp_lang-specs.h.patch b/gcc-4.4.3/piepatch/42_all_gcc44_objcp_lang-specs.h.patch
index 50ab607..c0e48c4 100644
--- a/gcc-4.4.3/piepatch/42_all_gcc44_objcp_lang-specs.h.patch
+++ b/gcc-4.4.3/piepatch/42_all_gcc44_objcp_lang-specs.h.patch
@@ -3,8 +3,8 @@
LP #346126
* gcc/objcp/lang-specs.h compiler spec Add %(esp_options).
---- gcc/objcp/lang-specs.h 2009-03-23 01:21:54.000000000 +0100
-+++ gcc/objcp/lang-specs.h 2009-03-23 01:22:16.000000000 +0100
+--- a/gcc/objcp/lang-specs.h 2009-03-23 01:21:54.000000000 +0100
++++ b/gcc/objcp/lang-specs.h 2009-03-23 01:22:16.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}}\
diff --git a/gcc-4.4.3/piepatch/60_all_gcc44_invoke.texi.patch b/gcc-4.4.3/piepatch/60_all_gcc44_invoke.texi.patch
index 16eab7e..899e2d5 100644
--- a/gcc-4.4.3/piepatch/60_all_gcc44_invoke.texi.patch
+++ b/gcc-4.4.3/piepatch/60_all_gcc44_invoke.texi.patch
@@ -1,10 +1,10 @@
-2009-09-11 Magnus Granberg <zorry@ume.nu>
+2009-09-11 Magnus Granberg <zorry@gentoo.org>
* gcc/doc/invoke.texi Add NOTES about -fstack-protector-all, -pie and
-fPIE/-fpie when --enable-esp is enable, this options is on by default.
---- gcc/doc/invoke.texi 2009-04-01 09:18:47.000000000 +0200
-+++ gcc/doc/invoke.texi 2009-06-18 14:08:38.000000000 +0200
+--- a/gcc/doc/invoke.texi 2009-04-01 09:18:47.000000000 +0200
++++ b/gcc/doc/invoke.texi 2009-06-18 14:08:38.000000000 +0200
@@ -7134,6 +7134,11 @@
@opindex fstack-protector-all
Like @option{-fstack-protector} except that all functions are protected.
diff --git a/gcc-4.4.3/piepatch/README.Changelog b/gcc-4.4.3/piepatch/README.Changelog
index 54e25b2..2d63248 100644
--- a/gcc-4.4.3/piepatch/README.Changelog
+++ b/gcc-4.4.3/piepatch/README.Changelog
@@ -1,3 +1,21 @@
+0.4.1 Magnus Granberg <zorry@gentoo.org>
+
+ *configure removed check for --enable-esp removed enable_esp
+ added check for --enable-esp=(no|all|nopie|nossp). added enable_esp_set
+ *Makefile.in renamed enable_esp to enable_esp_set
+ *gcc/configure removed check for --enable-esp removed enable_esp
+ added check for --enable-esp=(no|all|nopie|nossp). added enable_esp_set
+ added a -fPIE -pie check. change AC_COMPILE_IFELSE to AC_LINK_IFELSE in the
+ -fstack-protector check.
+ * gcc/config.in Added HAVE_GCC_LD_PIE
+ *gcc/Makefile.in renamed enable_esp to enable_esp_set
+ *gcc/esp Renamed HAVE_LD_PIE to HAVE_GCC_LD_PIE
+ Added HAVE_GCC_LD_PIE to #define ESP_CC1_PIE_SPEC.
+ * libmudflap/Makefiles.in In enable_esp change ifeq to ifdef.
+
+ #293843 b.g.o
+ *gcc/esp.h Added -nonow to the -z now specs.
+
0.4.0 Magnus Granberg <zorry@gentoo.org>
rename espf to esp and change espf-patchset to piepatchset
diff --git a/gcc-4.4.3/piepatch/README.history b/gcc-4.4.3/piepatch/README.history
index 72fe90e..86339a8 100644
--- a/gcc-4.4.3/piepatch/README.history
+++ b/gcc-4.4.3/piepatch/README.history
@@ -1,108 +1,119 @@
-0.4.0 19-04-2010
- rename espf to esp and change espf-patchset to piepatchset
-
-0.3.9 14-04-2010
- 10_all_gcc44_configure.patch
+0.4.1 23-04-2010
+ U 10_all_gcc44_configure.patch
+ U 12_all_gcc44_Makefile.in.patch
+ U 11_all_gcc44_config.in.patch
+ U 30_all_gcc44_esp.h.patch
+
+0.4.0 19-04-2010
+ U 10_all_gcc44_configure.patch
+ U 12_all_gcc44_Makefile.in.patch
+ U 11_all_gcc44_config.in.patch
+ U 20_all_gcc44_gcc.c.patch
+ - 30_all_gcc44_espf.h.patch
+ + 30_all_gcc44_esp.h.patch
+
+0.3.9 14-04-2010
+ U 10_all_gcc44_configure.patch
- 50_all_gcc44_no_ssp_tls_uclibc.patch
-0.3.8 10-04-2010
- 10_all_gcc44_configure.patch
- 11_all_gcc44_config.in.patch
- 20_all_gcc44_gcc.c.patch
- 30_all_gcc44_espf.h.patch
+0.3.8 10-04-2010
+ U 10_all_gcc44_configure.patch
+ U 11_all_gcc44_config.in.patch
+ U 20_all_gcc44_gcc.c.patch
+ U 30_all_gcc44_espf.h.patch
-0.3.7 10-02-2010
- 20_all_gcc44_gcc.c.patch
- 30_all_gcc44_espf.h.patch
+0.3.7 10-02-2010
+ U 20_all_gcc44_gcc.c.patch
+ U 30_all_gcc44_espf.h.patch
0.3.6 23-12-2009
- 10_all_gcc44_configure.patch
- 30_all_gcc44_espf.h.patch
- README
+ U 10_all_gcc44_configure.patch
+ U 30_all_gcc44_espf.h.patch
+ U README
0.3.5 24-09-2009
- 30_all_gcc44_espf.h.patch
- 35_all_gcc44_config_crtbegints.patch
+ U 30_all_gcc44_espf.h.patch
+ U 35_all_gcc44_config_crtbegints.patch
+ 33_all_gcc44_config_rs6000_linux64.h.patch
+ README.Gentoo.patches
0.3.4 11-09-2009
- 10_all_gcc44_configure.patch
- 11_all_gcc44_config.in.patch
- 12_all_gcc44_Makefile.in.patch
- 20_all_gcc44_gcc.c.patch
+ U 10_all_gcc44_configure.patch
+ U 11_all_gcc44_config.in.patch
+ U 12_all_gcc44_Makefile.in.patch
+ U 20_all_gcc44_gcc.c.patch
- 23_all_gcc44_opts.c.patch
- 30_all_gcc44_espf.h.patch
- 35_all_gcc44_config_crtbegints.patch
+ U 30_all_gcc44_espf.h.patch
+ U 35_all_gcc44_config_crtbegints.patch
+ 60_all_gcc44_invoke.texi.patch
+ README
0.3.3 14-08-2009
- 23_all_gcc44_opts.c.patch
+ U 23_all_gcc44_opts.c.patch
0.3.2 09-08-2009
- 50_all_gcc44_no_ssp_tls_uclibc.patch
+ U 50_all_gcc44_no_ssp_tls_uclibc.patch
+ README.Changelog
+ README.history
+ 23_all_gcc44_opts.c.patch
- 30_all_gcc44-espf.h.patch
+ U 30_all_gcc44-espf.h.patch
0.3.1 23-07-2009
- 10_all_gcc44_configure.patch
+ U 10_all_gcc44_configure.patch
0.3.0 23-07-2009
- 10_all_gcc44_configure.patch
- 11_all_gcc44_config.in.patch
- 12_all_gcc44_Makefile.in.patch
- 20_all_gcc44_gcc.c.patch
+ U 10_all_gcc44_configure.patch
+ U 11_all_gcc44_config.in.patch
+ U 12_all_gcc44_Makefile.in.patch
+ U20_all_gcc44_gcc.c.patch
+ 40_all_gcc44_obj_lang-specs.h.patch
+ 40_all_gcc44_objp_lang-specs.h.patch
+ 40_all_gcc44_cp_lang-specs.h.patch
- 50_all_gcc44_gentoo_v20090614.1.patch
- 30_all_gcc44-espf.h.patch
+ U 30_all_gcc44-espf.h.patch
0.2.9 14-06-2009
- 12_all_gcc44_Makefile.in.patch
- 30_all_gcc44-espf.h.patch
+ U 12_all_gcc44_Makefile.in.patch
+ U 30_all_gcc44-espf.h.patch
+ 50_all_gcc44_gentoo_v20090614.1.patch
- 50_all_gcc44_gentoo_v20090612.2.patch
0.2.8 12-06-2009
- 10_all_gcc44_configure.patch
- 11_all_gcc44_config.in.patch
- 12_all_gcc44_Makefile.in.patch
+ U 10_all_gcc44_configure.patch
+ U 11_all_gcc44_config.in.patch
+ U 12_all_gcc44_Makefile.in.patch
- 22_all_gcc44-toplev.c.patch
+ 30_all_gcc44-espf.h.patch
- 25_all_gcc44-espf.h.patch
+ 50_all_gcc44_gentoo_v20090612.2.patch
0.2.7 29-05-2009
- 11_all_gcc44_config.in.patch
- 12_all_gcc44_Makefile.in.patch
- 20_all_gcc44_gcc.c.patch
+ U 11_all_gcc44_config.in.patch
+ U 12_all_gcc44_Makefile.in.patch
+ U 20_all_gcc44_gcc.c.patch
+ 23_all_gcc44_opts.c.patch
- 25_all_gcc44-espf.h.patch
+ U 25_all_gcc44-espf.h.patch
- 30_all_gcc44-config-defaul-linux.patch
0.2.6 28-05-2009
+ 22_all_gcc44-toplev.c.patch
- 25_all_gcc44-espf.h.patch
- 30_all_gcc44-config-defaul-linux.patch
+ U 25_all_gcc44-espf.h.patch
+ U 30_all_gcc44-config-defaul-linux.patch
0.2.5 27-05-2009
- 10_all_gcc44_configure.patch
- 12_all_gcc44_Makefile.in.patch
- 20_all_gcc44_gcc.c.patch
- 25_all_gcc44-espf.h.patch
- 30_all_gcc44-config-defaul-linux.patch
+ U 10_all_gcc44_configure.patch
+ U 12_all_gcc44_Makefile.in.patch
+ U 20_all_gcc44_gcc.c.patch
+ U 25_all_gcc44-espf.h.patch
+ U 30_all_gcc44-config-defaul-linux.patch
- 40_all_gcc44-gentoo.patch
0.2.4 08-05-2009
- 12_all_gcc44_Makefile.in.patch
+ U 12_all_gcc44_Makefile.in.patch
0.2.3 08-05-2009
- 20_all_gcc44_gcc.c.patch
- 40_all_gcc44-gentoo.patch
+ U 20_all_gcc44_gcc.c.patch
+ U 40_all_gcc44-gentoo.patch
0.2.2 04-05-2009
+ 10_all_gcc44_configure.patch