# # Name: CMakeLists.txt (CMake control file) # Date: 2023-03-15 (Wed) # # message(STATUS "CMakeLists.txt: init") #cmake_minimum_required(VERSION 2.8) #cmake_minimum_required(VERSION 2.8.1 FATAL_ERROR) #cmake_minimum_required(VERSION 3.3) #cmake_minimum_required(VERSION 3.6) #message(STATUS "CMakeLists.txt: set minimum to 2.8") #!set(CMAKE_LEGACY_CYGWIN_WIN32 0) # Remove when CMake >= 2.8.4 is required # set the project name project(xmitmsgx C) message(STATUS "CMakeLists.txt: defined project 'xmitmsgx' language 'C'") #include(includable.cmake) #include_directories(./include) #xmitmsgx.h #include(config-defs2.cmake) ##### add the libraries add_library(xmitmsgx STATIC xmitmsgx.c) message(STATUS "CMakeLists.txt: added library 'xmitmsgx' source 'xmitmsgx.c'") add_library(xmitmsgxdyn SHARED xmitmsgx.c) message(STATUS "CMakeLists.txt: added library 'xmitmsgxdyn' source 'xmitmsgx.c'") #target_include_directories(include) #xmitmsgx.h #target_link_libraries(xmitmsgx) ##### add the executables #add_executable(xmitmsg xmitmsg.c) add_executable(xmitmsg xmitmsg.c xmitmsgx.c) message(STATUS "CMakeLists.txt: added executable 'xmitmsg' source 'xmitmsg.c'") #add_executable(xmiterr xmiterr.c) add_executable(xmiterr xmiterr.c xmitmsgx.c) message(STATUS "CMakeLists.txt: added executable 'xmiterr' source 'xmiterr.c'") #add_executable(xmsgtest xmsgtest.c) add_executable(xmsgtest xmsgtest.c xmitmsgx.c) message(STATUS "CMakeLists.txt: added executable 'xmsgtest' source 'xmsgtest.c'") #set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -L../.. -lxmitmsgx") #set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -L/home/rmt/git/xmitmsgx/xmitmsgx-2.0.21/cmake/work -lxmitmsgx") #set(CMAKE_EXE_LINKER_FLAGS "-static-libgcc -static-libstdc++ -static") #set(CMAKE_EXE_LINKER_FLAGS "-L../.. -lxmitmsgx") #find_package(OpenGL REQUIRED) #link_directories(${OPENGL_gl_LIBRARY}) #set(SOURCE_FILES main.cpp camera.h display.h display.cpp mesh.cpp mesh.h obj_loader.cpp obj_loader.h shader.cpp shader.h stb_image.c stb_image.h texture.cpp texture.h transform.h) #link_directories(texture_mapping ${PROJECT_SOURCE_DIR}/lib)