diff options
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 6ac4767..38f12c9 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,7 +1,10 @@ cmake_minimum_required(VERSION 3.0) -project(my_raylib_game C) +project(slgj C) set(CMAKE_C_STANDARD 99) +# the `pkg_check_modules` function is created with this call +find_package(PkgConfig REQUIRED) + # Adding Raylib include(FetchContent) set(FETCHCONTENT_QUIET FALSE) @@ -21,12 +24,14 @@ FetchContent_MakeAvailable(raylib) file(GLOB_RECURSE PROJECT_SOURCES CONFIGURE_DEPENDS "${CMAKE_CURRENT_LIST_DIR}/sources/*.c") # Define PROJECT_SOURCES as a list of all source files set(PROJECT_INCLUDE "${CMAKE_CURRENT_LIST_DIR}/sources/") # Define PROJECT_INCLUDE to be the path to the include directory of the project +pkg_check_modules(GUILE_PKG REQUIRED IMPORTED_TARGET guile-3.0) + # Declaring our executable add_executable(${PROJECT_NAME}) target_sources(${PROJECT_NAME} PRIVATE ${PROJECT_SOURCES}) target_include_directories(${PROJECT_NAME} PRIVATE ${PROJECT_INCLUDE}) -target_link_libraries(${PROJECT_NAME} PRIVATE raylib) +target_link_libraries(${PROJECT_NAME} PRIVATE raylib PkgConfig::GUILE_PKG) # Setting ASSETS_PATH -target_compile_definitions(${PROJECT_NAME} PUBLIC ASSETS_PATH="${CMAKE_CURRENT_SOURCE_DIR}/assets/") # Set the asset path macro to the absolute path on the dev machine -#target_compile_definitions(${PROJECT_NAME} PUBLIC ASSETS_PATH="./assets") # Set the asset path macro in release mode to a relative path that assumes the assets folder is in the same directory as the game executable
\ No newline at end of file +target_compile_definitions(${PROJECT_NAME} PUBLIC ASSETS_PATH="./assets/") +target_compile_definitions(${PROJECT_NAME} PUBLIC SCRIPTS_PATH="./scripts/") |