Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 732098 - sys-auth/pam_skey configure test for ld -shared fails with clang
Summary: sys-auth/pam_skey configure test for ld -shared fails with clang
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Ulrich Müller
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: systemwide-clang
  Show dependency tree
 
Reported: 2020-07-10 12:22 UTC by Agostino Sarubbo
Modified: 2020-07-10 15:13 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
build.log (build.log,11.38 KB, text/plain)
2020-07-10 12:22 UTC, Agostino Sarubbo
Details
other.tar.bz2 (other.tar.bz2,241 bytes, application/x-bzip-compressed-tar)
2020-07-10 12:22 UTC, Agostino Sarubbo
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Agostino Sarubbo gentoo-dev 2020-07-10 12:22:39 UTC
https://blogs.gentoo.org/ago/2020/07/04/gentoo-tinderbox/

Issue: sys-auth/pam_skey fails to compile.
Discovered on: amd64  (internal ref: tinderbox)

NOTE:
This machine uses a clang/LLVM toolchain.
If you think that this issue is strictly related to clang/LLVM please block bug 408963. If you think that this issue isstrictly related to the LLD linker, please block bug 731004.
Comment 1 Agostino Sarubbo gentoo-dev 2020-07-10 12:22:48 UTC
Created attachment 648808 [details]
build.log

build log and emerge --info
Comment 2 Agostino Sarubbo gentoo-dev 2020-07-10 12:22:52 UTC
Created attachment 648812 [details]
other.tar.bz2

other logs
Comment 3 Ulrich Müller gentoo-dev 2020-07-10 13:32:59 UTC
The problem is in configure:

checking for the ld -shared flag... no
Comment 4 Larry the Git Cow gentoo-dev 2020-07-10 13:46:46 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/dev/ulm.git/commit/?id=3f79558a92d59bc8e691c04ea001eaaa94148a1d

commit 3f79558a92d59bc8e691c04ea001eaaa94148a1d
Author:     Ulrich Müller <ulm@gentoo.org>
AuthorDate: 2020-07-10 13:38:28 +0000
Commit:     Ulrich Müller <ulm@gentoo.org>
CommitDate: 2020-07-10 13:38:28 +0000

    pam_skey: Fix configure test for ld -shared.
    
    Bug: https://bugs.gentoo.org/732098
    Signed-off-by: Ulrich Müller <ulm@gentoo.org>

 patchsets/pam_skey/1.1.5/06_all_ld-shared.patch | 13 +++++++++++++
 1 file changed, 13 insertions(+)
Comment 5 Larry the Git Cow gentoo-dev 2020-07-10 13:49:41 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7d197240b806daa3898e8a32fa9dd58ccaa999a7

commit 7d197240b806daa3898e8a32fa9dd58ccaa999a7
Author:     Ulrich Müller <ulm@gentoo.org>
AuthorDate: 2020-07-10 13:49:02 +0000
Commit:     Ulrich Müller <ulm@gentoo.org>
CommitDate: 2020-07-10 13:49:26 +0000

    sys-auth/pam_skey: Fix configure test for ld -shared.
    
    Closes: https://bugs.gentoo.org/732098
    Package-Manager: Portage-2.3.103, Repoman-2.3.23
    Signed-off-by: Ulrich Müller <ulm@gentoo.org>

 sys-auth/pam_skey/Manifest                 | 2 +-
 sys-auth/pam_skey/pam_skey-1.1.5-r6.ebuild | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)
Comment 6 Ulrich Müller gentoo-dev 2020-07-10 15:13:32 UTC
To clarify why I have labelled this as a clang issue:
configure.ac contains the following snippet:

AC_MSG_CHECKING(for the ld -shared flag)
LDFLAGS="${LDFLAGS} -shared"
AC_TRY_LINK([#include <stdio.h>], [void blahblah(){fprintf(stderr, "");}],
found=yes, found=no)

It is translated to this program ...

#include <stdio.h>
int
main ()
{
void blahblah(){fprintf(stderr, "");}
  ;
  return 0;
}

... which contains nested function definitions. These are allowed in gcc:
https://gcc.gnu.org/onlinedocs/gcc/Nested-Functions.html

Apparently clang has a problem with that construct. (Presumably it needs an extra option to enable support, but it looked simpler to remove the nesting instead.)