Bug #104126 | compile failure | ||
---|---|---|---|
Submitted: | 28 Jun 2021 6:25 | Modified: | 1 Jul 2021 2:27 |
Reporter: | xu chunming | Email Updates: | |
Status: | Can't repeat | Impact on me: | |
Category: | MySQL Server: Compiling | Severity: | S1 (Critical) |
Version: | MySQL5.7.32 | OS: | MacOS (11.2.3) |
Assigned to: | CPU Architecture: | x86 | |
Tags: | Compile failure on macOS Big Sur |
[28 Jun 2021 6:25]
xu chunming
[29 Jun 2021 2:51]
xu chunming
This problem has been resolved.
[30 Jun 2021 23:22]
MySQL Verification Team
Log of cmake process
Attachment: cmake-log-bug104126.txt (text/plain), 33.95 KiB.
[30 Jun 2021 23:33]
MySQL Verification Team
Log partial of make
Attachment: make-bug104126-txt (application/octet-stream, text), 2.42 MiB.
[30 Jun 2021 23:39]
MySQL Verification Team
Thank you for the bug report. I could not repeat with 5.7.34 source ( see attached logs of cmake and make ): rc/sql_service/sql_service_context.cc.o CMakeFiles/group_replication.dir/src/sql_service/sql_service_context_base.cc.o CMakeFiles/group_replication.dir/src/sql_service/sql_service_interface.cc.o CMakeFiles/group_replication.dir/src/sql_service/sql_command_test.cc.o CMakeFiles/group_replication.dir/src/sql_service/sql_service_command.cc.o ../../../archive_output_directory/libmysqlservices.a -Wl,-bundle_loader,/Users/miguel/bugcompilation/mysql-5.7.34/sql/mysqld ../../../archive_output_directory/liblz4_lib.a /usr/local/opt/openssl/lib/libssl.a /usr/local/opt/openssl/lib/libcrypto.a ../../../archive_output_directory/liblz4_lib.a /usr/local/opt/openssl/lib/libssl.a /usr/local/opt/openssl/lib/libcrypto.a [100%] Built target group_replication /Applications/CMake.app/Contents/bin/cmake -E cmake_progress_start /Users/miguel/bugcompilation/mysql-5.7.34/CMakeFiles 0 miguel:mysql-5.7.34 miguel$ sql/mysqld --version sql/mysqld Ver 5.7.34 for osx10.15 on x86_64 (Source distribution) miguel:mysql-5.7.34 miguel$
[1 Jul 2021 2:27]
xu chunming
The reason why the problem cannot be reproduced should be related to the system version osx11.2.3. The error after the compile command is changed to make VERBOSE=1 is as follows : In file included from /Users/tom/Desktop/src/test/mysql-5.7.32/storage/perfschema/cursor_by_account.cc:28: In file included from /Users/tom/Desktop/src/test/mysql-5.7.32/include/my_global.h:654: In file included from /Users/tom/Desktop/src/test/mysql-5.7.32/include/my_dbug.h:233: In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk/usr/include/c++/v1/sstream:173: In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk/usr/include/c++/v1/ostream:140: In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk/usr/include/c++/v1/locale:189: /Users/tom/Desktop/src/test/mysql-5.7.32/version:1:1: error: expected unqualified-id MYSQL_VERSION_MAJOR=5 ^ fatal error: too many errors emitted, stopping now [-ferror-limit=] 20 errors generated. make[2]: *** [storage/perfschema/CMakeFiles/perfschema.dir/cursor_by_account.cc.o] Error 1 make[1]: *** [storage/perfschema/CMakeFiles/perfschema.dir/all] Error 2 make: *** [all] Error 2 /Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk/usr/include/c++/v1/locale:189 ,the code is #include <version>. At the same time, there is a VERSION file in the compilation root directory . It looks like the file has the same name. So, I renamed the file VERSION to VERSION_BAK, and modified the mysql_version.cmake file, changed several VERSION in the file to VERSION_BAK, and then recompiled with make to be normal.
[22 Nov 2021 14:42]
Rahul Sisondia
I see the same error even with latest 5.7.36 build. I tried it on mac using ninja as following. cmake -G "Ninja" -DCMAKE_BUILD_TYPE=debug ../src -DWITH_SSL=system -DWITH_CURL=system -DWITH_BOOST=/Volumes/Neo/work/sw/boost_1_59_0 && ninja
[22 Nov 2021 14:44]
Rahul Sisondia
In continuation to my previous message. Here are the error logs. In file included from /Users/rsisondi/work/mysql-57/src/storage/perfschema/pfs_account.cc:28: In file included from /Users/rsisondi/work/mysql-57/src/include/my_global.h:654: In file included from /Users/rsisondi/work/mysql-57/src/include/my_dbug.h:231: In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk/usr/include/c++/v1/sstream:173: In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk/usr/include/c++/v1/ostream:140: In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk/usr/include/c++/v1/locale:189: /Users/rsisondi/work/mysql-57/src/version:1:1: error: expected unqualified-id MYSQL_VERSION_MAJOR=5 ^ include/my_config.h:404:29: note: expanded from macro 'MYSQL_VERSION_MAJOR' #define MYSQL_VERSION_MAJOR 5 ^ In file included from /Users/rsisondi/work/mysql-57/src/storage/perfschema/pfs_account.cc:28: In file included from /Users/rsisondi/work/mysql-57/src/include/my_global.h:654: In file included from /Users/rsisondi/work/mysql-57/src/include/my_dbug.h:231: In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk/usr/include/c++/v1/sstream:173: In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk/usr/include/c++/v1/ostream:140: In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk/usr/include/c++/v1/locale:197: /Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk/usr/include/nl_types.h:92:4: error: C++ requires a type specifier for all declarations } *nl_catd;
[23 Nov 2021 8:48]
Rahul Sisondia
Workaround proposed by Xu chunming works. But appreciate if mysql team could fix the problem.