Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions bamboo/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@

file(GLOB BAMBOO_CORE_GO_SRCS bamboo-core/*.go)
file(GLOB BAMBOO_GO_SRCS *.go)

Expand All @@ -9,11 +8,14 @@ add_custom_command(OUTPUT bamboo-core.a bamboo-core.h
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
COMMAND env CGO_CFLAGS="-fPIC" CGO_LDFLAGS="-fPIC" go build
-buildmode=c-archive
-buildvcs=false
"-ldflags=-s -w"
-v -o "${CMAKE_CURRENT_BINARY_DIR}/bamboo-core.a"
${BAMBOO_GO_SRCS})
add_custom_target(bamboo-core DEPENDS bamboo-core.a)
.
)

# Add a custom target for the library.
add_custom_target(bamboo-core DEPENDS bamboo-core.a)
add_library(Bamboo::Core UNKNOWN IMPORTED GLOBAL)
add_dependencies(Bamboo::Core bamboo-core)
set_target_properties(Bamboo::Core PROPERTIES
Expand Down
Loading