Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2011-02-15 21:33:05 +0300
committerCampbell Barton <ideasman42@gmail.com>2011-02-15 21:33:05 +0300
commit52c08fa4d351e37506f164dde77486af69b752ce (patch)
tree2589717977f58345ad87bab08dd4319db2c879c6 /build_files/cmake/packaging.cmake
parent884516357453e2530dc0a804cc14c6373e44e39c (diff)
CPack packaging support from Dan Eicher, tested to build redhat RPM's, a Mac bundle also defined.
Diffstat (limited to 'build_files/cmake/packaging.cmake')
-rw-r--r--build_files/cmake/packaging.cmake40
1 files changed, 40 insertions, 0 deletions
diff --git a/build_files/cmake/packaging.cmake b/build_files/cmake/packaging.cmake
new file mode 100644
index 00000000000..be2d4d76e90
--- /dev/null
+++ b/build_files/cmake/packaging.cmake
@@ -0,0 +1,40 @@
+set(PROJECT_DESCRIPTION "Blender is a very fast and versatile 3D modeller/renderer.")
+set(PROJECT_COPYRIGHT "Copyright (C) 2001-2011 Blender Foundation")
+set(PROJECT_CONTACT "foundation@blender.org")
+set(PROJECT_VENDOR "Blender Foundation")
+set(ORG_WEBSITE "www.blender.org")
+
+set(CPACK_SYSTEM_NAME ${CMAKE_SYSTEM_NAME})
+set(CPACK_PACKAGE_DESCRIPTION ${PROJECT_NAME_LONG})
+set(CPACK_PACKAGE_VENDOR ${PROJECT_VENDOR})
+set(CPACK_PACKAGE_CONTACT ${PROJECT_CONTACT})
+set(CPACK_RESOURCE_FILE_LICENSE "${CMAKE_SOURCE_DIR}/COPYING")
+set(CPACK_PACKAGE_INSTALL_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}")
+
+# Force Package Name
+set(CPACK_PACKAGE_FILE_NAME ${PROJECT_NAME}-${BLENDER_VERSION}-r${BUILD_REV}-${CPACK_SYSTEM_NAME}-${CMAKE_SYSTEM_PROCESSOR})
+
+# RPM packages
+include(build_files/cmake/RpmBuild.cmake)
+if(RPMBUILD_FOUND AND NOT WIN32)
+ set(CPACK_GENERATOR "RPM")
+ set(CPACK_SET_DESTDIR TRUE)
+ set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "${PROJECT_DESCRIPTION}")
+endif(RPMBUILD_FOUND AND NOT WIN32)
+
+# Mac Bundle
+if(APPLE)
+ set(CPACK_GENERATOR "DragNDrop")
+
+ #Libraries are bundled directly
+ set(CPACK_COMPONENT_LIBRARIES_HIDDEN TRUE)
+
+ # Bundle Properties
+ set(MACOSX_BUNDLE_BUNDLE_NAME blender)
+ set(MACOSX_BUNDLE_BUNDLE_VERSION ${BLENDER_VERSION})
+ set(MACOSX_BUNDLE_SHORT_VERSION_STRING ${BLENDER_VERSION})
+ set(MACOSX_BUNDLE_LONG_VERSION_STRING "Version ${BLENDER_VERSION}-r${BUILD_REV}")
+endif(APPLE)
+
+set(CPACK_PACKAGE_EXECUTABLES "blender")
+include(CPack)