Merge topic 'CPackRPM-protectATinFilename-reloaded'

1703e06 CPackRPM protect '@' character in filename processed in the spec file.
This commit is contained in:
Brad King 2013-07-15 09:30:29 -04:00 committed by CMake Topic Stage
commit 9f61436803
1 changed files with 10 additions and 0 deletions

View File

@ -876,6 +876,13 @@ if(CPACK_RPM_PACKAGE_DEBUG)
message("CPackRPM:Debug: CPACK_TEMPORARY_PACKAGE_FILE_NAME = ${CPACK_TEMPORARY_PACKAGE_FILE_NAME}") message("CPackRPM:Debug: CPACK_TEMPORARY_PACKAGE_FILE_NAME = ${CPACK_TEMPORARY_PACKAGE_FILE_NAME}")
endif() endif()
# protect @ in pathname in order to avoid their
# interpretation during the configure_file step
set(CPACK_RPM_INSTALL_FILES_LIST "${CPACK_RPM_INSTALL_FILES}")
set(PROTECTED_AT "@")
string(REPLACE "@" "\@PROTECTED_AT\@" CPACK_RPM_INSTALL_FILES "${CPACK_RPM_INSTALL_FILES_LIST}")
set(CPACK_RPM_INSTALL_FILES_LIST "")
# #
# USER generated/provided spec file handling. # USER generated/provided spec file handling.
# #
@ -982,6 +989,9 @@ else()
configure_file(${CPACK_RPM_BINARY_SPECFILE}.in ${CPACK_RPM_BINARY_SPECFILE} @ONLY) configure_file(${CPACK_RPM_BINARY_SPECFILE}.in ${CPACK_RPM_BINARY_SPECFILE} @ONLY)
endif() endif()
# remove AT protection
unset(PROTECTED_AT)
if(RPMBUILD_EXECUTABLE) if(RPMBUILD_EXECUTABLE)
# Now call rpmbuild using the SPECFILE # Now call rpmbuild using the SPECFILE
execute_process( execute_process(