Repository navigation
dev.modules
This command used to pick a build scheme for current project and called before hunter_download in project/<ProjectName>/hunter.cmake module:
hunter_pick_scheme(
DEFAULT default_scheme_name # this scheme will be used by default
IPHONEOS ios_scheme_name # this scheme will be used to build for iOS platform
WINDOWS windows_scheme # this scheme will be used on windows
)Examples:
# This is regular cmake project
hunter_pick_scheme(DEFAULT url_sha1_cmake)# This is no-install (unpack only) project
hunter_pick_scheme(DEFAULT url_sha1_unpack)# Boost bjam
hunter_pick_scheme(
DEFAULT url_sha1_boost_library
IPHONEOS url_sha1_boost_ios_library
)# OpenSSL
hunter_pick_scheme(
DEFAULT url_sha1_openssl
IPHONEOS url_sha1_openssl_ios
WINDOWS url_sha1_openssl_windows
)This command will choose which version of package to build exactly:
hunter_config(
<PackageName>
VERSION 1.2.8-hunter # Version from "project/<ProjectName>/hunter.cmake"
CMAKE_ARGS OPTION1=OFF OPTION2=ON # Arguments that will be forwarded to CMake build command (optional)
)OPTION1=OFF and OPTION2=ON will be used to build your third-party package. This is similar to ExternalProject_Add command sub-option CMAKE_ARGS. In the case above Hunter-engine will build this package something like this:
> cmake -H. -B_builds -DOPTION1=OFF -DOPTION2=ON
> cmake --build _builds --target installThis command will give permission to package so it can be saved in cache. Usually each root <hunter-id>/<config-id>/<toolchain-id> directory can be shared between unlimited number of projects but need to build from scratch every time. Binary cache allow to save builds in cache directory and share this cache between several <hunter-id>/<config-id>/<toolchain-id> roots. Note that all dependencies of this package and the package itself must be relocatable.
# cmake/project/TIFF/hunter.cmake
hunter_cacheable(TIFF)
hunter_download(PACKAGE_NAME TIFF)Messages in logs:
- successful build of cacheable package:
-- [hunter] Cache saved: /.../.hunter/_Base/Cache/raw/752c8b96f5613ee865c0cda5f3306d67e463a977.tar.bz2
- successful cache look-up (reuse/unpacked from cache):
-- [hunter] Cache HIT: TIFF
- Source
- Usage examples:
- PACKAGE_NAME
- PACKAGE_COMPONENT
- PACKAGE_DEPENDS_ON
- PACKAGE_INTERNAL_DEPS_ID
Final stage of adding package to the project. This command will read all package related variables and start the real download/build (or cache unpack) instructions. Name of package and component set by PACKAGE_NAME and PACKAGE_COMPONENT. Option PACKAGE_DEPENDS_ON used to set explicit dependency (this is a workaround for non-hunterized packages; note that dependencies tracked automatically in Hunter). Option PACKAGE_INTERNAL_DEPS_ID is an identifier of internal files that build the package (like build scheme or additional scripts). Usually there is no need to set this variable, take a look at this issues if you want to understand the meaning of it: binaries cache and correct reusing of cache directory.
Feel free to open new issue if you want to ask any questions.
- HOME
- Packages
- Android-Apk
- Android-Modules
- Android-SDK
- ArrayFire
- Assimp
- Async++
- Avahi
- BZip2
- Boost
- Boost.compute
- Boost.process
- CLAPACK
- Comet
- CppNetlib.URI
- CsvParserCPlusPlus
- Eigen
- Expat
- GPUImage
- GSL
- GTest
- GMock
- Igloo
- IntSizeof
- Jpeg
- JsonSpirit
- LLVM (Clang)
- Leathers
- Libssh2
- Lua
- MySQL-client
- nlohmann::json
- OpenCV
- OpenSSL
- PNG
- Poco C++
- PostgreSQL
- Protobuf
- Qt
- Qt-Android-CMake
- QtQmlManager
- RapidJSON
- Sugar
- TIFF
- Washer
- WTL
- ZeroMQ
- ZMQPP
- ZLIB
- rabbitmq-c
- sparsehash
- ccv
- cereal
- convertutf
- crashpad
- cvmatio
- dest
- dlib
- eos
- flatbuffers
- fmt
- freetype
- glm
- glog
- half
- hdf5
- ios_sim
- irrXML
- libyuv
- log4cplus
- minizip
- odb-pgsql
- odb-mysql
- ogles_gpgpu
- openddlparser
- poly2tri
- polyclipping
- spdlog
- szip
- thread-pool-cpp
- tinydir
- websocketpp
- msgpack
- wxWidgets
- xgboost
Don't see packages you need? Feel free to leave a package request.