| View Issue Details [ Jump to Notes ] | [ Print ] | ||||||||
| ID | Project | Category | View Status | Date Submitted | Last Update | ||||
| 0015516 | CMake | CPack | public | 2015-04-16 04:12 | 2015-11-02 09:13 | ||||
| Reporter | Dorian | ||||||||
| Assigned To | Nils Gladitz | ||||||||
| Priority | normal | Severity | minor | Reproducibility | always | ||||
| Status | closed | Resolution | no change required | ||||||
| Platform | OS | Windows | OS Version | 7 | |||||
| Product Version | CMake 3.2.1 | ||||||||
| Target Version | Fixed in Version | ||||||||
| Summary | 0015516: Wix with CPACK_PROJECT_CONFIG_FILE = wrong file name. | ||||||||
| Description | CPACK_PACKAGE_VERSION_* variables set in CPACK_PROJECT_CONFIG_FILE are ignored in output file name. It always gives me installer-name-0.1.1-win32.msi | ||||||||
| Steps To Reproduce | Add --- CMakeLists.txt --- set(CPACK_PROJECT_CONFIG_FILE ${CMAKE_BINARY_DIR}/CPackOptions.cmake) --- CMakeLists.txt end --- --- ${CMAKE_BINARY_DIR}/CPackOptions.cmake (generated by configure_file): SET(CPACK_PACKAGE_VERSION 1.9.50.65535) SET(CPACK_PACKAGE_VERSION_MAJOR 1) SET(CPACK_PACKAGE_VERSION_MINOR 9) SET(CPACK_PACKAGE_VERSION_PATCH 50) message("CPACK_PACKAGE_VERSION ${CPACK_PACKAGE_VERSION}") message("CPACK_PACKAGE_VERSION_MAJOR ${CPACK_PACKAGE_VERSION_MAJOR}") message("CPACK_PACKAGE_VERSION_MINOR ${CPACK_PACKAGE_VERSION_MINOR}") message("CPACK_PACKAGE_VERSION_PATCH ${CPACK_PACKAGE_VERSION_PATCH}") --- CPackOptions.cmake end Pack message output: ... 4> CPACK_PACKAGE_VERSION 1.9.50.65535 4> CPACK_PACKAGE_VERSION_MAJOR 1 4> CPACK_PACKAGE_VERSION_MINOR 9 4> CPACK_PACKAGE_VERSION_PATCH 50 ... 4> CPack: - package: D:/proj-build/proj-name-0.1.1-win32.msi generated. | ||||||||
| Additional Information | Note that version is displayed ok in ControlPanel->Add/Remove Programs, so it seems that only filename is a problem | ||||||||
| Tags | No tags attached. | ||||||||
| Attached Files | |||||||||
| Relationships | |
| Relationships |
| Notes | |
|
(0038529) Nils Gladitz (developer) 2015-04-16 06:36 |
The filename depends on the value of CPACK_PACKAGE_FILE_NAME which is implicitly created (if not already set) by the CPack module at configuration time. Your currently generated CPackConfig.cmake will contain e.g. SET(CPACK_PACKAGE_FILE_NAME "proj-name-0.1.1-win32") which cpack then bases the output filename on. To get the desired behaviour your CPackOptions.cmake will have to set CPACK_PACKAGE_FILE_NAME as well. |
|
(0038530) Dorian (reporter) 2015-04-16 08:10 |
Yes its true. I didn't know about CPACK_PACKAGE_FILE_NAME. I was expecting that CPACK_PACKAGE_FILE_NAME is generated implicitly by combining CPACK_PACKAGE_NAME and version variables during CPACK_PROJECT_CONFIG_FILE processing, not in cmake generate step. Than you Nils for quick and helpful answer. |
|
(0038531) Nils Gladitz (developer) 2015-04-16 08:22 |
Thanks. Resolving with "no change required". |
|
(0039774) Robert Maynard (manager) 2015-11-02 09:13 |
Closing resolved issues that have not been updated in more than 4 months. |
| Notes |
| Issue History | |||
| Date Modified | Username | Field | Change |
| 2015-04-16 04:12 | Dorian | New Issue | |
| 2015-04-16 06:36 | Nils Gladitz | Note Added: 0038529 | |
| 2015-04-16 08:10 | Dorian | Note Added: 0038530 | |
| 2015-04-16 08:22 | Nils Gladitz | Note Added: 0038531 | |
| 2015-04-16 08:22 | Nils Gladitz | Status | new => resolved |
| 2015-04-16 08:22 | Nils Gladitz | Resolution | open => no change required |
| 2015-04-16 08:22 | Nils Gladitz | Assigned To | => Nils Gladitz |
| 2015-11-02 09:13 | Robert Maynard | Note Added: 0039774 | |
| 2015-11-02 09:13 | Robert Maynard | Status | resolved => closed |
| Issue History |
| Copyright © 2000 - 2018 MantisBT Team |