]> git.pld-linux.org Git - packages/python3.git/commitdiff
define O_CLOEXEC on old libc
authorElan Ruusamäe <glen@delfi.ee>
Thu, 26 Jul 2012 08:36:34 +0000 (11:36 +0300)
committerElan Ruusamäe <glen@delfi.ee>
Thu, 26 Jul 2012 08:36:34 +0000 (11:36 +0300)
libc-cloexec.patch [new file with mode: 0644]
python3.spec

diff --git a/libc-cloexec.patch b/libc-cloexec.patch
new file mode 100644 (file)
index 0000000..398274a
--- /dev/null
@@ -0,0 +1,15 @@
+see also
+http://serverfault.com/questions/388865/building-python3-on-a-redhat-5-machine
+
+--- Python-3.2.3/Modules/_posixsubprocess.c~   2012-04-11 09:54:07.000000000 +0300
++++ Python-3.2.3/Modules/_posixsubprocess.c    2012-07-26 10:58:29.616131665 +0300
+@@ -37,6 +37,9 @@
+ #define POSIX_CALL(call)   if ((call) == -1) goto error
++#ifndef O_CLOEXEC
++#define O_CLOEXEC   02000000    /* set close_on_exec */
++#endif
+ /* Maximum file descriptor, initialized on module load. */
+ static long max_fd;
index e6f52d6a6fee35203c8cf28f6568420e98c62e8c..117530d466626fcba4753398d7f3a43f8baf544f 100644 (file)
@@ -46,6 +46,7 @@ Patch2:               %{name}-lib64.patch
 Patch3:                %{name}-noarch_to_datadir.patch
 Patch4:                %{name}-no_cmdline_tests.patch
 Patch5:                %{name}-makefile-location.patch
+Patch6:                libc-cloexec.patch
 URL:           http://www.python.org/
 BuildRequires: autoconf >= 2.65
 BuildRequires: bluez-libs-devel
@@ -447,6 +448,7 @@ Przykłady te są dla Pythona 2.3.4, nie %{version}.
 %patch3 -p1
 %patch4 -p1
 %patch5 -p1
+%patch6 -p1
 
 %build
 if ! grep -q "tmpfs" /proc/self/mounts; then
This page took 0.073142 seconds and 4 git commands to generate.