-
Notifications
You must be signed in to change notification settings - Fork 44
Linked to static Pthread_win. Solves #355 #358
Conversation
To avoid DLL dependency in python package, and since all other libs are statically linked, too.
Update after partial Appveyor CI crash and quick test of the py27-x64 wheel.
If no one has other opinions, I would cancel this PR and attempt the alternative path to distribute the pthread DLL (this is also recommended by their doc over static linking). |
Thanks for trying this out, @ldoyle. I agree that statically linking the pthread library seems like a good approach. Not sure what is going wrong here. Although you say the pthread docs recommend against that - can you provide a link? Some notes:
I also tried adding pthread to the libraries passed to the Python extension, but that didn't help either. @NexeyaSGara As our Windows build expert, do you have any suggestions for us? |
Hi, For the pthread builds, I use nmake as pointed in the documentation. So maybe we will have to edit the Makefile of pthread to add some definition for the compiler. |
Make the build environment/ compiler flags etc as close to cppTango as possible to ensure good linking.
I haven't got it running yet, but looking at the Cmake process I have a feeling that the precompiler defs have to be cleaned up, anyway.
If I find the spare time I will try to compile cppTango and PyTango manually from source, but maybe someone more experienced can say if this is at all the right direction. [1] https://sourceware.org/pthreads-win32/ -> How does it work? |
Pthreads only came in while trying to get the Windows builds to work with Unfortunately the original PRs to get Windows builds working in are incredibly long and complicated, with many dead ends. Started with #176, and then that was continued and finalised in #277. |
Closing this as we have a better solution in #395. No need for the pthread.dll. |
To avoid DLL dependency in python package, and since all other libs are statically linked, too. Solves #355
(Untested since I would have to set up a build env, hope the CI test will do. If not, sorry, this is my first PR, I can manually compile it locally if necessary)
Things to consider:
setup.py
inpackage_data
(and maybe toappveyor.yml
to copy the right architecture/version).