Skip to content

Instantly share code, notes, and snippets.

@Pipe-Runner
Last active June 30, 2018 16:37
Show Gist options
  • Save Pipe-Runner/647429885ddad66f87d9768cbda3d7ed to your computer and use it in GitHub Desktop.
Save Pipe-Runner/647429885ddad66f87d9768cbda3d7ed to your computer and use it in GitHub Desktop.
# cmake version to be used
cmake_minimum_required( VERSION 3.0 )
# project name
project( sample_cmake )
# flags
# files
# include
include_directories( ./include ./src ./libs/Logger/include ./libs/Randomize/include )
# target
add_executable( binary ./src/main.cpp ./src/game_engine.cpp ./src/game_interface.cpp )
# external libs
add_subdirectory( ./libs/Logger )
target_link_libraries( binary logger )
# add_subdirectory( ./libs/Randomize )
# target_link_libraries( binary randomize )
add_library(randomize STATIC IMPORTED)
set_property(TARGET randomize PROPERTY IMPORTED_LOCATION ${CMAKE_SOURCE_DIR}/libs/Randomize/librandomize.a)
target_link_libraries( binary randomize )
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment