-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
audemard
committed
May 9, 2023
1 parent
1a349a8
commit 084d737
Showing
11 changed files
with
883 additions
and
437 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
cmake_minimum_required(VERSION 2.6) | ||
|
||
project(glucose) | ||
|
||
option(BUILD_SHARED_LIBS OFF "True for building shared object") | ||
|
||
set(CMAKE_CXX_FLAGS "-std=c++11") | ||
|
||
# Dependencies {{{ | ||
find_package(ZLIB REQUIRED) | ||
find_package(Threads REQUIRED) | ||
# }}} | ||
|
||
set(main_simp "simp/Main.cc") | ||
set(main_parallel "parallel/Main.cc") | ||
|
||
# Basic Library | ||
file(GLOB lib_srcs RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} mtl/*.cc core/*.cc simp/*.cc utils/*.cc) | ||
list(REMOVE_ITEM lib_srcs ${main_simp} ${main_parallel}) | ||
|
||
message(${lib_srcs}) | ||
|
||
# Parallel Library | ||
file(GLOB lib_parallel_srcs RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} parallel/*.cc) | ||
list(REMOVE_ITEM lib_parallel_srcs ${main_simp} ${main_parallel}) | ||
|
||
|
||
if(BUILD_SHARED_LIBS) | ||
set(lib_type "SHARED") | ||
else() | ||
set(lib_type "STATIC") | ||
endif() | ||
|
||
|
||
include_directories( | ||
${CMAKE_CURRENT_SOURCE_DIR} | ||
${ZLIB_INCLUDE_DIR}) | ||
|
||
link_libraries(${ZLIB_LIBRARY}) | ||
|
||
# base library | ||
add_library(glucose ${lib_type} ${lib_srcs}) | ||
|
||
add_executable(glucose-simp ${main_simp}) | ||
target_link_libraries(glucose-simp glucose) | ||
|
||
# PARALLEL STUFF: | ||
add_library(glucosep ${lib_type} ${lib_srcs} ${lib_parallel_srcs}) | ||
add_executable(glucose-syrup ${main_parallel}) | ||
target_link_libraries(glucose-syrup glucosep ${CMAKE_THREAD_LIBS_INIT}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.