Hello I am new to Linux development, and just recently switched from Windows MSVS c++ development to Linux-based vim+cmake+gcc. I am using Debian Sid(unstable).
I am trying to get code on subdivision, I have gotten from a friend to run. I am not really used to Cmake, and googling for help often is troublesome, since every other dist seems to have different packages and different solutions.
cmake_minimum_required (VERSION 2.6)
project (Benchmark)
Find_Package(Qt4 REQUIRED) Include(${QT_USE_FILE})find_package(OpenGL REQUIRED)
include_directories(${OPENGL_INCLUDE_DIR})set(CORELIBS ${QT_LIBRARY} ${OPENGL_LIBRARY} )
File(GLOB SRC ".cpp")
File(GLOB HEAD ".h")
add_executable(Benchmark ${SRC})
target_link_libraries(Benchmark ${CORELIBS})
That is my current Cmake, I want to use find_package(), GLOB etc to make it as dynamic as possible, and not use absolute paths.
I get the following error when trying to build.
subdivbench/Matrix4x4.h:4:19: fatal error: gl/GL.h: No such file or directory
#include gl/GL.h
compilation terminated. make[2]: [CMakeFiles/Benchmark.dir/Matrix4x4.cpp.o] Error 1 make[1]: [CMakeFiles/Benchmark.dir/all] Error 2
The code is fairly irrelevant, since it's working perfectly in windows, all I need to do is to make the include etc work for Linux.