pyqtdeploy as shared library

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

pyqtdeploy as shared library

Shyne
Hello everyone,

I try to build a python project that use ctypes module with the following
versions:

pyqtdeploy today snapshot build
Python 3.7.1
Qt 5.11.2
sip 4.19.13
PyQt5 5.11.3

Here is my sysroot.json for python:

    "python": {
        "build_host_from_source":   false,
        "build_target_from_source": false,
        "version": "3.7"
    },

But that give me an error at the end of the build :

        link /NOLOGO /DYNAMICBASE /NXCOMPAT /INCREMENTAL:NO
/SUBSYSTEM:CONSOLE "
/MANIFESTDEPENDENCY:type='win32' name='Microsoft.Windows.Common-Controls'
versio
n='6.0.0.0' publicKeyToken='6595b64144ccf1df' language='*'
processorArchitecture
='*'" /MANIFEST:embed /OUT:release\ceres.exe
@C:\Users\shyne\AppData\Local\Temp
\nm6CD8.tmp
   Création de la bibliothèque release\ceres.lib et de l'objet
release\ceres.exp
pyqtdeploy_main.obj : error LNK2001: symbole externe non résolu PyInit__abc
release\ceres.exe : fatal error LNK1120: 1 externes non résolus
NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual
Studio\2017
\BuildTools\VC\Tools\MSVC\14.15.26726\bin\HostX64\x64\link.EXE"' : code
retour '
0x460'
Stop.
NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual
Studio\2017
\BuildTools\VC\Tools\MSVC\14.15.26726\bin\HostX64\x64\nmake.exe"' : code
retour
'0x2'
Stop.

I don't know what to do, I've tried to build the target from source but my
application give me this traceback:
AttributeError: module 'sys' has no attribute 'dllhandle'  

Any help would be greatly appreciated.

Thanks!




--
Sent from: http://python.6.x6.nabble.com/PyQt-f1792048.html
_______________________________________________
PyQt mailing list    [hidden email]
https://www.riverbankcomputing.com/mailman/listinfo/pyqt
Reply | Threaded
Open this post in threaded view
|

Re: pyqtdeploy as shared library

Phil Thompson-5
On 28 Oct 2018, at 10:17 am, Shyne <[hidden email]> wrote:

>
> Hello everyone,
>
> I try to build a python project that use ctypes module with the following
> versions:
>
> pyqtdeploy today snapshot build
> Python 3.7.1
> Qt 5.11.2
> sip 4.19.13
> PyQt5 5.11.3
>
> Here is my sysroot.json for python:
>
>    "python": {
>        "build_host_from_source":   false,
>        "build_target_from_source": false,
>        "version": "3.7"
>    },
>
> But that give me an error at the end of the build :
>
>        link /NOLOGO /DYNAMICBASE /NXCOMPAT /INCREMENTAL:NO
> /SUBSYSTEM:CONSOLE "
> /MANIFESTDEPENDENCY:type='win32' name='Microsoft.Windows.Common-Controls'
> versio
> n='6.0.0.0' publicKeyToken='6595b64144ccf1df' language='*'
> processorArchitecture
> ='*'" /MANIFEST:embed /OUT:release\ceres.exe
> @C:\Users\shyne\AppData\Local\Temp
> \nm6CD8.tmp
>   Création de la bibliothèque release\ceres.lib et de l'objet
> release\ceres.exp
> pyqtdeploy_main.obj : error LNK2001: symbole externe non résolu PyInit__abc
> release\ceres.exe : fatal error LNK1120: 1 externes non résolus
> NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual
> Studio\2017
> \BuildTools\VC\Tools\MSVC\14.15.26726\bin\HostX64\x64\link.EXE"' : code
> retour '
> 0x460'
> Stop.
> NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual
> Studio\2017
> \BuildTools\VC\Tools\MSVC\14.15.26726\bin\HostX64\x64\nmake.exe"' : code
> retour
> '0x2'
> Stop.
>
> I don't know what to do, I've tried to build the target from source but my
> application give me this traceback:
> AttributeError: module 'sys' has no attribute 'dllhandle'  
>
> Any help would be greatly appreciated.

It's a development snapshot - patches welcome :)

Phil
_______________________________________________
PyQt mailing list    [hidden email]
https://www.riverbankcomputing.com/mailman/listinfo/pyqt
Reply | Threaded
Open this post in threaded view
|

Re: pyqtdeploy as shared library

Shyne
Hi Phil, 

I've the same problem with the last snapshot.
Here is what I've done to fix the issue:

pyqtdeploy/metadata/python_metadata.py
3589c3589
<                 source='!win#_abc.c'),
---
>                 source='_abc.c'),

Thanks for your hard work on PyQt5, SIP and pyqtdeploy!

Le dim. 28 oct. 2018 à 11:55, Phil Thompson <[hidden email]> a écrit :
On 28 Oct 2018, at 10:17 am, Shyne <[hidden email]> wrote:
>
> Hello everyone,
>
> I try to build a python project that use ctypes module with the following
> versions:
>
> pyqtdeploy today snapshot build
> Python 3.7.1
> Qt 5.11.2
> sip 4.19.13
> PyQt5 5.11.3
>
> Here is my sysroot.json for python:
>
>    "python": {
>        "build_host_from_source":   false,
>        "build_target_from_source": false,
>        "version": "3.7"
>    },
>
> But that give me an error at the end of the build :
>
>        link /NOLOGO /DYNAMICBASE /NXCOMPAT /INCREMENTAL:NO
> /SUBSYSTEM:CONSOLE "
> /MANIFESTDEPENDENCY:type='win32' name='Microsoft.Windows.Common-Controls'
> versio
> n='6.0.0.0' publicKeyToken='6595b64144ccf1df' language='*'
> processorArchitecture
> ='*'" /MANIFEST:embed /OUT:release\ceres.exe
> @C:\Users\shyne\AppData\Local\Temp
> \nm6CD8.tmp
>   Création de la bibliothèque release\ceres.lib et de l'objet
> release\ceres.exp
> pyqtdeploy_main.obj : error LNK2001: symbole externe non résolu PyInit__abc
> release\ceres.exe : fatal error LNK1120: 1 externes non résolus
> NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual
> Studio\2017
> \BuildTools\VC\Tools\MSVC\14.15.26726\bin\HostX64\x64\link.EXE"' : code
> retour '
> 0x460'
> Stop.
> NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual
> Studio\2017
> \BuildTools\VC\Tools\MSVC\14.15.26726\bin\HostX64\x64\nmake.exe"' : code
> retour
> '0x2'
> Stop.
>
> I don't know what to do, I've tried to build the target from source but my
> application give me this traceback:
> AttributeError: module 'sys' has no attribute 'dllhandle' 
>
> Any help would be greatly appreciated.

It's a development snapshot - patches welcome :)

Phil

_______________________________________________
PyQt mailing list    [hidden email]
https://www.riverbankcomputing.com/mailman/listinfo/pyqt
Reply | Threaded
Open this post in threaded view
|

Re: pyqtdeploy as shared library

Phil Thompson-5
On 8 Nov 2018, at 9:25 am, Shyne <[hidden email]> wrote:

>
> Hi Phil,
>
> I've the same problem with the last snapshot.
> Here is what I've done to fix the issue:
>
> pyqtdeploy/metadata/python_metadata.py
> 3589c3589
> <                 source='!win#_abc.c'),
> ---
> >                 source='_abc.c'),

Works fine for me. Make sure you are using the standard Python shared library in the .pdy file.

Phil
_______________________________________________
PyQt mailing list    [hidden email]
https://www.riverbankcomputing.com/mailman/listinfo/pyqt