Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 6 Jul 2012 19:25:45 GMT
From:      Pawel Pekala <pawel@FreeBSD.org>
To:        freebsd-gnats-submit@FreeBSD.org
Subject:   ports/169688: devel/binutils fix build with clang
Message-ID:  <201207061925.q66JPjGP077933@red.freebsd.org>
Resent-Message-ID: <201207061930.q66JUBL8042403@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         169688
>Category:       ports
>Synopsis:       devel/binutils fix build with clang
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Fri Jul 06 19:30:11 UTC 2012
>Closed-Date:
>Last-Modified:
>Originator:     Pawel Pekala
>Release:        10.0-CURRENT
>Organization:
>Environment:
FreeBSD blaviken.slowicza.org 10.0-CURRENT FreeBSD 10.0-CURRENT #8: Sat Jun 30 10:52:22 CEST 2012     corn@blaviken.slowicza.org:/usr/obj/usr/src/sys/BLAVIKEN  i386

>Description:
Add patch to fix few namespace problems
>How-To-Repeat:

>Fix:


Patch attached with submission follows:

diff -urN /usr/ports/devel/binutils/files/patch-gold__script.cc ./files/patch-gold__script.cc
--- /usr/ports/devel/binutils/files/patch-gold__script.cc	1970-01-01 01:00:00.000000000 +0100
+++ ./files/patch-gold__script.cc	2012-07-06 20:57:27.000000000 +0200
@@ -0,0 +1,65 @@
+--- ./gold/script.cc.orig	2012-07-06 20:51:01.000000000 +0200
++++ ./gold/script.cc	2012-07-06 20:53:41.000000000 +0200
+@@ -2871,7 +2871,7 @@
+   else if (!closure->command_line()->options().nostdlib())
+     {
+       std::string s = "-L" + std::string(option, length);
+-      script_parse_option(closurev, s.c_str(), s.size());
++      gold::script_parse_option(closurev, s.c_str(), s.size());
+     }
+ }
+ 
+@@ -3011,7 +3011,7 @@
+       snprintf(buf, langlen + 100,
+ 	       _("unrecognized version script language '%s'"),
+ 	       language.c_str());
+-      yyerror(closurev, buf);
++      gold::yyerror(closurev, buf);
+       delete[] buf;
+       code = Version_script_info::LANGUAGE_C;
+     }
+@@ -3165,7 +3165,7 @@
+ 			    const struct Wildcard_section* string_sort)
+ {
+   if (pv == NULL)
+-    return script_new_string_sort_list(string_sort);
++    return gold::script_new_string_sort_list(string_sort);
+   else
+     {
+       pv->push_back(*string_sort);
+@@ -3189,7 +3189,7 @@
+ script_string_list_push_back(String_list_ptr pv, const char* str, size_t len)
+ {
+   if (pv == NULL)
+-    return script_new_string_list(str, len);
++    return gold::script_new_string_list(str, len);
+   else
+     {
+       pv->push_back(std::string(str, len));
+@@ -3261,7 +3261,7 @@
+     if (namelen == phdr_type_names[i].namelen
+ 	&& strncmp(name, phdr_type_names[i].name, namelen) == 0)
+       return phdr_type_names[i].val;
+-  yyerror(closurev, _("unknown PHDR type (try integer)"));
++  gold::yyerror(closurev, _("unknown PHDR type (try integer)"));
+   return elfcpp::PT_NULL;
+ }
+ 
+@@ -3336,7 +3336,7 @@
+       case 'l':
+ 	attributes |= MEM_INITIALIZED; break;
+       default:
+-	yyerror(closurev, _("unknown MEMORY attribute"));
++	gold::yyerror(closurev, _("unknown MEMORY attribute"));
+       }
+ 
+   if (invert)
+@@ -3349,7 +3349,7 @@
+ script_include_directive(void* closurev, const char*, size_t)
+ {
+   // FIXME: Implement ?
+-  yyerror (closurev, _("GOLD does not currently support INCLUDE directives"));
++  gold::yyerror (closurev, _("GOLD does not currently support INCLUDE directives"));
+ }
+ 
+ // Functions for memory regions.


>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201207061925.q66JPjGP077933>