Skip to content

Commit 02985d3

Browse files
GaryThomasrpurdie
authored andcommitted
python-pygtk: Clean up incorrect "fix"
This patch removes most of "dirty fix #1" which is no longer needed (no dependency on python-pygobject-dev exists). A side effect is that the pygtk code generator will also be installed. Merge 'fix-path.inc' into this recipe as it is not used by any other recipe. Signed-off-by: Gary Thomas <gary@mlbassoc.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
1 parent 0870d91 commit 02985d3

2 files changed

Lines changed: 21 additions & 28 deletions

File tree

meta/recipes-devtools/python/fix-path.inc

Lines changed: 0 additions & 22 deletions
This file was deleted.

meta/recipes-devtools/python/python-pygtk_2.24.0.bb

Lines changed: 21 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -40,16 +40,31 @@ do_configure_prepend() {
4040
sed -i 's:tests docs:tests:' ${S}/Makefile.am
4141
}
4242

43-
# dirty fix #1: remove dependency on python-pygobject-dev
43+
# dirty fix #2: fix build system paths leaking in
4444
do_install_append() {
45-
find ${D} -name "*.la"|xargs rm -f
46-
rm -f ${D}/${bindir}/pygtk-codegen-2.0
45+
for i in `find ${D} -name "*.py"` ; do \
46+
sed -i -e s:${D}::g $i
47+
done
48+
49+
for i in `find ${D} -name "*.la"` ; do \
50+
sed -i -e s:${STAGING_LIBDIR}:${libdir}:g $i
51+
done
52+
53+
if test -e ${D}${bindir} ; then
54+
for i in ${D}${bindir}/* ; do \
55+
sed -i -e s:${STAGING_BINDIR_NATIVE}:${bindir}:g $i
56+
done
57+
fi
58+
59+
if test -e ${D}${sbindir} ; then
60+
for i in ${D}${sbindir}/* ; do \
61+
sed -i -e s:${STAGING_BINDIR_NATIVE}:${bindir}:g $i
62+
done
63+
fi
64+
4765
sed -i -e '1s|^#!.*python|#!/usr/bin/env python|' ${D}${bindir}/pygtk-demo
4866
}
4967

50-
# dirty fix #2: fix build system paths leaking in
51-
require fix-path.inc
52-
5368
PACKAGES =+ "${PN}-demo"
5469
FILES_${PN}-demo = " ${bindir}/pygtk-demo ${libdir}/pygtk "
5570
RDEPENDS_${PN}-demo = "python-pygtk python-stringold python-lang"

0 commit comments

Comments
 (0)