[MacPorts] #71120: m4: configure: error: Cannot find a type to use in place of socklen_t (was: Failed to configure m4 on Mac Sequoia)
MacPorts
noreply at macports.org
Fri Oct 18 23:24:55 UTC 2024
#71120: m4: configure: error: Cannot find a type to use in place of socklen_t
---------------------------+--------------------
Reporter: tomasstolker | Owner: (none)
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version: 2.10.2
Resolution: | Keywords: arm64
Port: m4 |
---------------------------+--------------------
Changes (by ryandesign):
* keywords: => arm64
Comment:
The main.log says the problem is:
{{{
:info:configure checking for socklen_t... no
:info:configure checking for socklen_t equivalent... configure: error:
Cannot find a type to use in place of socklen_t
}}}
The config.log says the reason for that is:
{{{
configure:57981: checking for socklen_t
configure:57981: /usr/bin/clang -c -pipe -Os
-isysroot/Library/Developer/CommandLineTools/SDKs/MacOSX15.sdk -arch arm64
-I/opt/local/include
-isysroot/Library/Developer/CommandLineTools/SDKs/MacOSX15.sdk conftest.c
>&5
In file included from conftest.c:526:
In file included from
/Library/Developer/CommandLineTools/SDKs/MacOSX15.sdk/usr/include/sys/types.h:81:
In file included from
/Library/Developer/CommandLineTools/SDKs/MacOSX15.sdk/usr/include/machine/endian.h:35:
In file included from
/Library/Developer/CommandLineTools/SDKs/MacOSX15.sdk/usr/include/i386/endian.h:85:
In file included from
/Library/Developer/CommandLineTools/SDKs/MacOSX15.sdk/usr/include/sys/_endian.h:131:
In file included from
/Library/Developer/CommandLineTools/SDKs/MacOSX15.sdk/usr/include/libkern/_OSByteOrder.h:62:
/Library/Developer/CommandLineTools/SDKs/MacOSX15.sdk/usr/include/libkern/arm/_OSByteOrder.h:50:1:
error: redefinition of '_OSSwapInt16'
50 | _OSSwapInt16(
| ^
/Library/Developer/CommandLineTools/SDKs/MacOSX15.sdk/usr/include/libkern/i386/_OSByteOrder.h:50:1:
note: previous definition is here
50 | _OSSwapInt16(
| ^
}}}
This looks like #62991 (and the same issue for grep in #64135) which were
both fixed but the fix was only for when the universal variant is used.
Your log shows you are not using the universal variant. However I do see
this in your main.log:
{{{
:debug:sysinfo macOS 15.0.1 (darwin/24.0.0) arch i386
}}}
Are you on an Intel Mac or an Apple Silicon Mac? This line indicates
MacPorts thinks you are on an Intel Mac, but the log shows you are trying
to build m4 for Apple Silicon (arm64).
If you're on an Intel Mac, you won't be able to run arm64 software at all,
so I assume you're on an Apple Silicon Mac. In that case, this problem is
typically caused by running the Intel version of MacPorts, which happens
automatically if you're running an Intel shell, which happens
automatically if you're running an Intel terminal program. The solution is
to use an Apple Silicon terminal program, like the one Apple includes with
macOS at /Applications/Utilities/Terminal.app.
If you're already uisng Apple Terminal or a third-party terminal that is
compiled for Apple Silicon, then go to the Finder, click the terminal
program's icon, choose Get Info from the File menu, and see if the Open in
Rosetta checkbox is checked. If it is, uncheck it, then close and reopen
the terminal program.
--
Ticket URL: <https://trac.macports.org/ticket/71120#comment:3>
MacPorts <https://www.macports.org/>
Ports system for macOS
More information about the macports-tickets
mailing list