Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mapsme/omim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVictor Popov <v.popov@corp.mail.ru>2020-09-30 13:36:45 +0300
committermpimenov <mpimenov@users.noreply.github.com>2020-11-06 12:01:03 +0300
commit256c54826421d23ddcf73db5977ef5064b5a48dc (patch)
treec4e92cbb4699f85be593a30902f5669be60004b6 /local_ads/pylocal_ads
parente5dd1593726f2fd1539cb263b21b3eb295645a7f (diff)
[pybindings] Fix linking on Mac
Mac has different linker defaults than linux, and by default it does not allow undefined symbols to be left in resulting pybinding library. To allow it, we specifically pass linker argument when linking final pybinding object. This is done to avoid linking excessively to libpythonX.Y since at the time pybinding is loaded into Python process, all libpython symbols would be immediately available.
Diffstat (limited to 'local_ads/pylocal_ads')
-rw-r--r--local_ads/pylocal_ads/CMakeLists.txt4
1 files changed, 4 insertions, 0 deletions
diff --git a/local_ads/pylocal_ads/CMakeLists.txt b/local_ads/pylocal_ads/CMakeLists.txt
index 46478a4c40..20fdad6a6b 100644
--- a/local_ads/pylocal_ads/CMakeLists.txt
+++ b/local_ads/pylocal_ads/CMakeLists.txt
@@ -16,4 +16,8 @@ omim_link_libraries(
base
)
+if (PLATFORM_MAC)
+ omim_link_libraries(${PROJECT_NAME} "-Wl,-undefined,dynamic_lookup")
+endif()
+
set_target_properties(${PROJECT_NAME} PROPERTIES PREFIX "")