From 5753a9d000847d8bbaa9921e9b1d6e9f14cb4115 Mon Sep 17 00:00:00 2001 From: ck Date: Mon, 19 Apr 2021 14:16:49 +0800 Subject: [PATCH] fix: global function is missing MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 添加了默认隐藏符号的编译参数后,全局函数也需要导出才行。否则可能出现ld错误 Log: 修复获取全局版本号未导出的问题 Change-Id: I4c5c41c8c513e2571e458a99c61c14ea11d35639 --- src/dtkcore_global.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/dtkcore_global.h b/src/dtkcore_global.h index f6d4155..7a6ce6e 100644 --- a/src/dtkcore_global.h +++ b/src/dtkcore_global.h @@ -68,6 +68,6 @@ #define DTK_VERSION DTK_VERSION_CHECK(DTK_VERSION_MAJOR, DTK_VERSION_MINOR, DTK_VERSION_PATCH, DTK_VERSION_BUILD) extern "C" { -int dtkVersion(); -const char *dtkVersionString(); +int LIBDTKCORESHARED_EXPORT dtkVersion(); +const LIBDTKCORESHARED_EXPORT char *dtkVersionString(); }