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 5E057442BB3 for ; Sun, 12 Apr 2020 03:15:53 +0300 (MSK) Received: by smtp50.i.mail.ru with esmtpa (envelope-from ) id 1jNQHw-0005lJ-Sz for tarantool-patches@dev.tarantool.org; Sun, 12 Apr 2020 03:15:53 +0300 From: Vladislav Shpilevoy Date: Sun, 12 Apr 2020 02:13:25 +0200 Message-Id: <04305cabaa1e2a9ecb31cbe44e5d7f507dd32a2f.1586650014.git.v.shpilevoy@tarantool.org> In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [Tarantool-patches] [PATCH 42/43] build: export src/lua/string.c symbols List-Id: Tarantool development patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: tarantool-patches@dev.tarantool.org Exports a function used by src/lua/string.lua via FFI. Part of #2971 --- extra/exports | 4 ---- src/lua/init.c | 4 ++++ src/lua/string.c | 9 +++++++++ 3 files changed, 13 insertions(+), 4 deletions(-) diff --git a/extra/exports b/extra/exports index 5db526d2c..2341b0861 100644 --- a/extra/exports +++ b/extra/exports @@ -1,9 +1,5 @@ # Symbols exported by the main Tarantool executable -# Module API - -string_strip_helper - # Lua / LuaJIT lua_newstate diff --git a/src/lua/init.c b/src/lua/init.c index daa685f57..f115bd2c9 100644 --- a/src/lua/init.c +++ b/src/lua/init.c @@ -746,6 +746,9 @@ tarantool_lua_msgpack_export_syms(void); void ** tarantool_lua_socket_export_syms(void); +void ** +tarantool_lua_string_export_syms(void); + void ** tarantool_lua_tnt_iconv_export_syms(void); @@ -766,6 +769,7 @@ tarantool_lua_export_syms(void) (void *)tarantool_lua_msgpack_export_syms, (void *)tarantool_lua_socket_export_syms, (void *)tarantool_lua_tnt_iconv_export_syms, + (void *)tarantool_lua_string_export_syms, (void *)tarantool_lua_utils_export_syms, /* Own symbols. */ diff --git a/src/lua/string.c b/src/lua/string.c index c140299ff..d265697ea 100644 --- a/src/lua/string.c +++ b/src/lua/string.c @@ -115,3 +115,12 @@ string_strip_helper(const char *inp, size_t inp_len, const char *chars, *newlen = inp_len - skipped; } + +void ** +tarantool_lua_string_export_syms(void) +{ + static void *syms[] = { + string_strip_helper, + }; + return syms; +} -- 2.21.1 (Apple Git-122.3)