Skip to content

Instantly share code, notes, and snippets.

@Matrixbirds
Last active November 23, 2018 08:07
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Matrixbirds/f6f030a638afa8a223eb3e03e3aca283 to your computer and use it in GitHub Desktop.
Save Matrixbirds/f6f030a638afa8a223eb3e03e3aca283 to your computer and use it in GitHub Desktop.
cmake example
cmake_minimum_required (VERSION 3.12.4) #
project (dns-server) # project name
set(CMAKE_C_COMPILER g++) # set c++ compiler
add_compile_options(-std=c++11) # set c++11 standard
include_directories(${LINK_DIR}) # include path
link_directories(${LINK_DIR}) # link path
link_libraries(ev) # link libs
add_executable(app-name main.cpp) # entry point
target_link_libraries(app-name ev) # link xx
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment