]> de.git.xonotic.org Git - xonotic/netradiant.git/blobdiff - cmake/scripts/package.cmake
Add CPack targets package and package_source
[xonotic/netradiant.git] / cmake / scripts / package.cmake
diff --git a/cmake/scripts/package.cmake b/cmake/scripts/package.cmake
new file mode 100644 (file)
index 0000000..be530ec
--- /dev/null
@@ -0,0 +1,16 @@
+set(CPACK_PACKAGE_NAME "NetRadiant")
+set(CPACK_PACKAGE_VERSION_MAJOR "${NetRadiant_VERSION_MAJOR}")
+set(CPACK_PACKAGE_VERSION_MINOR "${NetRadiant_VERSION_MINOR}")
+set(CPACK_PACKAGE_VERSION_PATCH "${NetRadiant_VERSION_PATCH}")
+
+# binary: --target package
+set(CPACK_GENERATOR "ZIP")
+set(CPACK_STRIP_FILES 1)
+
+# source: --target package_source
+set(CPACK_SOURCE_GENERATOR "ZIP")
+set(CPACK_SOURCE_IGNORE_FILES "/\\\\.git/;/build/;/install/")
+
+# configure
+include(InstallRequiredSystemLibraries)
+include(CPack)