This is the point where we say: just don't do in-source builds... :-)
Use separate directories for source and binary trees.

2 cents,
David

Brad King wrote:

Steve Johns wrote:

ELSE(CMAKE_CONFIGURATION_TYPES)
  # Handle single-configuration generators.
  CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/traps_config.txt
                 ${CMAKE_CURRENT_BINARY_DIR}/traps_config.txt COPYONLY)
ENDIF(CMAKE_CONFIGURATION_TYPES)

Be careful with this. For an in-source build this may not work. That is why my original example included a ".in" extension on the input file.


I don't really understand that part but I did try this, as an experiment


If the build directory and source directory are the same then this may try to copy the file onto itself. I think CMake may just not copy it but I'm not sure what would happen with the dependency when the file changed since it is never newer than itself.

-Brad
_______________________________________________
CMake mailing list
[email protected]
http://www.cmake.org/mailman/listinfo/cmake

_______________________________________________
CMake mailing list
[email protected]
http://www.cmake.org/mailman/listinfo/cmake

Reply via email to