Skip to content

bug: compile Error, ‘STONEDB_TAG_NAME’ was not declared in this scope, #1328

@davidshiz

Description

@davidshiz

Have you read the Contributing Guidelines on issues?

Please confirm if bug report does NOT exists already ?

  • I confirm there is no existing issue for this

Describe the problem

When fock a branch in your own code repo, you cannot compile successfully. because your own code repo have no tag.
It is recommended to decouple from tags when compiling code.

/stonedb/libbinlogevents/include/rows_event.h: In constructor ‘binary_log::Table_map_event::Table_map_event(const Table_id&, long unsigned int, const char*, size_t, const char*, size_t)’:
/stonedb/libbinlogevents/include/rows_event.h:428:20: warning: implicitly-declared ‘constexpr Table_id::Table_id(const Table_id&)’ is deprecated [-Wdeprecated-copy]
  428 |       m_null_bits(0)
      |                    ^
In file included from /riyao/stonedb/sql/table.h:37,
                 from /riyao/stonedb/sql/field.h:37,
                 from /riyao/stonedb/sql/protocol_classic.h:27,
                 from /riyao/stonedb/sql/sql_class.h:40,
                 from /riyao/stonedb/sql/sql_parse.h:29,
                 from /riyao/stonedb/sql/mysqld.cc:57:
/stonedb/libbinlogevents/include/table_id.h:53:8: note: because ‘Table_id’ has user-provided ‘void Table_id::operator=(const Table_id&)’
   53 |   void operator=(const Table_id &tid) { m_id = tid.m_id; }
      |        ^~~~~~~~
/stonedb/sql/mysqld.cc: In function ‘void set_server_version()’:
/stonedb/sql/mysqld.cc:8134:31: error: ‘STONEDB_TAG_NAME’ was not declared in this scope; did you mean ‘STONEDB_BRANCH_NAME’?
 8134 |       static_cast<int>(sizeof(STONEDB_TAG_NAME)))
      |                               ^~~~~~~~~~~~~~~~
      |                               STONEDB_BRANCH_NAME
make[2]: *** [sql/CMakeFiles/sql.dir/build.make:5247: sql/CMakeFiles/sql.dir/mysqld.cc.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:8269: sql/CMakeFiles/sql.dir/all] Error 2
make: *** [Makefile:161: all] Error 2

Expected behavior

No response

How To Reproduce

No response

Environment

root@ub01:~# /stonedb57/install/bin/mysqld --version
/stonedb57/install/bin/mysqld  Ver 5.7.36-StoneDB-v1.0.2 for Linux on x86_64 (build-)
build information as follow:
        Repository address: https://github.com/stoneatom/stonedb.git:stonedb-5.7-dev
        Branch name: stonedb-5.7-dev
        Last commit ID: 0f4250589
        Last commit time: Date:   Tue Feb 21 06:09:37 2023 +0000
        Build time: Date: Wed Feb 22 17:50:51 CST 2023

Are you interested in submitting a PR to solve the problem?

  • Yes, I will!

Metadata

Metadata

Labels

Type

No type

Projects

Status

In Progress

Relationships

None yet

Development

No branches or pull requests

Issue actions