Commit 1b6bf12b authored by Vladislav Vaintroub's avatar Vladislav Vaintroub

Bug#58178: "make package" is broken with cmake 2.8.3

Problem:  with "make package" , many small packages are 
generated, one per CMake COMPONENT, instead of expected single
package. This is due to the new (in cmake 2.8.3) component-based 
install for archive( e.g ZIP,TGZ ) CPack generators.

See http://public.kitware.com/Bug/view.php?id=11452 for discussion.

Fix: use CPACK_MONOLITHIC_INSTALL=1 to enforce single package.
Reset this variable temporarily to 0 for  MSI creation  (MSI needs 
COMPONENTs)
parent 36fffdea
...@@ -331,6 +331,11 @@ ELSE() ...@@ -331,6 +331,11 @@ ELSE()
SET(CPACK_GENERATOR "TGZ") SET(CPACK_GENERATOR "TGZ")
ENDIF() ENDIF()
ADD_SUBDIRECTORY(packaging/WiX) ADD_SUBDIRECTORY(packaging/WiX)
# Create a single package with "make package"
# (see http://public.kitware.com/Bug/view.php?id=11452)
SET(CPACK_MONOLITHIC_INSTALL 1 CACHE INTERNAL "")
INCLUDE(CPack) INCLUDE(CPack)
IF(UNIX) IF(UNIX)
INSTALL(FILES Docs/mysql.info DESTINATION ${INSTALL_INFODIR} OPTIONAL) INSTALL(FILES Docs/mysql.info DESTINATION ${INSTALL_INFODIR} OPTIONAL)
......
...@@ -27,6 +27,12 @@ ENDIF() ...@@ -27,6 +27,12 @@ ENDIF()
SET(ENV{VS_UNICODE_OUTPUT}) SET(ENV{VS_UNICODE_OUTPUT})
# Switch off the monolithic install
EXECUTE_PROCESS(
COMMAND ${CMAKE_COMMAND} -DCPACK_MONOLITHIC_INSTALL=0 ${CMAKE_BINARY_DIR}
OUTPUT_QUIET
)
INCLUDE(${CMAKE_BINARY_DIR}/CPackConfig.cmake) INCLUDE(${CMAKE_BINARY_DIR}/CPackConfig.cmake)
IF(CPACK_WIX_CONFIG) IF(CPACK_WIX_CONFIG)
...@@ -318,3 +324,9 @@ EXECUTE_PROCESS( ...@@ -318,3 +324,9 @@ EXECUTE_PROCESS(
${EXTRA_LIGHT_ARGS} ${EXTRA_LIGHT_ARGS}
) )
# Switch monolithic install on again
EXECUTE_PROCESS(
COMMAND ${CMAKE_COMMAND} -DCPACK_MONOLITHIC_INSTALL=1 ${CMAKE_BINARY_DIR}
OUTPUT_QUIET
)
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment