How to tell SIP where to look for QtCoremod.sip (Flatpak)

Hello,

I have been trying to package SciDAVis as Flatpak.
https://github.com/highperformancecoder/scidavis

Here is my progress.
https://github.com/kevinsmia1939/io.github.highperformancecoder.SciDAVis

I build with this command.
flatpak-builder --install --user build net.sourceforge.scidavis.SciDAVis.yaml --force-clean

I could not compile SciDAVis. Error below.


-- The CXX compiler identification is GNU 10.2.0
-- The C compiler identification is GNU 10.2.0
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Found Python3: /usr/bin/python3.8 (found version "3.8.7") found components: Interpreter Development Development.Module Development.Embed
-- Found SIP: /app/bin/sip (found version "4.19.13")
-- Found PyQt: /app/include/PyQt5 (found version "5.11.3")
-- Found PkgConfig: /usr/bin/pkg-config (found version "1.7.3")
-- Found GSL: /app/include (found version "2.6")
-- Found ZLIB: /usr/lib/x86_64-linux-gnu/libz.so (found suitable version "1.2.11", minimum required is "1.2.11")
-- Found OpenGL: /usr/lib/x86_64-linux-gnu/libOpenGL.so found components: OpenGL
-- Found muParser : /app/lib/libmuparser.so include: /app/include
-- Qt5 GUI found /usr/include/;/usr/include/QtGui
-- Qwt5: using own code
-- QwtPlot3D: using own code
-- liborigin not enabled
-- Configuring done
-- Generating done

But later this happen.


  1%] Building CXX object fitPlugins/fitRational0/CMakeFiles/fitRational0.dir/fitRational0.cpp.o
  1%] **Compiling python files**
cd /run/build/scidavis/fitPlugins/fitRational0 && /usr/bin/c++ -DfitRational0_EXPORTS  -O2 -g -pipe -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong -grecord-gcc-switches -fasynchronous-unwind-tables -fstack-clash-protection -fcf
-protection -fexceptions -Wall -Wextra -pedantic -fPIC -std=c++17 -o CMakeFiles/fitRational0.dir/fitRational0.cpp.o -c /run/build/scidavis/fitPlugins/fitRational0/fitRational0.cpp 
  1%] **Generating sipAPIscidavis.h, sipscidaviscmodule.cpp, sipscidavisApplicationWindow.cpp, sipscidavisGraph.cpp, sipscidavisArrowMarker.cpp, sipscidavisImageMarker.cpp, sipscidavisLegend.cpp, sipscidavisMultiLayer.cpp, sipscidavisTable.cpp, sipscidavisMatrix.cpp, s**
ipscidavisMyWidget.cpp, sipscidavisScriptEdit.cpp, sipscidavisNote.cpp, sipscidavisPythonScript.cpp, sipscidavisPythonScripting.cpp, sipscidavisFolder.cpp, sipscidavisFit.cpp, sipscidavisExponentialFit.cpp, sipscidavisTwoExpFit.cpp, sipscidavisThreeExpFit.cpp, sipscid
avisSigmoidalFit.cpp, sipscidavisGaussAmpFit.cpp, sipscidavisLorentzFit.cpp, sipscidavisNonLinearFit.cpp, sipscidavisPluginFit.cpp, sipscidavisMultiPeakFit.cpp, sipscidavisPolynomialFit.cpp, sipscidavisLinearFit.cpp, sipscidavisGaussFit.cpp, sipscidavisFilter.cpp, sip
scidavisDifferentiation.cpp, sipscidavisIntegration.cpp, sipscidavisInterpolation.cpp, sipscidavisSmoothFilter.cpp, sipscidavisFFTFilter.cpp, sipscidavisFFT.cpp, sipscidavisCorrelation.cpp, sipscidavisConvolution.cpp, sipscidavisDeconvolution.cpp, sipscidavisAbstractA
spect.cpp, sipscidavisColumn.cpp, sipscidavisQwtSymbol.cpp, sipscidavisQwtPlotCurve.cpp, sipscidavisQwtPlot.cpp, sipscidavisGrid.cpp, sipscidavisQList0100QDateTime.cpp, sipscidavisQList0101Folder.cpp, sipscidavisQList0101MyWidget.cpp, sipscidavisQList0101QwtPlotCurve.
cpp
cd /run/build/scidavis/libscidavis && /app/bin/sip -c . -I/app/include/PyQt5 -n PyQt5.sip -t WS_X11 -t Qt_5_15_2 /run/build/scidavis/libscidavis/src/scidavis.sip 
cd /run/build/scidavis/scidavis && /usr/bin/python3.8 -m compileall -b scidavisrc.py 
sip: Unable to find file "QtCore/QtCoremod.sip" 
make[2]: *** [libscidavis/CMakeFiles/generate_PyQt_source.dir/build.make:131: libscidavis/sipAPIscidavis.h] Error 1 
make[2]: Leaving directory '/run/build/scidavis' 
make[1]: *** [CMakeFiles/Makefile2:481: libscidavis/CMakeFiles/generate_PyQt_source.dir/all] Error 2 
make[1]: *** Waiting for unfinished jobs.... 
Compiling 'scidavisrc.py'... 
  1%] **Linking C static library libminigzip.a**
cd /run/build/scidavis/3rdparty && /usr/bin/cmake -P CMakeFiles/minigzip.dir/cmake_clean_target.cmake 
make[2]: Leaving directory '/run/build/scidavis' 
cd /run/build/scidavis/3rdparty && /usr/bin/cmake -E cmake_link_script CMakeFiles/minigzip.dir/link.txt --verbose=1 
  1%] Built target generate_pyc_files 
/usr/bin/ar qc libminigzip.a CMakeFiles/minigzip.dir/minigzip/minigzip.c.o 
/usr/bin/ranlib libminigzip.a 
make[2]: Leaving directory '/run/build/scidavis' 
  1%] **Linking C shared library libexp_saturation.so**
cd /run/build/scidavis/fitPlugins/exp_saturation && /usr/bin/cmake -E cmake_link_script CMakeFiles/exp_saturation.dir/link.txt --verbose=1 
  1%] Built target minigzip 
  2%] **Linking C shared library libexplin.so**
cd /run/build/scidavis/fitPlugins/explin && /usr/bin/cmake -E cmake_link_script CMakeFiles/explin.dir/link.txt --verbose=1 
/usr/bin/cc -fPIC -O2 -g -pipe -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong -grecord-gcc-switches -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -Wall -Wextra -pedantic -L/app/lib -Wl,-z,relro,-z,now -W
l,--as-needed -shared -Wl,-soname,libexp_saturation.so -o libexp_saturation.so CMakeFiles/exp_saturation.dir/exp_saturation.c.o  /app/lib/libgsl.so /app/lib/libgslcblas.so  
/usr/bin/cc -fPIC -O2 -g -pipe -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong -grecord-gcc-switches -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -Wall -Wextra -pedantic -L/app/lib -Wl,-z,relro,-z,now -W
l,--as-needed -shared -Wl,-soname,libexplin.so -o libexplin.so CMakeFiles/explin.dir/explin.c.o  /app/lib/libgsl.so /app/lib/libgslcblas.so  
make[2]: Leaving directory '/run/build/scidavis' 
  2%] Built target exp_saturation 
make[2]: Leaving directory '/run/build/scidavis' 
  2%] Built target explin 
make[2]: Leaving directory '/run/build/scidavis' 
  2%] Built target qwtplot3d_autogen 
  2%] **Linking CXX shared library libfitRational0.so**
cd /run/build/scidavis/fitPlugins/fitRational0 && /usr/bin/cmake -E cmake_link_script CMakeFiles/fitRational0.dir/link.txt --verbose=1 
/usr/bin/c++ -fPIC -O2 -g -pipe -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong -grecord-gcc-switches -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fexceptions -Wall -Wextra -pedantic -L/app/lib -Wl,-z,r
elro,-z,now -Wl,--as-needed -shared -Wl,-soname,libfitRational0.so -o libfitRational0.so CMakeFiles/fitRational0.dir/fitRational0.cpp.o  /app/lib/libgsl.so /app/lib/libgslcblas.so  
make[2]: Leaving directory '/run/build/scidavis' 
  2%] Built target fitRational0 
make[2]: Leaving directory '/run/build/scidavis' 
  2%] Built target qwt5-qt5_autogen 
make[1]: Leaving directory '/run/build/scidavis' 
make: *** [Makefile:174: all] Error 2 
Error: module scidavis: Child process exited with code 2




However, QtCoremod.sip does exist in build/files/share/sip/PyQt5/QtCore/QtCoremod.sip. This is where flatpak build SciDAVis.
I came to conclusion that SIP is looking for QtCore/QtCoremod.sip in the wrong directory.

How can I tel SIP to look in different place?

Thanks.
Andy

I don’t see errors in anything you posted except the last 2 lines of your last output, and that by itself isn’t descriptive enough to know the error is what you conclude.

  1. What leads you to believe the error is what you say it is? Your assumption about where the makefile is looking might be right, but I don’t see anything that says that is so.
  2. If the error is what you say it is…
    The error should be reported to whoever created the makefile you’re using
    You can try editing the makefile directly to either point to the correct location or create a link from the wrong location to the correct location.

IMO,
TSU

Hi there! You should try out this new search engine called CoRepo, you might find a solution :slight_smile: