Opened 3 years ago

Closed 3 years ago

#62784 closed defect (fixed)

mysql57 @5.7.34: version:1:1: error: expected unqualified-id

Reported by: josephsacco Owned by: MarcusCalhoun-Lopez (Marcus Calhoun-Lopez)
Priority: Normal Milestone:
Component: ports Version: 2.6.4
Keywords: bigsur Cc: dsavransky (Dmitry Savransky), MarcusCalhoun-Lopez (Marcus Calhoun-Lopez)
Port: mysql57

Description

mysql57 @5.7.34_0 does not build under MacOS 11.3.

version:1
:debug:sysinfo macOS 11.3 (darwin/20.4.0) arch i386
:debug:sysinfo MacPorts 2.6.4
:debug:sysinfo Xcode 12.5
:debug:sysinfo SDK 11.3
:debug:sysinfo MACOSX_DEPLOYMENT_TARGET: 11.3

                 .........

:info:build [ 36%] Built target innobase
:info:build make[1]: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_databases_mysql57/mysql57/work/build'
:info:build make: *** [all] Error 2
:info:build make: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_databases_mysql57/mysql57/work/build'
:info:build Command failed:  cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_databases_mysql57/mysql57/work/build" && /usr/bin/make -j8 -w all VERBOSE=ON
:info:build Exit code: 2
:error:build Failed to build mysql57: command execution failed
:debug:build Error code: CHILDSTATUS 23880 2
:debug:build Backtrace: command execution failed
:debug:build     while executing
:debug:build "system {*}$notty {*}$nice $fullcmdstring"
:debug:build     invoked from within
:debug:build "command_exec build"
:debug:build     (procedure "portbuild::build_main" line 8)
:debug:build     invoked from within
:debug:build "$procedure $targetname"
:error:build See /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_databases_mysql57/mysql57/main.log for details.

I have poked around in the log file, but have not seen anything obvious. I can upload the log file if you wish.

-Joseph

Attachments (1)

main.log (2.5 MB) - added by josephsacco 3 years ago.
Build Log File

Change History (13)

comment:1 Changed 3 years ago by bestlem

Yes please, the log file would be useful

comment:2 Changed 3 years ago by ryandesign (Ryan Carsten Schmidt)

Keywords: bigsur added; Big Sur 11.3 removed

Changed 3 years ago by josephsacco

Attachment: main.log added

Build Log File

comment:3 Changed 3 years ago by josephsacco

Taking another look at the log file, I see that a number of tests failed during the configuration stage.

-Joseph

comment:4 in reply to:  3 Changed 3 years ago by ryandesign (Ryan Carsten Schmidt)

Summary: mysql57 @5.7.34_0 does not build under Big Sur 11.3mysql57 @5.7.34: version:1:1: error: expected unqualified-id

Replying to josephsacco:

Taking another look at the log file, I see that a number of tests failed during the configuration stage.

Specifically?

The configuration process determines the capabilities of your system. It is normal for some tests to report that things are not found.

It is also possible that some configuration tests are making incorrect determinations due to implicit declaration of functions, but we would not be able to know whether that is so without looking at the config.log. Or you could upgrade to MacPorts 2.7.0-beta2 which will print a message at the end of the configure phase if this problem occurs.

The problem I see in the log is:

version:1:1: error: expected unqualified-id

This means you are using a C++20-capable compiler and the VERSION file included in the source is conflicting with the version header of your compiler because you are on a case-insensitive filesystem. See https://bugs.llvm.org/show_bug.cgi?id=42540. The consensus seems to be that the correct fix is for the build system not to add the root directory (the one containing the VERSION file) as an include path, but I don't know whether that is easy or hard to do in the MySQL build system.

Is there a specific reason why you need mysql57, which is old? The current version is mysql8.

comment:5 Changed 3 years ago by dsavransky (Dmitry Savransky)

Cc: dsavransky added

comment:6 Changed 3 years ago by josephsacco

Our "friends" at BlueHost are still using mysql57, at least on shared server accounts. So... I am stuck with version 5.7 for now.

I recently upgraded the operating system and associated Xcode tools and CommandLine tools on my iMac to 11.3. I wonder if the 11.3 upgrade is causing the mischief.

-Joseph

comment:7 Changed 3 years ago by ryandesign (Ryan Carsten Schmidt)

Likely, the Xcode upgrade has given you a C++20-capable compiler where you did not have one before.

comment:8 Changed 3 years ago by kencu (Ken)

Finally, this will show up in xcode builds now, and be fixed broadly.

up to now, only 10.6.8 and other systems forced to clang-9.0 were seeing this error all the time.

We have fixed it properly here and there, or sometimes (like some of the mysql ports) just forced it build with an older macports-clang (5-7) that doesn't have this <version> header that causes the conflict.

comment:9 Changed 3 years ago by ostefano (Stefano Ortolani)

I can confirm this bug, and indeed it happens only on 11.3. Is there any workaround besides upgrading mysql?

comment:10 Changed 3 years ago by landabaso

Same here. We still need to maintain mysql 5.7 and it is now not possible to do so with BigSur. Besides, it's not possible to force compiling with clang below 9 on BigSur either.

Please, could you share any workaround while this is being fixed?

Thanks

comment:11 Changed 3 years ago by MarcusCalhoun-Lopez (Marcus Calhoun-Lopez)

Cc: MarcusCalhoun-Lopez added

comment:12 Changed 3 years ago by MarcusCalhoun-Lopez (Marcus Calhoun-Lopez)

Owner: set to MarcusCalhoun-Lopez
Resolution: fixed
Status: newclosed

In e88dc2b57f85b54b0c02b434576bc11e40cf9aae/macports-ports (master):

mysql57: avoid collision with C++17 header <version>

Fixes #62784
No revbump since port either builds correctly or not at all.

Note: See TracTickets for help on using tickets.