Opened 4 years ago

Last modified 3 years ago

#60959 new defect

openssh-8.1p1_9+gsskex+kerberos5+xauth: compiler cannot create working executables

Reported by: murrayE Owned by:
Priority: Normal Milestone:
Component: ports Version: 2.6.3
Keywords: Cc: rswail (Ron Wail), olupton (Olli Lupton), greyhare, akkornel (A. Karl Kornel), cooljeanius (Eric Gallager)
Port: openssh

Description

Command "openssh-8.1p1_9+gsskex+kerberos5+xauth" gives configure error (from config.log):

configure:2791: /usr/bin/clang -V >&5
clang: error: argument to '-V' is missing (expected 1 value)
...
conftest.c:9:10: fatal error: 'ac_nonexistent.h' file not found
#include <ac_nonexistent.h>
         ^~~~~~~~~~~~~~~~~~

main.log reports:

:info:configure configure: error: *** compiler cannot create working executables, check config.log ***
:info:configure Command failed:  cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_net_openssh/openssh/work/openssh-8.1p1" && ./configure --prefix=/opt/local --with-ssl-dir=/opt/local --sysconfdir=/opt/local/etc/ssh --with-privsep-path=/var/empty --with-md5-passwords --with-pid-dir=/opt/local/var/run --with-pam --mandir=/opt/local/share/man --with-zlib=/opt/local --with-libedit --with-pie --with-xauth=/opt/local/bin/xauth --without-ldns --with-audit=bsm --with-keychain=apple --with-kerberos5=/opt/local --with-4in6 --disable-utmp --disable-wtmp --with-privsep-user=_sshd

Attachments (4)

main.log (145.6 KB) - added by murrayE 4 years ago.
main.log
config.log (270.5 KB) - added by murrayE 4 years ago.
config.log
openssh-8.1p1-xcode12.2pedantry.patch (9.8 KB) - added by adpoliak 4 years ago.
patch applied to clean configure script and its source to allow building under macOS Big Sur 11.1 / XCode 12.2
main.2.log (349.7 KB) - added by soumyajyotih (Soumyajyoti Haldar) 4 years ago.

Download all attachments as: .zip

Change History (19)

Changed 4 years ago by murrayE

Attachment: main.log added

main.log

Changed 4 years ago by murrayE

Attachment: config.log added

config.log

comment:1 Changed 4 years ago by murrayE

Perhaps the solution is not to add +gsskex variant, as the docs say about openssh: "Apple's keychain integration and launchd changes are now included by default, not just with the gsskex variant."

And in that case, perhaps the gsskex variant should be removed?

Last edited 4 years ago by ryandesign (Ryan Carsten Schmidt) (previous) (diff)

comment:2 Changed 4 years ago by mf2k (Frank Schima)

Keywords: configure error removed
Port: openssh added; opens removed

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

Summary: openssh-8.1p1_9+gsskex+kerberos5+xauth config failureopenssh-8.1p1_9+gsskex+kerberos5+xauth: compiler cannot create working executables

Replying to murrayE:

Command "openssh-8.1p1_9+gsskex+kerberos5+xauth" gives configure error (from config.log):

configure:2791: /usr/bin/clang -V >&5
clang: error: argument to '-V' is missing (expected 1 value)
...
conftest.c:9:10: fatal error: 'ac_nonexistent.h' file not found
#include <ac_nonexistent.h>
         ^~~~~~~~~~~~~~~~~~

These errors are not problems; they are a consequence of how configure scripts work. They try all sorts of things, many of which will generate errors, in order to determine what works on your system.

main.log reports:

:info:configure configure: error: *** compiler cannot create working executables, check config.log ***

This is the problem, and the config.log says it happened because:

configure:9029: checking compiler and flags for sanity
configure:9047: /usr/bin/clang -o conftest -pipe -Os -fPIE -isysroot/Library/Developer/CommandLineTools/SDKs/MacOSX10.15.sdk -arch x86_64 -pipe -Wunknown-warning-option -Qunused-arguments -Wall -Wpointer-arith -Wuninitialized -Wsign-compare -Wformat-security -Wsizeof-pointer-memaccess -Wno-pointer-sign -Wno-unused-result -fno-strict-aliasing -mretpoline -D_FORTIFY_SOURCE=2 -ftrapv -fno-builtin-memset -fstack-protector-strong -I/opt/local/include -DBROKEN_STRNVIS=1 -D__APPLE_SANDBOX_NAMED_EXTERNAL__ -D__APPLE_API_STRICT_CONFORMANCE -isysroot/Library/Developer/CommandLineTools/SDKs/MacOSX10.15.sdk -L/opt/local/lib -Wl,-headerpad_max_install_names -Wl,-search_paths_first -Wl,-pie -Wl,-syslibroot,/Library/Developer/CommandLineTools/SDKs/MacOSX10.15.sdk -arch x86_64 -fstack-protector-strong conftest.c  -framework Security -framework Security >&5
conftest.c:88:2: error: implicitly declaring library function 'exit' with type 'void (int) __attribute__((noreturn))' [-Werror,-Wimplicit-function-declaration]
 exit(0);
 ^
conftest.c:88:2: note: include the header <stdlib.h> or explicitly provide a declaration for 'exit'
1 error generated.
configure:9047: $? = 1
configure: program exited with status 1

So this configure script test is faulty because it has neglected to include a required header. These kinds of problems used to generate warnings, but recent Xcode seems to have turned them into errors that must now be fixed.

Probably if someone wanted to try to fix this they should first update the port to the latest version, in case the developers have already fixed it there.

comment:4 Changed 4 years ago by anksil

Is there any kind of workaround for this? It's a bit of a blocker for both us and those of our customers who use Mac. We do have old binaries to fall back on, but they're not very up to date and don't support X11 forwarding.

I've tried to dig through both Xcode settings and the MacPorts config files and file trees, but I feel like I'm way out of my depth.

comment:5 Changed 4 years ago by kencu (Ken)

this is a new default error in the current xcode, and many ports have needed fixing for this issue.

here, it looks like the configure test needs a header added, but who knows what comes next after that is fixed.

comment:6 Changed 4 years ago by mf2k (Frank Schima)

Cc: rswail added

Has duplicate #61420.

comment:7 Changed 4 years ago by danielluke (Daniel J. Luke)

8.4p1_0+kerberos5+xauth builds fine. I don't use the other patches, so I don't bother to fix them up, but I usually bump a local copy of the Portfile whenever there's an openssh portable release.

comment:8 in reply to:  7 Changed 4 years ago by rswail (Ron Wail)

Replying to danielluke:

8.4p1_0+kerberos5+xauth builds fine. I don't use the other patches, so I don't bother to fix them up, but I usually bump a local copy of the Portfile whenever there's an openssh portable release.

Do you have the patchfiles and Portfile that you use for 8.4p1?

Changed 4 years ago by adpoliak

patch applied to clean configure script and its source to allow building under macOS Big Sur 11.1 / XCode 12.2

comment:9 Changed 4 years ago by adpoliak

by "clean", I mean the files directly extracted from "/opt/local/var/macports/distfiles/openssh/openssh-8.1p1.tar.gz" before any other patches are applied.

comment:10 Changed 4 years ago by olupton (Olli Lupton)

Cc: olupton added

comment:11 Changed 4 years ago by greyhare

It seems that OpenSSH 8.4p1 got stabilized, and it builds fine on Big Sur, so is this ticket moot?

comment:12 Changed 4 years ago by greyhare

Cc: greyhare added

Changed 4 years ago by soumyajyotih (Soumyajyoti Haldar)

Attachment: main.2.log added

comment:13 Changed 4 years ago by soumyajyotih (Soumyajyoti Haldar)

I still cannot compile openssh-8.4p1_0+gsskex+kerberos5+xauth. I see an error in terminal Error: Failed to build openssh: command execution failed.

See attached https://trac.macports.org/attachment/ticket/60959/main.2.log

However, openssh-8.4p1_0+kerberos5+xauth works.

comment:14 Changed 4 years ago by akkornel (A. Karl Kornel)

Cc: akkornel added

comment:15 Changed 3 years ago by cooljeanius (Eric Gallager)

Cc: cooljeanius added
Note: See TracTickets for help on using tickets.