Re: ld-elf.so.1: /usr/local/lib/libglib-2.0.so.0: Undefined symbol "environ" (RPI/arm64)

From: Julian H. Stacey <jhs_at_berklix.com>
Date: Mon, 07 Jan 2019 17:25:55 +0100
Hi, Reference:
> From:		"Julian H. Stacey" <jhs_at_berklix.com>
> Date:		Sun, 06 Jan 2019 23:31:03 +0100

"Julian H. Stacey" wrote:
> Gary Jennejohn wrote:
> > On Sun, 06 Jan 2019 08:13:52 +0100
> > "Julian H. Stacey" <jhs_at_berklix.com> wrote:
> > 
> > > > > > $ chrome
> > > > > > ld-elf.so.1: /usr/local/lib/libglib-2.0.so.0: Undefined symbol "environ"  
> > > 
> > > [ Delayed report (as it took about 2 days to build chrome from ports/)] ...
> > > 
> > > I too am still seing from chrome:
> > > 	ld-elf.so.1: /usr/local/lib/libglib-2.0.so.0: Undefined symbol "environ"
> > > which I first saw from chrome after a pkg add, but now too from a ports/ build
> > > 
> > > My src/ was maybe a week or so old. To be precise on next failure report,
> > > I've since added WITHOUT_REPRODUCIBLE_BUILD="YES" to /etc/src.conf 
> > > & finished a buildworld  on .svn_revision 342785, now running buildkernel
> > > 
> > 
> > IIRC the problem was attributed to some flags being passed to the
> > compiler or linker.  Don't know exactly which reply, but it
> > should be findable in the mail-list database.  AFAIK it was never
> > verified that it was the cause.
> 
> Thanks Gary, my world is now updated to
> uname -a
> FreeBSD lapr.js.berklix.net 13.0-CURRENT FreeBSD 13.0-CURRENT #0: Sun Jan  6 08:06:58 CET 2019     jhs_at_lapr.js.berklix.net:/usr/obj/usr/src/amd64.amd64/sys/GENERIC  amd64
> /usr/src/.svn_revision 342810
> 
> chrome still fails
> 
> https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=220103
> has 30 comments inc. 2 patches (That Ive had no time to try yet)

chrome now works after I hand patched my already built /usr/ports/www/chromium
using this patch 
------
--- build/linux/chrome.map.orig	2018-08-08 19:10:32 UTC
+++ build/linux/chrome.map
_at__at_ -1,4 +1,7 _at__at_
 {
+local:
+  *;
+
 global:
   __bss_start;
   __data_start;
_at__at_ -20,6 +23,10 _at__at_ global:
   # Program entry point.
   _start;
 
+  # FreeBSD specific variables.
+  __progname;
+  environ;
+
   # Memory allocation symbols.  We want chrome and any libraries to
   # share the same heap, so it is correct to export these symbols.
   calloc;
_at__at_ -81,7 +88,4 _at__at_ global:
   localtime64;
   localtime64_r;
   localtime_r;
-
-local:
-  *;
 };

------
which looks like
https://bugs.freebsd.org/bugzilla/attachment.cgi?id=200811&action=diff

I extracted mine by hand from 
https://bz-attachments.freebsd.org/attachment.cgi?id=200811
Where Max also says it works.

Thanks to Dimitry Andric cc'd for the patch,
I hope it gets commited.

Cheers,
Julian
-- 
Julian Stacey, Computer Consultant Sys.Eng. BSD Linux Unix, Munich Aachen Kent
 First referendum stole 700,000 votes from Brits in EU;  3,700,000 globaly.
 Lies criminal funded; jobs pound & markets down. 1.9M new voters 1.3M dead.
 Email MP: "A new referendum will buy UK & EU more time (Art 50.3), to avoid
       a hard crash, & consider all options."  http://berklix.org/brexit/#mp
Received on Mon Jan 07 2019 - 15:26:29 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:41:19 UTC