- # 1) copy dll. Make it an action to occur after freeglut dll is
- # built, otherwise we'd have to hijack one of the demos above to do
- # it. Not sure whats cleaner really... MSVC only for now...
- GET_TARGET_PROPERTY(DEMO_OUTPUT_DIRECTORY CallbackMaker RUNTIME_OUTPUT_DIRECTORY)
- GET_TARGET_PROPERTY(LIB_OUTPUT_DIRECTORY freeglut LIBRARY_OUTPUT_DIRECTORY)
- if(MSVC AND BUILD_SHARED_LIBS)
- # $(Configuration) gets replaced by MSBuild (not by CMake) with
- # Debug, Release or whatever the current build is.
- ADD_CUSTOM_COMMAND(
- TARGET freeglut
- POST_BUILD
- COMMAND ${CMAKE_COMMAND} -E copy
- ${LIB_OUTPUT_DIRECTORY}/$(Configuration)/freeglut${CMAKE_SHARED_LIBRARY_SUFFIX}
- ${DEMO_OUTPUT_DIRECTORY}/$(Configuration)
- )
+ # 1) copy fractals.dat from freeglut/progs/demos/Fractals
+ IF(BUILD_SHARED_LIBS)
+ SET(Frac_target Fractals)
+ ELSE()
+ SET(Frac_target Fractals_static)