-
-
Notifications
You must be signed in to change notification settings - Fork 678
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ENH: Update mangled third-party libraries to use MANGLE_PREFIX CMake variable #4102
ENH: Update mangled third-party libraries to use MANGLE_PREFIX CMake variable #4102
Conversation
This commit updates mangled libraries to consistently configure the mangle header based on the value of the MANGLE_PREFIX CMake variable. It updates the following libraries: * Expat * HDF5 * JPEG * NrrdIO * PNG * TIFF
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Zlib has a prefix. It is set here:
https://github.com/InsightSoftwareConsortium/ITK/blob/v5.4rc01/Modules/ThirdParty/ZLIB/src/CMakeLists.txt#L5
Have you tried integrating this into Slicer, and does it work?
@@ -178,6 +178,11 @@ CONFIGURE_FILE(${ITK3P_EXPAT_SOURCE_DIR}/expatDllConfig.h.in | |||
|
|||
configure_file(expat_config.h.cmake "${ITK3P_EXPAT_BINARY_DIR}/expat_config.h") | |||
|
|||
set(MANGLE_PREFIX itk_expat) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does this respect cache? If the calling code has set(MANGLE_PREFIX slicer_expat)
, will this line not override that?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These are local variables not intended to allow customization.
Customization of mangling will be done in a follow-up pull request introducing code like:
set(MANGLE_PREFIX ${ITK_NAMESPACE}_expat)
or
set(MANGLE_PREFIX ${ITK_NAMESPACE})
based on the third-party library mangling requirements.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Purpose of these changes it to introduce a uniform mangling interface for all third-parties.
This commit updates mangled third-party libraries to consistently configure the mangle header based on the value of the
MANGLE_PREFIX
CMake variable.This pull request is done in the context of the topic Adding support for customizing ITK namespace. See https://discourse.itk.org/t/adding-support-for-customizing-itk-namespace/5170/2
Third-party Modules
Updated from
mangle.h
to_mangle.h.in
:ThirdParty/VNL/src/vxl/v3p/netlib/(v3p_f2c_mangle.h|v3p_netlib_mangle.h)
)Already using
_mangle.h.in
:Not yet using mangling
These may be updated in follow-up pull-requests
Related pull requests
PR Checklist