diff options
-rw-r--r-- | cmake/Internal/CPack/CPackRPM.cmake | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/cmake/Internal/CPack/CPackRPM.cmake b/cmake/Internal/CPack/CPackRPM.cmake index a1040a0161f..d16965be1e9 100644 --- a/cmake/Internal/CPack/CPackRPM.cmake +++ b/cmake/Internal/CPack/CPackRPM.cmake @@ -18,7 +18,8 @@ macro(restore WHAT) endmacro() foreach (WHAT SUMMARY DESCRIPTION) - if(NOT CPACK_RPM_${CPACK_RPM_PACKAGE_COMPONENT}_PACKAGE_${WHAT}) + if(CPACK_RPM_PACKAGE_COMPONENT AND + NOT CPACK_RPM_${CPACK_RPM_PACKAGE_COMPONENT}_PACKAGE_${WHAT}) message(FATAL_ERROR "CPACK_RPM_${CPACK_RPM_PACKAGE_COMPONENT}_PACKAGE_${WHAT} is not defined") endif() endforeach() |