CMakeLists.txt 350 B

123456789101112
  1. PROJECT( LinkLine )
  2. # Makes sure that the library order as specified by the user are
  3. # unchanged by dependency analysis, etc. libOne and libTwo are
  4. # dependent on each other. The link line should be -lOne -lTwo -lOne.
  5. ADD_LIBRARY( One One.c )
  6. ADD_LIBRARY( Two Two.c )
  7. LINK_LIBRARIES( One Two )
  8. ADD_EXECUTABLE( Exec Exec.c )
  9. LINK_LIBRARIES( One )