public inbox for glibc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug build/14476] New: test-installation.pl fails on x86_64
@ 2012-08-16  5:03 bruce.dubbs at gmail dot com
  2012-08-28 12:53 ` [Bug build/14476] " aj at suse dot de
                   ` (6 more replies)
  0 siblings, 7 replies; 8+ messages in thread
From: bruce.dubbs at gmail dot com @ 2012-08-16  5:03 UTC (permalink / raw)
  To: glibc-bugs

http://sourceware.org/bugzilla/show_bug.cgi?id=14476

             Bug #: 14476
           Summary: test-installation.pl fails on x86_64
           Product: glibc
           Version: 2.16
            Status: NEW
          Severity: normal
          Priority: P2
         Component: build
        AssignedTo: unassigned@sourceware.org
        ReportedBy: bruce.dubbs@gmail.com
                CC: carlos@systemhalted.org
    Classification: Unclassified


When building glibc-2.16, 'make install' runs test-installation.pl.  This
fails.

I traced it down to an error in soversions.mk.  A literal extract:

...
ld.so-version=$(if $(abi-64-ld-soname),$(abi-64-ld-soname),ld.so.1)
all-sonames+=ld=$(ld.so-version)
...

The value for ld.so-version crashes test-installation.pl.  It should be
ld-linux-x86-64.so.2.  abi-64-ld-soname is defined correctly in
sysdeps/unix/sysv/linux/x86/Makefile, but it is not getting into soversions.mk.

This problem seems to have been introduced into Makeconfig on 26 May 2012 in
commit 0ab0291b84b45f2389a019af2c88bf5169d14f64

@@ -816,24 +834,17 @@ $(common-objpfx)soversions.i: $(..)scripts/soversions.awk
\
               -f $^ > $@T
        mv -f $@T $@
 $(common-objpfx)soversions.mk: $(common-objpfx)soversions.i $(..)Makeconfig
-       (seen_DEFAULT=0; seen_WORDSIZE32=0; seen_WORDSIZE64=0; \
-        while read which lib number setname; do \
+       (while read which lib number setname; do \
           eval seen_$$which=1; \
           test x"$$which" != xABI || echo abi-name = "$$lib"; \
           test x"$$which" = xDEFAULT || continue; \
           case $$number in \
             [0-9]*) echo "$$lib.so-version=.$$number"; \
                     echo "all-sonames+=$$lib=$$lib.so\$$($$lib.so-version)";;\
-            *)      echo "$$lib.so-version=$$number"; \
+            *)      echo "$$lib.so-version=\$$(if
\$$(abi-$(default-abi)-$$lib-soname),\$$(abi-$(default-abi)-$$lib-soname),$$number)";
\
                     echo "all-sonames+=$$lib=\$$($$lib.so-version)";;\
           esac; \
         done; \

We can work around this by simply deleting the test-installation.pl line from
the Makefile, but that doesn't seem to be a real fix.

  -- Bruce Dubbs
     linuxfromscratch.org

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug build/14476] test-installation.pl fails on x86_64
  2012-08-16  5:03 [Bug build/14476] New: test-installation.pl fails on x86_64 bruce.dubbs at gmail dot com
@ 2012-08-28 12:53 ` aj at suse dot de
  2012-08-28 16:23 ` hjl.tools at gmail dot com
                   ` (5 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: aj at suse dot de @ 2012-08-28 12:53 UTC (permalink / raw)
  To: glibc-bugs

http://sourceware.org/bugzilla/show_bug.cgi?id=14476

Andreas Jaeger <aj at suse dot de> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |aj at suse dot de,
                   |                            |hjl.tools at gmail dot com

--- Comment #1 from Andreas Jaeger <aj at suse dot de> 2012-08-28 12:52:53 UTC ---
HJ, this seems to have introduced by one of your commits. Could you have a look
at it, please?

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug build/14476] test-installation.pl fails on x86_64
  2012-08-16  5:03 [Bug build/14476] New: test-installation.pl fails on x86_64 bruce.dubbs at gmail dot com
  2012-08-28 12:53 ` [Bug build/14476] " aj at suse dot de
@ 2012-08-28 16:23 ` hjl.tools at gmail dot com
  2012-08-28 17:05 ` bruce.dubbs at gmail dot com
                   ` (4 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: hjl.tools at gmail dot com @ 2012-08-28 16:23 UTC (permalink / raw)
  To: glibc-bugs

http://sourceware.org/bugzilla/show_bug.cgi?id=14476

H.J. Lu <hjl.tools at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |WAITING

--- Comment #2 from H.J. Lu <hjl.tools at gmail dot com> 2012-08-28 16:22:51 UTC ---
scripts/test-installation.pl reads soversions.mk.  But it
doesn't understand

ld.so-version=$(if $(abi-64-ld-soname),$(abi-64-ld-soname),ld.so.1)

We do

diff --git a/Makefile b/Makefile
index b0d3edb..8eccec7 100644
--- a/Makefile
+++ b/Makefile
@@ -111,7 +111,7 @@ install:
 ifneq (no,$(PERL))
 ifeq (/usr,$(prefix))
 ifeq (,$(install_root))
-    CC="$(CC)" $(PERL) scripts/test-installation.pl $(common-objpfx)
+    LD_SO_VERSION=$(ld.so-version) CC="$(CC)" $(PERL) scripts/test-installat
ion.pl $(common-objpfx)
 endif
 endif
 endif

and update scripts/test-installation.pl to use it.  Is there a way to test
scripts/test-installation.pl with install_root set?

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug build/14476] test-installation.pl fails on x86_64
  2012-08-16  5:03 [Bug build/14476] New: test-installation.pl fails on x86_64 bruce.dubbs at gmail dot com
  2012-08-28 12:53 ` [Bug build/14476] " aj at suse dot de
  2012-08-28 16:23 ` hjl.tools at gmail dot com
@ 2012-08-28 17:05 ` bruce.dubbs at gmail dot com
  2012-08-28 17:59 ` hjl.tools at gmail dot com
                   ` (3 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: bruce.dubbs at gmail dot com @ 2012-08-28 17:05 UTC (permalink / raw)
  To: glibc-bugs

http://sourceware.org/bugzilla/show_bug.cgi?id=14476

--- Comment #3 from Bruce Dubbs <bruce.dubbs at gmail dot com> 2012-08-28 17:05:03 UTC ---
That doesn't affect the perl script.  Starting at line 97:

while (<SOVERSIONS>) {
  next if (/^all-sonames/);
  chop;
  if (/^lib/) {
    ($name, $version)= /^lib(.*)\.so-version=\.(.*)$/;
    # Filter out some libraries we don't want to link:
    # - nss_ldap since it's not yet available
    # - libdb1 since it conflicts with libdb
    # - libnss1_* from glibc-compat add-on
    # - libthread_db since it contains unresolved references
    # - it's just a test NSS module
    # - We don't provide the libgcc so we don't test it
    if ($name ne "nss_ldap" && $name ne "db1"
        && !($name =~/^nss1_/) && $name ne "thread_db"
        && $name ne "nss_test1" && $name ne "libgcc_s") {
      $link_libs .= " -l$name";
      $versions{$name} = $version;
    }
  } else {
    if (/^ld\.so/) {
      ($ld_so_name, $ld_so_version)= /=(.*)\.so\.(.*)$/;
    }
  }
}

The problem is in the else clause.  It does not evaluate the expression to the
right of the = sign.  Also, the value in the expression extracted from
soversions.mk, $(abi-64-ld-soname), is not defined in the script.

LD_SO_VERSION is never used in the script.

A hack would be:

if ( /ld\.so-version/ ) {
  ld.so-version = $LD_SO_VERSION;
}

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug build/14476] test-installation.pl fails on x86_64
  2012-08-16  5:03 [Bug build/14476] New: test-installation.pl fails on x86_64 bruce.dubbs at gmail dot com
                   ` (2 preceding siblings ...)
  2012-08-28 17:05 ` bruce.dubbs at gmail dot com
@ 2012-08-28 17:59 ` hjl.tools at gmail dot com
  2012-08-28 19:25 ` bruce.dubbs at gmail dot com
                   ` (2 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: hjl.tools at gmail dot com @ 2012-08-28 17:59 UTC (permalink / raw)
  To: glibc-bugs

http://sourceware.org/bugzilla/show_bug.cgi?id=14476

--- Comment #4 from H.J. Lu <hjl.tools at gmail dot com> 2012-08-28 17:58:50 UTC ---
Created attachment 6616
  --> http://sourceware.org/bugzilla/attachment.cgi?id=6616
A patch

This patch passes $(ld.so-version) to scripts/test-installation.pl.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug build/14476] test-installation.pl fails on x86_64
  2012-08-16  5:03 [Bug build/14476] New: test-installation.pl fails on x86_64 bruce.dubbs at gmail dot com
                   ` (3 preceding siblings ...)
  2012-08-28 17:59 ` hjl.tools at gmail dot com
@ 2012-08-28 19:25 ` bruce.dubbs at gmail dot com
  2012-08-30 13:48 ` hjl.tools at gmail dot com
  2014-06-17 18:37 ` fweimer at redhat dot com
  6 siblings, 0 replies; 8+ messages in thread
From: bruce.dubbs at gmail dot com @ 2012-08-28 19:25 UTC (permalink / raw)
  To: glibc-bugs

http://sourceware.org/bugzilla/show_bug.cgi?id=14476

--- Comment #5 from Bruce Dubbs <bruce.dubbs at gmail dot com> 2012-08-28 19:25:21 UTC ---
That patch works fine.  I now get (slightly formatted):

LD_SO=ld-linux-x86-64.so.2 CC="gcc" /usr/bin/perl scripts/test-installation.pl
\
/sources/glibc-build/
Your new glibc installation seems to be ok.
make[1]: Leaving directory `/sources/glibc-2.16.0'

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug build/14476] test-installation.pl fails on x86_64
  2012-08-16  5:03 [Bug build/14476] New: test-installation.pl fails on x86_64 bruce.dubbs at gmail dot com
                   ` (4 preceding siblings ...)
  2012-08-28 19:25 ` bruce.dubbs at gmail dot com
@ 2012-08-30 13:48 ` hjl.tools at gmail dot com
  2014-06-17 18:37 ` fweimer at redhat dot com
  6 siblings, 0 replies; 8+ messages in thread
From: hjl.tools at gmail dot com @ 2012-08-30 13:48 UTC (permalink / raw)
  To: glibc-bugs

http://sourceware.org/bugzilla/show_bug.cgi?id=14476

H.J. Lu <hjl.tools at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|WAITING                     |RESOLVED
         Resolution|                            |FIXED

--- Comment #6 from H.J. Lu <hjl.tools at gmail dot com> 2012-08-30 13:47:56 UTC ---
Fixed on master and 2.16 branch.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug build/14476] test-installation.pl fails on x86_64
  2012-08-16  5:03 [Bug build/14476] New: test-installation.pl fails on x86_64 bruce.dubbs at gmail dot com
                   ` (5 preceding siblings ...)
  2012-08-30 13:48 ` hjl.tools at gmail dot com
@ 2014-06-17 18:37 ` fweimer at redhat dot com
  6 siblings, 0 replies; 8+ messages in thread
From: fweimer at redhat dot com @ 2014-06-17 18:37 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=14476

Florian Weimer <fweimer at redhat dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
              Flags|                            |security-

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2014-06-17 18:37 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-08-16  5:03 [Bug build/14476] New: test-installation.pl fails on x86_64 bruce.dubbs at gmail dot com
2012-08-28 12:53 ` [Bug build/14476] " aj at suse dot de
2012-08-28 16:23 ` hjl.tools at gmail dot com
2012-08-28 17:05 ` bruce.dubbs at gmail dot com
2012-08-28 17:59 ` hjl.tools at gmail dot com
2012-08-28 19:25 ` bruce.dubbs at gmail dot com
2012-08-30 13:48 ` hjl.tools at gmail dot com
2014-06-17 18:37 ` fweimer at redhat dot com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).