forked from Infinidat/relocatable-python3
-
Notifications
You must be signed in to change notification settings - Fork 0
/
buildout-build-aix.cfg
92 lines (79 loc) · 4.95 KB
/
buildout-build-aix.cfg
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
[buildout]
extends = buildout-build.cfg
parts = zlib ncurses readline openssl openssh libgpg-error libgcrypt gettext libiconv libgnutls bzip2 sqlite3 libxml2 libxslt libffi gdbm cyrus-sasl libevent libev zeromq openldap python
[environment]
CC = gcc -static-libgcc -fPIC -maix64
LDFLAGS = -L${options:prefix}/lib -Wl,-blibpath:/usr/lib
SHARED_LDFLAGS = -L${options:prefix}/lib -Wl,-blibpath:/usr/lib
LIBPATH = -L${options:prefix}/lib
CFLAGS = -I${options:prefix}/include -maix64
CPPFLAGS = ${:CFLAGS}
CXXFLAGS = ${:CFLAGS}
# The *_LIBRARY_PATH definitions cause built-in executables that we run to link against our new shared objects which doesn't work
DYLD_LIBRARY_PATH =
LD_LIBRARY_PATH =
OBJECT_MODE = 64
[ncurses]
# removed with-shared due to error in configure: "Shared libraries are not supported in this version"
configure-options = ${options:configure-options} --with-gpg-error-prefix=${:prefix} --disable-big-core --disable-root-environ --disable-macros --disable-rpath --disable-largefile --without-ada --without-cxx-binding --with-terminfo-dirs=/etc/terminfo:/lib/terminfo:/usr/share/terminfo
[readline]
version = 6.2
[openssl]
# Version held back due to numerous problems
# OpenSSL's configure doesn't respect CC/GCC env vars properly (it only decides which compiler to use according to which is defined, but doesn't use the flags).
# we pass the compiler and flags in the configure options instead, this overwrites any env var
# note that --shared doesn't actually work on aix
configure-options = --prefix=${options:prefix} --openssldir=${:openssldir} --shared --libdir=lib gcc:"gcc -static-libgcc -fPIC"
# run "slibclean" before "make install", otherwise make install fails due to "files already in use"
make-binary = slibclean; make
openssldir = /var/ssl
version = 1.0.2q
patches = ${:patches-dir}/${:name}-${:version}-Makefile.patch
${:patches-dir}/${:name}-${:version}-linux-ldflags.patch
${:patches-dir}/${:name}-${:version}-apps-Makefile.patch
${:patches-dir}/${:name}-${:version}-tools-Makefile.patch
[openssh]
# /bin/sh written in the shebang line doesn't recognize some syntax in the configure script
configure-command = /bin/bash ./configure
[openssh-environment]
<= environment
# add . and .. as search paths, otherwise the wrong "buffer.h" (from openssl) will be used
CFLAGS = ${environment:CFLAGS} -I. -I.. -I${options:prefix}/include/openssl
[libgcrypt]
configure-options += --disable-asm
[libevent]
environment-section = libevent-environment
[libevent-environment]
<= environment
# define _EVENT_HAVE_FD_MASK, otherwise there is redefinition of type fd_mask
CFLAGS = ${environment:CFLAGS} -D_EVENT_HAVE_FD_MASK
[zeromq]
patches = ${:patches-dir}/${:name}-${:version}-newline.patch
${:patches-dir}/${:name}-${:version}-test_disconnect_inproc.cpp.patch
[openldap]
# /bin/sh written in the shebang line doesn't recognize some syntax in the configure script
configure-command = /bin/bash ./configure
[python]
environment-section = python-environment
configure-options = --prefix=${options:prefix} --enable-shared --enable-ipv6 --with-dbmliborder=gdbm --with-gcc --with-system-ffi --libdir=${options:prefix}/lib --with-system-ffi --with-openssl=${options:prefix}
patches = ${:patches-dir}/${:name}-${:version}-sysconfig.py.patch
${:patches-dir}/${:name}-${:version}-distutils-sysconfig.py.patch
${:patches-dir}/${:name}-${:version}-pythonhome-pythonrun.c.patch
${:patches-dir}/${:name}-${:version}-linux-symlink.patch
${:patches-dir}/${:name}-${:version}-aix-libpath.patch
${:patches-dir}/${:name}-${:version}-aix-Makefile.patch
post-make-hook = ${options:hooks-dir}/aix.py:python_post_make
[python-environment]
<= environment
CFLAGS = ${environment:CFLAGS} -I${options:prefix}/include/gnutls -I${options:prefix}/include/graphviz -I${options:prefix}/include/libexslt -I${options:prefix}/include/libxml2 -I${options:prefix}/include/libxslt -I${options:prefix}/include/ncurses -I${options:prefix}/include/openssl -I${options:prefix}/include/readline -I${options:prefix}/include/sasl -I${options:prefix}/lib/libffi-${libffi:version}/include
LDFLAGS = ${environment:LDFLAGS} -L${options:prefix}/lib/engines -L${options:prefix}/lib/gettext -L${options:prefix}/lib/graphviz -L${options:prefix}/lib/libxslt-plugins -L${options:prefix}/lib/pkgconfig -L${options:prefix}/lib/sasl2 -Wl,-blibpath:.:../lib:/usr/lib -lintl
OPT = -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes
# RUNSHARED is the env var that is used to run python during make, for example
# when building the external modules for Python like "_ctypes". The default on
# on AIX sets LIBPATH to whatever is in the environment variables already. We
# want to set LIBPATH to our lib folder for that purpose but we can't set LIBPATH
# for the entire build process because that can interfere with external binaries
# like gcc. So we have a patch in place that clears RUNSHARED so that we can
# set it here, making LIBPATH correct specifically during the "shared modules"
# build
RUNSHARED = LIBPATH=${options:prefix}/lib