Ultimaker / libArcus

Communication library between internal components for Ultimaker software

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

building from source failed, SIP version may be the cause

janemba opened this issue · comments

Hello,

I have an issue building libArcus from source and it seems to be related to SIP. I installed SIP version 4.19.8 using pip3.
Below, the cmake log :

# cmake -DSIP_INCLUDE_DIRS=/usr/include/python3.7 ..
Scanning dependencies of target Arcus
[  4%] Building CXX object CMakeFiles/Arcus.dir/src/Socket.cpp.o
[  9%] Building CXX object CMakeFiles/Arcus.dir/src/SocketListener.cpp.o
[ 13%] Building CXX object CMakeFiles/Arcus.dir/src/MessageTypeStore.cpp.o
[ 18%] Building CXX object CMakeFiles/Arcus.dir/src/PlatformSocket.cpp.o
[ 22%] Building CXX object CMakeFiles/Arcus.dir/src/Error.cpp.o
[ 27%] Linking CXX shared library libArcus.so
[ 27%] Built target Arcus
[ 31%] Generating python/sipArcuspart0.cpp, python/sipArcuspart1.cpp, python/sipArcuspart2.cpp, python/sipArcuspart3.cpp, python/sipArcuspart4.cpp, python/sipArcuspart5.cpp, python/sipArcuspart6.cpp, python/sipArcuspart7.cpp

Scanning dependencies of target python_module_Arcus
[ 36%] Building CXX object CMakeFiles/python_module_Arcus.dir/python/sipArcuspart0.cpp.o
In file included from /tmp/libArcus/build/python/sipArcuspart0.cpp:10:
/tmp/libArcus/build/python/sipArcuspart0.cpp: In destructor ‘virtual sipSocket::~sipSocket()’:
/tmp/libArcus/build/python/sipAPIArcus.h:161:51: error: ‘const sipAPIDef’ {aka ‘const struct _sipAPIDef’} has no member named ‘api_instance_destroyed_ex’; did you mean ‘api_instance_destroyed’?
 #define sipInstanceDestroyedEx      sipAPI_Arcus->api_instance_destroyed_ex
                                                   ^~~~~~~~~~~~~~~~~~~~~~~~~
/tmp/libArcus/build/python/sipArcuspart0.cpp:301:5: note: in expansion of macro ‘sipInstanceDestroyedEx’
     sipInstanceDestroyedEx(&sipPySelf);
     ^~~~~~~~~~~~~~~~~~~~~~
make[2]: *** [CMakeFiles/python_module_Arcus.dir/build.make:94: CMakeFiles/python_module_Arcus.dir/python/sipArcuspart0.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:73: CMakeFiles/python_module_Arcus.dir/all] Error 2
make: *** [Makefile:152: all] Error 2

Any idea of how to fix it ?

I tried with version 4.19.12 but the issue persist.

That's strange because the function that the compiler is missing was introduced in 4.19.11 iirc.

Are you sure that your entire environment uses the newer SIP version that you installed later? An easy way to check is to remove the old SIP installation.

It's also possible that it's using a SIP installation from your system instead. Ubuntu comes supplied with SIP.

It's worth mentioning that I never met a person yet who was able to compile anything with SIP bindings without compiling SIP themselves as well.

Yes, I have only one SIP version installed in my system.