From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp50.i.mail.ru (smtp50.i.mail.ru [94.100.177.110]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dev.tarantool.org (Postfix) with ESMTPS id 410274696CB for ; Sun, 12 Apr 2020 03:13:44 +0300 (MSK) Received: by smtp50.i.mail.ru with esmtpa (envelope-from ) id 1jNQFr-0005lJ-O7 for tarantool-patches@dev.tarantool.org; Sun, 12 Apr 2020 03:13:44 +0300 From: Vladislav Shpilevoy Date: Sun, 12 Apr 2020 02:12:57 +0200 Message-Id: <33c1539feb7a881d8b82dae17decbcd86567fbcd.1586650014.git.v.shpilevoy@tarantool.org> In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [Tarantool-patches] [PATCH 17/43] build: export src/lib/uuid/tt_uuid.c symbols List-Id: Tarantool development patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: tarantool-patches@dev.tarantool.org Exports functions and a variable used by src/lua/uuid.lua via FFI. Part of #2971 --- extra/exports | 7 ------- src/exports.c | 2 ++ src/lib/uuid/tt_uuid.c | 15 +++++++++++++++ 3 files changed, 17 insertions(+), 7 deletions(-) diff --git a/extra/exports b/extra/exports index 34c5d2df6..b81ca4492 100644 --- a/extra/exports +++ b/extra/exports @@ -7,13 +7,6 @@ ibuf_reinit ibuf_destroy ibuf_reserve_slow -uuid_nil -tt_uuid_create -tt_uuid_str -tt_uuid_is_equal -tt_uuid_is_nil -tt_uuid_bswap -tt_uuid_from_string log_level log_format uri_parse diff --git a/src/exports.c b/src/exports.c index fbfde5632..37570d40e 100644 --- a/src/exports.c +++ b/src/exports.c @@ -59,6 +59,7 @@ EXPORT(salad_guava_export_syms); EXPORT(scramble_export_syms); EXPORT(tarantool_lua_export_syms); EXPORT(title_export_syms); +EXPORT(tt_uuid_export_syms); void export_syms(void) @@ -75,6 +76,7 @@ export_syms(void) scramble_export_syms, tarantool_lua_export_syms, title_export_syms, + tt_uuid_export_syms, }; const int func_count = sizeof(syms) / sizeof(syms[0]); for (int i = 0; i < func_count; ++i) diff --git a/src/lib/uuid/tt_uuid.c b/src/lib/uuid/tt_uuid.c index 1bd2e2cfe..182bd09c9 100644 --- a/src/lib/uuid/tt_uuid.c +++ b/src/lib/uuid/tt_uuid.c @@ -99,3 +99,18 @@ tt_uuid_from_strl(const char *in, size_t len, struct tt_uuid *uu) snprintf(buf, sizeof(buf), "%.*s", (int) len, in); return tt_uuid_from_string(buf, uu); } + +void ** +tt_uuid_export_syms(void) +{ + static void *syms[] = { + (void *)tt_uuid_bswap, + (void *)tt_uuid_create, + (void *)tt_uuid_from_string, + (void *)tt_uuid_is_equal, + (void *)tt_uuid_is_nil, + (void *)tt_uuid_str, + (void *)&uuid_nil, + }; + return syms; +} -- 2.21.1 (Apple Git-122.3)