CMake添加以“ * .a”结尾的文件

时间:2018-11-15 20:48:53

标签: cmake

我的编译命令是:

cc -std=c11 -I include src/main.c lib/libflatccrt.a -o run_file

必须具有lib/libflatccrt.a的init才能进行编译。如何将此文件添加到CMake? 现在我的CMakeLists.txt是:

cmake_minimum_required (VERSION 2.6)
project (MyProject)
include_directories(include)
file(GLOB SOURCES "src/*.c")
add_executable(MyProject ${SOURCES})

0 个答案:

没有答案