diff options
author | lazydodo <github@lazydodo.com> | 2016-09-06 16:21:23 +0300 |
---|---|---|
committer | lazydodo <github@lazydodo.com> | 2016-09-06 16:22:04 +0300 |
commit | abd54f1ed2a5706a394e31ef00f89dee19d55e87 (patch) | |
tree | f72995b80af80191aa18f872654afd92390c0ce3 /build_files/cmake | |
parent | b40d1c1903207f1c5ba1b7cb3050b4a836c2171d (diff) |
[cmake/cpack] allow override of package name
Cpack generates a standard filename with git information in it, which might not always be wanted for release builds, this patch adds an option to override that default filename.
Reviewers: sergey, juicyfruit
Reviewed By: juicyfruit
Differential Revision: https://developer.blender.org/D2199
Diffstat (limited to 'build_files/cmake')
-rw-r--r-- | build_files/cmake/packaging.cmake | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/build_files/cmake/packaging.cmake b/build_files/cmake/packaging.cmake index bc1d64f7494..1563331387f 100644 --- a/build_files/cmake/packaging.cmake +++ b/build_files/cmake/packaging.cmake @@ -48,7 +48,11 @@ else(MSVC) set(PACKAGE_ARCH ${CMAKE_SYSTEM_PROCESSOR}) endif() -set(CPACK_PACKAGE_FILE_NAME ${PROJECT_NAME_LOWER}-${MAJOR_VERSION}.${MINOR_VERSION}.${PATCH_VERSION}-git${CPACK_DATE}.${BUILD_REV}-${PACKAGE_ARCH}) +if (CPACK_OVERRIDE_PACKAGENAME) + set(CPACK_PACKAGE_FILE_NAME ${CPACK_OVERRIDE_PACKAGENAME}-${PACKAGE_ARCH}) +else() + set(CPACK_PACKAGE_FILE_NAME ${PROJECT_NAME_LOWER}-${MAJOR_VERSION}.${MINOR_VERSION}.${PATCH_VERSION}-git${CPACK_DATE}.${BUILD_REV}-${PACKAGE_ARCH}) +endif() if(CMAKE_SYSTEM_NAME MATCHES "Linux") # RPM packages |