[CMake] My nomination for least helpful CMake Error Message (CONFIGURE_FILE issue)

kent williams nkwmailinglists at gmail.com
Mon Nov 23 12:11:49 EST 2009


CMake Error at common/CMakeLists.txt:83 (CONFIGURE_FILE):
   configure_file Problem configuring file

The issue being the CONFIGURE_FILE command:

PROJECT(SGICOMMONLIB)
#
# other stuff removed for brevity.
#
SET(DIRNAME pixmaps)
FILE(GLOB DEFAULT_CONFIG_FILES "*.xbm" ".xpm" ".gif" "*.tif" "*.pal" )
FOREACH(MODULE ${DEFAULT_CONFIG_FILES} )
  GET_FILENAME_COMPONENT(CURR_FILENAME ${MODULE} NAME)
  CONFIGURE_FILE(${SGICOMMONLIB_SOURCE_DIR}/${CURR_FILENAME}
${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/${DIRNAME}/${CURR_FILENAME} COPYONLY
IMMEDIATE )
  INSTALL(FILES ${SGICOMMONLIB_SOURCE_DIR}/${DIRNAME}/${CURR_FILENAME}
                DESTINATION bin/${DIRNAME})
ENDFOREACH(MODULE)


-----------------------------------------------------------------------------------------------
I think the reason I'm having this trouble is that
CMAKE_RUNTIME_OUTPUT_DIRECTORY isn't defined.  But the error message
doesn't say anything useful.


More information about the CMake mailing list