From c9b3ccd0790d2044e69b16cd596886f8b84272e3 Mon Sep 17 00:00:00 2001
From: Georgiy Lebedev <g.lebedev@tarantool.org>
Date: Mon, 30 Jan 2023 11:56:46 +0300
Subject: [PATCH] exports: add `tarantool_version`
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

The `tarantool_version` symbol identifies the binary as Tarantool (see also
https://github.com/tarantool/tarantool/blob/f991f7c0be73558f0710f0af871d07e8bd506efe/tools/tarabrt.sh#L179-L180).
It is not exported and thus can be optimized away by LTO — add it to the
exports list.

Closes #8129

Acked-by: Aleksandr Lyapunov <alyapunov@tarantool.org>

NO_CHANGELOG=<internal change>
NO_DOC=<internal change>
NO_TEST=<no convenient way to test devtools>
---
 extra/exports                      | 1 +
 static-build/test/exports.test.lua | 1 +
 2 files changed, 2 insertions(+)

diff --git a/extra/exports b/extra/exports
index 6052413744..da0f9c7df7 100644
--- a/extra/exports
+++ b/extra/exports
@@ -469,6 +469,7 @@ swim_size
 tarantool_exit
 tarantool_lua_slab_cache
 tarantool_uptime
+tarantool_version
 title_get
 title_get_custom
 title_get_interpretor_name
diff --git a/static-build/test/exports.test.lua b/static-build/test/exports.test.lua
index b50132d7fb..fe013a693b 100755
--- a/static-build/test/exports.test.lua
+++ b/static-build/test/exports.test.lua
@@ -76,6 +76,7 @@ local check_symbols = {
     'say_set_log_format',
     'tarantool_uptime',
     'tarantool_exit',
+    'tarantool_version',
     'log_pid',
     'space_by_id',
     'space_run_triggers',
-- 
GitLab