I’ve noticed that CMAKE_JOB_POOL_LINK specifies the pool for static libraries archive step, this step is not always considered as linking, if this is intended, is there a way to specify the job pool for linking executables & shared libraries only without static libraries archiving ?
You can unset the JOB_POOL_LINK
property on STATIC
libraries to remove them from the pool. The CMAKE_JOB_POOL_LINK
variable just initializes this property.
Unsetting the property could be inconvenient for a project with large set of static libraries.
Moreover, it may involve some logic to test if BUILD_SHARED_LIBS is set or not, which may convert the static library to shared library.
BUILD_SHARED_LIBS
only affects the initial add_library
call without an explicit request. Once declared, the TYPE
property is reliable.