Commit 3c7d4840 authored by Matt Arsenault's avatar Matt Arsenault Committed by Matt Arsenault

Fix NSIS installer errors, MinGW build.

The CPack NSIS installer was in a state where it would always give a
useless error. I think it was using stuff intended for running cpack
separately from cmake.
parent a1d6a222
...@@ -394,6 +394,11 @@ foreach(source ${rc-sources}) ...@@ -394,6 +394,11 @@ foreach(source ${rc-sources})
list(APPEND sources ${CMAKE_CURRENT_BINARY_DIR}/${source}) list(APPEND sources ${CMAKE_CURRENT_BINARY_DIR}/${source})
endforeach() endforeach()
foreach(source ${rc-sources})
list(APPEND sources ${CMAKE_BINARY_DIR}/${source})
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/src/${source}.in ${CMAKE_CURRENT_BINARY_DIR}/${source})
endforeach()
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/builds/cmake/platform.hpp.in ${CMAKE_CURRENT_BINARY_DIR}/platform.hpp) configure_file(${CMAKE_CURRENT_SOURCE_DIR}/builds/cmake/platform.hpp.in ${CMAKE_CURRENT_BINARY_DIR}/platform.hpp)
list(APPEND sources ${CMAKE_CURRENT_BINARY_DIR}/platform.hpp) list(APPEND sources ${CMAKE_CURRENT_BINARY_DIR}/platform.hpp)
...@@ -516,8 +521,6 @@ set(perf-tools local_lat ...@@ -516,8 +521,6 @@ set(perf-tools local_lat
inproc_lat inproc_lat
inproc_thr) inproc_thr)
#get_target_property
if(NOT CMAKE_BUILD_TYPE STREQUAL "Debug") # Why? if(NOT CMAKE_BUILD_TYPE STREQUAL "Debug") # Why?
foreach(perf-tool ${perf-tools}) foreach(perf-tool ${perf-tools})
add_executable(${perf-tool} perf/${perf-tool}.cpp) add_executable(${perf-tool} perf/${perf-tool}.cpp)
...@@ -535,7 +538,7 @@ if(NOT CMAKE_BUILD_TYPE STREQUAL "Debug") # Why? ...@@ -535,7 +538,7 @@ if(NOT CMAKE_BUILD_TYPE STREQUAL "Debug") # Why?
else() else()
install(TARGETS ${perf-tool} install(TARGETS ${perf-tool}
RUNTIME DESTINATION bin RUNTIME DESTINATION bin
COMPONENT PerfTools) COMPONENT PerfTools)
endif() endif()
endforeach() endforeach()
endif() endif()
...@@ -560,7 +563,7 @@ if(MSVC) ...@@ -560,7 +563,7 @@ if(MSVC)
else() else()
install(TARGETS libzmq install(TARGETS libzmq
RUNTIME DESTINATION bin RUNTIME DESTINATION bin
PUBLIC_HEADER DESTINATION include #PUBLIC_HEADER DESTINATION include
COMPONENT Runtime) COMPONENT Runtime)
endif() endif()
else() else()
...@@ -605,25 +608,9 @@ if(MSVC) ...@@ -605,25 +608,9 @@ if(MSVC)
include(InstallRequiredSystemLibraries) include(InstallRequiredSystemLibraries)
if(CMAKE_CL_64) if(CMAKE_CL_64)
set(CPACK_NSIS_DISPLAY_NAME "ZeroMQ ${ZMQ_VERSION_MAJOR}.${ZMQ_VERSION_MINOR}.${ZMQ_VERSION_PATCH}(x64)") set(arch_name "x64")
set(CPACK_PACKAGE_FILE_NAME "ZeroMQ-${ZMQ_VERSION_MAJOR}.${ZMQ_VERSION_MINOR}.${ZMQ_VERSION_PATCH}-x64")
set(CPACK_INSTALL_CMAKE_PROJECTS
"${CMAKE_SOURCE_DIR}/build/x64/v110;ZeroMQ;ALL;/"
"${CMAKE_SOURCE_DIR}/debug/x64/v110;ZeroMQ;ALL;/"
"${CMAKE_SOURCE_DIR}/build/x64/v100;ZeroMQ;ALL;/"
"${CMAKE_SOURCE_DIR}/debug/x64/v100;ZeroMQ;ALL;/"
"${CMAKE_SOURCE_DIR}/build/x64/v90;ZeroMQ;ALL;/"
"${CMAKE_SOURCE_DIR}/debug/x64/v90;ZeroMQ;ALL;/")
else() else()
set(CPACK_NSIS_DISPLAY_NAME "ZeroMQ ${ZMQ_VERSION_MAJOR}.${ZMQ_VERSION_MINOR}.${ZMQ_VERSION_PATCH}") set(arch_name "x86")
set(CPACK_PACKAGE_FILE_NAME "ZeroMQ-${ZMQ_VERSION_MAJOR}.${ZMQ_VERSION_MINOR}.${ZMQ_VERSION_PATCH}-x86")
set(CPACK_INSTALL_CMAKE_PROJECTS
"${CMAKE_SOURCE_DIR}/build/x86/v110;ZeroMQ;ALL;/"
"${CMAKE_SOURCE_DIR}/debug/x86/v110;ZeroMQ;ALL;/"
"${CMAKE_SOURCE_DIR}/build/x86/v100;ZeroMQ;ALL;/"
"${CMAKE_SOURCE_DIR}/debug/x86/v100;ZeroMQ;ALL;/"
"${CMAKE_SOURCE_DIR}/build/x86/v90;ZeroMQ;ALL;/"
"${CMAKE_SOURCE_DIR}/debug/x86/v90;ZeroMQ;ALL;/")
endif() endif()
set(CPACK_NSIS_DISPLAY_NAME "ZeroMQ ${ZMQ_VERSION_MAJOR}.${ZMQ_VERSION_MINOR}.${ZMQ_VERSION_PATCH}(${arch_name})") set(CPACK_NSIS_DISPLAY_NAME "ZeroMQ ${ZMQ_VERSION_MAJOR}.${ZMQ_VERSION_MINOR}.${ZMQ_VERSION_PATCH}(${arch_name})")
...@@ -674,35 +661,35 @@ if(MSVC) ...@@ -674,35 +661,35 @@ if(MSVC)
include(CPack) include(CPack)
cpack_add_component_group(Development cpack_add_component_group(Development
DISPLAY_NAME "ZeroMQ software development kit" DISPLAY_NAME "ZeroMQ software development kit"
EXPANDED) EXPANDED)
cpack_add_component(PerfTools cpack_add_component(PerfTools
DISPLAY_NAME "ZeroMQ performance tools" DISPLAY_NAME "ZeroMQ performance tools"
INSTALL_TYPES FullInstall DevInstall) INSTALL_TYPES FullInstall DevInstall)
cpack_add_component(SourceCode cpack_add_component(SourceCode
DISPLAY_NAME "ZeroMQ source code" DISPLAY_NAME "ZeroMQ source code"
DISABLED DISABLED
INSTALL_TYPES FullInstall) INSTALL_TYPES FullInstall)
cpack_add_component(SDK cpack_add_component(SDK
DISPLAY_NAME "ZeroMQ headers and libraries" DISPLAY_NAME "ZeroMQ headers and libraries"
INSTALL_TYPES FullInstall DevInstall INSTALL_TYPES FullInstall DevInstall
GROUP Development) GROUP Development)
if(WITH_DOC) if(WITH_DOC)
cpack_add_component(RefGuide cpack_add_component(RefGuide
DISPLAY_NAME "ZeroMQ reference guide" DISPLAY_NAME "ZeroMQ reference guide"
INSTALL_TYPES FullInstall DevInstall INSTALL_TYPES FullInstall DevInstall
GROUP Development) GROUP Development)
endif(WITH_DOC) endif()
cpack_add_component(Runtime cpack_add_component(Runtime
DISPLAY_NAME "ZeroMQ runtime files" DISPLAY_NAME "ZeroMQ runtime files"
REQUIRED REQUIRED
INSTALL_TYPES FullInstall DevInstall MinInstall) INSTALL_TYPES FullInstall DevInstall MinInstall)
cpack_add_install_type(FullInstall cpack_add_install_type(FullInstall
DISPLAY_NAME "Full install, including source code") DISPLAY_NAME "Full install, including source code")
cpack_add_install_type(DevInstall cpack_add_install_type(DevInstall
DISPLAY_NAME "Developer install, headers and libraries") DISPLAY_NAME "Developer install, headers and libraries")
cpack_add_install_type(MinInstall cpack_add_install_type(MinInstall
DISPLAY_NAME "Minimal install, runtime only") DISPLAY_NAME "Minimal install, runtime only")
endif() endif()
# Export this for library to help build this as a sub-project # Export this for library to help build this as a sub-project
......
...@@ -12,7 +12,12 @@ find_program(ASCIIDOC_EXECUTABLE asciidoc asciidoc.py ...@@ -12,7 +12,12 @@ find_program(ASCIIDOC_EXECUTABLE asciidoc asciidoc.py
"$ENV{PROGRAMFILES}/asciidoc" "$ENV{PROGRAMFILES}/asciidoc"
"$ENV{PROGRAMFILES(X86)}/asciidoc") "$ENV{PROGRAMFILES(X86)}/asciidoc")
find_program(A2X_EXECUTABLE a2x) find_program(A2X_EXECUTABLE a2x
PATHS "$ENV{ASCIIDOC_ROOT}"
"$ENV{PROGRAMW6432}/asciidoc"
"$ENV{PROGRAMFILES}/asciidoc"
"$ENV{PROGRAMFILES(X86)}/asciidoc")
include(FindPackageHandleStandardArgs) include(FindPackageHandleStandardArgs)
find_package_handle_standard_ARGS(AsciiDoc REQUIRED_VARS ASCIIDOC_EXECUTABLE) find_package_handle_standard_ARGS(AsciiDoc REQUIRED_VARS ASCIIDOC_EXECUTABLE)
......
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