diff options
author | Brad King <brad.king@kitware.com> | 2017-04-25 12:52:14 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2017-04-25 12:52:14 (GMT) |
commit | 8ed663791bdda4e726f7b3764bc75f8856724d6f (patch) | |
tree | 294af58db345710e752ab43b01eebc13295e0bfd /Modules/UseSWIG.cmake | |
parent | 759c6752127092447e8978a978eefde451024b28 (diff) | |
download | CMake-8ed663791bdda4e726f7b3764bc75f8856724d6f.zip CMake-8ed663791bdda4e726f7b3764bc75f8856724d6f.tar.gz CMake-8ed663791bdda4e726f7b3764bc75f8856724d6f.tar.bz2 |
UseSWIG: Fall back to empty PREFIX for unknown languages
Teach `SWIG_ADD_LIBRARY` to fall back to an empty library prefix for
languages we don't explicitly define already.
Suggested-by: Alan W. Irwin <irwin@beluga.phys.uvic.ca>
Diffstat (limited to 'Modules/UseSWIG.cmake')
-rw-r--r-- | Modules/UseSWIG.cmake | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/Modules/UseSWIG.cmake b/Modules/UseSWIG.cmake index 277f4ca..bfe1a6f 100644 --- a/Modules/UseSWIG.cmake +++ b/Modules/UseSWIG.cmake @@ -326,6 +326,9 @@ macro(SWIG_ADD_LIBRARY name) if (APPLE) set_target_properties (${SWIG_MODULE_${name}_REAL_NAME} PROPERTIES SUFFIX ".bundle") endif () + else() + # assume empty prefix because we expect the module to be dynamically loaded + set_target_properties (${SWIG_MODULE_${name}_REAL_NAME} PROPERTIES PREFIX "") endif () endmacro() |