diff options
author | Dan Eicher <dan@eu.phorio.us> | 2014-02-13 00:39:23 +0400 |
---|---|---|
committer | Dan Eicher <dan@eu.phorio.us> | 2014-02-13 00:45:36 +0400 |
commit | 6ad9941c74c5e6c5a1fe519ed1dba2561528d0fe (patch) | |
tree | 786c3c7c10de22597df75180e98c1e1ac804c12c | |
parent | a397009181c8fa76501f09029d7f308e4961df51 (diff) |
Add the date to the CPack rpm package version
Updating rpms built from 'make package' has issues using the git hash since it isn't in a set order like svn commits, this lets it use the date to determine if the rpm is newer than the installed version.
Also updates the license text.
-rw-r--r-- | build_files/cmake/packaging.cmake | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/build_files/cmake/packaging.cmake b/build_files/cmake/packaging.cmake index ad309b0a0c8..735d3fd819e 100644 --- a/build_files/cmake/packaging.cmake +++ b/build_files/cmake/packaging.cmake @@ -35,18 +35,19 @@ set(BUILD_REV ${MY_WC_HASH}) # Force Package Name -set(CPACK_PACKAGE_FILE_NAME ${PROJECT_NAME}-${MAJOR_VERSION}.${MINOR_VERSION}.${PATCH_VERSION}-1.${BUILD_REV}-${CMAKE_SYSTEM_PROCESSOR}) +execute_process(COMMAND date "+%Y%m%d" OUTPUT_VARIABLE CPACK_DATE OUTPUT_STRIP_TRAILING_WHITESPACE) +set(CPACK_PACKAGE_FILE_NAME ${PROJECT_NAME}-${MAJOR_VERSION}.${MINOR_VERSION}.${PATCH_VERSION}-git${CPACK_DATE}.${BUILD_REV}-${CMAKE_SYSTEM_PROCESSOR}) if(CMAKE_SYSTEM_NAME MATCHES "Linux") # RPM packages include(build_files/cmake/RpmBuild.cmake) if(RPMBUILD_FOUND AND NOT WIN32) set(CPACK_GENERATOR "RPM") - set(CPACK_RPM_PACKAGE_RELEASE "1.${BUILD_REV}") + set(CPACK_RPM_PACKAGE_RELEASE "git${CPACK_DATE}.${BUILD_REV}") set(CPACK_SET_DESTDIR "true") set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "${PROJECT_DESCRIPTION}") set(CPACK_PACKAGE_RELOCATABLE "false") - set(CPACK_RPM_PACKAGE_LICENSE "GPLv2") + set(CPACK_RPM_PACKAGE_LICENSE "GPLv2+ and Apache 2.0") set(CPACK_RPM_PACKAGE_GROUP "Amusements/Multimedia") set(CPACK_RPM_USER_BINARY_SPECFILE "${CMAKE_SOURCE_DIR}/build_files/package_spec/rpm/blender.spec.in") endif() |