forked from KomputeProject/kompute
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request KomputeProject#338 from SlopeCraft/fix-find-package
Fix find_package, enable CPack and support clang-cl
- Loading branch information
Showing
12 changed files
with
246 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
# This file is for generating archive packages. | ||
# Up to v3.20, CPack supports .7z, .tar.bz2, .tar.gz, .tar.xz, .tar.z, .tar.zst and .zip | ||
# For details, see https://cmake.org/cmake/help/v3.20/cpack_gen/archive.html | ||
|
||
# The number of available cores on the machine will be used to compress | ||
# Only available for tar.xz. | ||
set(CPACK_ARCHIVE_THREADS 0) | ||
|
||
# Other variables: | ||
# set(CPACK_ARCHIVE_FILE_NAME) | ||
# set(CPACK_ARCHIVE_<component>_FILE_NAME) | ||
# set(CPACK_ARCHIVE_COMPONENT_INSTALL) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
# This file is for generating .deb packages for debian Linux | ||
|
||
# Here are all variables for deb generators. | ||
# Commented variables are not used, or their default values are ok. | ||
# Also see https://cmake.org/cmake/help/v3.20/cpack_gen/deb.html | ||
|
||
# Kompute depends on the vulkan development package | ||
set(CPACK_DEBIAN_PACKAGE_DEPENDS "libvulkan-dev") | ||
# set(CPACK_DEBIAN_<COMPONENT>_PACKAGE_DEPENDS) | ||
|
||
# The maintainer of this deb package | ||
set(CPACK_DEBIAN_PACKAGE_MAINTAINER "axsaucedo") | ||
|
||
|
||
# These variables may be used. | ||
# set(CPACK_DEBIAN_ARCHIVE_TYPE) # The archive format used for creating the Debian package. | ||
# set(CPACK_DEBIAN_COMPRESSION_TYPE) # Possible values: lzma, xz, bzip2, gzip. gzip by default. | ||
|
||
# Set Priority control field e.g. required, important, standard, optional, extra. Default value is optional. | ||
# set(CPACK_DEBIAN_PACKAGE_PRIORITY) | ||
# set(CPACK_DEBIAN_<COMPONENT>_PACKAGE_PRIORITY) | ||
|
||
# Predepends is like depends, but it forces dpkg to complete installation of predepend packages even before starting | ||
# the installation of our package. | ||
# set(CPACK_DEBIAN_PACKAGE_PREDEPENDS) | ||
# set(CPACK_DEBIAN_<COMPONENT>_PACKAGE_PREDEPENDS) | ||
|
||
# Recommend other packages after user installs our package | ||
# set(CPACK_DEBIAN_PACKAGE_RECOMMENDS) | ||
# set(CPACK_DEBIAN_<COMPONENT>_PACKAGE_RECOMMENDS) | ||
|
||
# Suggest other packages before user installs our package | ||
# set(CPACK_DEBIAN_PACKAGE_SUGGESTS) | ||
# set(CPACK_DEBIAN_<COMPONENT>_PACKAGE_SUGGESTS) | ||
|
||
# Packages that will be broken by our package | ||
# set(CPACK_DEBIAN_PACKAGE_BREAKS) | ||
# set(CPACK_DEBIAN_<COMPONENT>_PACKAGE_BREAKS) | ||
|
||
# Packages that conflicts with our package | ||
# set(CPACK_DEBIAN_PACKAGE_CONFLICTS) | ||
# set(CPACK_DEBIAN_<COMPONENT>_PACKAGE_CONFLICTS) | ||
|
||
# Used for virtual packages | ||
# set(CPACK_DEBIAN_PACKAGE_PROVIDES) | ||
# set(CPACK_DEBIAN_<COMPONENT>_PACKAGE_PROVIDES) | ||
|
||
# Packages that should be overwritten by our package | ||
# set(CPACK_DEBIAN_PACKAGE_REPLACES) | ||
# set(CPACK_DEBIAN_<COMPONENT>_PACKAGE_REPLACES) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
# This file is for generating .exe installer (NSIS) for Windows | ||
|
||
# Here are all variables for NSIS generators. | ||
# Commented variables are not used, or their default values are ok. | ||
# Also see https://cmake.org/cmake/help/v3.20/cpack_gen/nsis.html | ||
|
||
# The compressing method. Supported values: ZLIB, BZIP2 and LZMA | ||
set(CPACK_NSIS_COMPRESSOR "LZMA") | ||
|
||
# The name appears in Windows Apps & features in Control Panel | ||
set(CPACK_NSIS_DISPLAY_NAME "Kompute") | ||
|
||
# Ask the user whether to uninstall the previous versions | ||
set(CPACK_NSIS_ENABLE_UNINSTALL_BEFORE_INSTALL ON) | ||
|
||
# The icon of exe installer | ||
set(CPACK_NSIS_MUI_ICON "${CMAKE_SOURCE_DIR}/docs/images/kompute.ico") | ||
|
||
# The icon of exe uninstaller | ||
set(CPACK_NSIS_MUI_UNIICON ${CPACK_NSIS_MUI_ICON}) | ||
|
||
set(CPACK_NSIS_URL_INFO_ABOUT "https://kompute.cc") | ||
set(CPACK_NSIS_HELP_LINK "https://kompute.cc/overview/community.html") | ||
|
||
#set(CPACK_NSNS_CONTACT) | ||
#set(CPACK_NSIS_MUI_WELCOMEFINISHPAGE_BITMAP) | ||
#set(CPACK_NSIS_MUI_UNWELCOMEFINISHPAGE_BITMAP) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
# This file is to setup information for cpack | ||
# CPack is a package tool distributed with cmake. | ||
# For details about CPack, see https://cmake.org/cmake/help/book/mastering-cmake/chapter/Packaging%20With%20CPack.html | ||
|
||
|
||
# Common variables for all generators | ||
if (CMAKE_BUILD_TYPE STREQUAL "Debug") | ||
set(CPACK_PACKAGE_NAME "kompute-debug") | ||
else() | ||
set(CPACK_PACKAGE_NAME "kompute") | ||
endif () | ||
set(CPACK_PACKAGE_VENDOR "KomputeProject") | ||
set(CPACK_PACKAGE_DESCRIPTION "General purpose GPU compute framework built on Vulkan to support 1000s of cross vendor graphics cards (AMD, Qualcomm, NVIDIA & friends). Blazing fast, mobile-enabled, asynchronous and optimized for advanced GPU data processing usecases. Backed by the Linux Foundation. ") | ||
set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "GPGPU framework built on Vulkan.") | ||
set(CPACK_PACKAGE_HOMEPAGE_URL "https://kompute.cc/") | ||
|
||
# The license file used by GUI installers | ||
set(CPACK_RESOURCE_FILE_LICENSE "${CMAKE_SOURCE_DIR}/LICENSE") | ||
# The readme file used by GUI installers | ||
set(CPACK_RESOURCE_FILE_README "${CMAKE_SOURCE_DIR}/README.md") | ||
|
||
set(CPACK_PACKAGE_INSTALL_DIRECTORY "${PROJECT_NAME}\\\\${PROJECT_VERSION}") | ||
# set(CPACK_PACKAGE_ICON "${CMAKE_SOURCE_DIR}/docs/images/kompute.jpg") | ||
|
||
# Other common variables, in most cases they are not used, | ||
# otherwise their default values are ok. | ||
# Also see https://cmake.org/cmake/help/v3.20/module/CPack.html | ||
# | ||
# set(CPACK_PACKAGE_DIRECTORY) | ||
# set(CPACK_PACKAGE_VERSION ${PROJECT_VERSION}) | ||
# set(CPACK_PACKAGE_DIRECTORY) | ||
# set(CPACK_PACKAGE_VERSION_MAJOR) | ||
# set(CPACK_PACKAGE_VERSION_MINOR) | ||
# set(CPACK_PACKAGE_VERSION_PATCH) | ||
# set(CPACK_PACKAGE_DESCRIPTION_FILE) | ||
# set(CPACK_PACKAGE_FILE_NAME) | ||
# set(CPACK_PACKAGE_INSTALL_DIRECTORY) | ||
# set(CPACK_PACKAGE_ICON) | ||
# set(CPACK_PACKAGE_CHECKSUM) | ||
# set(CPACK_PROJECT_CONFIG_FILE) | ||
# set(CPACK_RESOURCE_FILE_LICENSE) | ||
# set(CPACK_RESOURCE_FILE_README) | ||
# set(CPACK_RESOURCE_FILE_WELCOME) | ||
# set(CPACK_MONOLITHIC_INSTALL) | ||
# set(CPACK_GENERATOR) | ||
# set(CPACK_OUTPUT_CONFIG_FILE) | ||
# set(CPACK_PACKAGE_EXECUTABLES) | ||
# set(CPACK_STRIP_FILES) | ||
# set(CPACK_VERBATIM_VARIABLES) | ||
# set(CPACK_THREADS) | ||
|
||
|
||
|
||
# Setup detailed package info for any cpack generator. | ||
# Each file correspond to a cpack generator | ||
file(GLOB config_files "${CMAKE_SOURCE_DIR}/cmake/cpack-configs/*.cmake") | ||
foreach (config_file ${config_files}) | ||
include(${config_file}) | ||
endforeach () | ||
|
||
# This should be include at last, and all unset cpack variables will be setup to their default value. | ||
include(CPack) |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters