* Help with building app recipe
@ 2014-05-16 11:23 Neuer User
2014-05-16 12:04 ` Anders Darander
0 siblings, 1 reply; 6+ messages in thread
From: Neuer User @ 2014-05-16 11:23 UTC (permalink / raw)
To: yocto
Hello
I am trying to build a simple recipe for a package called "pyotherside".
It currently looks like this:
------------------------------------------------------------------------
SUMMARY = "Python3 bindings for Qt5"
DESCRIPTION = "New framework for including pyhton interpreter into Qt5 apps"
HOMEPAGE = "http://thp.io/2011/pyotherside/"
LICENSE = "MIT"
LIC_FILES_CHKSUM =
"file://${COMMON_LICENSE_DIR\}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302"
PV = "1.2+git${SRCPV}"
SRCREV = "87e5eaf4707261dfcb37d7daadef018266c83d5a"
SRC_URI = "git://github.com/thp/pyotherside.git;branch=master;protocol=git \
"
S = "${WORKDIR}/git/"
DEPENDS = "qtdeclarative python3 python3-native"
RDEPENDS_${PN} = "qtdeclarative-qmlplugins"
require recipes-qt/qt5/qt5.inc
------------------------------------------------------------------------
It is WIP, so e.g. the license is stil wrong.
The package depends on Qt5 and Python3.
I am currently experiencing two (rather small) problems:
1.) the configure step does not find "python3-config". It is located in
tmp/sysroots/i686-linux/usr/bin/python3-native
If I do a devshell and edit run.do_configure, I can add this path to the
PATH env variable, and then everything works.
How can I modify my recipe, so that this path is automatically added?
2.) The "python3-config" script just uses "#!/usr/bin/env python" to
define its interpreter, so the system starts the script with python2. If
I change the script manually, it works.
What would be the correct way to change my receipt to make it work? Or
would I need to change the python3 recipe to patch this file?
Thanks for your help!
Michael
P.S.: Seems, pyotherside is working nicely...
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Help with building app recipe
2014-05-16 11:23 Help with building app recipe Neuer User
@ 2014-05-16 12:04 ` Anders Darander
2014-05-16 12:16 ` Neuer User
0 siblings, 1 reply; 6+ messages in thread
From: Anders Darander @ 2014-05-16 12:04 UTC (permalink / raw)
To: yocto
* Neuer User <auslands-kv@gmx.de> [140516 13:24]:
> require recipes-qt/qt5/qt5.inc
> ------------------------------------------------------------------------
> It is WIP, so e.g. the license is stil wrong.
> The package depends on Qt5 and Python3.
In that case, I would have expected to see
inherit python3native qmake5
in your recipe.
> I am currently experiencing two (rather small) problems:
> 1.) the configure step does not find "python3-config". It is located in
> tmp/sysroots/i686-linux/usr/bin/python3-native
I haven't used python3 in combination with OE yet. Though, this should
likely have been handled by
inherit python3native
Cheers,
Anders
--
Anders Darander
ChargeStorm AB / eStorm AB
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Help with building app recipe
2014-05-16 12:04 ` Anders Darander
@ 2014-05-16 12:16 ` Neuer User
2014-05-16 12:33 ` Neuer User
0 siblings, 1 reply; 6+ messages in thread
From: Neuer User @ 2014-05-16 12:16 UTC (permalink / raw)
To: yocto
Am 16.05.2014 14:04, schrieb Anders Darander:
> * Neuer User <auslands-kv@gmx.de> [140516 13:24]:
>
>> require recipes-qt/qt5/qt5.inc
>> ------------------------------------------------------------------------
>
>
>> It is WIP, so e.g. the license is stil wrong.
>
>> The package depends on Qt5 and Python3.
>
> In that case, I would have expected to see
>
> inherit python3native qmake5
>
> in your recipe.
>
>> I am currently experiencing two (rather small) problems:
>
>> 1.) the configure step does not find "python3-config". It is located in
>> tmp/sysroots/i686-linux/usr/bin/python3-native
>
> I haven't used python3 in combination with OE yet. Though, this should
> likely have been handled by
> inherit python3native
>
> Cheers,
> Anders
>
Great, that helped with no 1.). Still a lot to learn for me.
No 2. is still open, though. Is that a problem of my recipe or rather a
generic problem of the python3 recipe? I could patch the python3 recipe,
so that it changes the interpreter line to "python3".
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Help with building app recipe
2014-05-16 12:16 ` Neuer User
@ 2014-05-16 12:33 ` Neuer User
2014-05-17 5:18 ` Khem Raj
0 siblings, 1 reply; 6+ messages in thread
From: Neuer User @ 2014-05-16 12:33 UTC (permalink / raw)
To: yocto
Am 16.05.2014 14:16, schrieb Neuer User:
> Am 16.05.2014 14:04, schrieb Anders Darander:
>
> Great, that helped with no 1.). Still a lot to learn for me.
>
> No 2. is still open, though. Is that a problem of my recipe or rather a
> generic problem of the python3 recipe? I could patch the python3 recipe,
> so that it changes the interpreter line to "python3".
>
Hmm the python3-native recipe has this install function:
----------------------------------------------------------
do_install() {
install -d ${D}${libdir}/pkgconfig
oe_runmake 'DESTDIR=${D}' install
if [ -e ${WORKDIR}/sitecustomize.py ]; then
install -m 0644 ${WORKDIR}/sitecustomize.py
${D}/${libdir}/python${PYTHON_MAJMIN}
fi
install -d ${D}${bindir}/${PN}
install -m 0755 Parser/pgen ${D}${bindir}/${PN}
# Make sure we use /usr/bin/env python
for PYTHSCRIPT in `grep -rIl ${bindir}/${PN}/python
${D}${bindir}/${PN}`; do
sed -i -e '1s|^#!.*|#!/usr/bin/env python|' $PYTHSCRIPT
done
}
----------------------------------------------------------
If I change the sed line to "#!/usr/bin/env python3", that would
probably work then. But would it break something else?
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Help with building app recipe
2014-05-16 12:33 ` Neuer User
@ 2014-05-17 5:18 ` Khem Raj
2014-05-22 13:50 ` Diego Sueiro
0 siblings, 1 reply; 6+ messages in thread
From: Khem Raj @ 2014-05-17 5:18 UTC (permalink / raw)
To: Neuer User; +Cc: yocto@yoctoproject.org
On Fri, May 16, 2014 at 5:33 AM, Neuer User <auslands-kv@gmx.de> wrote:
> If I change the sed line to "#!/usr/bin/env python3", that would
> probably work then. But would it break something else?
would be fine.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Help with building app recipe
2014-05-17 5:18 ` Khem Raj
@ 2014-05-22 13:50 ` Diego Sueiro
0 siblings, 0 replies; 6+ messages in thread
From: Diego Sueiro @ 2014-05-22 13:50 UTC (permalink / raw)
To: Khem Raj; +Cc: yocto@yoctoproject.org, Neuer User
[-- Attachment #1: Type: text/plain, Size: 1909 bytes --]
Folks,
I'm trying to accomplish this in a 64bits host machine. But I'm getting
errors the following error on compile task:
| In file included from
/<snip>/tmp/sysroots/x86_64-linux/usr/include/python3.3m/Python.h:50:0,
| from ../../git/src/qpython_priv.h:22,
| from moc_qpython_priv.cpp:9:
| /<snip>/sysroots/x86_64-linux/usr/include/python3.3m/pyport.h:820:2:
error: #error "LONG_BIT definition appears wrong for platform (bad
gcc/glibc config?)."
| #error "LONG_BIT definition appears wrong for platform (bad gcc/glibc
config?)."
| ^
Searching on Google it says that this is a known bug when trying to
cross-compile Python stuff for 32bits machines on 64bits hosts.
It seems that the guys from Buildroot could get this solved:
http://lists.busybox.net/pipermail/buildroot/2011-August/045257.html
I'm trying to find the "magical" patch to how to get this fixed.
Also found this link too:
http://blog.devork.be/2009/02/compiling-32-bit-python-on-amd64.html
But I'm not quite sure how to get this fixed on Yocto. Should it need to be
fixed on the pyotherside, or python3, or python3-native recipe?
Any directions are appreciated.
Regards,
--
*dS
Diego Sueiro
Administrador do Embarcados
www.embarcados.com.br<http://www.embarcados.com.br/?utm_source=assinatura_diego&utm_medium=e-mail&utm_campaign=Assinatura%20Email%20Diego>
/*long live rock 'n roll*/
On Sat, May 17, 2014 at 2:18 AM, Khem Raj <raj.khem@gmail.com> wrote:
> On Fri, May 16, 2014 at 5:33 AM, Neuer User <auslands-kv@gmx.de> wrote:
> > If I change the sed line to "#!/usr/bin/env python3", that would
> > probably work then. But would it break something else?
>
> would be fine.
> --
> _______________________________________________
> yocto mailing list
> yocto@yoctoproject.org
> https://lists.yoctoproject.org/listinfo/yocto
>
[-- Attachment #2: Type: text/html, Size: 4863 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2014-05-22 13:50 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-05-16 11:23 Help with building app recipe Neuer User
2014-05-16 12:04 ` Anders Darander
2014-05-16 12:16 ` Neuer User
2014-05-16 12:33 ` Neuer User
2014-05-17 5:18 ` Khem Raj
2014-05-22 13:50 ` Diego Sueiro
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.