PnMPI icon indicating copy to clipboard operation
PnMPI copied to clipboard

CMake failure with latest CMake version

Open jprotze opened this issue 4 years ago • 0 comments

With CMake 3.20.3, I see the following error (while still 3.16 succeeds):

CMake Error: install(EXPORT "pnmpi-libs" ...) includes target "pnmpi" which requires target "pnmpi_debug" that is not in any export set.

and the same error for pnmpi_modules, pnmpi_service, and pnmpi_wrapper. I think, the reason for packaging these intermediate targets was to avoid redundant compilation of the object files. My suggestion would be to change the targets from OBJECT to STATIC, install the static libraries with EXPORT and set(CMAKE_POSITION_INDEPENDENT_CODE ON).

jprotze avatar Jun 27 '21 14:06 jprotze