Install Options¶
When installing Imath from source, take note of the following CMake options:
IMATH_CXX_STANDARDC++ standard to compile against. Default is
14.IMATH_HALF_USE_LOOKUP_TABLEUse the half-to-float conversion lookup table. Default is
ONfor backwards compatibility. With the value ofOFF, use a bit-shift conversion algorithm. Note that this setting is overriden when compiler flags enable the F16C SSE instruction set.IMATH_USE_DEFAULT_VISIBILITYUse default visibility, which makes all symbols visible in compiled objects. Default is
OFF, in which case only designated necessary symbols are marked for export.IMATH_USE_NOEXCEPTUse the
noexceptspecifier of appropriate methods. Default isON. With the value ofOFF, thenoexceptspecifier is omitted, for situations in which it is not desireable.IMATH_ENABLE_LARGE_STACKEnables the
halfFunctionobject to place the lookup tables on the stack rather than allocating heap memory. Default isOFF.IMATH_VERSION_RELEASE_TYPEA string to append to the version number in the internal package name macro IMATH_PACKAGE_STRING. Default is the empty string, but can be set to, for example, “-dev” during development (e.g. “3.1.0-dev”).
IMATH_INSTALL_SYM_LINKInstall an unversioned symbolic link (i.e. libImath.so) to the versioned library.
IMATH_INSTALL_PKG_CONFIGInstall Imath.pc file. Default is
ON.IMATH_NAMESPACEPublic namespace alias for Imath. Default is
Imath.IMATH_INTERNAL_NAMESPACEReal namespace for Imath that will end up in compiled symbols. Default is
Imath_<major>_<minor>.IMATH_NAMESPACE_CUSTOMWhether the namespace has been customized (so external users know). Default is
NO.IMATH_LIB_SUFFIXString added to the end of all the versioned libraries. Default is
-<major>_<minor>IMATH_OUTPUT_SUBDIRDestination sub-folder of the include path for install. Default is
Imath.
To enable half-to-float conversion using the F16C SSE instruction set
for g++ and clang when installing Imath, add the -mf16c compiler
option:
% cmake <Imath source directory> -DCMAKE_CXX_FLAGS="-mf16c"
See half-float Conversion Configuration Options for more information about the half-float conversion process.