]> git.ipfire.org Git - people/amarx/ipfire-3.x.git/blob - python/python.nm
Add a -debuginfo for every package that is not noarch.
[people/amarx/ipfire-3.x.git] / python / python.nm
1 ###############################################################################
2 # IPFire.org - An Open Source Firewall Solution #
3 # Copyright (C) - IPFire Development Team <info@ipfire.org> #
4 ###############################################################################
5
6 name = python
7 major_ver = 2.7
8 version = %{major_ver}.2
9 release = 3
10 thisapp = Python-%{version}
11
12 groups = Development/Languages
13 url = http://www.python.org
14 license = Python
15 summary = An interpreted, interactive, object-oriented programming language.
16
17 description
18 Python is an interpreted, interactive, object-oriented programming
19 language often compared to Tcl, Perl, Scheme or Java. Python includes
20 modules, classes, exceptions, very high level dynamic data types and
21 dynamic typing. Python supports interfaces to many system calls and
22 libraries, as well as to various windowing systems.
23 end
24
25 source_dl = http://python.org/ftp/python/%{version}/
26 sources = %{thisapp}.tar.xz
27
28 build
29 requires
30 autoconf
31 automake
32 bzip2-devel
33 db4-devel
34 expat-devel
35 gdbm-devel
36 libffi-devel
37 libselinux-devel
38 ncurses-devel
39 openssl-devel
40 pkg-config
41 readline-devel
42 sqlite-devel
43 tar
44 zlib-devel
45 end
46
47 export CFLAGS += -D_GNU_SOURCE -fwrapv
48
49 prepare_cmds
50 sed -e "s/#*shared*/*shared*/g" -i Modules/Setup.dist
51
52 # Remove embedded copies of expat, zlib and libffi
53 rm -rf Modules/{expat,zlib}
54 rm -rf Modules/_ctypes/{darwin,libffi,libffi_arm_wince,libffi_msvc,libffi_osx}
55
56 # Remove autoconf version check and reconfigure
57 sed -e "s/^version_required.*//" -i configure.in
58 autoreconf --force
59 end
60
61 build
62 export CPPFLAGS=$(pkg-config --cflags-only-I libffi)
63
64 OPT="%{CFLAGS}" \
65 ./configure \
66 --prefix=/usr \
67 --enable-ipv6 \
68 --enable-unicode=ucs4 \
69 --with-system-expat \
70 --with-system-ffi \
71 --enable-shared
72
73 make %{PARALLELISMFLAGS}
74 end
75
76 install_cmds
77 # All *.py files don't need to be executeable...
78 find %{BUILDROOT}/usr/lib/python*/ -name "*.py" | xargs chmod a-x -v
79
80 # Create symlink for shared lib.
81 ln -svf ../../libpython%{major_ver}.so %{BUILDROOT}/usr/lib/python%{major_ver}/config/
82 end
83 end
84
85 packages
86 package %{name}
87
88 package %{name}-devel
89 template DEVEL
90
91 files += \
92 !/usr/lib/python*/config/Makefile \
93 !/usr/include/python*/pyconfig.h
94 end
95
96 package %{name}-debuginfo
97 template DEBUGINFO
98 end
99 end