diff options
Diffstat (limited to 'meta/recipes-devtools/python/python-native_2.7.13.bb')
-rw-r--r-- | meta/recipes-devtools/python/python-native_2.7.13.bb | 24 |
1 files changed, 21 insertions, 3 deletions
diff --git a/meta/recipes-devtools/python/python-native_2.7.13.bb b/meta/recipes-devtools/python/python-native_2.7.13.bb index 7edf153489..2b74003c79 100644 --- a/meta/recipes-devtools/python/python-native_2.7.13.bb +++ b/meta/recipes-devtools/python/python-native_2.7.13.bb | |||
@@ -1,5 +1,4 @@ | |||
1 | require python.inc | 1 | require python.inc |
2 | |||
3 | EXTRANATIVEPATH += "bzip2-native" | 2 | EXTRANATIVEPATH += "bzip2-native" |
4 | DEPENDS = "openssl-native bzip2-replacement-native zlib-native readline-native sqlite3-native expat-native" | 3 | DEPENDS = "openssl-native bzip2-replacement-native zlib-native readline-native sqlite3-native expat-native" |
5 | PR = "${INC_PR}.1" | 4 | PR = "${INC_PR}.1" |
@@ -25,8 +24,6 @@ FILESEXTRAPATHS =. "${FILE_DIRNAME}/${PN}:" | |||
25 | 24 | ||
26 | inherit native | 25 | inherit native |
27 | 26 | ||
28 | require python-native-${PYTHON_MAJMIN}-manifest.inc | ||
29 | |||
30 | EXTRA_OECONF_append = " --bindir=${bindir}/${PN} --with-system-expat=${STAGING_DIR_HOST}" | 27 | EXTRA_OECONF_append = " --bindir=${bindir}/${PN} --with-system-expat=${STAGING_DIR_HOST}" |
31 | 28 | ||
32 | EXTRA_OEMAKE = '\ | 29 | EXTRA_OEMAKE = '\ |
@@ -59,3 +56,24 @@ do_install() { | |||
59 | # installed in the native sysroot, so disable user site support. | 56 | # installed in the native sysroot, so disable user site support. |
60 | sed -i -e 's,^\(ENABLE_USER_SITE = \).*,\1False,' ${D}${libdir}/python${PYTHON_MAJMIN}/site.py | 57 | sed -i -e 's,^\(ENABLE_USER_SITE = \).*,\1False,' ${D}${libdir}/python${PYTHON_MAJMIN}/site.py |
61 | } | 58 | } |
59 | |||
60 | python(){ | ||
61 | |||
62 | # Read JSON manifest | ||
63 | import json | ||
64 | pythondir = d.getVar('THISDIR',True) | ||
65 | with open(pythondir+'/python/python2-manifest.json') as manifest_file: | ||
66 | python_manifest=json.load(manifest_file) | ||
67 | |||
68 | rprovides = d.getVar('RPROVIDES').split() | ||
69 | |||
70 | # Hardcoded since it cant be python-native-foo, should be python-foo-native | ||
71 | pn = 'python' | ||
72 | |||
73 | for key in python_manifest: | ||
74 | pypackage = pn + '-' + key + '-native' | ||
75 | if pypackage not in rprovides: | ||
76 | rprovides.append(pypackage) | ||
77 | |||
78 | d.setVar('RPROVIDES', ' '.join(rprovides)) | ||
79 | } | ||