Skip to content

Instantly share code, notes, and snippets.

@kougazhang
Created December 16, 2021 00:41
Show Gist options
  • Save kougazhang/3486189968945d4f3e65dc9b51d0c738 to your computer and use it in GitHub Desktop.
Save kougazhang/3486189968945d4f3e65dc9b51d0c738 to your computer and use it in GitHub Desktop.
#clion
cmake_minimum_required(VERSION 3.15)
project(run_curl C)
set(CMAKE_C_STANDARD 99)
# 设置头文件
set(INC_DIR ./curl/include)
# 设置源码
set(LINK_DIR ./curl/lib)
include_directories(${INC_DIR})
link_directories(${LINK_DIR})
link_libraries(curl)
add_executable(run_curl main.c)
# 进行链接,注意要放到下面
target_link_libraries(run_curl curl)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment