1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/python/python.patch Tue Sep 20 15:22:39 2011 +0200 1.3 @@ -0,0 +1,120 @@ 1.4 +Index: configure 1.5 +--- configure.orig 2010-11-01 02:47:19.000000000 +0100 1.6 ++++ configure 2010-12-05 18:07:39.000000000 +0100 1.7 +@@ -3904,9 +3904,9 @@ 1.8 + CFLAGS=$ac_save_CFLAGS 1.9 + elif test $ac_cv_prog_cc_g = yes; then 1.10 + if test "$GCC" = yes; then 1.11 +- CFLAGS="-g -O2" 1.12 ++ CFLAGS="-O2" 1.13 + else 1.14 +- CFLAGS="-g" 1.15 ++ CFLAGS="" 1.16 + fi 1.17 + else 1.18 + if test "$GCC" = yes; then 1.19 +@@ -5352,7 +5352,7 @@ 1.20 + # debug builds. 1.21 + OPT="-g -O0 -Wall $STRICT_PROTO" 1.22 + else 1.23 +- OPT="-g $WRAP -O3 -Wall $STRICT_PROTO" 1.24 ++ OPT="$WRAP -O3 -Wall $STRICT_PROTO" 1.25 + fi 1.26 + ;; 1.27 + *) 1.28 +@@ -7627,24 +7627,24 @@ 1.29 + FreeBSD*) 1.30 + if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] 1.31 + then 1.32 +- LDSHARED='$(CC) -shared ${LDFLAGS}' 1.33 +- LDCXXSHARED='$(CXX) -shared ${LDFLAGS}' 1.34 ++ LDSHARED="\$(CC) -shared ${LDFLAGS}" 1.35 ++ LDCXXSHARED="\$(CXX) -shared ${LDFLAGS}" 1.36 + else 1.37 + LDSHARED="ld -Bshareable ${LDFLAGS}" 1.38 + fi;; 1.39 + OpenBSD*) 1.40 + if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] 1.41 + then 1.42 +- LDSHARED='$(CC) -shared $(CCSHARED) ${LDFLAGS}' 1.43 +- LDCXXSHARED='$(CXX) -shared $(CCSHARED) ${LDFLAGS}' 1.44 ++ LDSHARED="\$(CC) -shared \$(CCSHARED) ${LDFLAGS}" 1.45 ++ LDCXXSHARED="\$(CXX) -shared \$(CCSHARED) ${LDFLAGS}" 1.46 + else 1.47 + case `uname -r` in 1.48 + [01].* | 2.[0-7] | 2.[0-7].*) 1.49 + LDSHARED="ld -Bshareable ${LDFLAGS}" 1.50 + ;; 1.51 + *) 1.52 +- LDSHARED='$(CC) -shared $(CCSHARED) ${LDFLAGS}' 1.53 +- LDCXXSHARED='$(CXX) -shared $(CCSHARED) ${LDFLAGS}' 1.54 ++ LDSHARED="\$(CC) -shared \$(CCSHARED) ${LDFLAGS}" 1.55 ++ LDCXXSHARED="\$(CXX) -shared \$(CCSHARED) ${LDFLAGS}" 1.56 + ;; 1.57 + esac 1.58 + fi;; 1.59 +@@ -7751,7 +7751,7 @@ 1.60 + then 1.61 + LINKFORSHARED="-Wl,--export-dynamic" 1.62 + fi;; 1.63 +- SunOS/5*) case $CC in 1.64 ++ SunOS/5*) case gcc in 1.65 + *gcc*) 1.66 + if $CC -Xlinker --help 2>&1 | grep export-dynamic >/dev/null 1.67 + then 1.68 +Index: setup.py 1.69 +--- setup.py.orig 2010-10-31 17:40:21.000000000 +0100 1.70 ++++ setup.py 2010-12-05 18:05:56.000000000 +0100 1.71 +@@ -347,8 +347,8 @@ 1.72 + 1.73 + def detect_modules(self): 1.74 + # Ensure that /usr/local is always used 1.75 +- add_dir_to_list(self.compiler.library_dirs, '/usr/local/lib') 1.76 +- add_dir_to_list(self.compiler.include_dirs, '/usr/local/include') 1.77 ++ add_dir_to_list(self.compiler.library_dirs, '@l_prefix@/lib') 1.78 ++ add_dir_to_list(self.compiler.include_dirs, '@l_prefix@/include') 1.79 + 1.80 + # Add paths specified in the environment variables LDFLAGS and 1.81 + # CPPFLAGS for header and library files. 1.82 +@@ -680,8 +680,6 @@ 1.83 + depends = ['socketmodule.h']) ) 1.84 + # Detect SSL support for the socket module (via _ssl) 1.85 + search_for_ssl_incs_in = [ 1.86 +- '/usr/local/ssl/include', 1.87 +- '/usr/contrib/ssl/include/' 1.88 + ] 1.89 + ssl_incs = find_file('openssl/ssl.h', inc_dirs, 1.90 + search_for_ssl_incs_in 1.91 +@@ -692,8 +690,7 @@ 1.92 + if krb5_h: 1.93 + ssl_incs += krb5_h 1.94 + ssl_libs = find_library_file(self.compiler, 'ssl',lib_dirs, 1.95 +- ['/usr/local/ssl/lib', 1.96 +- '/usr/contrib/ssl/lib/' 1.97 ++ ['@l_prefix@/lib' 1.98 + ] ) 1.99 + 1.100 + if (ssl_incs is not None and 1.101 +@@ -813,14 +810,8 @@ 1.102 + # top of the normal inc_dirs. 1.103 + db_inc_paths = [ 1.104 + '/usr/include/db4', 1.105 +- '/usr/local/include/db4', 1.106 + '/opt/sfw/include/db4', 1.107 +- '/usr/include/db3', 1.108 +- '/usr/local/include/db3', 1.109 +- '/opt/sfw/include/db3', 1.110 +- # Fink defaults (http://fink.sourceforge.net/) 1.111 + '/sw/include/db4', 1.112 +- '/sw/include/db3', 1.113 + ] 1.114 + # 4.x minor number specific paths 1.115 + for x in gen_db_minor_ver_nums(4): 1.116 +@@ -1708,6 +1699,7 @@ 1.117 + dotversion = dotversion[:-1] + '.' + dotversion[-1] 1.118 + tcl_include_sub = [] 1.119 + tk_include_sub = [] 1.120 ++ dotversion = '' 1.121 + for dir in inc_dirs: 1.122 + tcl_include_sub += [dir + os.sep + "tcl" + dotversion] 1.123 + tk_include_sub += [dir + os.sep + "tk" + dotversion]