<html><head><style type="text/css"><!-- DIV {margin:0px;} --></style></head><body><div style="font-family:times new roman,new york,times,serif;font-size:12pt"><div>Hi<br><br></div><div style="font-family: times new roman,new york,times,serif; font-size: 12pt;">I have a problem when cmake builds the objects for shared library.<br><br>I have the following in my cmaklists.txt<br><br>set(SIMULATOR_SOURCES circuit.cc matrix.cc plot.cc sources.cc <br> sparse.cc btzdense.cc element.cc util.cc parse.c <br> netlist_parse.y netlist_lex.l circuit_step.cc zmatrix.cc <br> hash_key.cc zsparse.cc zbtzdense.cc mtutil.cc)<br><br>add_library(simulator SHARED ${SIMULATOR_SOURCES})<br><br>set_target_properties(simulator PROPERTIES LINK_FLAGS "-I../sparse-libs/include")<br>target_link_libraries(simulator ${LIBS} "models/libmodels.a ../sparse-libs/libsparse.a") <br><br><br>However, target_link_libraries does not include
the flags when building the objects. it only does when building the library. And I do not want to add (-I../sparse-libs/include) for all my objects. <br><br>Thanks for your help<br><br></div>
</div><br></body></html>