summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/python
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-devtools/python')
-rw-r--r--meta/recipes-devtools/python/fix-path.inc22
-rw-r--r--meta/recipes-devtools/python/python-2.6-manifest.inc268
-rw-r--r--meta/recipes-devtools/python/python-dbus_0.83.1.bb21
-rw-r--r--meta/recipes-devtools/python/python-gst/python-path.patch25
-rw-r--r--meta/recipes-devtools/python/python-gst_0.10.18.bb17
-rw-r--r--meta/recipes-devtools/python/python-imaging/path.patch33
-rw-r--r--meta/recipes-devtools/python/python-imaging_1.1.7.bb30
-rw-r--r--meta/recipes-devtools/python/python-iniparse-native_0.3.2.bb6
-rw-r--r--meta/recipes-devtools/python/python-iniparse_0.3.2.bb11
-rw-r--r--meta/recipes-devtools/python/python-native-2.6.5/00-fix-bindir-libdir-for-cross.patch20
-rw-r--r--meta/recipes-devtools/python/python-native-2.6.5/04-default-is-optimized.patch18
-rw-r--r--meta/recipes-devtools/python/python-native-2.6.5/10-distutils-fix-swig-parameter.patch16
-rw-r--r--meta/recipes-devtools/python/python-native-2.6.5/11-distutils-never-modify-shebang-line.patch18
-rw-r--r--meta/recipes-devtools/python/python-native-2.6.5/12-distutils-prefix-is-inside-staging-area.patch60
-rw-r--r--meta/recipes-devtools/python/python-native-2.6.5/debug.patch27
-rw-r--r--meta/recipes-devtools/python/python-native-2.6.5/nohostlibs.patch53
-rw-r--r--meta/recipes-devtools/python/python-native-2.6.5/sitecustomize.py45
-rw-r--r--meta/recipes-devtools/python/python-native_2.6.5.bb30
-rw-r--r--meta/recipes-devtools/python/python-pycairo_1.8.10.bb22
-rw-r--r--meta/recipes-devtools/python/python-pycurl/no-static-link.patch14
-rw-r--r--meta/recipes-devtools/python/python-pycurl_7.19.0.bb29
-rw-r--r--meta/recipes-devtools/python/python-pygobject-native_2.21.1.bb15
-rw-r--r--meta/recipes-devtools/python/python-pygobject/generate-constants.patch18
-rw-r--r--meta/recipes-devtools/python/python-pygobject_2.21.1.bb30
-rw-r--r--meta/recipes-devtools/python/python-pygtk/acinclude.m490
-rw-r--r--meta/recipes-devtools/python/python-pygtk/fix-gtkunixprint.patch16
-rw-r--r--meta/recipes-devtools/python/python-pygtk/nodocs.patch13
-rw-r--r--meta/recipes-devtools/python/python-pygtk/prevent_to_get_display_during_import.patch14
-rw-r--r--meta/recipes-devtools/python/python-pygtk/python-pygtk2/acinclude.m490
-rw-r--r--meta/recipes-devtools/python/python-pygtk_2.17.0.bb42
-rw-r--r--meta/recipes-devtools/python/python-pyrex-native_0.9.9.bb5
-rw-r--r--meta/recipes-devtools/python/python-pyrex/pyrex-fix-optimized-mode.patch13
-rw-r--r--meta/recipes-devtools/python/python-pyrex_0.9.9.bb16
-rw-r--r--meta/recipes-devtools/python/python-scons-native_1.3.0.bb6
-rw-r--r--meta/recipes-devtools/python/python-scons_1.3.0.bb12
-rw-r--r--meta/recipes-devtools/python/python-urlgrabber-native_3.9.1.bb4
-rw-r--r--meta/recipes-devtools/python/python-urlgrabber/urlgrabber-3.0.0-cleanup.patch28
-rw-r--r--meta/recipes-devtools/python/python-urlgrabber/urlgrabber-HEAD.patch142
-rw-r--r--meta/recipes-devtools/python/python-urlgrabber/urlgrabber-reset.patch15
-rw-r--r--meta/recipes-devtools/python/python-urlgrabber_3.9.1.bb16
-rw-r--r--meta/recipes-devtools/python/python.inc25
-rw-r--r--meta/recipes-devtools/python/python/00-fix-bindir-libdir-for-cross.patch20
-rw-r--r--meta/recipes-devtools/python/python/01-use-proper-tools-for-cross-build.patch116
-rw-r--r--meta/recipes-devtools/python/python/02-remove-test-for-cross.patch106
-rw-r--r--meta/recipes-devtools/python/python/03-fix-tkinter-detection.patch40
-rw-r--r--meta/recipes-devtools/python/python/04-default-is-optimized.patch52
-rw-r--r--meta/recipes-devtools/python/python/05-enable-ctypes-cross-build.patch28
-rw-r--r--meta/recipes-devtools/python/python/99-ignore-optimization-flag.patch19
-rw-r--r--meta/recipes-devtools/python/python/sitecustomize.py45
-rw-r--r--meta/recipes-devtools/python/python_2.6.5.bb121
-rw-r--r--meta/recipes-devtools/python/yum-metadata-parser-native_1.1.4.bb7
-rw-r--r--meta/recipes-devtools/python/yum-metadata-parser_1.1.4.bb15
52 files changed, 1964 insertions, 0 deletions
diff --git a/meta/recipes-devtools/python/fix-path.inc b/meta/recipes-devtools/python/fix-path.inc
new file mode 100644
index 0000000000..0738c59ada
--- /dev/null
+++ b/meta/recipes-devtools/python/fix-path.inc
@@ -0,0 +1,22 @@
1do_install_append() {
2 for i in `find ${D} -name "*.py"` ; do \
3 sed -i -e s:${D}::g $i
4 done
5
6 for i in `find ${D} -name "*.la"` ; do \
7 sed -i -e s:${STAGING_LIBDIR}:${libdir}:g $i
8 done
9
10 if test -e ${D}${bindir} ; then
11 for i in ${D}${bindir}/* ; do \
12 sed -i -e s:${STAGING_BINDIR_NATIVE}:${bindir}:g $i
13 done
14 fi
15
16 if test -e ${D}${sbindir} ; then
17 for i in ${D}${sbindir}/* ; do \
18 sed -i -e s:${STAGING_BINDIR_NATIVE}:${bindir}:g $i
19 done
20 fi
21}
22
diff --git a/meta/recipes-devtools/python/python-2.6-manifest.inc b/meta/recipes-devtools/python/python-2.6-manifest.inc
new file mode 100644
index 0000000000..cee12c866c
--- /dev/null
+++ b/meta/recipes-devtools/python/python-2.6-manifest.inc
@@ -0,0 +1,268 @@
1
2# WARNING: This file is AUTO GENERATED: Manual edits will be lost next time I regenerate the file.
3# Generator: '../../contrib/python/generate-manifest-2.6.py' Version 20091004 (C) 2002-2009 Michael 'Mickey' Lauer <mlauer@vanille-media.de>
4# Visit the Python for Embedded Systems Site => http://www.Vanille.de/projects/python.spy
5
6
7
8PROVIDES+="python-profile python-threading python-distutils python-doctest python-stringold python-codecs python-ctypes python-pickle python-datetime python-core python-io python-compiler python-compression python-re python-xmlrpc python-terminal python-email python-image python-tests python-core-dbg python-resource python-json python-devel python-difflib python-math python-syslog python-hotshot python-unixadmin python-textutils python-tkinter python-gdbm python-elementtree python-fcntl python-netclient python-pprint python-netserver python-curses python-smtpd python-html python-readline python-subprocess python-pydoc python-logging python-mailbox python-xml python-mime python-sqlite3 python-sqlite3-tests python-unittest python-multiprocessing python-robotparser python-compile python-debugger python-pkgutil python-shell python-bsddb python-mmap python-zlib python-db python-crypt python-idle python-lang python-audio "
9
10PACKAGES="python-core-dbg python-profile python-threading python-distutils python-doctest python-stringold python-codecs python-ctypes python-pickle python-datetime python-core python-io python-compiler python-compression python-re python-xmlrpc python-terminal python-email python-image python-tests python-resource python-json python-devel python-difflib python-math python-syslog python-hotshot python-unixadmin python-textutils python-tkinter python-gdbm python-elementtree python-fcntl python-netclient python-pprint python-netserver python-curses python-smtpd python-html python-readline python-subprocess python-pydoc python-logging python-mailbox python-xml python-mime python-sqlite3 python-sqlite3-tests python-unittest python-multiprocessing python-robotparser python-compile python-debugger python-pkgutil python-shell python-bsddb python-mmap python-zlib python-db python-crypt python-idle python-lang python-audio python-modules"
11
12DESCRIPTION_python-profile="Python Basic Profiling Support"
13RDEPENDS_python-profile="python-core python-textutils"
14FILES_python-profile="${libdir}/python2.6/profile.* ${libdir}/python2.6/pstats.* ${libdir}/python2.6/cProfile.* ${libdir}/python2.6/lib-dynload/_lsprof.so "
15
16DESCRIPTION_python-threading="Python Threading & Synchronization Support"
17RDEPENDS_python-threading="python-core python-lang"
18FILES_python-threading="${libdir}/python2.6/_threading_local.* ${libdir}/python2.6/dummy_thread.* ${libdir}/python2.6/dummy_threading.* ${libdir}/python2.6/mutex.* ${libdir}/python2.6/threading.* ${libdir}/python2.6/Queue.* "
19
20DESCRIPTION_python-distutils="Python Distribution Utilities"
21RDEPENDS_python-distutils="python-core"
22FILES_python-distutils="${libdir}/python2.6/config ${libdir}/python2.6/distutils "
23
24DESCRIPTION_python-doctest="Python framework for running examples in docstrings."
25RDEPENDS_python-doctest="python-core python-lang python-io python-re python-unittest python-debugger python-difflib"
26FILES_python-doctest="${libdir}/python2.6/doctest.* "
27
28DESCRIPTION_python-stringold="Python String APIs [deprecated]"
29RDEPENDS_python-stringold="python-core python-re"
30FILES_python-stringold="${libdir}/python2.6/lib-dynload/strop.so ${libdir}/python2.6/string.* "
31
32DESCRIPTION_python-codecs="Python Codecs, Encodings & i18n Support"
33RDEPENDS_python-codecs="python-core python-lang"
34FILES_python-codecs="${libdir}/python2.6/codecs.* ${libdir}/python2.6/encodings ${libdir}/python2.6/gettext.* ${libdir}/python2.6/locale.* ${libdir}/python2.6/lib-dynload/_locale.so ${libdir}/python2.6/lib-dynload/unicodedata.so ${libdir}/python2.6/stringprep.* ${libdir}/python2.6/xdrlib.* "
35
36DESCRIPTION_python-ctypes="Python C Types Support"
37RDEPENDS_python-ctypes="python-core"
38FILES_python-ctypes="${libdir}/python2.6/ctypes ${libdir}/python2.6/lib-dynload/_ctypes.so "
39
40DESCRIPTION_python-pickle="Python Persistence Support"
41RDEPENDS_python-pickle="python-core python-codecs python-io python-re"
42FILES_python-pickle="${libdir}/python2.6/pickle.* ${libdir}/python2.6/shelve.* ${libdir}/python2.6/lib-dynload/cPickle.so "
43
44DESCRIPTION_python-datetime="Python Calendar and Time support"
45RDEPENDS_python-datetime="python-core python-codecs"
46FILES_python-datetime="${libdir}/python2.6/_strptime.* ${libdir}/python2.6/calendar.* ${libdir}/python2.6/lib-dynload/datetime.so "
47
48DESCRIPTION_python-core="Python Interpreter and core modules (needed!)"
49RDEPENDS_python-core=""
50FILES_python-core="${libdir}/python2.6/__future__.* ${libdir}/python2.6/_abcoll.* ${libdir}/python2.6/abc.* ${libdir}/python2.6/copy.* ${libdir}/python2.6/copy_reg.* ${libdir}/python2.6/ConfigParser.* ${libdir}/python2.6/genericpath.* ${libdir}/python2.6/getopt.* ${libdir}/python2.6/linecache.* ${libdir}/python2.6/new.* ${libdir}/python2.6/os.* ${libdir}/python2.6/posixpath.* ${libdir}/python2.6/struct.* ${libdir}/python2.6/warnings.* ${libdir}/python2.6/site.* ${libdir}/python2.6/stat.* ${libdir}/python2.6/UserDict.* ${libdir}/python2.6/UserList.* ${libdir}/python2.6/UserString.* ${libdir}/python2.6/lib-dynload/binascii.so ${libdir}/python2.6/lib-dynload/_struct.so ${libdir}/python2.6/lib-dynload/time.so ${libdir}/python2.6/lib-dynload/xreadlines.so ${libdir}/python2.6/types.* ${bindir}/python* "
51
52DESCRIPTION_python-io="Python Low-Level I/O"
53RDEPENDS_python-io="python-core python-math"
54FILES_python-io="${libdir}/python2.6/lib-dynload/_socket.so ${libdir}/python2.6/lib-dynload/_ssl.so ${libdir}/python2.6/lib-dynload/select.so ${libdir}/python2.6/lib-dynload/termios.so ${libdir}/python2.6/lib-dynload/cStringIO.so ${libdir}/python2.6/pipes.* ${libdir}/python2.6/socket.* ${libdir}/python2.6/tempfile.* ${libdir}/python2.6/StringIO.* "
55
56DESCRIPTION_python-compiler="Python Compiler Support"
57RDEPENDS_python-compiler="python-core"
58FILES_python-compiler="${libdir}/python2.6/compiler "
59
60DESCRIPTION_python-compression="Python High Level Compression Support"
61RDEPENDS_python-compression="python-core python-zlib"
62FILES_python-compression="${libdir}/python2.6/gzip.* ${libdir}/python2.6/zipfile.* ${libdir}/python2.6/tarfile.* ${libdir}/python2.6/lib-dynload/bz2.so "
63
64DESCRIPTION_python-re="Python Regular Expression APIs"
65RDEPENDS_python-re="python-core"
66FILES_python-re="${libdir}/python2.6/re.* ${libdir}/python2.6/sre.* ${libdir}/python2.6/sre_compile.* ${libdir}/python2.6/sre_constants* ${libdir}/python2.6/sre_parse.* "
67
68DESCRIPTION_python-xmlrpc="Python XMLRPC Support"
69RDEPENDS_python-xmlrpc="python-core python-xml python-netserver python-lang"
70FILES_python-xmlrpc="${libdir}/python2.6/xmlrpclib.* ${libdir}/python2.6/SimpleXMLRPCServer.* "
71
72DESCRIPTION_python-terminal="Python Terminal Controlling Support"
73RDEPENDS_python-terminal="python-core python-io"
74FILES_python-terminal="${libdir}/python2.6/pty.* ${libdir}/python2.6/tty.* "
75
76DESCRIPTION_python-email="Python Email Support"
77RDEPENDS_python-email="python-core python-io python-re python-mime python-audio python-image python-netclient"
78FILES_python-email="${libdir}/python2.6/imaplib.* ${libdir}/python2.6/email "
79
80DESCRIPTION_python-image="Python Graphical Image Handling"
81RDEPENDS_python-image="python-core"
82FILES_python-image="${libdir}/python2.6/colorsys.* ${libdir}/python2.6/imghdr.* ${libdir}/python2.6/lib-dynload/imageop.so ${libdir}/python2.6/lib-dynload/rgbimg.so "
83
84DESCRIPTION_python-tests="Python Tests"
85RDEPENDS_python-tests="python-core"
86FILES_python-tests="${libdir}/python2.6/test "
87
88DESCRIPTION_python-core-dbg="Python core module debug information"
89RDEPENDS_python-core-dbg="python-core"
90FILES_python-core-dbg="${libdir}/python2.6/config/.debug ${libdir}/python2.6/lib-dynload/.debug ${bindir}/.debug ${libdir}/.debug "
91
92DESCRIPTION_python-resource="Python Resource Control Interface"
93RDEPENDS_python-resource="python-core"
94FILES_python-resource="${libdir}/python2.6/lib-dynload/resource.so "
95
96DESCRIPTION_python-json="Python JSON Support"
97RDEPENDS_python-json="python-core python-math python-re"
98FILES_python-json="${libdir}/python2.6/json "
99
100DESCRIPTION_python-devel="Python Development Package"
101RDEPENDS_python-devel="python-core"
102FILES_python-devel="${includedir} ${libdir}/libpython2.6.so ${libdir}/python2.6/config "
103
104DESCRIPTION_python-difflib="Python helpers for computing deltas between objects."
105RDEPENDS_python-difflib="python-lang python-re"
106FILES_python-difflib="${libdir}/python2.6/difflib.* "
107
108DESCRIPTION_python-math="Python Math Support"
109RDEPENDS_python-math="python-core"
110FILES_python-math="${libdir}/python2.6/lib-dynload/cmath.so ${libdir}/python2.6/lib-dynload/math.so ${libdir}/python2.6/lib-dynload/_random.so ${libdir}/python2.6/random.* ${libdir}/python2.6/sets.* "
111
112DESCRIPTION_python-syslog="Python Syslog Interface"
113RDEPENDS_python-syslog="python-core"
114FILES_python-syslog="${libdir}/python2.6/lib-dynload/syslog.so "
115
116DESCRIPTION_python-hotshot="Python Hotshot Profiler"
117RDEPENDS_python-hotshot="python-core"
118FILES_python-hotshot="${libdir}/python2.6/hotshot ${libdir}/python2.6/lib-dynload/_hotshot.so "
119
120DESCRIPTION_python-unixadmin="Python Unix Administration Support"
121RDEPENDS_python-unixadmin="python-core"
122FILES_python-unixadmin="${libdir}/python2.6/lib-dynload/nis.so ${libdir}/python2.6/lib-dynload/grp.so ${libdir}/python2.6/lib-dynload/pwd.so ${libdir}/python2.6/getpass.* "
123
124DESCRIPTION_python-textutils="Python Option Parsing, Text Wrapping and Comma-Separated-Value Support"
125RDEPENDS_python-textutils="python-core python-io python-re python-stringold"
126FILES_python-textutils="${libdir}/python2.6/lib-dynload/_csv.so ${libdir}/python2.6/csv.* ${libdir}/python2.6/optparse.* ${libdir}/python2.6/textwrap.* "
127
128DESCRIPTION_python-tkinter="Python Tcl/Tk Bindings"
129RDEPENDS_python-tkinter="python-core"
130FILES_python-tkinter="${libdir}/python2.6/lib-dynload/_tkinter.so ${libdir}/python2.6/lib-tk "
131
132DESCRIPTION_python-gdbm="Python GNU Database Support"
133RDEPENDS_python-gdbm="python-core"
134FILES_python-gdbm="${libdir}/python2.6/lib-dynload/gdbm.so "
135
136DESCRIPTION_python-elementtree="Python elementree"
137RDEPENDS_python-elementtree="python-core"
138FILES_python-elementtree="${libdir}/python2.6/lib-dynload/_elementtree.so "
139
140DESCRIPTION_python-fcntl="Python's fcntl Interface"
141RDEPENDS_python-fcntl="python-core"
142FILES_python-fcntl="${libdir}/python2.6/lib-dynload/fcntl.so "
143
144DESCRIPTION_python-netclient="Python Internet Protocol Clients"
145RDEPENDS_python-netclient="python-core python-crypt python-datetime python-io python-lang python-logging python-mime"
146FILES_python-netclient="${libdir}/python2.6/*Cookie*.* ${libdir}/python2.6/base64.* ${libdir}/python2.6/cookielib.* ${libdir}/python2.6/ftplib.* ${libdir}/python2.6/gopherlib.* ${libdir}/python2.6/hmac.* ${libdir}/python2.6/httplib.* ${libdir}/python2.6/mimetypes.* ${libdir}/python2.6/nntplib.* ${libdir}/python2.6/poplib.* ${libdir}/python2.6/smtplib.* ${libdir}/python2.6/telnetlib.* ${libdir}/python2.6/urllib.* ${libdir}/python2.6/urllib2.* ${libdir}/python2.6/urlparse.* ${libdir}/python2.6/uuid.* ${libdir}/python2.6/rfc822.* ${libdir}/python2.6/mimetools.* "
147
148DESCRIPTION_python-pprint="Python Pretty-Print Support"
149RDEPENDS_python-pprint="python-core"
150FILES_python-pprint="${libdir}/python2.6/pprint.* "
151
152DESCRIPTION_python-netserver="Python Internet Protocol Servers"
153RDEPENDS_python-netserver="python-core python-netclient"
154FILES_python-netserver="${libdir}/python2.6/cgi.* ${libdir}/python2.6/*HTTPServer.* ${libdir}/python2.6/SocketServer.* "
155
156DESCRIPTION_python-curses="Python Curses Support"
157RDEPENDS_python-curses="python-core"
158FILES_python-curses="${libdir}/python2.6/curses ${libdir}/python2.6/lib-dynload/_curses.so ${libdir}/python2.6/lib-dynload/_curses_panel.so "
159
160DESCRIPTION_python-smtpd="Python Simple Mail Transport Daemon"
161RDEPENDS_python-smtpd="python-core python-netserver python-email python-mime"
162FILES_python-smtpd="${bindir}/smtpd.* "
163
164DESCRIPTION_python-html="Python HTML Processing"
165RDEPENDS_python-html="python-core"
166FILES_python-html="${libdir}/python2.6/formatter.* ${libdir}/python2.6/htmlentitydefs.* ${libdir}/python2.6/htmllib.* ${libdir}/python2.6/markupbase.* ${libdir}/python2.6/sgmllib.* "
167
168DESCRIPTION_python-readline="Python Readline Support"
169RDEPENDS_python-readline="python-core"
170FILES_python-readline="${libdir}/python2.6/lib-dynload/readline.so ${libdir}/python2.6/rlcompleter.* "
171
172DESCRIPTION_python-subprocess="Python Subprocess Support"
173RDEPENDS_python-subprocess="python-core python-io python-re python-fcntl python-pickle"
174FILES_python-subprocess="${libdir}/python2.6/subprocess.* "
175
176DESCRIPTION_python-pydoc="Python Interactive Help Support"
177RDEPENDS_python-pydoc="python-core python-lang python-stringold python-re"
178FILES_python-pydoc="${bindir}/pydoc ${libdir}/python2.6/pydoc.* "
179
180DESCRIPTION_python-logging="Python Logging Support"
181RDEPENDS_python-logging="python-core python-io python-lang python-pickle python-stringold"
182FILES_python-logging="${libdir}/python2.6/logging "
183
184DESCRIPTION_python-mailbox="Python Mailbox Format Support"
185RDEPENDS_python-mailbox="python-core python-mime"
186FILES_python-mailbox="${libdir}/python2.6/mailbox.* "
187
188DESCRIPTION_python-xml="Python basic XML support."
189RDEPENDS_python-xml="python-core python-re"
190FILES_python-xml="${libdir}/python2.6/lib-dynload/pyexpat.so ${libdir}/python2.6/xml ${libdir}/python2.6/xmllib.* "
191
192DESCRIPTION_python-mime="Python MIME Handling APIs"
193RDEPENDS_python-mime="python-core python-io"
194FILES_python-mime="${libdir}/python2.6/mimetools.* ${libdir}/python2.6/uu.* ${libdir}/python2.6/quopri.* ${libdir}/python2.6/rfc822.* "
195
196DESCRIPTION_python-sqlite3="Python Sqlite3 Database Support"
197RDEPENDS_python-sqlite3="python-core python-datetime python-lang python-crypt python-io python-threading python-zlib"
198FILES_python-sqlite3="${libdir}/python2.6/lib-dynload/_sqlite3.so ${libdir}/python2.6/sqlite3/dbapi2.* ${libdir}/python2.6/sqlite3/__init__.* ${libdir}/python2.6/sqlite3/dump.* "
199
200DESCRIPTION_python-sqlite3-tests="Python Sqlite3 Database Support Tests"
201RDEPENDS_python-sqlite3-tests="python-core python-sqlite3"
202FILES_python-sqlite3-tests="${libdir}/python2.6/sqlite3/test "
203
204DESCRIPTION_python-unittest="Python Unit Testing Framework"
205RDEPENDS_python-unittest="python-core python-stringold python-lang"
206FILES_python-unittest="${libdir}/python2.6/unittest.* "
207
208DESCRIPTION_python-multiprocessing="Python Multiprocessing Support"
209RDEPENDS_python-multiprocessing="python-core python-io python-lang"
210FILES_python-multiprocessing="${libdir}/python2.6/lib-dynload/_multiprocessing.so ${libdir}/python2.6/multiprocessing "
211
212DESCRIPTION_python-robotparser="Python robots.txt parser"
213RDEPENDS_python-robotparser="python-core python-netclient"
214FILES_python-robotparser="${libdir}/python2.6/robotparser.* "
215
216DESCRIPTION_python-compile="Python Bytecode Compilation Support"
217RDEPENDS_python-compile="python-core"
218FILES_python-compile="${libdir}/python2.6/py_compile.* ${libdir}/python2.6/compileall.* "
219
220DESCRIPTION_python-debugger="Python Debugger"
221RDEPENDS_python-debugger="python-core python-io python-lang python-re python-stringold python-shell python-pprint"
222FILES_python-debugger="${libdir}/python2.6/bdb.* ${libdir}/python2.6/pdb.* "
223
224DESCRIPTION_python-pkgutil="Python Package Extension Utility Support"
225RDEPENDS_python-pkgutil="python-core"
226FILES_python-pkgutil="${libdir}/python2.6/pkgutil.* "
227
228DESCRIPTION_python-shell="Python Shell-Like Functionality"
229RDEPENDS_python-shell="python-core python-re"
230FILES_python-shell="${libdir}/python2.6/cmd.* ${libdir}/python2.6/commands.* ${libdir}/python2.6/dircache.* ${libdir}/python2.6/fnmatch.* ${libdir}/python2.6/glob.* ${libdir}/python2.6/popen2.* ${libdir}/python2.6/shlex.* ${libdir}/python2.6/shutil.* "
231
232DESCRIPTION_python-bsddb="Python Berkeley Database Bindings"
233RDEPENDS_python-bsddb="python-core"
234FILES_python-bsddb="${libdir}/python2.6/bsddb ${libdir}/python2.6/lib-dynload/_bsddb.so "
235
236DESCRIPTION_python-mmap="Python Memory-Mapped-File Support"
237RDEPENDS_python-mmap="python-core python-io"
238FILES_python-mmap="${libdir}/python2.6/lib-dynload/mmap.so "
239
240DESCRIPTION_python-zlib="Python zlib Support."
241RDEPENDS_python-zlib="python-core"
242FILES_python-zlib="${libdir}/python2.6/lib-dynload/zlib.so "
243
244DESCRIPTION_python-db="Python File-Based Database Support"
245RDEPENDS_python-db="python-core"
246FILES_python-db="${libdir}/python2.6/anydbm.* ${libdir}/python2.6/dumbdbm.* ${libdir}/python2.6/whichdb.* "
247
248DESCRIPTION_python-crypt="Python Basic Cryptographic and Hashing Support"
249RDEPENDS_python-crypt="python-core"
250FILES_python-crypt="${libdir}/python2.6/hashlib.* ${libdir}/python2.6/md5.* ${libdir}/python2.6/sha.* ${libdir}/python2.6/lib-dynload/crypt.so ${libdir}/python2.6/lib-dynload/_hashlib.so ${libdir}/python2.6/lib-dynload/_sha256.so ${libdir}/python2.6/lib-dynload/_sha512.so "
251
252DESCRIPTION_python-idle="Python Integrated Development Environment"
253RDEPENDS_python-idle="python-core python-tkinter"
254FILES_python-idle="${bindir}/idle ${libdir}/python2.6/idlelib "
255
256DESCRIPTION_python-lang="Python Low-Level Language Support"
257RDEPENDS_python-lang="python-core"
258FILES_python-lang="${libdir}/python2.6/lib-dynload/_bisect.so ${libdir}/python2.6/lib-dynload/_collections.so ${libdir}/python2.6/lib-dynload/_heapq.so ${libdir}/python2.6/lib-dynload/_weakref.so ${libdir}/python2.6/lib-dynload/_functools.so ${libdir}/python2.6/lib-dynload/array.so ${libdir}/python2.6/lib-dynload/itertools.so ${libdir}/python2.6/lib-dynload/operator.so ${libdir}/python2.6/lib-dynload/parser.so ${libdir}/python2.6/atexit.* ${libdir}/python2.6/bisect.* ${libdir}/python2.6/code.* ${libdir}/python2.6/codeop.* ${libdir}/python2.6/collections.* ${libdir}/python2.6/dis.* ${libdir}/python2.6/functools.* ${libdir}/python2.6/heapq.* ${libdir}/python2.6/inspect.* ${libdir}/python2.6/keyword.* ${libdir}/python2.6/opcode.* ${libdir}/python2.6/symbol.* ${libdir}/python2.6/repr.* ${libdir}/python2.6/token.* ${libdir}/python2.6/tokenize.* ${libdir}/python2.6/traceback.* ${libdir}/python2.6/linecache.* ${libdir}/python2.6/weakref.* "
259
260DESCRIPTION_python-audio="Python Audio Handling"
261RDEPENDS_python-audio="python-core"
262FILES_python-audio="${libdir}/python2.6/wave.* ${libdir}/python2.6/chunk.* ${libdir}/python2.6/sndhdr.* ${libdir}/python2.6/lib-dynload/ossaudiodev.so ${libdir}/python2.6/lib-dynload/audioop.so "
263
264DESCRIPTION_python-modules="All Python modules"
265RDEPENDS_python-modules="python-profile python-threading python-distutils python-doctest python-stringold python-codecs python-ctypes python-pickle python-datetime python-core python-io python-compiler python-compression python-re python-xmlrpc python-terminal python-email python-image python-tests python-resource python-json python-devel python-difflib python-math python-syslog python-hotshot python-unixadmin python-textutils python-tkinter python-gdbm python-elementtree python-fcntl python-netclient python-pprint python-netserver python-curses python-smtpd python-html python-readline python-subprocess python-pydoc python-logging python-mailbox python-xml python-mime python-sqlite3 python-sqlite3-tests python-unittest python-multiprocessing python-robotparser python-compile python-debugger python-pkgutil python-shell python-bsddb python-mmap python-zlib python-db python-crypt python-idle python-lang python-audio "
266ALLOW_EMPTY_python-modules = "1"
267
268
diff --git a/meta/recipes-devtools/python/python-dbus_0.83.1.bb b/meta/recipes-devtools/python/python-dbus_0.83.1.bb
new file mode 100644
index 0000000000..b30e82be6a
--- /dev/null
+++ b/meta/recipes-devtools/python/python-dbus_0.83.1.bb
@@ -0,0 +1,21 @@
1DESCRIPTION = "Python bindings for DBus, a socket-based message bus system for interprocess communication"
2SECTION = "devel/python"
3HOMEPAGE = "http://www.freedesktop.org/Software/dbus"
4LICENSE = "MIT"
5DEPENDS = "expat dbus dbus-glib virtual/libintl python-pyrex-native"
6PR = "ml0"
7
8SRC_URI = "http://dbus.freedesktop.org/releases/dbus-python/dbus-python-${PV}.tar.gz"
9S = "${WORKDIR}/dbus-python-${PV}"
10
11inherit distutils-base autotools pkgconfig
12
13export BUILD_SYS
14export HOST_SYS
15
16export STAGING_LIBDIR
17export STAGING_INCDIR
18
19RDEPENDS = "python-io python-logging python-stringold python-threading python-xml"
20
21FILES_${PN}-dev += "${libdir}/pkgconfig
diff --git a/meta/recipes-devtools/python/python-gst/python-path.patch b/meta/recipes-devtools/python/python-gst/python-path.patch
new file mode 100644
index 0000000000..af5badd4d9
--- /dev/null
+++ b/meta/recipes-devtools/python/python-gst/python-path.patch
@@ -0,0 +1,25 @@
1Index: gst-python-0.10.18/acinclude.m4
2===================================================================
3--- gst-python-0.10.18.orig/acinclude.m4
4+++ gst-python-0.10.18/acinclude.m4
5@@ -43,6 +43,12 @@ AC_DEFUN([AM_CHECK_PYTHON_HEADERS],
6 [AC_REQUIRE([AM_PATH_PYTHON])
7 AC_MSG_CHECKING(for headers required to compile python extensions)
8 dnl deduce PYTHON_INCLUDES
9+
10+AC_ARG_WITH(python-includes,
11+ [ --with-python-includes=DIR path to Python includes], py_exec_prefix=$withval)
12+if test x$py_exec_prefix != x; then
13+PYTHON_INCLUDES="-I${py_exec_prefix}/include/python${PYTHON_VERSION}"
14+else
15 py_prefix=`$PYTHON -c "import sys; print sys.prefix"`
16 py_exec_prefix=`$PYTHON -c "import sys; print sys.exec_prefix"`
17 if $PYTHON-config --help 2>/dev/null; then
18@@ -53,6 +59,7 @@ else
19 PYTHON_INCLUDES="$PYTHON_INCLUDES -I${py_exec_prefix}/include/python${PYTHON_VERSION}"
20 fi
21 fi
22+fi
23 AC_SUBST(PYTHON_INCLUDES)
24 dnl check if the headers exist:
25 save_CPPFLAGS="$CPPFLAGS"
diff --git a/meta/recipes-devtools/python/python-gst_0.10.18.bb b/meta/recipes-devtools/python/python-gst_0.10.18.bb
new file mode 100644
index 0000000000..9de07b3c4f
--- /dev/null
+++ b/meta/recipes-devtools/python/python-gst_0.10.18.bb
@@ -0,0 +1,17 @@
1DESCRIPTION = "Python Gstreamer bindings"
2SECTION = "devel/python"
3LICENSE = "LGPL"
4DEPENDS = "gstreamer gst-plugins-base python-pygobject"
5PR = "ml1"
6
7SRC_URI = "http://gstreamer.freedesktop.org/src/gst-python/gst-python-${PV}.tar.bz2 \
8 file://python-path.patch"
9S = "${WORKDIR}/gst-python-${PV}"
10
11inherit autotools distutils-base pkgconfig
12
13EXTRA_OECONF += "--with-python-includes=${STAGING_INCDIR}/../"
14
15FILES_${PN} += "${datadir}/gst-python"
16FILES_${PN}-dev += "${datadir}/gst-python/0.10/defs"
17FILES_${PN}-dbg += "${libdir}/${PYTHON_DIR}/site-packages/gst-0.10/gst/.debug/"
diff --git a/meta/recipes-devtools/python/python-imaging/path.patch b/meta/recipes-devtools/python/python-imaging/path.patch
new file mode 100644
index 0000000000..264dcc09b8
--- /dev/null
+++ b/meta/recipes-devtools/python/python-imaging/path.patch
@@ -0,0 +1,33 @@
1Index: Imaging-1.1.7/setup.py
2===================================================================
3--- Imaging-1.1.7.orig/setup.py
4+++ Imaging-1.1.7/setup.py
5@@ -34,10 +34,10 @@ def libinclude(root):
6 # TIFF_ROOT = libinclude("/opt/tiff")
7
8 TCL_ROOT = None
9-JPEG_ROOT = None
10-ZLIB_ROOT = None
11+JPEG_ROOT = os.environ['STAGING_LIBDIR']
12+ZLIB_ROOT = os.environ['STAGING_LIBDIR']
13 TIFF_ROOT = None
14-FREETYPE_ROOT = None
15+FREETYPE_ROOT = os.environ['STAGING_LIBDIR'], os.environ['STAGING_INCDIR']
16 LCMS_ROOT = None
17
18 # FIXME: add mechanism to explicitly *disable* the use of a library
19@@ -207,14 +207,6 @@ class pil_build_ext(build_ext):
20 if os.path.isfile(os.path.join(tcl_dir, "tk.h")):
21 add_directory(include_dirs, tcl_dir)
22
23- # standard locations
24- add_directory(library_dirs, "/usr/local/lib")
25- add_directory(include_dirs, "/usr/local/include")
26-
27- add_directory(library_dirs, "/usr/lib")
28- add_directory(include_dirs, "/usr/include")
29-
30- #
31 # insert new dirs *before* default libs, to avoid conflicts
32 # between Python PYD stub libs and real libraries
33
diff --git a/meta/recipes-devtools/python/python-imaging_1.1.7.bb b/meta/recipes-devtools/python/python-imaging_1.1.7.bb
new file mode 100644
index 0000000000..98120432ac
--- /dev/null
+++ b/meta/recipes-devtools/python/python-imaging_1.1.7.bb
@@ -0,0 +1,30 @@
1DESCRIPTION = "Python Imaging Library"
2SECTION = "devel/python"
3PRIORITY = "optional"
4LICENSE = "GPL"
5DEPENDS = "freetype jpeg tiff"
6RDEPENDS = "python-lang python-stringold"
7SRCNAME = "Imaging"
8PR = "ml0"
9
10SRC_URI = "http://effbot.org/downloads/Imaging-${PV}.tar.gz \
11 file://path.patch"
12S = "${WORKDIR}/${SRCNAME}-${PV}"
13
14inherit distutils
15
16do_compile() {
17 export STAGING_LIBDIR=${STAGING_LIBDIR}
18 export STAGING_INCDIR=${STAGING_INCDIR}
19 distutils_do_compile
20}
21
22do_install() {
23 export STAGING_LIBDIR=${STAGING_LIBDIR}
24 export STAGING_INCDIR=${STAGING_INCDIR}
25 distutils_do_install
26 install -d ${D}${datadir}/doc/${PN}/html/
27 install -m 0644 ${S}/README ${D}${datadir}/doc/${PN}/
28 install -m 0644 ${S}/Docs/* ${D}${datadir}/doc/${PN}/html/
29
30}
diff --git a/meta/recipes-devtools/python/python-iniparse-native_0.3.2.bb b/meta/recipes-devtools/python/python-iniparse-native_0.3.2.bb
new file mode 100644
index 0000000000..41aa13d97a
--- /dev/null
+++ b/meta/recipes-devtools/python/python-iniparse-native_0.3.2.bb
@@ -0,0 +1,6 @@
1require python-iniparse_${PV}.bb
2inherit native
3DEPENDS = "python-native"
4RDEPENDS = ""
5PR = "r0"
6
diff --git a/meta/recipes-devtools/python/python-iniparse_0.3.2.bb b/meta/recipes-devtools/python/python-iniparse_0.3.2.bb
new file mode 100644
index 0000000000..27a38f4249
--- /dev/null
+++ b/meta/recipes-devtools/python/python-iniparse_0.3.2.bb
@@ -0,0 +1,11 @@
1DESCRIPTION = "iniparse is a INI parser for Python"
2HOMEPAGE = "http://code.google.com/p/iniparse/"
3SECTION = "devel/python"
4PRIORITY = "optional"
5LICENSE = "GPL"
6PR = "r0"
7
8SRC_URI = "http://iniparse.googlecode.com/files/iniparse-${PV}.tar.gz"
9S = "${WORKDIR}/iniparse-${PV}"
10
11inherit distutils
diff --git a/meta/recipes-devtools/python/python-native-2.6.5/00-fix-bindir-libdir-for-cross.patch b/meta/recipes-devtools/python/python-native-2.6.5/00-fix-bindir-libdir-for-cross.patch
new file mode 100644
index 0000000000..2559e3a0e4
--- /dev/null
+++ b/meta/recipes-devtools/python/python-native-2.6.5/00-fix-bindir-libdir-for-cross.patch
@@ -0,0 +1,20 @@
1# $(exec_prefix) points to the wrong directory, when installing
2# a cross-build. @bindir@ and @libdir@ works better and doesn't
3# affect the native build.
4# Signed-Off: Michael 'Mickey' Lauer <mickey@vanille-media.de>
5
6Index: Python-2.6.1/Makefile.pre.in
7===================================================================
8--- Python-2.6.1.orig/Makefile.pre.in
9+++ Python-2.6.1/Makefile.pre.in
10@@ -86,8 +86,8 @@ exec_prefix= @exec_prefix@
11 datarootdir= @datarootdir@
12
13 # Expanded directories
14-BINDIR= $(exec_prefix)/bin
15-LIBDIR= $(exec_prefix)/lib
16+BINDIR= @bindir@
17+LIBDIR= @libdir@
18 MANDIR= @mandir@
19 INCLUDEDIR= @includedir@
20 CONFINCLUDEDIR= $(exec_prefix)/include
diff --git a/meta/recipes-devtools/python/python-native-2.6.5/04-default-is-optimized.patch b/meta/recipes-devtools/python/python-native-2.6.5/04-default-is-optimized.patch
new file mode 100644
index 0000000000..5131e0ba69
--- /dev/null
+++ b/meta/recipes-devtools/python/python-native-2.6.5/04-default-is-optimized.patch
@@ -0,0 +1,18 @@
1# When compiling for an embedded system, we need every bit of
2# performance we can get. default to optimized with the option
3# of opt-out.
4# Signed-Off: Michael 'Mickey' Lauer <mickey@vanille-media.de>
5
6Index: Python-2.6.1/Python/compile.c
7===================================================================
8--- Python-2.6.1.orig/Python/compile.c
9+++ Python-2.6.1/Python/compile.c
10@@ -32,7 +32,7 @@
11 #include "symtable.h"
12 #include "opcode.h"
13
14-int Py_OptimizeFlag = 0;
15+int Py_OptimizeFlag = 1;
16
17 #define DEFAULT_BLOCK_SIZE 16
18 #define DEFAULT_BLOCKS 8
diff --git a/meta/recipes-devtools/python/python-native-2.6.5/10-distutils-fix-swig-parameter.patch b/meta/recipes-devtools/python/python-native-2.6.5/10-distutils-fix-swig-parameter.patch
new file mode 100644
index 0000000000..f5e852a118
--- /dev/null
+++ b/meta/recipes-devtools/python/python-native-2.6.5/10-distutils-fix-swig-parameter.patch
@@ -0,0 +1,16 @@
1# Some versions of SWIG do not use the extension parameter.
2# Make it optional.
3# Signed-Off: Michael 'Mickey' Lauer <mickey@vanille-media.de>
4Index: Python-2.6.1/Lib/distutils/command/build_ext.py
5===================================================================
6--- Python-2.6.1.orig/Lib/distutils/command/build_ext.py
7+++ Python-2.6.1/Lib/distutils/command/build_ext.py
8@@ -566,7 +566,7 @@ class build_ext (Command):
9 target_lang=language)
10
11
12- def swig_sources (self, sources, extension):
13+ def swig_sources (self, sources, extension=None):
14
15 """Walk the list of source files in 'sources', looking for SWIG
16 interface (.i) files. Run SWIG on all that are found, and
diff --git a/meta/recipes-devtools/python/python-native-2.6.5/11-distutils-never-modify-shebang-line.patch b/meta/recipes-devtools/python/python-native-2.6.5/11-distutils-never-modify-shebang-line.patch
new file mode 100644
index 0000000000..8354e266fa
--- /dev/null
+++ b/meta/recipes-devtools/python/python-native-2.6.5/11-distutils-never-modify-shebang-line.patch
@@ -0,0 +1,18 @@
1# Don't modify the she-bang line for a cross-build.
2# Otherwise it points to our hostpython (which we do not want)
3#
4# Signed-Off: Michael 'Mickey' Lauer <mickey@vanille-media.de>
5
6Index: Python-2.6.1/Lib/distutils/command/build_scripts.py
7===================================================================
8--- Python-2.6.1.orig/Lib/distutils/command/build_scripts.py
9+++ Python-2.6.1/Lib/distutils/command/build_scripts.py
10@@ -87,7 +87,7 @@ class build_scripts (Command):
11 continue
12
13 match = first_line_re.match(first_line)
14- if match:
15+ if False: #match:
16 adjust = 1
17 post_interp = match.group(1) or ''
18
diff --git a/meta/recipes-devtools/python/python-native-2.6.5/12-distutils-prefix-is-inside-staging-area.patch b/meta/recipes-devtools/python/python-native-2.6.5/12-distutils-prefix-is-inside-staging-area.patch
new file mode 100644
index 0000000000..aa4393679f
--- /dev/null
+++ b/meta/recipes-devtools/python/python-native-2.6.5/12-distutils-prefix-is-inside-staging-area.patch
@@ -0,0 +1,60 @@
1# The proper prefix is inside our staging area.
2# Signed-Off: Michael 'Mickey' Lauer <mickey@vanille-media.de>
3
4Index: Python-2.6.1/Lib/distutils/sysconfig.py
5===================================================================
6--- Python-2.6.1.orig/Lib/distutils/sysconfig.py
7+++ Python-2.6.1/Lib/distutils/sysconfig.py
8@@ -19,8 +19,8 @@ import sys
9 from distutils.errors import DistutilsPlatformError
10
11 # These are needed in a couple of spots, so just compute them once.
12-PREFIX = os.path.normpath(sys.prefix)
13-EXEC_PREFIX = os.path.normpath(sys.exec_prefix)
14+PREFIX = os.path.normpath(sys.prefix).replace( os.getenv("BUILD_SYS"), os.getenv("HOST_SYS") )
15+EXEC_PREFIX = os.path.normpath(sys.exec_prefix).replace( os.getenv("BUILD_SYS"), os.getenv("HOST_SYS") )
16
17 # Path to the base directory of the project. On Windows the binary may
18 # live in project/PCBuild9. If we're dealing with an x64 Windows build,
19@@ -70,7 +70,10 @@ def get_python_inc(plat_specific=0, pref
20 sys.exec_prefix -- i.e., ignore 'plat_specific'.
21 """
22 if prefix is None:
23- prefix = plat_specific and EXEC_PREFIX or PREFIX
24+ if plat_specific:
25+ prefix = plat_specific and os.environ['STAGING_INCDIR'].rstrip('include')
26+ else:
27+ prefix = plat_specific and EXEC_PREFIX or PREFIX
28 if os.name == "posix":
29 if python_build:
30 base = os.path.dirname(os.path.abspath(sys.executable))
31@@ -112,7 +115,10 @@ def get_python_lib(plat_specific=0, stan
32 sys.exec_prefix -- i.e., ignore 'plat_specific'.
33 """
34 if prefix is None:
35- prefix = plat_specific and EXEC_PREFIX or PREFIX
36+ if plat_specific:
37+ prefix = plat_specific and os.environ['STAGING_LIBDIR'].rstrip('lib')
38+ else:
39+ prefix = plat_specific and EXEC_PREFIX or PREFIX
40
41 if os.name == "posix":
42 libpython = os.path.join(prefix,
43@@ -218,7 +218,7 @@ def get_config_h_filename():
44 else:
45 # The name of the config.h file changed in 2.2
46 config_h = 'pyconfig.h'
47- return os.path.join(inc_dir, config_h)
48+ return os.path.join(inc_dir, config_h).replace( os.getenv("BUILD_SYS"), os.getenv("HOST_SYS") )
49
50
51 def get_makefile_filename():
52@@ -226,7 +226,7 @@ def get_makefile_filename():
53 if python_build:
54 return os.path.join(os.path.dirname(sys.executable), "Makefile")
55 lib_dir = get_python_lib(plat_specific=1, standard_lib=1)
56- return os.path.join(lib_dir, "config", "Makefile")
57+ return os.path.join(lib_dir, "config", "Makefile").replace( os.getenv("BUILD_SYS"), os.getenv("HOST_SYS") )
58
59
60 def parse_config_h(fp, g=None):
diff --git a/meta/recipes-devtools/python/python-native-2.6.5/debug.patch b/meta/recipes-devtools/python/python-native-2.6.5/debug.patch
new file mode 100644
index 0000000000..beb3adc6db
--- /dev/null
+++ b/meta/recipes-devtools/python/python-native-2.6.5/debug.patch
@@ -0,0 +1,27 @@
1Index: Python-2.6.1/Lib/distutils/unixccompiler.py
2===================================================================
3--- Python-2.6.1.orig/Lib/distutils/unixccompiler.py 2009-11-13 16:04:54.000000000 +0000
4+++ Python-2.6.1/Lib/distutils/unixccompiler.py 2009-11-13 16:06:27.000000000 +0000
5@@ -300,6 +300,8 @@
6 dylib_f = self.library_filename(lib, lib_type='dylib')
7 static_f = self.library_filename(lib, lib_type='static')
8
9+ print "Looking in %s for %s" % (lib, dirs)
10+
11 for dir in dirs:
12 shared = os.path.join(dir, shared_f)
13 dylib = os.path.join(dir, dylib_f)
14@@ -309,10 +311,13 @@
15 # assuming that *all* Unix C compilers do. And of course I'm
16 # ignoring even GCC's "-static" option. So sue me.
17 if os.path.exists(dylib):
18+ print "Found %s" % (dylib)
19 return dylib
20 elif os.path.exists(shared):
21+ print "Found %s" % (shared)
22 return shared
23 elif os.path.exists(static):
24+ print "Found %s" % (static)
25 return static
26
27 # Oops, didn't find it in *any* of 'dirs'
diff --git a/meta/recipes-devtools/python/python-native-2.6.5/nohostlibs.patch b/meta/recipes-devtools/python/python-native-2.6.5/nohostlibs.patch
new file mode 100644
index 0000000000..7020f3c2a9
--- /dev/null
+++ b/meta/recipes-devtools/python/python-native-2.6.5/nohostlibs.patch
@@ -0,0 +1,53 @@
1Index: Python-2.6.1/setup.py
2===================================================================
3--- Python-2.6.1.orig/setup.py 2009-11-13 16:20:47.000000000 +0000
4+++ Python-2.6.1/setup.py 2009-11-13 16:28:00.000000000 +0000
5@@ -310,8 +310,8 @@
6
7 def detect_modules(self):
8 # Ensure that /usr/local is always used
9- add_dir_to_list(self.compiler.library_dirs, '/usr/local/lib')
10- add_dir_to_list(self.compiler.include_dirs, '/usr/local/include')
11+ #add_dir_to_list(self.compiler.library_dirs, '/usr/local/lib')
12+ #add_dir_to_list(self.compiler.include_dirs, '/usr/local/include')
13
14 # Add paths specified in the environment variables LDFLAGS and
15 # CPPFLAGS for header and library files.
16@@ -347,10 +347,10 @@
17 for directory in reversed(options.dirs):
18 add_dir_to_list(dir_list, directory)
19
20- if os.path.normpath(sys.prefix) != '/usr':
21- add_dir_to_list(self.compiler.library_dirs,
22+
23+ add_dir_to_list(self.compiler.library_dirs,
24 sysconfig.get_config_var("LIBDIR"))
25- add_dir_to_list(self.compiler.include_dirs,
26+ add_dir_to_list(self.compiler.include_dirs,
27 sysconfig.get_config_var("INCLUDEDIR"))
28
29 try:
30@@ -361,11 +361,8 @@
31 # lib_dirs and inc_dirs are used to search for files;
32 # if a file is found in one of those directories, it can
33 # be assumed that no additional -I,-L directives are needed.
34- lib_dirs = self.compiler.library_dirs + [
35- '/lib64', '/usr/lib64',
36- '/lib', '/usr/lib',
37- ]
38- inc_dirs = self.compiler.include_dirs + ['/usr/include']
39+ lib_dirs = self.compiler.library_dirs
40+ inc_dirs = self.compiler.include_dirs
41 exts = []
42 missing = []
43
44@@ -583,8 +580,7 @@
45 readline_libs.append('ncurses')
46 elif self.compiler.find_library_file(lib_dirs, 'curses'):
47 readline_libs.append('curses')
48- elif self.compiler.find_library_file(lib_dirs +
49- ['/usr/lib/termcap'],
50+ elif self.compiler.find_library_file(lib_dirs,
51 'termcap'):
52 readline_libs.append('termcap')
53 exts.append( Extension('readline', ['readline.c'],
diff --git a/meta/recipes-devtools/python/python-native-2.6.5/sitecustomize.py b/meta/recipes-devtools/python/python-native-2.6.5/sitecustomize.py
new file mode 100644
index 0000000000..273901898a
--- /dev/null
+++ b/meta/recipes-devtools/python/python-native-2.6.5/sitecustomize.py
@@ -0,0 +1,45 @@
1# OpenEmbedded sitecustomize.py (C) 2002-2008 Michael 'Mickey' Lauer <mlauer@vanille-media.de>
2# GPLv2 or later
3# Version: 20081123
4# Features:
5# * set proper default encoding
6# * enable readline completion in the interactive interpreter
7# * load command line history on startup
8# * save command line history on exit
9
10import os
11
12def __exithandler():
13 try:
14 readline.write_history_file( "%s/.python-history" % os.getenv( "HOME", "/tmp" ) )
15 except IOError:
16 pass
17
18def __registerExitHandler():
19 import atexit
20 atexit.register( __exithandler )
21
22def __enableReadlineSupport():
23 readline.set_history_length( 1000 )
24 readline.parse_and_bind( "tab: complete" )
25 try:
26 readline.read_history_file( "%s/.python-history" % os.getenv( "HOME", "/tmp" ) )
27 except IOError:
28 pass
29
30def __enableDefaultEncoding():
31 import sys
32 try:
33 sys.setdefaultencoding( "utf8" )
34 except LookupError:
35 pass
36
37import sys
38try:
39 import rlcompleter, readline
40except ImportError:
41 pass
42else:
43 __enableDefaultEncoding()
44 __registerExitHandler()
45 __enableReadlineSupport()
diff --git a/meta/recipes-devtools/python/python-native_2.6.5.bb b/meta/recipes-devtools/python/python-native_2.6.5.bb
new file mode 100644
index 0000000000..cb95e4b964
--- /dev/null
+++ b/meta/recipes-devtools/python/python-native_2.6.5.bb
@@ -0,0 +1,30 @@
1require python.inc
2DEPENDS = "openssl-native bzip2-full-native zlib-native readline-native sqlite3-native"
3PR = "${INC_PR}.3"
4
5SRC_URI = "http://www.python.org/ftp/python/${PV}/Python-${PV}.tar.bz2 \
6 file://00-fix-bindir-libdir-for-cross.patch \
7 file://04-default-is-optimized.patch \
8 file://05-enable-ctypes-cross-build.patch \
9 file://10-distutils-fix-swig-parameter.patch \
10 file://11-distutils-never-modify-shebang-line.patch \
11 file://12-distutils-prefix-is-inside-staging-area.patch \
12 file://debug.patch \
13 file://nohostlibs.patch"
14S = "${WORKDIR}/Python-${PV}"
15
16inherit native
17
18EXTRA_OEMAKE = '\
19 BUILD_SYS="" \
20 HOST_SYS="" \
21 LIBC="" \
22 STAGING_LIBDIR=${STAGING_LIBDIR_NATIVE} \
23 STAGING_INCDIR=${STAGING_INCDIR_NATIVE} \
24'
25
26do_install() {
27 oe_runmake 'DESTDIR=${D}' install
28 install -d ${D}${bindir}/
29 install -m 0755 Parser/pgen ${D}${bindir}/
30}
diff --git a/meta/recipes-devtools/python/python-pycairo_1.8.10.bb b/meta/recipes-devtools/python/python-pycairo_1.8.10.bb
new file mode 100644
index 0000000000..1ff603875a
--- /dev/null
+++ b/meta/recipes-devtools/python/python-pycairo_1.8.10.bb
@@ -0,0 +1,22 @@
1DESCRIPTION = "Python Bindings for the Cairo canvas library"
2HOMEPAGE = "http://cairographics.org/pycairo"
3BUGTRACKER = "http://bugs.freedesktop.org"
4SECTION = "python-devel"
5LICENSE = "LGPLv2.1 & MPLv1.1"
6LIC_FILES_CHKSUM = "file://COPYING;md5=f2e071ab72978431b294a0d696327421"
7# cairo >= 1.8.8
8DEPENDS = "cairo"
9PR = "ml0"
10
11SRC_URI = "http://cairographics.org/releases/py2cairo-${PV}.tar.gz"
12S = "${WORKDIR}/pycairo-${PV}"
13
14inherit distutils pkgconfig
15
16do_install_append () {
17 install -d ${D}${includedir}
18 install -d ${D}${libdir}
19 mv ${D}${datadir}/include/* ${D}${includedir}
20 mv ${D}${datadir}/lib/* ${D}${libdir}
21 sed -i -e 's#prefix=.*#prefix=${prefix}#' ${D}${libdir}/pkgconfig/pycairo.pc
22}
diff --git a/meta/recipes-devtools/python/python-pycurl/no-static-link.patch b/meta/recipes-devtools/python/python-pycurl/no-static-link.patch
new file mode 100644
index 0000000000..b7c5ab9c9c
--- /dev/null
+++ b/meta/recipes-devtools/python/python-pycurl/no-static-link.patch
@@ -0,0 +1,14 @@
1Index: pycurl-7.18.2/setup.py
2===================================================================
3--- pycurl-7.18.2.orig/setup.py
4+++ pycurl-7.18.2/setup.py
5@@ -97,8 +97,7 @@ else:
6 else:
7 extra_compile_args.append(e)
8 libs = split_quoted(
9- os.popen("'%s' --libs" % CURL_CONFIG).read()+\
10- os.popen("'%s' --static-libs" % CURL_CONFIG).read())
11+ os.popen("'%s' --libs" % CURL_CONFIG).read())
12 for e in libs:
13 if e[:2] == "-l":
14 libraries.append(e[2:])
diff --git a/meta/recipes-devtools/python/python-pycurl_7.19.0.bb b/meta/recipes-devtools/python/python-pycurl_7.19.0.bb
new file mode 100644
index 0000000000..1a04767266
--- /dev/null
+++ b/meta/recipes-devtools/python/python-pycurl_7.19.0.bb
@@ -0,0 +1,29 @@
1DESCRIPTION = "libcurl python bindings."
2HOMEPAGE = "http://pycurl.sourceforge.net/"
3SECTION = "devel/python"
4PRIORITY = "optional"
5LICENSE = "LGPLv2.1+ | MIT"
6LIC_FILES_CHKSUM = "file://README;endline=13;md5=fbfe545b1869617123a08c0983ef17b2 \
7 file://COPYING;md5=3579a9fd0221d49a237aaa33492f988c \
8 file://COPYING2;md5=ffaa1e283b7f9bf5aafd8d45db6f7518"
9
10DEPENDS = "curl python"
11RDEPENDS = "python-core curl"
12SRCNAME = "pycurl"
13PR = "r0"
14
15SRC_URI = "\
16 http://${SRCNAME}.sourceforge.net/download/${SRCNAME}-${PV}.tar.gz;name=archive \
17 file://no-static-link.patch;patch=1 \
18"
19S = "${WORKDIR}/${SRCNAME}-${PV}"
20
21inherit distutils
22
23# need to export these variables for python-config to work
24export BUILD_SYS
25export HOST_SYS
26export STAGING_INCDIR
27export STAGING_LIBDIR
28
29BBCLASSEXTEND = "native"
diff --git a/meta/recipes-devtools/python/python-pygobject-native_2.21.1.bb b/meta/recipes-devtools/python/python-pygobject-native_2.21.1.bb
new file mode 100644
index 0000000000..d3602277a4
--- /dev/null
+++ b/meta/recipes-devtools/python/python-pygobject-native_2.21.1.bb
@@ -0,0 +1,15 @@
1require python-pygobject_${PV}.bb
2
3DEPENDS = "python-native glib-2.0-native"
4PR = "r0"
5
6PARALLEL_MAKE = ""
7
8inherit native
9
10SRC_URI = "ftp://ftp.gnome.org/pub/GNOME/sources/pygobject/${MAJ_VER}/pygobject-${PV}.tar.bz2"
11
12do_install_append() {
13 install -d ${D}${bindir}
14 install -m 0755 gobject/generate-constants ${D}${bindir}/gobject-generate-constants
15}
diff --git a/meta/recipes-devtools/python/python-pygobject/generate-constants.patch b/meta/recipes-devtools/python/python-pygobject/generate-constants.patch
new file mode 100644
index 0000000000..57a9380620
--- /dev/null
+++ b/meta/recipes-devtools/python/python-pygobject/generate-constants.patch
@@ -0,0 +1,18 @@
1Index: pygobject-2.14.2/gobject/Makefile.am
2===================================================================
3--- pygobject-2.14.2.orig/gobject/Makefile.am
4+++ pygobject-2.14.2/gobject/Makefile.am
5@@ -21,11 +21,11 @@ if PLATFORM_WIN32
6 common_ldflags += -no-undefined
7 endif
8
9-constants.py: generate-constants$(EXEEXT) constants.py.in
10+constants.py: constants.py.in
11 rm -f constants.py
12 cp $(srcdir)/constants.py.in constants.py
13 chmod 644 constants.py
14- $(top_builddir)/gobject/generate-constants$(EXEEXT) >> constants.py
15+ gobject-generate-constants$(EXEEXT) >> constants.py
16 chmod 444 constants.py
17
18 generate_constants_CFLAGS = $(GLIB_CFLAGS)
diff --git a/meta/recipes-devtools/python/python-pygobject_2.21.1.bb b/meta/recipes-devtools/python/python-pygobject_2.21.1.bb
new file mode 100644
index 0000000000..b815e4c0f2
--- /dev/null
+++ b/meta/recipes-devtools/python/python-pygobject_2.21.1.bb
@@ -0,0 +1,30 @@
1DESCRIPTION = "Python GObject bindings"
2SECTION = "devel/python"
3LICENSE = "LGPL"
4DEPENDS = "python-pygobject-native-${PV} glib-2.0"
5PR = "ml0"
6
7MAJ_VER = "${@bb.data.getVar('PV',d,1).split('.')[0]}.${@bb.data.getVar('PV',d,1).split('.')[1]}"
8
9SRC_URI = "ftp://ftp.gnome.org/pub/GNOME/sources/pygobject/${MAJ_VER}/pygobject-${PV}.tar.bz2 \
10 file://generate-constants.patch"
11S = "${WORKDIR}/pygobject-${PV}"
12
13FILESPATH = "${FILE_DIRNAME}/python-pygobject:${FILE_DIRNAME}/files"
14
15inherit autotools distutils-base pkgconfig
16
17# necessary to let the call for python-config succeed
18export BUILD_SYS
19export HOST_SYS
20export STAGING_INCDIR
21export STAGING_LIBDIR
22
23PACKAGES += "${PN}-lib"
24
25RDEPENDS_${PN} += "python-textutils"
26
27FILES_${PN} = "${libdir}/python*"
28FILES_${PN}-lib = "${libdir}/lib*.so.*"
29FILES_${PN}-dev += "${bindir} ${datadir}"
30FILES_${PN}-dbg += "${libdir}/.debug"
diff --git a/meta/recipes-devtools/python/python-pygtk/acinclude.m4 b/meta/recipes-devtools/python/python-pygtk/acinclude.m4
new file mode 100644
index 0000000000..53518fb2eb
--- /dev/null
+++ b/meta/recipes-devtools/python/python-pygtk/acinclude.m4
@@ -0,0 +1,90 @@
1## this one is commonly used with AM_PATH_PYTHONDIR ...
2dnl AM_CHECK_PYMOD(MODNAME [,SYMBOL [,ACTION-IF-FOUND [,ACTION-IF-NOT-FOUND]]])
3dnl Check if a module containing a given symbol is visible to python.
4AC_DEFUN(AM_CHECK_PYMOD,
5[AC_REQUIRE([AM_PATH_PYTHON])
6py_mod_var=`echo $1['_']$2 | sed 'y%./+-%__p_%'`
7AC_MSG_CHECKING(for ifelse([$2],[],,[$2 in ])python module $1)
8AC_CACHE_VAL(py_cv_mod_$py_mod_var, [
9ifelse([$2],[], [prog="
10import sys
11try:
12 import $1
13except ImportError:
14 sys.exit(1)
15except:
16 sys.exit(0)
17sys.exit(0)"], [prog="
18import $1
19$1.$2"])
20if $PYTHON -c "$prog" 1>&AC_FD_CC 2>&AC_FD_CC
21 then
22 eval "py_cv_mod_$py_mod_var=yes"
23 else
24 eval "py_cv_mod_$py_mod_var=no"
25 fi
26])
27py_val=`eval "echo \`echo '$py_cv_mod_'$py_mod_var\`"`
28if test "x$py_val" != xno; then
29 AC_MSG_RESULT(yes)
30 ifelse([$3], [],, [$3
31])dnl
32else
33 AC_MSG_RESULT(no)
34 ifelse([$4], [],, [$4
35])dnl
36fi
37])
38
39dnl a macro to check for ability to create python extensions
40dnl AM_CHECK_PYTHON_HEADERS([ACTION-IF-POSSIBLE], [ACTION-IF-NOT-POSSIBLE])
41dnl function also defines PYTHON_INCLUDES
42AC_DEFUN([AM_CHECK_PYTHON_HEADERS],
43[AC_REQUIRE([AM_PATH_PYTHON])
44AC_MSG_CHECKING(for headers required to compile python extensions)
45dnl deduce PYTHON_INCLUDES
46AC_ARG_WITH(python-includes,
47 [ --with-python-includes=DIR path to Python includes], py_exec_prefix=$withval)
48if test x$py_exec_prefix != x; then
49PYTHON_INCLUDES="-I${py_exec_prefix}/include/python${PYTHON_VERSION}"
50else
51py_prefix=`$PYTHON -c "import sys; print sys.prefix"`
52py_exec_prefix=`$PYTHON -c "import sys; print sys.exec_prefix"`
53PYTHON_INCLUDES="-I${py_prefix}/include/python${PYTHON_VERSION}"
54if test "$py_prefix" != "$py_exec_prefix"; then
55 PYTHON_INCLUDES="$PYTHON_INCLUDES -I${py_exec_prefix}/include/python${PYTHON_VERSION}"
56fi
57fi
58AC_SUBST(PYTHON_INCLUDES)
59dnl check if the headers exist:
60save_CPPFLAGS="$CPPFLAGS"
61CPPFLAGS="$CPPFLAGS $PYTHON_INCLUDES"
62AC_TRY_CPP([#include <Python.h>],dnl
63[AC_MSG_RESULT(found)
64$1],dnl
65[AC_MSG_RESULT(not found)
66$2])
67CPPFLAGS="$save_CPPFLAGS"
68])
69
70dnl
71dnl JH_ADD_CFLAG(FLAG)
72dnl checks whether the C compiler supports the given flag, and if so, adds
73dnl it to $CFLAGS. If the flag is already present in the list, then the
74dnl check is not performed.
75AC_DEFUN([JH_ADD_CFLAG],
76[
77case " $CFLAGS " in
78*@<:@\ \ @:>@$1@<:@\ \ @:>@*)
79 ;;
80*)
81 save_CFLAGS="$CFLAGS"
82 CFLAGS="$CFLAGS $1"
83 AC_MSG_CHECKING([whether [$]CC understands $1])
84 AC_TRY_COMPILE([], [], [jh_has_option=yes], [jh_has_option=no])
85 AC_MSG_RESULT($jh_has_option)
86 if test $jh_has_option = no; then
87 CFLAGS="$save_CFLAGS"
88 fi
89 ;;
90esac])
diff --git a/meta/recipes-devtools/python/python-pygtk/fix-gtkunixprint.patch b/meta/recipes-devtools/python/python-pygtk/fix-gtkunixprint.patch
new file mode 100644
index 0000000000..dca19ce5ed
--- /dev/null
+++ b/meta/recipes-devtools/python/python-pygtk/fix-gtkunixprint.patch
@@ -0,0 +1,16 @@
1Index: pygtk-2.10.0/gtk/gtkunixprint.override
2===================================================================
3--- pygtk-2.10.0.orig/gtk/gtkunixprint.override
4+++ pygtk-2.10.0/gtk/gtkunixprint.override
5@@ -105,11 +105,7 @@ _wrap_gtk_print_job_get_surface(PyGObjec
6 if (pyg_error_check(&error))
7 return NULL;
8
9-#if PYCAIRO_VERSION_HEX >= 0x1010600
10 return PycairoSurface_FromSurface(surface, NULL);
11-#else
12- return PycairoSurface_FromSurface(surface, NULL, NULL);
13-#endif
14 }
15 %%
16 override gtk_print_job_send kwargs
diff --git a/meta/recipes-devtools/python/python-pygtk/nodocs.patch b/meta/recipes-devtools/python/python-pygtk/nodocs.patch
new file mode 100644
index 0000000000..c3581043c3
--- /dev/null
+++ b/meta/recipes-devtools/python/python-pygtk/nodocs.patch
@@ -0,0 +1,13 @@
1Index: pygtk-2.17.0/Makefile.am
2===================================================================
3--- pygtk-2.17.0.orig/Makefile.am
4+++ pygtk-2.17.0/Makefile.am
5@@ -4,7 +4,7 @@ if BUILD_GTK
6 GTK_SUBDIR = gtk
7 endif
8
9-SUBDIRS = . $(GTK_SUBDIR) examples tests docs
10+SUBDIRS = . $(GTK_SUBDIR) examples tests
11
12 PLATFORM_VERSION = 2.0
13
diff --git a/meta/recipes-devtools/python/python-pygtk/prevent_to_get_display_during_import.patch b/meta/recipes-devtools/python/python-pygtk/prevent_to_get_display_during_import.patch
new file mode 100644
index 0000000000..9340f8244d
--- /dev/null
+++ b/meta/recipes-devtools/python/python-pygtk/prevent_to_get_display_during_import.patch
@@ -0,0 +1,14 @@
1Index: pygtk-2.10.4/gtk/__init__.py
2===================================================================
3--- pygtk-2.10.4.orig/gtk/__init__.py 2007-11-27 19:27:05.000000000 -0300
4+++ pygtk-2.10.4/gtk/__init__.py 2007-11-27 19:28:22.000000000 -0300
5@@ -78,7 +78,8 @@
6
7 keysyms = LazyModule('keysyms', locals())
8
9-_init()
10+if not hasattr(sys.modules['__main__'], 'python_launcher_enabled'):
11+ _init()
12
13 # CAPI
14 _PyGtk_API = _gtk._PyGtk_API
diff --git a/meta/recipes-devtools/python/python-pygtk/python-pygtk2/acinclude.m4 b/meta/recipes-devtools/python/python-pygtk/python-pygtk2/acinclude.m4
new file mode 100644
index 0000000000..53518fb2eb
--- /dev/null
+++ b/meta/recipes-devtools/python/python-pygtk/python-pygtk2/acinclude.m4
@@ -0,0 +1,90 @@
1## this one is commonly used with AM_PATH_PYTHONDIR ...
2dnl AM_CHECK_PYMOD(MODNAME [,SYMBOL [,ACTION-IF-FOUND [,ACTION-IF-NOT-FOUND]]])
3dnl Check if a module containing a given symbol is visible to python.
4AC_DEFUN(AM_CHECK_PYMOD,
5[AC_REQUIRE([AM_PATH_PYTHON])
6py_mod_var=`echo $1['_']$2 | sed 'y%./+-%__p_%'`
7AC_MSG_CHECKING(for ifelse([$2],[],,[$2 in ])python module $1)
8AC_CACHE_VAL(py_cv_mod_$py_mod_var, [
9ifelse([$2],[], [prog="
10import sys
11try:
12 import $1
13except ImportError:
14 sys.exit(1)
15except:
16 sys.exit(0)
17sys.exit(0)"], [prog="
18import $1
19$1.$2"])
20if $PYTHON -c "$prog" 1>&AC_FD_CC 2>&AC_FD_CC
21 then
22 eval "py_cv_mod_$py_mod_var=yes"
23 else
24 eval "py_cv_mod_$py_mod_var=no"
25 fi
26])
27py_val=`eval "echo \`echo '$py_cv_mod_'$py_mod_var\`"`
28if test "x$py_val" != xno; then
29 AC_MSG_RESULT(yes)
30 ifelse([$3], [],, [$3
31])dnl
32else
33 AC_MSG_RESULT(no)
34 ifelse([$4], [],, [$4
35])dnl
36fi
37])
38
39dnl a macro to check for ability to create python extensions
40dnl AM_CHECK_PYTHON_HEADERS([ACTION-IF-POSSIBLE], [ACTION-IF-NOT-POSSIBLE])
41dnl function also defines PYTHON_INCLUDES
42AC_DEFUN([AM_CHECK_PYTHON_HEADERS],
43[AC_REQUIRE([AM_PATH_PYTHON])
44AC_MSG_CHECKING(for headers required to compile python extensions)
45dnl deduce PYTHON_INCLUDES
46AC_ARG_WITH(python-includes,
47 [ --with-python-includes=DIR path to Python includes], py_exec_prefix=$withval)
48if test x$py_exec_prefix != x; then
49PYTHON_INCLUDES="-I${py_exec_prefix}/include/python${PYTHON_VERSION}"
50else
51py_prefix=`$PYTHON -c "import sys; print sys.prefix"`
52py_exec_prefix=`$PYTHON -c "import sys; print sys.exec_prefix"`
53PYTHON_INCLUDES="-I${py_prefix}/include/python${PYTHON_VERSION}"
54if test "$py_prefix" != "$py_exec_prefix"; then
55 PYTHON_INCLUDES="$PYTHON_INCLUDES -I${py_exec_prefix}/include/python${PYTHON_VERSION}"
56fi
57fi
58AC_SUBST(PYTHON_INCLUDES)
59dnl check if the headers exist:
60save_CPPFLAGS="$CPPFLAGS"
61CPPFLAGS="$CPPFLAGS $PYTHON_INCLUDES"
62AC_TRY_CPP([#include <Python.h>],dnl
63[AC_MSG_RESULT(found)
64$1],dnl
65[AC_MSG_RESULT(not found)
66$2])
67CPPFLAGS="$save_CPPFLAGS"
68])
69
70dnl
71dnl JH_ADD_CFLAG(FLAG)
72dnl checks whether the C compiler supports the given flag, and if so, adds
73dnl it to $CFLAGS. If the flag is already present in the list, then the
74dnl check is not performed.
75AC_DEFUN([JH_ADD_CFLAG],
76[
77case " $CFLAGS " in
78*@<:@\ \ @:>@$1@<:@\ \ @:>@*)
79 ;;
80*)
81 save_CFLAGS="$CFLAGS"
82 CFLAGS="$CFLAGS $1"
83 AC_MSG_CHECKING([whether [$]CC understands $1])
84 AC_TRY_COMPILE([], [], [jh_has_option=yes], [jh_has_option=no])
85 AC_MSG_RESULT($jh_has_option)
86 if test $jh_has_option = no; then
87 CFLAGS="$save_CFLAGS"
88 fi
89 ;;
90esac])
diff --git a/meta/recipes-devtools/python/python-pygtk_2.17.0.bb b/meta/recipes-devtools/python/python-pygtk_2.17.0.bb
new file mode 100644
index 0000000000..ef63b51038
--- /dev/null
+++ b/meta/recipes-devtools/python/python-pygtk_2.17.0.bb
@@ -0,0 +1,42 @@
1DESCRIPTION = "Python GTK+ 2.17.x Bindings"
2SECTION = "devel/python"
3# needs gtk+ 2.17.x
4DEPENDS = "gtk+ libglade python-pycairo python-pygobject"
5RDEPENDS = "python-shell python-pycairo python-pygobject"
6PROVIDES = "python-pygtk2"
7SRCNAME = "pygtk"
8LICENSE = "LGPL"
9PR = "ml8.2"
10
11SRC_URI = "ftp://ftp.gnome.org/pub/gnome/sources/pygtk/2.17/${SRCNAME}-${PV}.tar.bz2 \
12 file://fix-gtkunixprint.patch \
13 file://prevent_to_get_display_during_import.patch \
14 file://nodocs.patch \
15 file://acinclude.m4"
16S = "${WORKDIR}/${SRCNAME}-${PV}"
17
18EXTRA_OECONF = "--disable-docs --with-python-includes=${STAGING_INCDIR}/../"
19
20inherit autotools pkgconfig distutils-base
21
22do_configure_prepend() {
23 install -m 0644 ${WORKDIR}/acinclude.m4 ${S}/
24}
25
26# dirty fix #1: remove dependency on python-pygobject-dev
27do_install_append() {
28 find ${D} -name "*.la"|xargs rm -f
29 rm -f ${D}/${bindir}/pygtk-codegen-2.0
30 rm -rf ${D}/${libdir}/pkgconfig
31}
32
33# dirty fix #2: fix build system paths leaking in
34require fix-path.inc
35
36PACKAGES =+ "${PN}-demo"
37FILES_${PN}-demo = " ${bindir}/pygtk-demo ${libdir}/pygtk "
38RDEPENDS_${PN}-demo = "python-pygtk python-stringold python-lang"
39
40# todo: revamp packaging, package demo seperatly
41FILES_${PN}-dev += " ${libdir}/pygtk/2.0 ${bindir}/pygtk-* ${datadir}/pygtk/2.0"
42
diff --git a/meta/recipes-devtools/python/python-pyrex-native_0.9.9.bb b/meta/recipes-devtools/python/python-pyrex-native_0.9.9.bb
new file mode 100644
index 0000000000..90b6b16836
--- /dev/null
+++ b/meta/recipes-devtools/python/python-pyrex-native_0.9.9.bb
@@ -0,0 +1,5 @@
1require python-pyrex_${PV}.bb
2inherit native
3DEPENDS = "python-native"
4RDEPENDS = ""
5PR = "r0"
diff --git a/meta/recipes-devtools/python/python-pyrex/pyrex-fix-optimized-mode.patch b/meta/recipes-devtools/python/python-pyrex/pyrex-fix-optimized-mode.patch
new file mode 100644
index 0000000000..a1f5bb29ba
--- /dev/null
+++ b/meta/recipes-devtools/python/python-pyrex/pyrex-fix-optimized-mode.patch
@@ -0,0 +1,13 @@
1Index: Pyrex-0.9.8.4/Pyrex/Distutils/extension.py
2===================================================================
3--- Pyrex-0.9.8.4.orig/Pyrex/Distutils/extension.py
4+++ Pyrex-0.9.8.4/Pyrex/Distutils/extension.py
5@@ -15,7 +15,7 @@ except ImportError:
6 warnings = None
7
8 class Extension(_Extension.Extension):
9- _Extension.Extension.__doc__ + \
10+ _Extension.Extension.__doc__ or "" + \
11 """pyrex_include_dirs : [string]
12 list of directories to search for Pyrex header files (.pxd) (in
13 Unix form for portability)
diff --git a/meta/recipes-devtools/python/python-pyrex_0.9.9.bb b/meta/recipes-devtools/python/python-pyrex_0.9.9.bb
new file mode 100644
index 0000000000..6c57af50d5
--- /dev/null
+++ b/meta/recipes-devtools/python/python-pyrex_0.9.9.bb
@@ -0,0 +1,16 @@
1DESCRIPTION = "Pyrex is a language specially designed for writing Python extension modules. \
2It's designed to bridge the gap between the nice, high-level, easy-to-use world of Python \
3and the messy, low-level world of C."
4SECTION = "devel/python"
5PRIORITY = "optional"
6LICENSE = "GPL"
7SRCNAME = "Pyrex"
8PR = "ml0"
9
10SRC_URI = "\
11 http://www.cosc.canterbury.ac.nz/greg.ewing/python/${SRCNAME}/${SRCNAME}-${PV}.tar.gz \
12 file://pyrex-fix-optimized-mode.patch \
13"
14S = "${WORKDIR}/${SRCNAME}-${PV}"
15
16inherit distutils
diff --git a/meta/recipes-devtools/python/python-scons-native_1.3.0.bb b/meta/recipes-devtools/python/python-scons-native_1.3.0.bb
new file mode 100644
index 0000000000..a4bcd4258a
--- /dev/null
+++ b/meta/recipes-devtools/python/python-scons-native_1.3.0.bb
@@ -0,0 +1,6 @@
1require python-scons_${PV}.bb
2inherit native
3DEPENDS = "python-native"
4RDEPENDS = ""
5PR = "r0"
6
diff --git a/meta/recipes-devtools/python/python-scons_1.3.0.bb b/meta/recipes-devtools/python/python-scons_1.3.0.bb
new file mode 100644
index 0000000000..f5d11eb925
--- /dev/null
+++ b/meta/recipes-devtools/python/python-scons_1.3.0.bb
@@ -0,0 +1,12 @@
1DESCRIPTION = "A Software Construction Tool"
2SECTION = "devel/python"
3PRIORITY = "optional"
4LICENSE = "GPL"
5SRCNAME = "scons"
6
7PR = "r0"
8
9SRC_URI = "${SOURCEFORGE_MIRROR}/scons/scons-${PV}.tar.gz"
10S = "${WORKDIR}/${SRCNAME}-${PV}"
11
12inherit distutils
diff --git a/meta/recipes-devtools/python/python-urlgrabber-native_3.9.1.bb b/meta/recipes-devtools/python/python-urlgrabber-native_3.9.1.bb
new file mode 100644
index 0000000000..ff8f02ecd7
--- /dev/null
+++ b/meta/recipes-devtools/python/python-urlgrabber-native_3.9.1.bb
@@ -0,0 +1,4 @@
1require python-urlgrabber_${PV}.bb
2inherit native
3DEPENDS = "python-native python-pycurl-native"
4RDEPENDS = ""
diff --git a/meta/recipes-devtools/python/python-urlgrabber/urlgrabber-3.0.0-cleanup.patch b/meta/recipes-devtools/python/python-urlgrabber/urlgrabber-3.0.0-cleanup.patch
new file mode 100644
index 0000000000..7a1ee059d1
--- /dev/null
+++ b/meta/recipes-devtools/python/python-urlgrabber/urlgrabber-3.0.0-cleanup.patch
@@ -0,0 +1,28 @@
1diff -up urlgrabber-3.0.0/urlgrabber/grabber.py.cleanup urlgrabber-3.0.0/urlgrabber/grabber.py
2--- urlgrabber-3.0.0/urlgrabber/grabber.py.cleanup 2007-11-29 10:25:13.000000000 +0000
3+++ urlgrabber-3.0.0/urlgrabber/grabber.py 2007-11-29 10:26:15.000000000 +0000
4@@ -1204,16 +1204,18 @@ class URLGrabberFileObject:
5 bs = 1024*8
6 size = 0
7
8- if amount is not None: bs = min(bs, amount - size)
9- block = self.read(bs)
10- size = size + len(block)
11- while block:
12- new_fo.write(block)
13+ try:
14 if amount is not None: bs = min(bs, amount - size)
15 block = self.read(bs)
16 size = size + len(block)
17+ while block:
18+ new_fo.write(block)
19+ if amount is not None: bs = min(bs, amount - size)
20+ block = self.read(bs)
21+ size = size + len(block)
22+ finally:
23+ new_fo.close()
24
25- new_fo.close()
26 try:
27 modified_tuple = self.hdr.getdate_tz('last-modified')
28 modified_stamp = rfc822.mktime_tz(modified_tuple)
diff --git a/meta/recipes-devtools/python/python-urlgrabber/urlgrabber-HEAD.patch b/meta/recipes-devtools/python/python-urlgrabber/urlgrabber-HEAD.patch
new file mode 100644
index 0000000000..90180d29a0
--- /dev/null
+++ b/meta/recipes-devtools/python/python-urlgrabber/urlgrabber-HEAD.patch
@@ -0,0 +1,142 @@
1diff --git a/urlgrabber/grabber.py b/urlgrabber/grabber.py
2index e090e90..a26880c 100644
3--- a/urlgrabber/grabber.py
4+++ b/urlgrabber/grabber.py
5@@ -439,6 +439,12 @@ try:
6 except:
7 __version__ = '???'
8
9+try:
10+ # this part isn't going to do much - need to talk to gettext
11+ from i18n import _
12+except ImportError, msg:
13+ def _(st): return st
14+
15 ########################################################################
16 # functions for debugging output. These functions are here because they
17 # are also part of the module initialization.
18@@ -1052,7 +1058,8 @@ class PyCurlFileObject():
19 self._reget_length = 0
20 self._prog_running = False
21 self._error = (None, None)
22- self.size = None
23+ self.size = 0
24+ self._hdr_ended = False
25 self._do_open()
26
27
28@@ -1085,9 +1092,14 @@ class PyCurlFileObject():
29 return -1
30
31 def _hdr_retrieve(self, buf):
32+ if self._hdr_ended:
33+ self._hdr_dump = ''
34+ self.size = 0
35+ self._hdr_ended = False
36+
37 if self._over_max_size(cur=len(self._hdr_dump),
38 max_size=self.opts.max_header_size):
39- return -1
40+ return -1
41 try:
42 self._hdr_dump += buf
43 # we have to get the size before we do the progress obj start
44@@ -1104,7 +1116,17 @@ class PyCurlFileObject():
45 s = parse150(buf)
46 if s:
47 self.size = int(s)
48-
49+
50+ if buf.lower().find('location') != -1:
51+ location = ':'.join(buf.split(':')[1:])
52+ location = location.strip()
53+ self.scheme = urlparse.urlsplit(location)[0]
54+ self.url = location
55+
56+ if len(self._hdr_dump) != 0 and buf == '\r\n':
57+ self._hdr_ended = True
58+ if DEBUG: DEBUG.info('header ended:')
59+
60 return len(buf)
61 except KeyboardInterrupt:
62 return pycurl.READFUNC_ABORT
63@@ -1136,6 +1158,7 @@ class PyCurlFileObject():
64 self.curl_obj.setopt(pycurl.PROGRESSFUNCTION, self._progress_update)
65 self.curl_obj.setopt(pycurl.FAILONERROR, True)
66 self.curl_obj.setopt(pycurl.OPT_FILETIME, True)
67+ self.curl_obj.setopt(pycurl.FOLLOWLOCATION, True)
68
69 if DEBUG:
70 self.curl_obj.setopt(pycurl.VERBOSE, True)
71@@ -1291,7 +1314,12 @@ class PyCurlFileObject():
72 raise err
73
74 elif str(e.args[1]) == '' and self.http_code != 0: # fake it until you make it
75- msg = 'HTTP Error %s : %s ' % (self.http_code, self.url)
76+ if self.scheme in ['http', 'https']:
77+ msg = 'HTTP Error %s : %s ' % (self.http_code, self.url)
78+ elif self.scheme in ['ftp']:
79+ msg = 'FTP Error %s : %s ' % (self.http_code, self.url)
80+ else:
81+ msg = "Unknown Error: URL=%s , scheme=%s" % (self.url, self.scheme)
82 else:
83 msg = 'PYCURL ERROR %s - "%s"' % (errcode, str(e.args[1]))
84 code = errcode
85@@ -1299,6 +1327,12 @@ class PyCurlFileObject():
86 err.code = code
87 err.exception = e
88 raise err
89+ else:
90+ if self._error[1]:
91+ msg = self._error[1]
92+ err = URLGRabError(14, msg)
93+ err.url = self.url
94+ raise err
95
96 def _do_open(self):
97 self.curl_obj = _curl_cache
98@@ -1532,11 +1566,14 @@ class PyCurlFileObject():
99 def _over_max_size(self, cur, max_size=None):
100
101 if not max_size:
102- max_size = self.size
103- if self.opts.size: # if we set an opts size use that, no matter what
104- max_size = self.opts.size
105+ if not self.opts.size:
106+ max_size = self.size
107+ else:
108+ max_size = self.opts.size
109+
110 if not max_size: return False # if we have None for all of the Max then this is dumb
111- if cur > max_size + max_size*.10:
112+
113+ if cur > int(float(max_size) * 1.10):
114
115 msg = _("Downloaded more than max size for %s: %s > %s") \
116 % (self.url, cur, max_size)
117@@ -1582,7 +1619,11 @@ class PyCurlFileObject():
118 self.opts.progress_obj.end(self._amount_read)
119 self.fo.close()
120
121-
122+ def geturl(self):
123+ """ Provide the geturl() method, used to be got from
124+ urllib.addinfourl, via. urllib.URLopener.* """
125+ return self.url
126+
127 _curl_cache = pycurl.Curl() # make one and reuse it over and over and over
128
129
130diff --git a/urlgrabber/progress.py b/urlgrabber/progress.py
131index dd07c6a..45eb248 100644
132--- a/urlgrabber/progress.py
133+++ b/urlgrabber/progress.py
134@@ -658,6 +658,8 @@ def format_time(seconds, use_hours=0):
135 if seconds is None or seconds < 0:
136 if use_hours: return '--:--:--'
137 else: return '--:--'
138+ elif seconds == float('inf'):
139+ return 'Infinite'
140 else:
141 seconds = int(seconds)
142 minutes = seconds / 60
diff --git a/meta/recipes-devtools/python/python-urlgrabber/urlgrabber-reset.patch b/meta/recipes-devtools/python/python-urlgrabber/urlgrabber-reset.patch
new file mode 100644
index 0000000000..b63e7c33ac
--- /dev/null
+++ b/meta/recipes-devtools/python/python-urlgrabber/urlgrabber-reset.patch
@@ -0,0 +1,15 @@
1--- a/urlgrabber/grabber.py 2010-02-19 14:50:45.000000000 -0500
2+++ b/urlgrabber/grabber.py 2010-02-19 14:51:28.000000000 -0500
3@@ -1626,6 +1626,12 @@
4
5 _curl_cache = pycurl.Curl() # make one and reuse it over and over and over
6
7+def reset_curl_obj():
8+ """To make sure curl has reread the network/dns info we force a reload"""
9+ global _curl_cache
10+ _curl_cache.close()
11+ _curl_cache = pycurl.Curl()
12+
13
14 #####################################################################
15 # DEPRECATED FUNCTIONS
diff --git a/meta/recipes-devtools/python/python-urlgrabber_3.9.1.bb b/meta/recipes-devtools/python/python-urlgrabber_3.9.1.bb
new file mode 100644
index 0000000000..9f3a4cc6a7
--- /dev/null
+++ b/meta/recipes-devtools/python/python-urlgrabber_3.9.1.bb
@@ -0,0 +1,16 @@
1DESCRIPTION = "urlgrabber is a pure python package that drastically simplifies the fetching of files."
2
3HOMEPAGE = "http://urlgrabber.baseurl.org/"
4SECTION = "devel/python"
5PRIORITY = "optional"
6LICENSE = "GPL"
7PR = "r1"
8
9SRC_URI = "http://urlgrabber.baseurl.org/download/urlgrabber-${PV}.tar.gz \
10 file://urlgrabber-HEAD.patch;patch=1 \
11 file://urlgrabber-reset.patch;patch=1"
12S = "${WORKDIR}/urlgrabber-${PV}"
13
14DEPENDS = "python-pycurl"
15
16inherit distutils \ No newline at end of file
diff --git a/meta/recipes-devtools/python/python.inc b/meta/recipes-devtools/python/python.inc
new file mode 100644
index 0000000000..682bd5a2da
--- /dev/null
+++ b/meta/recipes-devtools/python/python.inc
@@ -0,0 +1,25 @@
1DESCRIPTION = "The Python Programming Language"
2HOMEPAGE = "http://www.python.org"
3LICENSE = "PSF"
4SECTION = "devel/python"
5PRIORITY = "optional"
6# bump this on every change in contrib/python/generate-manifest-2.6.py
7INC_PR = "ml8"
8
9DEFAULT_PREFERENCE = "-26"
10
11PYTHON_MAJMIN = "2.6"
12
13inherit autotools
14
15EXTRA_OECONF = "\
16 --with-threads \
17 --with-pymalloc \
18 --with-cyclic-gc \
19 --without-cxx \
20 --with-signal-module \
21 --with-wctype-functions \
22 --enable-shared \
23"
24
25PARALLEL_MAKE = ""
diff --git a/meta/recipes-devtools/python/python/00-fix-bindir-libdir-for-cross.patch b/meta/recipes-devtools/python/python/00-fix-bindir-libdir-for-cross.patch
new file mode 100644
index 0000000000..2559e3a0e4
--- /dev/null
+++ b/meta/recipes-devtools/python/python/00-fix-bindir-libdir-for-cross.patch
@@ -0,0 +1,20 @@
1# $(exec_prefix) points to the wrong directory, when installing
2# a cross-build. @bindir@ and @libdir@ works better and doesn't
3# affect the native build.
4# Signed-Off: Michael 'Mickey' Lauer <mickey@vanille-media.de>
5
6Index: Python-2.6.1/Makefile.pre.in
7===================================================================
8--- Python-2.6.1.orig/Makefile.pre.in
9+++ Python-2.6.1/Makefile.pre.in
10@@ -86,8 +86,8 @@ exec_prefix= @exec_prefix@
11 datarootdir= @datarootdir@
12
13 # Expanded directories
14-BINDIR= $(exec_prefix)/bin
15-LIBDIR= $(exec_prefix)/lib
16+BINDIR= @bindir@
17+LIBDIR= @libdir@
18 MANDIR= @mandir@
19 INCLUDEDIR= @includedir@
20 CONFINCLUDEDIR= $(exec_prefix)/include
diff --git a/meta/recipes-devtools/python/python/01-use-proper-tools-for-cross-build.patch b/meta/recipes-devtools/python/python/01-use-proper-tools-for-cross-build.patch
new file mode 100644
index 0000000000..e89faa4fb0
--- /dev/null
+++ b/meta/recipes-devtools/python/python/01-use-proper-tools-for-cross-build.patch
@@ -0,0 +1,116 @@
1# We need to ensure our host tools get run during build, not the freshly
2# built cross-tools (this will not work), so we introduce HOSTPYTHON and HOSTPGEN.
3# Signed-Off: Michael 'Mickey' Lauer <mickey@vanille-media.de>
4
5Index: Python-2.6.1/Makefile.pre.in
6===================================================================
7--- Python-2.6.1.orig/Makefile.pre.in
8+++ Python-2.6.1/Makefile.pre.in
9@@ -175,6 +175,7 @@ UNICODE_OBJS= @UNICODE_OBJS@
10
11 PYTHON= python$(EXE)
12 BUILDPYTHON= python$(BUILDEXE)
13+HOSTPYTHON= $(BUILDPYTHON)
14
15 # The task to run while instrument when building the profile-opt target
16 PROFILE_TASK= $(srcdir)/Tools/pybench/pybench.py -n 2 --with-gc --with-syscheck
17@@ -205,7 +206,7 @@ GRAMMAR_INPUT= $(srcdir)/Grammar/Grammar
18 ##########################################################################
19 # Parser
20 PGEN= Parser/pgen$(EXE)
21-
22+HOSTPGEN= $(PGEN)$(EXE)
23 POBJS= \
24 Parser/acceler.o \
25 Parser/grammar1.o \
26@@ -394,8 +395,8 @@ platform: $(BUILDPYTHON)
27 # Build the shared modules
28 sharedmods: $(BUILDPYTHON)
29 @case $$MAKEFLAGS in \
30- *s*) $(RUNSHARED) CC='$(CC)' LDSHARED='$(BLDSHARED)' OPT='$(OPT)' ./$(BUILDPYTHON) -E $(srcdir)/setup.py -q build;; \
31- *) $(RUNSHARED) CC='$(CC)' LDSHARED='$(BLDSHARED)' OPT='$(OPT)' ./$(BUILDPYTHON) -E $(srcdir)/setup.py build;; \
32+ *s*) $(RUNSHARED) CC='$(CC)' LDSHARED='$(BLDSHARED)' OPT='$(OPT)' $(HOSTPYTHON) -E $(srcdir)/setup.py -q build;; \
33+ *) $(RUNSHARED) CC='$(CC)' LDSHARED='$(BLDSHARED)' OPT='$(OPT)' $(HOSTPYTHON) -E $(srcdir)/setup.py build;; \
34 esac
35
36 # Build static library
37@@ -513,7 +514,7 @@ Modules/python.o: $(srcdir)/Modules/pyth
38
39 $(GRAMMAR_H) $(GRAMMAR_C): $(PGEN) $(GRAMMAR_INPUT)
40 -@$(INSTALL) -d Include
41- -$(PGEN) $(GRAMMAR_INPUT) $(GRAMMAR_H) $(GRAMMAR_C)
42+ -$(HOSTPGEN) $(GRAMMAR_INPUT) $(GRAMMAR_H) $(GRAMMAR_C)
43
44 $(PGEN): $(PGENOBJS)
45 $(CC) $(OPT) $(LDFLAGS) $(PGENOBJS) $(LIBS) -o $(PGEN)
46@@ -879,23 +880,23 @@ libinstall: build_all $(srcdir)/Lib/$(PL
47 done
48 $(INSTALL_DATA) $(srcdir)/LICENSE $(DESTDIR)$(LIBDEST)/LICENSE.txt
49 PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \
50- ./$(BUILDPYTHON) -Wi -tt $(DESTDIR)$(LIBDEST)/compileall.py \
51+ $(HOSTPYTHON) -Wi -tt $(DESTDIR)$(LIBDEST)/compileall.py \
52 -d $(LIBDEST) -f \
53 -x 'bad_coding|badsyntax|site-packages' $(DESTDIR)$(LIBDEST)
54 PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \
55- ./$(BUILDPYTHON) -Wi -tt -O $(DESTDIR)$(LIBDEST)/compileall.py \
56+ $(HOSTPYTHON) -Wi -tt -O $(DESTDIR)$(LIBDEST)/compileall.py \
57 -d $(LIBDEST) -f \
58 -x 'bad_coding|badsyntax|site-packages' $(DESTDIR)$(LIBDEST)
59 -PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \
60- ./$(BUILDPYTHON) -Wi -t $(DESTDIR)$(LIBDEST)/compileall.py \
61+ $(HOSTPYTHON) -Wi -t $(DESTDIR)$(LIBDEST)/compileall.py \
62 -d $(LIBDEST)/site-packages -f \
63 -x badsyntax $(DESTDIR)$(LIBDEST)/site-packages
64 -PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \
65- ./$(BUILDPYTHON) -Wi -t -O $(DESTDIR)$(LIBDEST)/compileall.py \
66+ $(HOSTPYTHON) -Wi -t -O $(DESTDIR)$(LIBDEST)/compileall.py \
67 -d $(LIBDEST)/site-packages -f \
68 -x badsyntax $(DESTDIR)$(LIBDEST)/site-packages
69 -PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \
70- ./$(BUILDPYTHON) -Wi -t -c "import lib2to3.pygram, lib2to3.patcomp;lib2to3.patcomp.PatternCompiler()"
71+ $(HOSTPYTHON) -Wi -t -c "import lib2to3.pygram, lib2to3.patcomp;lib2to3.patcomp.PatternCompiler()"
72
73 # Create the PLATDIR source directory, if one wasn't distributed..
74 $(srcdir)/Lib/$(PLATDIR):
75@@ -993,7 +994,7 @@ libainstall: all
76 # Install the dynamically loadable modules
77 # This goes into $(exec_prefix)
78 sharedinstall:
79- $(RUNSHARED) ./$(BUILDPYTHON) -E $(srcdir)/setup.py install \
80+ $(RUNSHARED) $(HOSTPYTHON) -E $(srcdir)/setup.py install \
81 --prefix=$(prefix) \
82 --install-scripts=$(BINDIR) \
83 --install-platlib=$(DESTSHARED) \
84Index: Python-2.6.1/setup.py
85===================================================================
86--- Python-2.6.1.orig/setup.py
87+++ Python-2.6.1/setup.py
88@@ -276,6 +276,7 @@ class PyBuildExt(build_ext):
89 self.failed.append(ext.name)
90 self.announce('*** WARNING: renaming "%s" since importing it'
91 ' failed: %s' % (ext.name, why), level=3)
92+ return
93 assert not self.inplace
94 basename, tail = os.path.splitext(ext_filename)
95 newname = basename + "_failed" + tail
96@@ -310,8 +311,8 @@ class PyBuildExt(build_ext):
97
98 def detect_modules(self):
99 # Ensure that /usr/local is always used
100- add_dir_to_list(self.compiler.library_dirs, '/usr/local/lib')
101- add_dir_to_list(self.compiler.include_dirs, '/usr/local/include')
102+ # add_dir_to_list(self.compiler.library_dirs, '/usr/local/lib')
103+ # add_dir_to_list(self.compiler.include_dirs, '/usr/local/include')
104
105 # Add paths specified in the environment variables LDFLAGS and
106 # CPPFLAGS for header and library files.
107@@ -410,6 +411,9 @@ class PyBuildExt(build_ext):
108
109 # XXX Omitted modules: gl, pure, dl, SGI-specific modules
110
111+ lib_dirs = [ os.getenv( "STAGING_LIBDIR" ) ]
112+ inc_dirs = [ os.getenv( "STAGING_INCDIR" ) ]
113+
114 #
115 # The following modules are all pretty straightforward, and compile
116 # on pretty much any POSIXish platform.
diff --git a/meta/recipes-devtools/python/python/02-remove-test-for-cross.patch b/meta/recipes-devtools/python/python/02-remove-test-for-cross.patch
new file mode 100644
index 0000000000..b1c0bfb859
--- /dev/null
+++ b/meta/recipes-devtools/python/python/02-remove-test-for-cross.patch
@@ -0,0 +1,106 @@
1# OpenEmbedded prepopulates the autotools site cache, so if this
2# would be using AC_TRY_CACHE, we could patch it in a more sane way
3# Alas, I don't have enough autotalent to do that.
4#
5# Signed-Off: Michael 'Mickey' Lauer <mickey@vanille-media.de>
6Index: Python-2.6.1/configure.in
7===================================================================
8--- Python-2.6.5.orig/configure.in 2010-07-06 04:37:09.000000000 -0700
9+++ Python-2.6.5/configure.in 2010-07-06 04:40:18.000000000 -0700
10@@ -2697,50 +2697,6 @@
11 AC_CHECK_LIB(resolv, inet_aton)
12 )
13
14-# On Tru64, chflags seems to be present, but calling it will
15-# exit Python
16-AC_CACHE_CHECK([for chflags], [ac_cv_have_chflags], [dnl
17-AC_TRY_RUN([[
18-#include <sys/stat.h>
19-#include <unistd.h>
20-int main(int argc, char*argv[])
21-{
22- if(chflags(argv[0], 0) != 0)
23- return 1;
24- return 0;
25-}
26-]], ac_cv_have_chflags=yes,
27- ac_cv_have_chflags=no,
28- ac_cv_have_chflags=cross)
29-])
30-if test "$ac_cv_have_chflags" = cross ; then
31- AC_CHECK_FUNC([chflags], [ac_cv_have_chflags="yes"], [ac_cv_have_chflags="no"])
32-fi
33-if test "$ac_cv_have_chflags" = yes ; then
34- AC_DEFINE(HAVE_CHFLAGS, 1, Define to 1 if you have the `chflags' function.)
35-fi
36-
37-AC_CACHE_CHECK([for lchflags], [ac_cv_have_lchflags], [dnl
38-AC_TRY_RUN([[
39-#include <sys/stat.h>
40-#include <unistd.h>
41-int main(int argc, char*argv[])
42-{
43- if(lchflags(argv[0], 0) != 0)
44- return 1;
45- return 0;
46-}
47-]], ac_cv_have_lchflags=yes,
48- ac_cv_have_lchflags=no,
49- ac_cv_have_lchflags=cross)
50-])
51-if test "$ac_cv_have_lchflags" = cross ; then
52- AC_CHECK_FUNC([lchflags], [ac_cv_have_lchflags="yes"], [ac_cv_have_lchflags="no"])
53-fi
54-if test "$ac_cv_have_lchflags" = yes ; then
55- AC_DEFINE(HAVE_LCHFLAGS, 1, Define to 1 if you have the `lchflags' function.)
56-fi
57-
58 dnl Check if system zlib has *Copy() functions
59 dnl
60 dnl On MacOSX the linker will search for dylibs on the entire linker path
61@@ -3844,45 +3800,6 @@
62 AC_MSG_RESULT(no)
63 fi
64
65-AC_MSG_CHECKING(for %zd printf() format support)
66-AC_TRY_RUN([#include <stdio.h>
67-#include <stddef.h>
68-#include <string.h>
69-
70-#ifdef HAVE_SYS_TYPES_H
71-#include <sys/types.h>
72-#endif
73-
74-#ifdef HAVE_SSIZE_T
75-typedef ssize_t Py_ssize_t;
76-#elif SIZEOF_VOID_P == SIZEOF_LONG
77-typedef long Py_ssize_t;
78-#else
79-typedef int Py_ssize_t;
80-#endif
81-
82-int main()
83-{
84- char buffer[256];
85-
86- if(sprintf(buffer, "%zd", (size_t)123) < 0)
87- return 1;
88-
89- if (strcmp(buffer, "123"))
90- return 1;
91-
92- if (sprintf(buffer, "%zd", (Py_ssize_t)-123) < 0)
93- return 1;
94-
95- if (strcmp(buffer, "-123"))
96- return 1;
97-
98- return 0;
99-}],
100-[AC_MSG_RESULT(yes)
101- AC_DEFINE(PY_FORMAT_SIZE_T, "z", [Define to printf format modifier for Py_ssize_t])],
102- AC_MSG_RESULT(no))
103-
104 AC_CHECK_TYPE(socklen_t,,
105 AC_DEFINE(socklen_t,int,
106 Define to `int' if <sys/socket.h> does not define.),[
diff --git a/meta/recipes-devtools/python/python/03-fix-tkinter-detection.patch b/meta/recipes-devtools/python/python/03-fix-tkinter-detection.patch
new file mode 100644
index 0000000000..a1a385a07c
--- /dev/null
+++ b/meta/recipes-devtools/python/python/03-fix-tkinter-detection.patch
@@ -0,0 +1,40 @@
1# We need to supply STAGING_INCDIR here, otherwise the Tk headers
2# will not be found.
3# Signed-Off: Michael 'Mickey' Lauer <mickey@vanille.de>
4
5Index: Python-2.6.1/setup.py
6===================================================================
7--- Python-2.6.1.orig/setup.py
8+++ Python-2.6.1/setup.py
9@@ -1543,7 +1543,7 @@ class PyBuildExt(build_ext):
10 dotversion = dotversion[:-1] + '.' + dotversion[-1]
11 tcl_include_sub = []
12 tk_include_sub = []
13- for dir in inc_dirs:
14+ for dir in [os.getenv("STAGING_INCDIR")]:
15 tcl_include_sub += [dir + os.sep + "tcl" + dotversion]
16 tk_include_sub += [dir + os.sep + "tk" + dotversion]
17 tk_include_sub += tcl_include_sub
18@@ -1562,22 +1562,6 @@ class PyBuildExt(build_ext):
19 if dir not in include_dirs:
20 include_dirs.append(dir)
21
22- # Check for various platform-specific directories
23- if platform == 'sunos5':
24- include_dirs.append('/usr/openwin/include')
25- added_lib_dirs.append('/usr/openwin/lib')
26- elif os.path.exists('/usr/X11R6/include'):
27- include_dirs.append('/usr/X11R6/include')
28- added_lib_dirs.append('/usr/X11R6/lib64')
29- added_lib_dirs.append('/usr/X11R6/lib')
30- elif os.path.exists('/usr/X11R5/include'):
31- include_dirs.append('/usr/X11R5/include')
32- added_lib_dirs.append('/usr/X11R5/lib')
33- else:
34- # Assume default location for X11
35- include_dirs.append('/usr/X11/include')
36- added_lib_dirs.append('/usr/X11/lib')
37-
38 # If Cygwin, then verify that X is installed before proceeding
39 if platform == 'cygwin':
40 x11_inc = find_file('X11/Xlib.h', [], include_dirs)
diff --git a/meta/recipes-devtools/python/python/04-default-is-optimized.patch b/meta/recipes-devtools/python/python/04-default-is-optimized.patch
new file mode 100644
index 0000000000..805f4f696c
--- /dev/null
+++ b/meta/recipes-devtools/python/python/04-default-is-optimized.patch
@@ -0,0 +1,52 @@
1# when compiling for an embedded system, we need every bit of
2# performance we can get. default to optimized with the option
3# of opt-out.
4# Signed-Off: Michael 'Mickey' Lauer <mickey@vanille-media.de>
5
6Index: Python-2.6.1/Python/compile.c
7===================================================================
8--- Python-2.6.1.orig/Python/compile.c
9+++ Python-2.6.1/Python/compile.c
10@@ -32,7 +32,7 @@
11 #include "symtable.h"
12 #include "opcode.h"
13
14-int Py_OptimizeFlag = 0;
15+int Py_OptimizeFlag = 1;
16
17 #define DEFAULT_BLOCK_SIZE 16
18 #define DEFAULT_BLOCKS 8
19Index: Python-2.6.1/Modules/main.c
20===================================================================
21--- Python-2.6.1.orig/Modules/main.c
22+++ Python-2.6.1/Modules/main.c
23@@ -40,7 +40,7 @@ static char **orig_argv;
24 static int orig_argc;
25
26 /* command line options */
27-#define BASE_OPTS "3bBc:dEhiJm:OQ:sStuUvVW:xX?"
28+#define BASE_OPTS "3bBc:dEhiJm:NOQ:sStuUvVW:xX?"
29
30 #ifndef RISCOS
31 #define PROGRAM_OPTS BASE_OPTS
32@@ -69,8 +69,7 @@ Options and arguments (and corresponding
33 static char *usage_2 = "\
34 if stdin does not appear to be a terminal; also PYTHONINSPECT=x\n\
35 -m mod : run library module as a script (terminates option list)\n\
36--O : optimize generated bytecode slightly; also PYTHONOPTIMIZE=x\n\
37--OO : remove doc-strings in addition to the -O optimizations\n\
38+-N : do NOT optimize generated bytecode\n\
39 -Q arg : division options: -Qold (default), -Qwarn, -Qwarnall, -Qnew\n\
40 -s : don't add user site directory to sys.path; also PYTHONNOUSERSITE\n\
41 -S : don't imply 'import site' on initialization\n\
42@@ -353,8 +352,8 @@ Py_Main(int argc, char **argv)
43
44 /* case 'J': reserved for Jython */
45
46- case 'O':
47- Py_OptimizeFlag++;
48+ case 'N':
49+ Py_OptimizeFlag=0;
50 break;
51
52 case 'B':
diff --git a/meta/recipes-devtools/python/python/05-enable-ctypes-cross-build.patch b/meta/recipes-devtools/python/python/05-enable-ctypes-cross-build.patch
new file mode 100644
index 0000000000..58b8078068
--- /dev/null
+++ b/meta/recipes-devtools/python/python/05-enable-ctypes-cross-build.patch
@@ -0,0 +1,28 @@
1# CTypes need to know the actual host we are building on.
2# Signed-Off: Michael Dietrich <mdt@emdete.de>
3
4Index: Python-2.6.1/setup.py
5===================================================================
6--- Python-2.6.1.orig/setup.py
7+++ Python-2.6.1/setup.py
8@@ -1656,16 +1656,16 @@ class PyBuildExt(build_ext):
9 ffi_configfile):
10 from distutils.dir_util import mkpath
11 mkpath(ffi_builddir)
12- config_args = []
13+ config_args = ['--host=%s' % os.environ["HOST_SYS"], ]
14
15 # Pass empty CFLAGS because we'll just append the resulting
16 # CFLAGS to Python's; -g or -O2 is to be avoided.
17- cmd = "cd %s && env CFLAGS='' '%s/configure' %s" \
18- % (ffi_builddir, ffi_srcdir, " ".join(config_args))
19+ cmd = "(cd %s && autoconf -W cross) && (cd %s && env CFLAGS='' '%s/configure' %s)" \
20+ % (ffi_srcdir, ffi_builddir, ffi_srcdir, " ".join(config_args))
21
22 res = os.system(cmd)
23 if res or not os.path.exists(ffi_configfile):
24- print "Failed to configure _ctypes module"
25+ print "Failed to configure _ctypes module (res=%d) or missing conffile=%s" % ( res, ffi_configfile )
26 return False
27
28 fficonfig = {}
diff --git a/meta/recipes-devtools/python/python/99-ignore-optimization-flag.patch b/meta/recipes-devtools/python/python/99-ignore-optimization-flag.patch
new file mode 100644
index 0000000000..02dc44c847
--- /dev/null
+++ b/meta/recipes-devtools/python/python/99-ignore-optimization-flag.patch
@@ -0,0 +1,19 @@
1# Reinstate the empty -O option to fix weird mixing of native and target
2# binaries and libraries with LD_LIBRARY_PATH when host==target
3#
4# Signed-off-by: Denys Dmytriyenko <denis@denix.org>
5
6Index: Python-2.6.1/Modules/main.c
7===================================================================
8--- Python-2.6.1-orig/Modules/main.c
9+++ Python-2.6.1/Modules/main.c
10@@ -352,6 +352,9 @@ Py_Main(int argc, char **argv)
11
12 /* case 'J': reserved for Jython */
13
14+ case 'O': /* ignore it */
15+ break;
16+
17 case 'N':
18 Py_OptimizeFlag=0;
19 break;
diff --git a/meta/recipes-devtools/python/python/sitecustomize.py b/meta/recipes-devtools/python/python/sitecustomize.py
new file mode 100644
index 0000000000..273901898a
--- /dev/null
+++ b/meta/recipes-devtools/python/python/sitecustomize.py
@@ -0,0 +1,45 @@
1# OpenEmbedded sitecustomize.py (C) 2002-2008 Michael 'Mickey' Lauer <mlauer@vanille-media.de>
2# GPLv2 or later
3# Version: 20081123
4# Features:
5# * set proper default encoding
6# * enable readline completion in the interactive interpreter
7# * load command line history on startup
8# * save command line history on exit
9
10import os
11
12def __exithandler():
13 try:
14 readline.write_history_file( "%s/.python-history" % os.getenv( "HOME", "/tmp" ) )
15 except IOError:
16 pass
17
18def __registerExitHandler():
19 import atexit
20 atexit.register( __exithandler )
21
22def __enableReadlineSupport():
23 readline.set_history_length( 1000 )
24 readline.parse_and_bind( "tab: complete" )
25 try:
26 readline.read_history_file( "%s/.python-history" % os.getenv( "HOME", "/tmp" ) )
27 except IOError:
28 pass
29
30def __enableDefaultEncoding():
31 import sys
32 try:
33 sys.setdefaultencoding( "utf8" )
34 except LookupError:
35 pass
36
37import sys
38try:
39 import rlcompleter, readline
40except ImportError:
41 pass
42else:
43 __enableDefaultEncoding()
44 __registerExitHandler()
45 __enableReadlineSupport()
diff --git a/meta/recipes-devtools/python/python_2.6.5.bb b/meta/recipes-devtools/python/python_2.6.5.bb
new file mode 100644
index 0000000000..9658fd48dc
--- /dev/null
+++ b/meta/recipes-devtools/python/python_2.6.5.bb
@@ -0,0 +1,121 @@
1require python.inc
2DEPENDS = "python-native db gdbm openssl readline sqlite3 zlib"
3DEPENDS_sharprom = "python-native db readline zlib gdbm openssl"
4# set to .0 on every increase of INC_PR
5PR = "${INC_PR}.2"
6
7SRC_URI = "\
8 http://www.python.org/ftp/python/${PV}/Python-${PV}.tar.bz2 \
9 file://00-fix-bindir-libdir-for-cross.patch \
10 file://01-use-proper-tools-for-cross-build.patch \
11 file://02-remove-test-for-cross.patch \
12 file://03-fix-tkinter-detection.patch \
13 file://04-default-is-optimized.patch \
14 file://05-enable-ctypes-cross-build.patch \
15 file://99-ignore-optimization-flag.patch \
16 file://sitecustomize.py \
17"
18S = "${WORKDIR}/Python-${PV}"
19
20inherit autotools
21
22# The 3 lines below are copied from the libffi recipe, ctypes ships its own copy of the libffi sources
23#Somehow gcc doesn't set __SOFTFP__ when passing -mfloatabi=softp :(
24TARGET_CC_ARCH_append_armv6 = " -D__SOFTFP__"
25TARGET_CC_ARCH_append_armv7a = " -D__SOFTFP__"
26
27do_configure_prepend() {
28 autoreconf -Wcross --verbose --install --force --exclude=autopoint Modules/_ctypes/libffi || oenote "_ctypes failed to autoreconf"
29}
30
31#
32# Copy config.h and an appropriate Makefile for distutils.sysconfig,
33# which laters uses the information out of these to compile extensions
34#
35do_compile_prepend() {
36 install -d ${STAGING_INCDIR}/python${PYTHON_MAJMIN}/
37 install -d ${STAGING_LIBDIR}/python${PYTHON_MAJMIN}/config/
38 install -m 0644 pyconfig.h ${STAGING_INCDIR}/python${PYTHON_MAJMIN}/
39 install -m 0644 Makefile Makefile.orig
40 install -m 0644 Makefile Makefile.backup
41 sed -e 's,${includedir},${STAGING_INCDIR},' < Makefile.backup > Makefile
42 install -m 0644 Makefile Makefile.backup
43 sed -e 's,${libdir},${STAGING_LIBDIR},' < Makefile.backup > Makefile
44 install -m 0644 Makefile ${STAGING_LIBDIR}/python${PYTHON_MAJMIN}/config/
45}
46
47do_compile() {
48 oe_runmake HOSTPGEN=${STAGING_BINDIR_NATIVE}/pgen \
49 HOSTPYTHON=${STAGING_BINDIR_NATIVE}/python \
50 STAGING_LIBDIR=${STAGING_LIBDIR} \
51 STAGING_INCDIR=${STAGING_INCDIR} \
52 BUILD_SYS=${BUILD_SYS} HOST_SYS=${HOST_SYS} \
53 OPT="${CFLAGS}" libpython${PYTHON_MAJMIN}.so
54
55 oe_libinstall -so libpython${PYTHON_MAJMIN} ${STAGING_LIBDIR}
56
57 oe_runmake HOSTPGEN=${STAGING_BINDIR_NATIVE}/pgen \
58 HOSTPYTHON=${STAGING_BINDIR_NATIVE}/python \
59 STAGING_LIBDIR=${STAGING_LIBDIR} \
60 STAGING_INCDIR=${STAGING_INCDIR} \
61 BUILD_SYS=${BUILD_SYS} HOST_SYS=${HOST_SYS} \
62 OPT="${CFLAGS}"
63}
64
65do_install() {
66 install -m 0644 Makefile.orig Makefile
67
68 oe_runmake HOSTPGEN=${STAGING_BINDIR_NATIVE}/pgen \
69 HOSTPYTHON=${STAGING_BINDIR_NATIVE}/python \
70 STAGING_LIBDIR=${STAGING_LIBDIR} \
71 STAGING_INCDIR=${STAGING_INCDIR} \
72 BUILD_SYS=${BUILD_SYS} HOST_SYS=${HOST_SYS} \
73 DESTDIR=${D} LIBDIR=${libdir} install
74
75 install -m 0644 ${WORKDIR}/sitecustomize.py ${D}/${libdir}/python${PYTHON_MAJMIN}
76
77 # remove hardcoded ccache, see http://bugs.openembedded.net/show_bug.cgi?id=4144
78 sed -i -e s,ccache,'$(CCACHE)', ${D}/${libdir}/python${PYTHON_MAJMIN}/config/Makefile
79}
80
81require python-${PYTHON_MAJMIN}-manifest.inc
82
83# manual dependency additions
84RPROVIDES_python-core = "python"
85RRECOMMENDS_python-core = "python-readline"
86RRECOMMENDS_python-crypt = "openssl"
87
88# add sitecustomize
89FILES_python-core += "${libdir}/python${PYTHON_MAJMIN}/sitecustomize.py"
90# ship 2to3
91FILES_python-core += "${bindir}/2to3"
92
93# package libpython2
94PACKAGES =+ "libpython2"
95FILES_libpython2 = "${libdir}/libpython*.so*"
96
97# additional stuff -dev
98
99FILES_${PN}-dev = "\
100 ${includedir} \
101 ${libdir}/lib*${SOLIBSDEV} \
102 ${libdir}/*.la \
103 ${libdir}/*.a \
104 ${libdir}/*.o \
105 ${libdir}/pkgconfig \
106 ${base_libdir}/*.a \
107 ${base_libdir}/*.o \
108 ${datadir}/aclocal \
109 ${datadir}/pkgconfig \
110"
111
112# catch debug extensions (isn't that already in python-core-dbg?)
113FILES_python-dbg += "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/.debug"
114
115# catch all the rest (unsorted)
116PACKAGES += "python-misc"
117FILES_python-misc = "${libdir}/python${PYTHON_MAJMIN}"
118
119# catch manpage
120PACKAGES += "python-man"
121FILES_python-man = "${datadir}/man"
diff --git a/meta/recipes-devtools/python/yum-metadata-parser-native_1.1.4.bb b/meta/recipes-devtools/python/yum-metadata-parser-native_1.1.4.bb
new file mode 100644
index 0000000000..0a44b99e2c
--- /dev/null
+++ b/meta/recipes-devtools/python/yum-metadata-parser-native_1.1.4.bb
@@ -0,0 +1,7 @@
1require yum-metadata-parser_${PV}.bb
2inherit native
3DEPENDS = "python-native sqlite3-native glib-2.0-native libxml2-native"
4RDEPENDS = ""
5PR = "r0"
6
7#BUILD_CFLAGS += "-I${STAGING_LIBDIR}/glib-2.0"
diff --git a/meta/recipes-devtools/python/yum-metadata-parser_1.1.4.bb b/meta/recipes-devtools/python/yum-metadata-parser_1.1.4.bb
new file mode 100644
index 0000000000..2e404a2bb1
--- /dev/null
+++ b/meta/recipes-devtools/python/yum-metadata-parser_1.1.4.bb
@@ -0,0 +1,15 @@
1DESCRIPTION = "C-based metadata parser to quickly parse xml metadata into sqlite databases."
2HOMEPAGE = "http://linux.duke.edu/projects/yum/download.ptml"
3SECTION = "devel/python"
4PRIORITY = "optional"
5DEPENDS = "python sqlite3 glib-2.0 libxml2"
6LICENSE = "GPL"
7
8PR = "r1"
9
10SRC_URI = "http://linux.duke.edu/projects/yum/download/yum-metadata-parser/yum-metadata-parser-${PV}.tar.gz"
11S = "${WORKDIR}/yum-metadata-parser-${PV}"
12
13TARGET_CFLAGS += "-I${STAGING_LIBDIR}/glib-2.0"
14
15inherit distutils