[SailfishDevel] Fwd: Re: Include Python.h

Reto Zingg reto.zingg at jollamobile.com
Tue Aug 6 09:32:58 UTC 2013


Hi,

On 06.08.2013 12:14, christopher.lamb at thurweb.ch wrote:
> Hi Benoit
>
> B.t.w, zypper in to the MERSDK and adding packages to the toolchain via
> the SDK Control Center are NOT the same thing*.
>
> I was also a bit confused on this, but as I see it, using zypper in the
> MERSDK makes stuff available to the underlaying operating system, but
> not necessarily to the toolchain.

yes installing something with zypper logged into the build engine, just 
installs that package in the build engine it self (the vbox image). You 
can install packages in the sb2 target also on the command line[0], but 
it's recommended to do it in the control center, since it assures that

a) it gets installed in the right sb2 target (aka toolchain)
b) call caches are in sync

If you install via cli, please hit the "sync" button, in the control center.

I know it's rather confusing at the beginning, but once you understand 
the differences between Build engine, SB2 Target / Toolchain and 
Emulator it should be clearer.

best regards
Reto

[0]
sb2 -t SailfishOS-i486-x86 -m sdk-install -R zypper install PACKAGE

>
> To me it makes sense to isolate the 2, the OS may require different
> versions of the same package then those in the toolchain (which are
> intended to build stuff for a third party - in this case the Emulator)
>
> Perhaps David can explain this better.
>
> Chris
>
> * having just added python-devel via the SDK Control Center, I also did
> a zypper se python-devel, which showed that package is not installed
> (for the OS), yet it is in the toolchain.
>
>
> ----- Weitergeleitete Nachricht von christopher.lamb at thurweb.ch -----
>       Datum: Tue, 06 Aug 2013 11:03:35 +0200
>         Von: christopher.lamb at thurweb.ch
>     Betreff: Re: [SailfishDevel] Include Python.h
>          An: "Benoît HERVIER" <khertan at khertan.net>
>          Cc: devel at lists.sailfishos.org
>
> Salut Benoit
>
> Have you tried installing python-devel via the SDK Control Center in
> QtCreator. (The Sailfish Icon on the left side of QtCreator)
>
> I have just done so, an now have a python.h file in the toolchain
> (before I had none).
>
> Chris
>
> Zitat von "Benoît HERVIER" <khertan at khertan.net>:
>
>> Morning
>>
>> I'm currently facing a problem that i didn't understand :
>>
>> ./qpython.h:4:20: fatal error: Python.h: No such file or directory
>>
>>
>> qpython.h
>> ~~~~
>> #ifndef _QPYTHON_H
>> #define _QPYTHON_H
>>
>> #include "Python.h"
>> ~~~~
>>
>> I ve installed via zypper python-devel in mersdk vm.
>>
>> I've even added hardcoded path in .pro:
>> INCLUDEPATH += /usr/include/python2.7
>> LIBS += -lpython2.7
>>
>> And python2.7 headers path are in the gcc cmd:
>>
>> Exécution_de(%build): /bin/sh -e /var/tmp/rpm-tmp.b27OWP
>> g++ -c -m32 -pipe -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2
>> -fexceptions -fstack-protector --param=ssp-buffer-size=4 -Wformat
>> -Wformat-security -m32 -march=core2 -mssse3 -mtune=atom -mfpmath=sse
>> -fasynchronous-unwind-tables -fno-omit-frame-pointer -Wall -W
>> -D_REENTRANT -fPIE
>> -DDEPLOYMENT_PATH="\""/usr/share/ownNotesForSailfish/"\""
>> -DQT_QML_DEBUG -DQT_DECLARATIVE_DEBUG -DQT_QUICK_LIB -DQT_QML_LIB
>> -DQT_NETWORK_LIB -DQT_GUI_LIB -DQT_CORE_LIB
>> -I/usr/share/qt5/mkspecs/linux-g++-32 -I. -I/usr/include/python2.7
>> -Isailfishapplication -I/usr/include/qt5 -I/usr/include/qt5/QtQuick
>> -I/usr/include/qt5/QtQml -I/usr/include/qt5/QtNetwork
>> -I/usr/include/qt5/QtGui -I/usr/include/qt5/QtCore -Imoc -o obj/main.o
>> main.cpp
>>
>> Python.h is available in /usr/include/python2.7 on mersdk vm.
>>
>> Such include is working in QtProject QtCreator on desktop ... so i
>> suppose that something i miss with the compilation on target ...
>>
>> Any advice ?
>> Thx
>> --
>> Benoît HERVIER - http://khertan.net/
>> _______________________________________________
>> SailfishOS.org Devel mailing list
>
>
>
> _______________________________________________
> SailfishOS.org Devel mailing list
>
> ----- Ende der weitergeleiteten Nachricht -----
>
>
> _______________________________________________
> SailfishOS.org Devel mailing list



More information about the Devel mailing list