1
1

When build from a tarball, there will be Linux-generated files that could not be used on Windows, so exclude them, and use the ones generated by CMake.

This commit was SVN r20858.
Этот коммит содержится в:
Shiqing Fan 2009-03-24 18:10:57 +00:00
родитель d0b50a2b9b
Коммит 36a813415d
2 изменённых файлов: 22 добавлений и 3 удалений

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

@ -53,7 +53,8 @@ STRING (REGEX MATCHALL "[a-zA-Z1-9_]+" OPAL_SUBDIRS ${OUTPUT})
FOREACH(OPAL_SUBDIR ${OPAL_SUBDIRS})
IF(NOT ${OPAL_SUBDIR} STREQUAL "mca" AND NOT ${OPAL_SUBDIR} STREQUAL "event"
AND NOT ${OPAL_SUBDIR} STREQUAL "include" AND NOT ${OPAL_SUBDIR} STREQUAL "tools")
AND NOT ${OPAL_SUBDIR} STREQUAL "libltdl" AND NOT ${OPAL_SUBDIR} STREQUAL "include"
AND NOT ${OPAL_SUBDIR} STREQUAL "tools")
IF(NOT ${OPAL_SUBDIR} STREQUAL "win32")
FILE(GLOB_RECURSE OPAL_${OPAL_SUBDIR}_FILES
@ -71,7 +72,8 @@ FOREACH(OPAL_SUBDIR ${OPAL_SUBDIRS})
SOURCE_GROUP("${OPAL_SUBDIR}" FILES ${OPAL_${OPAL_SUBDIR}_FILES})
ENDIF(NOT ${OPAL_SUBDIR} STREQUAL "mca" AND NOT ${OPAL_SUBDIR} STREQUAL "event"
AND NOT ${OPAL_SUBDIR} STREQUAL "include" AND NOT ${OPAL_SUBDIR} STREQUAL "tools")
AND NOT ${OPAL_SUBDIR} STREQUAL "libltdl" AND NOT ${OPAL_SUBDIR} STREQUAL "include"
AND NOT ${OPAL_SUBDIR} STREQUAL "tools")
ENDFOREACH(OPAL_SUBDIR ${OPAL_SUBDIRS})
@ -79,6 +81,16 @@ ENDFOREACH(OPAL_SUBDIR ${OPAL_SUBDIRS})
ADD_FLEX_FILE(OPAL_SOURCE_FILES ./util/keyval/keyval_lex.l opal_util_keyval_yy "${PROJECT_BINARY_DIR}/util/keyval/")
ADD_FLEX_FILE(OPAL_SOURCE_FILES ./util/show_help_lex.l opal_show_help_yy "${PROJECT_BINARY_DIR}/util/")
# Exclude the same flex files that generaged on Linux,
# which could be found in a tarball.
IF(EXISTS ${PROJECT_SOURCE_DIR}/util/keyval/keyval_lex.c)
LIST(REMOVE_ITEM OPAL_SOURCE_FILES "${PROJECT_SOURCE_DIR}/util/keyval/keyval_lex.c")
ENDIF(EXISTS ${PROJECT_SOURCE_DIR}/util/keyval/keyval_lex.c)
IF(EXISTS ${PROJECT_SOURCE_DIR}/util/keyval/show_help_lex.c)
LIST(REMOVE_ITEM OPAL_SOURCE_FILES "${PROJECT_SOURCE_DIR}/util/keyval/show_help_lex.c")
ENDIF(EXISTS ${PROJECT_SOURCE_DIR}/util/keyval/show_help_lex.c)
# Add Libtool support
IF(BUILD_SHARED_LIBS)
SET (LIBLTDL_FILES

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

@ -52,6 +52,13 @@ ADD_FLEX_FILE(ORTE_SOURCE_FILES "./util/hostfile/hostfile_lex.l" "orte_util_host
SET_SOURCE_FILES_PROPERTIES(${PROJECT_BINARY_DIR}/util/hostfile/hostfile_lex.c
PROPERTIES COMPILE_DEFINITIONS YY_NO_UNISTD_H)
# Exclude the same flex files that generaged on Linux,
# which could be found in a tarball.
IF(EXISTS ${PROJECT_SOURCE_DIR}/util/hostfile/hostfile_lex.c)
LIST(REMOVE_ITEM ORTE_SOURCE_FILES "${PROJECT_SOURCE_DIR}/util/hostfile/hostfile_lex.c")
ENDIF(EXISTS ${PROJECT_SOURCE_DIR}/util/hostfile/hostfile_lex.c)
INCLUDE (check_mca_subdirs)
SET (ORTE_SOURCE_FILES ${ORTE_SOURCE_FILES} ${MCA_FILES})
SET_SOURCE_FILES_PROPERTIES(${ORTE_SOURCE_FILES} PROPERTIES LANGUAGE CXX)