summaryrefslogtreecommitdiffstats
path: root/gcc45-misc-core.diff
diff options
context:
space:
mode:
authorYaakov Selkowitz <yselkowitz@users.sourceforge.net>2011-02-17 04:20:39 -0600
committerYaakov Selkowitz <yselkowitz@users.sourceforge.net>2011-02-17 04:20:39 -0600
commit18b2215312477fd9a72e5526f7ccb18e824102d8 (patch)
tree97976982c2d228d8f6b5eb627f85b796631cd6b5 /gcc45-misc-core.diff
downloadcygwin-gcc-18b2215312477fd9a72e5526f7ccb18e824102d8.tar.gz
cygwin-gcc-18b2215312477fd9a72e5526f7ccb18e824102d8.tar.xz
cygwin-gcc-18b2215312477fd9a72e5526f7ccb18e824102d8.zip
Initial commit
Diffstat (limited to 'gcc45-misc-core.diff')
-rw-r--r--gcc45-misc-core.diff54
1 files changed, 54 insertions, 0 deletions
diff --git a/gcc45-misc-core.diff b/gcc45-misc-core.diff
new file mode 100644
index 0000000..51cee37
--- /dev/null
+++ b/gcc45-misc-core.diff
@@ -0,0 +1,54 @@
+diff -pruN origsrc/gcc-4.5.0/gcc/config/i386/cygwin.h src/gcc-4.5.0/gcc/config/i386/cygwin.h
+--- origsrc/gcc-4.5.0/gcc/config/i386/cygwin.h 2010-04-02 20:54:46.000000000 +0100
++++ src/gcc-4.5.0/gcc/config/i386/cygwin.h 2010-04-19 03:58:09.031250000 +0100
+@@ -303,3 +303,23 @@ while (0)
+ /* We should find a way to not have to update this manually. */
+ #define LIBGCJ_SONAME "cyggcj" /*LIBGCC_EH_EXTN*/ "-11.dll"
+
++/* Make stack executable to avoid DEP problems with trampolines. */
++#undef CYGWIN_ENABLE_EXECUTE_STACK
++#define CYGWIN_ENABLE_EXECUTE_STACK \
++extern void __enable_execute_stack (void *); \
++void \
++__enable_execute_stack (void *addr) \
++{ \
++ MEMORY_BASIC_INFORMATION b; \
++ if (!VirtualQuery (addr, &b, sizeof(b))) \
++ abort (); \
++ VirtualProtect (b.BaseAddress, b.RegionSize, PAGE_EXECUTE_READWRITE, \
++ &b.Protect); \
++}
++
++#undef ENABLE_EXECUTE_STACK
++#define ENABLE_EXECUTE_STACK CYGWIN_ENABLE_EXECUTE_STACK
++
++#ifdef IN_LIBGCC2
++#include <windows.h>
++#endif
+diff -pruN origsrc/gcc-4.5.0/gcc/cppdefault.c src/gcc-4.5.0/gcc/cppdefault.c
+--- origsrc/gcc-4.5.0/gcc/cppdefault.c 2007-07-26 09:37:01.000000000 +0100
++++ src/gcc-4.5.0/gcc/cppdefault.c 2010-04-19 04:28:35.406250000 +0100
+@@ -39,6 +39,8 @@
+ # undef STANDARD_INCLUDE_DIR
+ #else
+ # undef CROSS_INCLUDE_DIR
++# undef CROSS_INCLUDE_DIR_1
++# undef CROSS_INCLUDE_DIR_2
+ #endif
+
+ const struct default_include cpp_include_defaults[]
+@@ -85,6 +87,14 @@ const struct default_include cpp_include
+ /* One place the target system's headers might be. */
+ { CROSS_INCLUDE_DIR, "GCC", 0, 0, 0, 0 },
+ #endif
++#ifdef CROSS_INCLUDE_DIR_1
++ /* One more place the target system's headers might be. */
++ { CROSS_INCLUDE_DIR_1, "GCC", 0, 0, 0, 0 },
++#endif
++#ifdef CROSS_INCLUDE_DIR_2
++ /* One more place the target system's headers might be. */
++ { CROSS_INCLUDE_DIR_2, "GCC", 0, 0, 0, 0 },
++#endif
+ #ifdef TOOL_INCLUDE_DIR
+ /* Another place the target system's headers might be. */
+ { TOOL_INCLUDE_DIR, "BINUTILS", 0, 1, 0, 0 },