GNU bug report logs - #21503
[PATCH] libtool: Fix support for NIOS2 processor

Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.

Package: libtool; Reported by: Marek Vasut <marex@HIDDEN>; Keywords: patch; dated Thu, 17 Sep 2015 04:57:02 UTC; Maintainer for libtool is bug-libtool@HIDDEN.

Message received at submit <at> debbugs.gnu.org:


Received: (at submit) by debbugs.gnu.org; 17 Sep 2015 04:56:11 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu Sep 17 00:56:11 2015
Received: from localhost ([127.0.0.1]:35617 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.80)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1ZcREw-0008Cd-Jg
	for submit <at> debbugs.gnu.org; Thu, 17 Sep 2015 00:56:11 -0400
Received: from eggs.gnu.org ([208.118.235.92]:47261)
 by debbugs.gnu.org with esmtp (Exim 4.80)
 (envelope-from <marex@HIDDEN>) id 1ZcMXA-0000nL-En
 for submit <at> debbugs.gnu.org; Wed, 16 Sep 2015 19:54:40 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <marex@HIDDEN>) id 1ZcMX8-0007XU-RM
 for submit <at> debbugs.gnu.org; Wed, 16 Sep 2015 19:54:40 -0400
X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org
X-Spam-Level: 
X-Spam-Status: No, score=-0.0 required=5.0 tests=BAYES_40 autolearn=disabled
 version=3.3.2
Received: from lists.gnu.org ([2001:4830:134:3::11]:43437)
 by eggs.gnu.org with esmtp (Exim 4.71)
 (envelope-from <marex@HIDDEN>) id 1ZcMX8-0007XJ-OW
 for submit <at> debbugs.gnu.org; Wed, 16 Sep 2015 19:54:38 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:57263)
 by lists.gnu.org with esmtp (Exim 4.71)
 (envelope-from <marex@HIDDEN>) id 1ZcMX7-0006DS-JI
 for bug-libtool@HIDDEN; Wed, 16 Sep 2015 19:54:38 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <marex@HIDDEN>) id 1ZcMX4-0007WW-8N
 for bug-libtool@HIDDEN; Wed, 16 Sep 2015 19:54:37 -0400
Received: from mail-out.m-online.net ([212.18.0.10]:32941)
 by eggs.gnu.org with esmtp (Exim 4.71)
 (envelope-from <marex@HIDDEN>) id 1ZcMX4-0007W8-1O
 for bug-libtool@HIDDEN; Wed, 16 Sep 2015 19:54:34 -0400
Received: from mail.nefkom.net (unknown [192.168.8.184])
 by mail-out.m-online.net (Postfix) with ESMTP id 3nGdZG639Nz3hj0T;
 Thu, 17 Sep 2015 01:54:30 +0200 (CEST)
X-Auth-Info: DOKTgGB/867LaAhimEhngdvT/zN+jhz4ONc2dFZxeu8=
Received: from chi.lan (unknown [195.140.253.167])
 by smtp-auth.mnet-online.de (Postfix) with ESMTPA id 3nGdZG3g0JzvdWS;
 Thu, 17 Sep 2015 01:54:30 +0200 (CEST)
From: Marek Vasut <marex@HIDDEN>
To: bug-libtool@HIDDEN
Subject: [PATCH] libtool: Fix support for NIOS2 processor
Date: Thu, 17 Sep 2015 01:54:37 +0200
Message-Id: <1442447677-6678-1-git-send-email-marex@HIDDEN>
X-Mailer: git-send-email 2.1.4
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x
X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address
 (bad octet value).
X-Received-From: 2001:4830:134:3::11
X-Spam-Score: -5.0 (-----)
X-Debbugs-Envelope-To: submit
X-Mailman-Approved-At: Thu, 17 Sep 2015 00:56:08 -0400
Cc: Marek Vasut <marex@HIDDEN>, lftan@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -5.0 (-----)

The name of the system contains the string "nios2". This string
is caught by the some of the greedy checks for OS/2 in libtool,
in particular the *os2* branches of switch statements match for
the nios2 string, which results in incorrect behavior of libtool.

This patch adds an explicit check for *nios2* before the *os2*
checks to prevent the OS/2 check incorrectly trapping the nios2
as well.

Signed-off-by: Marek Vasut <marex@HIDDEN>
---
 build-aux/ltmain.in | 20 ++++++++++++++++++++
 1 file changed, 20 insertions(+)

diff --git a/build-aux/ltmain.in b/build-aux/ltmain.in
index d5cf07a..4164284 100644
--- a/build-aux/ltmain.in
+++ b/build-aux/ltmain.in
@@ -504,6 +504,12 @@ libtool_validate_options ()
     test : = "$debug_cmd" || func_append preserve_args " --debug"
 
     case $host in
+      # For NIOS2, we want to make sure that it's not caught by the
+      # more general OS/2 check below. Otherwise, NIOS2 is the same
+      # as the default option.
+      *nios2*)
+        opt_duplicate_compiler_generated_deps=$opt_preserve_dup_deps
+        ;;
       # Solaris2 added to fix http://debbugs.gnu.org/cgi/bugreport.cgi?bug=16452
       # see also: http://gcc.gnu.org/bugzilla/show_bug.cgi?id=59788
       *cygwin* | *mingw* | *pw32* | *cegcc* | *solaris2* | *os2*)
@@ -6220,6 +6226,15 @@ func_mode_link ()
 	if test -n "$library_names" &&
 	   { test no = "$use_static_libs" || test -z "$old_library"; }; then
 	  case $host in
+	  *nios2*)
+	    # For NIOS2, we want to make sure that it's not caught by the
+	    # more general OS/2 check below. Otherwise, NIOS2 is the same
+	    # as the default option.
+	    if test no = "$installed"; then
+	      func_append notinst_deplibs " $lib"
+	      need_relink=yes
+	    fi
+	    ;;
 	  *cygwin* | *mingw* | *cegcc* | *os2*)
 	      # No point in relinking DLLs because paths are not encoded
 	      func_append notinst_deplibs " $lib"
@@ -6290,6 +6305,11 @@ func_mode_link ()
 	    elif test -n "$soname_spec"; then
 	      # bleh windows
 	      case $host in
+	      *nios2*)
+		# For NIOS2, we want to make sure that it's not caught by the
+		# more general OS/2 check below. Otherwise, NIOS2 is the same
+		# as the default option.
+		;;
 	      *cygwin* | mingw* | *cegcc* | *os2*)
 	        func_arith $current - $age
 		major=$func_arith_result
-- 
2.5.1





Acknowledgement sent to Marek Vasut <marex@HIDDEN>:
New bug report received and forwarded. Copy sent to bug-libtool@HIDDEN. Full text available.
Report forwarded to bug-libtool@HIDDEN:
bug#21503; Package libtool. Full text available.
Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.
Last modified: Mon, 25 Nov 2019 12:00:02 UTC

GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997 nCipher Corporation Ltd, 1994-97 Ian Jackson.