Bug while installing Yade from source code

Asked by Rémi Chassagne

Hello everyone,

I have a bug while installing YADE from source code.
My system : Ubuntu 14.04.5 LTS
Yade version : Yade 2017-11-27.git-8bae8f2

I followed the instruction given in the tutorial : https://yade-dem.org/doc/installation.html#source-code
         - In my "home" I created a "myYade/" directory in which I did : git clone https://github.com/yade/trunk.git
         - I created the directories "build/" and "install/" in "myYade/"
         - in "myYade/build/" I configured the compilation : cmake -DCMAKE_CXX_FLAGS=-frounding-math -DCMAKE_INSTALL_PREFIX=../install ../trunk
         - I compiled : "make" (stilll in "myYade/build/")

Until here everything seems normal. The bug comes during the installation process. I did "make install" and the following bug occured :
"
CMake Error at gui/cmake_install.cmake:88 (FILE):
  file INSTALL cannot find "/home/remi/myYade/build/img_rc.py".
Call Stack (most recent call first):
  cmake_install.cmake:197 (INCLUDE)

make: *** [install] Error 1
"

I tired to copy-paste "img_rc.py" from an older version already installed on my computer.
Doing again "make install" I have the same error but with "ui_controller.py". Again I did a copy-paste.
Now "make install" works.

If I try to launch Yade in "myYade/install/bin/" with ./yade-2017-11-27.git-8bae8f2 and I have a segmentation fault :
"
Welcome to Yade 2017-11-27.git-8bae8f2
Segmentation fault (core dumped)
"

If someone has an idea and can help me, I would be grateful.

Rémi

Question information

Language:
English Edit question
Status:
Solved
For:
Yade Edit question
Assignee:
No assignee Edit question
Solved by:
Bruno Chareyre
Solved:
Last query:
Last reply:
Revision history for this message
Jérôme Duriez (jduriez) said :
#1

Hi,

I think we will need the output of cmake in order for us to possibly help you.

Jérôme

Revision history for this message
Rémi Chassagne (remicha) said :
#2

Thank you for your answer. Here is the output of cmake -DCMAKE_CXX_FLAGS=-frounding-math -DCMAKE_INSTALL_PREFIX=../install ../trunk done in "~/myYade/build/"

-- Version is set to 2017-11-27.git-8bae8f2
-- GTS using gts-config /usr/bin/gts-config
-- Using GTS from /usr
-- GCC Version >= 4.8. Adding -ftrack-macro-expansion=0 and -save-temps
-- Boost version: 1.54.0
-- Found the following Boost libraries:
-- python
-- thread
-- filesystem
-- iostreams
-- regex
-- serialization
-- system
-- date_time
-- Boost_VERSION: 105400
-- Boost_LIB_VERSION: 1_54
-- Boost_INCLUDE_DIRS: /usr/include
-- Boost_LIBRARIES: /usr/lib/x86_64-linux-gnu/libboost_python.so/usr/lib/x86_64-linux-gnu/libboost_thread.so/usr/lib/x86_64-linux-gnu/libboost_filesystem.so/usr/lib/x86_64-linux-gnu/libboost_iostreams.so/usr/lib/x86_64-linux-gnu/libboost_regex.so/usr/lib/x86_64-linux-gnu/libboost_serialization.so/usr/lib/x86_64-linux-gnu/libboost_system.so/usr/lib/x86_64-linux-gnu/libboost_date_time.so/usr/lib/x86_64-linux-gnu/libpthread.so
-- Found Eigen3, version: 3.2.1
-- Disable vectorization
-- The imported target "vtkParseJava" references the file
   "/usr/bin/vtkParseJava"
but this file does not exist. Possible reasons include:
* The file was deleted, renamed, or moved to another location.
* An install or uninstall procedure did not complete successfully.
* The installation package was faulty and contained
   "/usr/lib/vtk-5.8/VTKTargets.cmake"
but not all the files it references.

-- The imported target "vtkWrapJava" references the file
   "/usr/bin/vtkWrapJava"
but this file does not exist. Possible reasons include:
* The file was deleted, renamed, or moved to another location.
* An install or uninstall procedure did not complete successfully.
* The installation package was faulty and contained
   "/usr/lib/vtk-5.8/VTKTargets.cmake"
but not all the files it references.

-- The imported target "vtkCommonJava" references the file
   "/usr/lib/jni/libvtkCommonJava.so.5.8.0"
but this file does not exist. Possible reasons include:
* The file was deleted, renamed, or moved to another location.
* An install or uninstall procedure did not complete successfully.
* The installation package was faulty and contained
   "/usr/lib/vtk-5.8/VTKTargets.cmake"
but not all the files it references.

-- The imported target "vtkFilteringJava" references the file
   "/usr/lib/jni/libvtkFilteringJava.so.5.8.0"
but this file does not exist. Possible reasons include:
* The file was deleted, renamed, or moved to another location.
* An install or uninstall procedure did not complete successfully.
* The installation package was faulty and contained
   "/usr/lib/vtk-5.8/VTKTargets.cmake"
but not all the files it references.

-- The imported target "vtkImagingJava" references the file
   "/usr/lib/jni/libvtkImagingJava.so.5.8.0"
but this file does not exist. Possible reasons include:
* The file was deleted, renamed, or moved to another location.
* An install or uninstall procedure did not complete successfully.
* The installation package was faulty and contained
   "/usr/lib/vtk-5.8/VTKTargets.cmake"
but not all the files it references.

-- The imported target "vtkGraphicsJava" references the file
   "/usr/lib/jni/libvtkGraphicsJava.so.5.8.0"
but this file does not exist. Possible reasons include:
* The file was deleted, renamed, or moved to another location.
* An install or uninstall procedure did not complete successfully.
* The installation package was faulty and contained
   "/usr/lib/vtk-5.8/VTKTargets.cmake"
but not all the files it references.

-- The imported target "vtkGenericFilteringJava" references the file
   "/usr/lib/jni/libvtkGenericFilteringJava.so.5.8.0"
but this file does not exist. Possible reasons include:
* The file was deleted, renamed, or moved to another location.
* An install or uninstall procedure did not complete successfully.
* The installation package was faulty and contained
   "/usr/lib/vtk-5.8/VTKTargets.cmake"
but not all the files it references.

-- The imported target "vtkIOJava" references the file
   "/usr/lib/jni/libvtkIOJava.so.5.8.0"
but this file does not exist. Possible reasons include:
* The file was deleted, renamed, or moved to another location.
* An install or uninstall procedure did not complete successfully.
* The installation package was faulty and contained
   "/usr/lib/vtk-5.8/VTKTargets.cmake"
but not all the files it references.

-- The imported target "vtkRenderingJava" references the file
   "/usr/lib/jni/libvtkRenderingJava.so.5.8.0"
but this file does not exist. Possible reasons include:
* The file was deleted, renamed, or moved to another location.
* An install or uninstall procedure did not complete successfully.
* The installation package was faulty and contained
   "/usr/lib/vtk-5.8/VTKTargets.cmake"
but not all the files it references.

-- The imported target "vtkVolumeRenderingJava" references the file
   "/usr/lib/jni/libvtkVolumeRenderingJava.so.5.8.0"
but this file does not exist. Possible reasons include:
* The file was deleted, renamed, or moved to another location.
* An install or uninstall procedure did not complete successfully.
* The installation package was faulty and contained
   "/usr/lib/vtk-5.8/VTKTargets.cmake"
but not all the files it references.

-- The imported target "vtkHybridJava" references the file
   "/usr/lib/jni/libvtkHybridJava.so.5.8.0"
but this file does not exist. Possible reasons include:
* The file was deleted, renamed, or moved to another location.
* An install or uninstall procedure did not complete successfully.
* The installation package was faulty and contained
   "/usr/lib/vtk-5.8/VTKTargets.cmake"
but not all the files it references.

-- The imported target "vtkWidgetsJava" references the file
   "/usr/lib/jni/libvtkWidgetsJava.so.5.8.0"
but this file does not exist. Possible reasons include:
* The file was deleted, renamed, or moved to another location.
* An install or uninstall procedure did not complete successfully.
* The installation package was faulty and contained
   "/usr/lib/vtk-5.8/VTKTargets.cmake"
but not all the files it references.

-- The imported target "vtkParallelJava" references the file
   "/usr/lib/jni/libvtkParallelJava.so.5.8.0"
but this file does not exist. Possible reasons include:
* The file was deleted, renamed, or moved to another location.
* An install or uninstall procedure did not complete successfully.
* The installation package was faulty and contained
   "/usr/lib/vtk-5.8/VTKTargets.cmake"
but not all the files it references.

-- The imported target "vtkInfovisJava" references the file
   "/usr/lib/jni/libvtkInfovisJava.so.5.8.0"
but this file does not exist. Possible reasons include:
* The file was deleted, renamed, or moved to another location.
* An install or uninstall procedure did not complete successfully.
* The installation package was faulty and contained
   "/usr/lib/vtk-5.8/VTKTargets.cmake"
but not all the files it references.

-- The imported target "vtkGeovisJava" references the file
   "/usr/lib/jni/libvtkGeovisJava.so.5.8.0"
but this file does not exist. Possible reasons include:
* The file was deleted, renamed, or moved to another location.
* An install or uninstall procedure did not complete successfully.
* The installation package was faulty and contained
   "/usr/lib/vtk-5.8/VTKTargets.cmake"
but not all the files it references.

-- The imported target "vtkViewsJava" references the file
   "/usr/lib/jni/libvtkViewsJava.so.5.8.0"
but this file does not exist. Possible reasons include:
* The file was deleted, renamed, or moved to another location.
* An install or uninstall procedure did not complete successfully.
* The installation package was faulty and contained
   "/usr/lib/vtk-5.8/VTKTargets.cmake"
but not all the files it references.

-- The imported target "vtkQtChart" references the file
   "/usr/lib/libvtkQtChart.so.5.8.0"
but this file does not exist. Possible reasons include:
* The file was deleted, renamed, or moved to another location.
* An install or uninstall procedure did not complete successfully.
* The installation package was faulty and contained
   "/usr/lib/vtk-5.8/VTKTargets.cmake"
but not all the files it references.

-- The imported target "QVTK" references the file
   "/usr/lib/libQVTK.so.5.8.0"
but this file does not exist. Possible reasons include:
* The file was deleted, renamed, or moved to another location.
* An install or uninstall procedure did not complete successfully.
* The installation package was faulty and contained
   "/usr/lib/vtk-5.8/VTKTargets.cmake"
but not all the files it references.

-- The imported target "vtkChartsJava" references the file
   "/usr/lib/jni/libvtkChartsJava.so.5.8.0"
but this file does not exist. Possible reasons include:
* The file was deleted, renamed, or moved to another location.
* An install or uninstall procedure did not complete successfully.
* The installation package was faulty and contained
   "/usr/lib/vtk-5.8/VTKTargets.cmake"
but not all the files it references.

-- Found VTK
-- Found OpenMP
-- GTS using gts-config /usr/bin/gts-config
-- Using GTS from /usr
-- Found GTS
-- Found GUI-Qt5-LIBS
-- GMP libs: /usr/lib/x86_64-linux-gnu/libgmp.so /usr/lib/x86_64-linux-gnu/libgmpxx.so
-- GMP libs: /usr/lib/x86_64-linux-gnu/libgmp.so /usr/lib/x86_64-linux-gnu/libgmpxx.so
-- Found CGAL
-- Found Cholmod in /usr/lib/libcholmod.so
-- Found OpenBlas in /usr/lib/libopenblas.so
-- Found Metis in /usr/lib/libmetis.so
-- Found GL2PS
LBMFLOW is still experimental, building and running LBM engine are at your own risk!
Yade will be installed to /home/remi/myYade/install
-- Suffix is set to -2017-11-27.git-8bae8f2
-- LIBRARY_OUTPUT_PATH is set to lib/x86_64-linux-gnu
-- runtimePREFIX is set to /home/remi/myYade/install
-- Use system gts version
-- ===========================================================
-- Yade configured with following features: Odeint VTK OpenMP GTS GUI-Qt5 CGAL PFVFLOW LINSOLV GL2PS LBMFLOW
-- Disabled features: CHOLMOD_GPU SPH DEFORM LIQMIGRATION MASK_ARBITRARY PROFILING PotentialParticles PotentialBlocks
-- Optimized build
-- ===========================================================
-- Configuring done
-- Generating done
-- Build files have been written to: /home/remi/myYade/build

Revision history for this message
Marcus Moravia (mgmoravia) said :
#3

Hi Rémi.

There are packages missing in your system. I am quite sure that the cause of the problem is the lack of 'pyqt4-dev-tools'. You can see all necessary packages for Ubuntu Trusty on:

https://github.com/yade/yadedaily/blob/trusty/control

Cheers!

Marcus

Revision history for this message
Manfred Hampl (m-hampl) said :
#4

Maybe missing package is / are

libvtk-java
libvtk5-dev

Revision history for this message
Rémi Chassagne (remicha) said :
#5

Thanks for your help. I installed all the missing packages I found at the page : https://github.com/yade/yadedaily/blob/trusty/control
So I do not have any warning messages during the compilation configuration process. The output of cmake -DCMAKE_CXX_FLAGS=-frounding-math -DCMAKE_INSTALL_PREFIX=../install ../trunk is now :

-- Version is set to 2017-11-27.git-79e991c
-- GTS using gts-config /usr/bin/gts-config
-- Using GTS from /usr
-- GCC Version >= 4.8. Adding -ftrack-macro-expansion=0 and -save-temps
-- Boost version: 1.54.0
-- Found the following Boost libraries:
-- python
-- thread
-- filesystem
-- iostreams
-- regex
-- serialization
-- system
-- date_time
-- Boost_VERSION: 105400
-- Boost_LIB_VERSION: 1_54
-- Boost_INCLUDE_DIRS: /usr/include
-- Boost_LIBRARIES: /usr/lib/x86_64-linux-gnu/libboost_python.so/usr/lib/x86_64-linux-gnu/libboost_thread.so/usr/lib/x86_64-linux-gnu/libboost_filesystem.so/usr/lib/x86_64-linux-gnu/libboost_iostreams.so/usr/lib/x86_64-linux-gnu/libboost_regex.so/usr/lib/x86_64-linux-gnu/libboost_serialization.so/usr/lib/x86_64-linux-gnu/libboost_system.so/usr/lib/x86_64-linux-gnu/libboost_date_time.so/usr/lib/x86_64-linux-gnu/libpthread.so
-- Found Eigen3, version: 3.2.1
-- Disable vectorization
-- Found VTK
-- Found OpenMP
-- GTS using gts-config /usr/bin/gts-config
-- Using GTS from /usr
-- Found GTS
-- Found GUI-Qt5-LIBS
-- GMP libs: /usr/lib/x86_64-linux-gnu/libgmp.so /usr/lib/x86_64-linux-gnu/libgmpxx.so
-- GMP libs: /usr/lib/x86_64-linux-gnu/libgmp.so /usr/lib/x86_64-linux-gnu/libgmpxx.so
-- Found CGAL
-- Found Cholmod in /usr/lib/x86_64-linux-gnu/libcholmod.so
-- Found OpenBlas in /usr/lib/libopenblas.so
-- Found Metis in /usr/lib/x86_64-linux-gnu/libmetis.so
-- Found GL2PS
LBMFLOW is still experimental, building and running LBM engine are at your own risk!
Yade will be installed to /home/remi/myYade/install
-- Suffix is set to -2017-11-27.git-79e991c
-- LIBRARY_OUTPUT_PATH is set to lib/x86_64-linux-gnu
-- runtimePREFIX is set to /home/remi/myYade/install
-- Use system gts version
-- ===========================================================
-- Yade configured with following features: Odeint VTK OpenMP GTS GUI-Qt5 CGAL PFVFLOW LINSOLV GL2PS LBMFLOW
-- Disabled features: CHOLMOD_GPU SPH DEFORM LIQMIGRATION MASK_ARBITRARY PROFILING PotentialParticles PotentialBlocks
-- Optimized build
-- ===========================================================
-- Configuring done
-- Generating done
-- Build files have been written to: /home/remi/myYade/build

I recompiled, but the bug is not fixed, the file img_rc.py is not found and the installation failed.
I have a warning during the compilation phase that occur several time but that I do not understand :

In file included from /usr/lib/python2.7/dist-packages/numpy/core/include/numpy/ndarraytypes.h:1761:0,
                 from /home/remi/myYade/trunk/py/_polyhedra_utils.cpp:15:
/usr/lib/python2.7/dist-packages/numpy/core/include/numpy/npy_1_7_deprecated_api.h:15:2: warning: #warning "Using deprecated NumPy API, disable it by " "#defining NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION" [-Wcpp]
 #warning "Using deprecated NumPy API, disable it by " \
  ^

Rémi

Revision history for this message
Marcus Moravia (mgmoravia) said :
#6

Hi Rémi,

Before recompile you need to erase everything inside the /build and /install folders. Did you do this?

Marcus.

Revision history for this message
Rémi Chassagne (remicha) said :
#7

Hi,

Yes I did this...

Rémi

Revision history for this message
Best Bruno Chareyre (bruno-chareyre) said :
#8

Hi,
It sounds like the Qt4/Qt5 problem on 14.04. You may try to compile with -DUSE_QT5=OFF (or maybe install additional/updated Qt5 dependencies, I'm less sure).
There was a comment about that in the installation page some time ago [1], now not visible but it was maybe worth keeping. I'll insert it again.

Quoting:
"To provide Qt4->Qt5 migration one needs to provide an additional option USE_QT5.
This option should be ON or OFF according to the Qt version, which was used
to compile libQGLViewer. On Debian/Ubuntu operating systems libQGLViewer
of version 2.6.3 and higher are compiled against Qt5 (for other operating systems
refer to the package archive of your distribution), so if you are using
such version, please switch this option ON. Otherwise, if you mix Qt-versions a
Segmentation fault will appear just after Yade is started. To provide
necessary build dependencies for Qt5, install python-pyqt5 pyqt5-dev-tools
instead of python-qt4 pyqt4-dev-tools."

I hope it will help

Bruno

[1] https://github.com/yade/trunk/commit/1c06b6ad9d2cfcb574017ca64e70da4ca3b3b95b#diff-dd4d2ec3eab729a92cd85af90fe5e929L247

Revision history for this message
Rémi Chassagne (remicha) said :
#9

Hello,

Thank you very much, that solved the problem. I just added the option -DUSE_QT5=OFF in the cmake instance and it worked.

Thank you for all the answers !

Rémi

Revision history for this message
Rémi Chassagne (remicha) said :
#10

Thanks Bruno Chareyre, that solved my question.