Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cmake error #36

Closed
tai61031 opened this issue Jul 14, 2019 · 2 comments
Closed

Cmake error #36

tai61031 opened this issue Jul 14, 2019 · 2 comments

Comments

@tai61031
Copy link

cmake ../csrc/ -D_OPENGL_LIB_PATH=/usr/lib/nvidia-410
-- The CXX compiler identification is GNU 5.4.0
-- The CUDA compiler identification is NVIDIA 9.0.176
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Check for working CUDA compiler: /usr/bin/nvcc
-- Check for working CUDA compiler: /usr/bin/nvcc -- works
-- Detecting CUDA compiler ABI info
-- Detecting CUDA compiler ABI info - done
-- Found OpenGL: /usr/lib/nvidia-410/libOpenGL.so found components: OpenGL EGL
-- Configuring done
CMake Warning at CMakeLists.txt:42 (add_library):
Cannot generate a safe runtime search path for target rasterise because
files in some directories may conflict with libraries in implicit
directories:

runtime library [libEGL.so.1] in /usr/lib/x86_64-linux-gnu may be hidden by files in:
  /usr/lib/nvidia-410

Some of these libraries may not be found correctly.

-- Generating done

@pmh47
Copy link
Owner

pmh47 commented Jul 17, 2019

Note that this is a warning not an error; sometimes DIRT will still work when it happens.

The warning means you have two versions of OpenGL, system and nvidia, and they aren't "tied together" by GLVND. To avoid the warning, you need to tell cmake not to look in /usr/lib/x86_64-linux at all when searching for OpenGL libraries, which can't be done (AFAIK) without modifying FindOpenGL itself.

If it does crash at runtime (because system libEGL is picked up at runtime instead of nvidia's), you can try with LD_PRELOAD=/usr/lib/nvidia-410/libEGL.so python square_test.py.

If that fails, please run

import dirt.rasterise_ops
import subprocess
subprocess.call(['ldd', dirt.rasterise_ops._lib_path + '/librasterise.so'])

and paste the output here.

@tai61031
Copy link
Author

This warning will cause the core dumped error when running the testing code
i just solved this by
cmake ../csrc/ -D_OPENGL_LIB_PATH=/usr/lib/nvidia-410 -DCMAKE_LIBRARY_PATH=/usr/lib/nvidia-410

thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants