1
1

put all generated files in the binary directory.

This commit was SVN r21160.
Этот коммит содержится в:
Shiqing Fan 2009-05-05 13:50:48 +00:00
родитель db096d7d3a
Коммит c3380e9df2
2 изменённых файлов: 6 добавлений и 5 удалений

Просмотреть файл

@ -1588,6 +1588,7 @@ ENDIF(HAVE_PTRDIFF_T)
OPTION(OMPI_ENABLE_DLOPEN_SUPPORT "Whether to include support for libltdl or not" OFF)
MARK_AS_ADVANCED(OMPI_ENABLE_DLOPEN_SUPPORT)
IF(OMPI_ENABLE_DLOPEN_SUPPORT)
SET(BUILD_SHARED_LIBS TRUE)
INCLUDE(FIND_LIBLTDL)
FIND_LIBLTDL()
IF(LIBLTDL_FOUND)

Просмотреть файл

@ -95,13 +95,13 @@ ENDIF(EXISTS ${PROJECT_SOURCE_DIR}/util/keyval/show_help_lex.c)
IF(OMPI_WANT_LIBLTDL)
# if we want libltdl, that means ltdl.h and ltdl.c has been found,
# just copy them into the source tree for compiling.
CONFIGURE_FILE("${LIBLTDL_PATH}/ltdl.c" ${CMAKE_CURRENT_SOURCE_DIR}/libltdl/ltdl.c COPYONLY)
CONFIGURE_FILE("${LIBLTDL_PATH}/ltdl.h" ${CMAKE_CURRENT_SOURCE_DIR}/libltdl/ltdl.h COPYONLY)
CONFIGURE_FILE("${LIBLTDL_PATH}/ltdl.c" ${CMAKE_CURRENT_BINARY_DIR}/libltdl/ltdl.c COPYONLY)
CONFIGURE_FILE("${LIBLTDL_PATH}/ltdl.h" ${CMAKE_CURRENT_BINARY_DIR}/libltdl/ltdl.h COPYONLY)
# insert "#include opal_config.h" into ltdl.c, otherwise, it won't compile.
FILE(READ ${CMAKE_CURRENT_SOURCE_DIR}/libltdl/ltdl.c LTDL_C_PART1 LIMIT 1183)
FILE(READ ${CMAKE_CURRENT_SOURCE_DIR}/libltdl/ltdl.c LTDL_C_PART2 OFFSET 1183)
FILE(WRITE ${CMAKE_CURRENT_SOURCE_DIR}/libltdl/ltdl.c
FILE(READ ${CMAKE_CURRENT_BINARY_DIR}/libltdl/ltdl.c LTDL_C_PART1 LIMIT 1183)
FILE(READ ${CMAKE_CURRENT_BINARY_DIR}/libltdl/ltdl.c LTDL_C_PART2 OFFSET 1183)
FILE(WRITE ${CMAKE_CURRENT_BINARY_DIR}/libltdl/ltdl.c
"${LTDL_C_PART1}" "\n#include \"opal_config.h\"\n" "${LTDL_C_PART2}")
SET (LIBLTDL_FILES libltdl/ltdl.c libltdl/ltdl.h)