]>
Commit | Line | Data |
---|---|---|
1914e110 SS |
1 | ############################################################################### |
2 | # IPFire.org - An Open Source Firewall Solution # | |
3 | # Copyright (C) - IPFire Development Team <info@ipfire.org> # | |
4 | ############################################################################### | |
5 | ||
6 | name = pygobject3 | |
7 | version = %{ver_major}.%{ver_minor} | |
1bb3a638 MT |
8 | ver_major = 3.18 |
9 | ver_minor = 0 | |
10 | release = 1 | |
1914e110 SS |
11 | |
12 | groups = Development/Tools | |
13 | url = http://www.pygtk.org/ | |
14 | license = LGPLv2+ | |
15 | summary = Python 2 bindings for GObject. | |
16 | ||
17 | description | |
18 | The %{name} package provides a convenient wrapper for the GObject library | |
19 | for use in Python programs. | |
20 | end | |
21 | ||
22 | thisapp = pygobject-%{version} | |
23 | ||
24 | source_dl = http://ftp.gnome.org/pub/GNOME/sources/pygobject/%{ver_major}/ | |
25 | sources = %{thisapp}.tar.xz | |
26 | ||
27 | build | |
28 | requires | |
29 | cairo-gobject-devel >= 1.12.12 | |
1914e110 SS |
30 | glib2-devel >= 2.34.2 |
31 | gobject-introspection-devel >= 1.34.2 | |
32 | pkg-config | |
33 | python-cairo-devel | |
34 | python3-cairo-devel | |
35 | python-devel | |
1bb3a638 | 36 | python3-devel >= 3.4 |
1914e110 SS |
37 | end |
38 | ||
39 | DIR_APP3 = %{DIR_APP}-python3 | |
40 | ||
41 | prepare_cmds | |
42 | cp -av %{DIR_APP} %{DIR_APP3} | |
43 | ||
44 | pushd %{DIR_APP3} | |
45 | find -name '*.py' | xargs sed -i '1s|^#!python|#!%{python3}|' | |
46 | popd | |
47 | ||
48 | find -name '*.py' | xargs sed -i '1s|^#!python|#!%{python}|' | |
49 | end | |
50 | ||
51 | build | |
52 | pushd %{DIR_APP3} | |
53 | export PYTHON=%{python3} | |
54 | ./configure %{configure_options} | |
55 | make %{PARALLELISMFLAGS} | |
56 | popd | |
57 | ||
58 | export PYTHON=%{python} | |
59 | ./configure %{configure_options} | |
60 | make %{PARALELLISMFLAGS} | |
61 | end | |
62 | ||
63 | install | |
64 | pushd %{DIR_APP3} | |
65 | export PYTHON=%{python3} | |
66 | make install DESTDIR=%{BUILDROOT} | |
1914e110 SS |
67 | popd |
68 | ||
69 | export PYTHON=%{python} | |
70 | make install DESTDIR=%{BUILDROOT} | |
1914e110 SS |
71 | end |
72 | end | |
73 | ||
74 | packages | |
75 | package python-gobject3 | |
76 | requires | |
77 | gobject-introspection >= 1.34.2 | |
78 | python-cairo | |
79 | end | |
28aba233 SS |
80 | |
81 | files += \ | |
82 | {libdir}/*python2*.so.* | |
1914e110 SS |
83 | end |
84 | ||
85 | package python3-gobject3 | |
86 | template PYTHON3 | |
87 | ||
88 | requires | |
89 | gobject-introspection >= 1.34.2 | |
90 | python3-cairo | |
91 | end | |
28aba233 SS |
92 | |
93 | files += \ | |
94 | %{libdir}/*python3*.so.* | |
1914e110 SS |
95 | end |
96 | ||
97 | package %{name}-devel | |
98 | template DEVEL | |
99 | ||
100 | provides | |
101 | python-gobject3-devel | |
102 | python3-gobject3-devel | |
103 | end | |
104 | ||
105 | requires | |
106 | glib2-devel | |
107 | gobject-introspection-devel >= 1.34.2 | |
108 | end | |
109 | ||
110 | files += \ | |
28aba233 | 111 | %{libdir}/*python3*.so |
1914e110 SS |
112 | end |
113 | ||
114 | package %{name}-debuginfo | |
115 | template DEBUGINFO | |
116 | end | |
117 | end |