mirror of
https://github.com/microsoft/vcpkg.git
synced 2024-12-27 18:31:15 +08:00
[fontconfig] use __attribute__((visibility("default"))) for exporting symbols on macOS (#5689)
* use __attribute__((visibility("default"))) for exporting symbols on macOS * [fontconfig] Bump CONTROL version
This commit is contained in:
parent
ee957d9170
commit
e740b5717c
@ -37,7 +37,11 @@ add_library(fontconfig
|
||||
src/fcxml.c
|
||||
src/ftglue.c)
|
||||
|
||||
set_target_properties(fontconfig PROPERTIES DEFINE_SYMBOL "FcPublic=__declspec(dllexport)")
|
||||
if(WIN32)
|
||||
set_target_properties(fontconfig PROPERTIES DEFINE_SYMBOL "FcPublic=__declspec(dllexport)")
|
||||
else()
|
||||
set_target_properties(fontconfig PROPERTIES DEFINE_SYMBOL "FcPublic=__attribute__((visibility(\"default\")))")
|
||||
endif()
|
||||
|
||||
target_include_directories(fontconfig PRIVATE .
|
||||
${FC_INCLUDE_DIR}/alias
|
||||
|
@ -1,4 +1,4 @@
|
||||
Source: fontconfig
|
||||
Version: 2.12.4-7
|
||||
Version: 2.12.4-8
|
||||
Description: Library for configuring and customizing font access.
|
||||
Build-Depends: freetype, expat, libiconv, dirent
|
||||
|
@ -36,7 +36,11 @@ vcpkg_copy_pdbs()
|
||||
if(VCPKG_LIBRARY_LINKAGE STREQUAL dynamic)
|
||||
foreach(HEADER fcfreetype.h fontconfig.h)
|
||||
file(READ ${CURRENT_PACKAGES_DIR}/include/fontconfig/${HEADER} FC_HEADER)
|
||||
string(REPLACE "#define FcPublic" "#define FcPublic __declspec(dllimport)" FC_HEADER "${FC_HEADER}")
|
||||
if(WIN32)
|
||||
string(REPLACE "#define FcPublic" "#define FcPublic __declspec(dllimport)" FC_HEADER "${FC_HEADER}")
|
||||
else()
|
||||
string(REPLACE "#define FcPublic" "#define FcPublic __attribute__((visibility(\"default\")))" FC_HEADER "${FC_HEADER}")
|
||||
endif()
|
||||
file(WRITE ${CURRENT_PACKAGES_DIR}/include/fontconfig/${HEADER} "${FC_HEADER}")
|
||||
endforeach()
|
||||
endif()
|
||||
|
Loading…
x
Reference in New Issue
Block a user