Making a static lib target with variable dependencies with CMake -


so have static library can have bunch of settings turned on, depending on compiling configuration. have these settings pushed out import file:

cmake_minimum_required (version 2.8) message(status "***making foo***") add_definitions(-dfoo) include_directories("$env{foo_root}/includes") link_directories("$env{foo_root}/libraries") 

called with

cmake_minimum_required (version 2.8) project(a) if (foo) import(cmakelist.foo.txt) add_library(a static a.cpp) 

because library static, appears have populate these settings other project in chain exports them...is there way library own linking other static libraries, or way around make library shared?

edit: should add i'm building part of subdirs project


Comments

Popular posts from this blog

jquery - How can I dynamically add a browser tab? -

node.js - Getting the socket id,user id pair of a logged in user(s) -

keyboard - C++ GetAsyncKeyState alternative -