From d01a29b0e06dd3959e2f48317dc9c0ffd9f244d2 Mon Sep 17 00:00:00 2001 From: Yuichi Nishiwaki Date: Sun, 2 Mar 2014 18:50:35 +0900 Subject: [PATCH] use file glob --- src/CMakeLists.txt | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index e80d7cc3..f5a61f25 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -1,10 +1,8 @@ +# flex find_package(FLEX REQUIRED) flex_target(scan src/scan.l ${PROJECT_SOURCE_DIR}/src/lex.yy.c COMPILE_FLAGS --header-file="src/lex.yy.h") -add_library(picrin SHARED - src/blob.c src/bool.c src/char.c src/codegen.c src/cont.c src/error.c - src/file.c src/gc.c src/init.c src/lib.c src/load.c src/macro.c - src/number.c src/pair.c src/port.c src/proc.c src/read.c src/state.c - src/string.c src/symbol.c src/system.c src/time.c src/var.c src/vector.c - src/vm.c src/write.c ${PROJECT_SOURCE_DIR}/src/lex.yy.c) +# build! +file(GLOB C_SOURCES ${PROJECT_SOURCE_DIR}/src/*.c) +add_library(picrin SHARED ${C_SOURCES} ${FLEX_scan_OUTPUTS}) target_link_libraries(picrin m xfile)