Date: Mon, 25 Nov 2013 21:24:58 +0200 From: Konstantin Belousov <kostikbel@gmail.com> To: Dimitry Andric <dim@FreeBSD.org> Cc: Glen Barber <gjb@FreeBSD.org>, freebsd-current <freebsd-current@freebsd.org>, peter@freebsd.org Subject: Re: Buildworld broken with WITHOUT_DYNAMICROOT=yes in src.conf Message-ID: <20131125192458.GQ59496@kib.kiev.ua> In-Reply-To: <063D36C2-E1D0-449E-A662-0CCA5A9B887E@FreeBSD.org> References: <201311250111.rAP1BuI0009520@pozo.com> <20131125011949.GC1627@glenbarber.us> <20131125012302.GD1627@glenbarber.us> <201311250129.rAP1TJfQ033437@pozo.com> <20131125041724.GA2310@glenbarber.us> <201311250441.rAP4freb002330@pozo.com> <20131125044854.GC2310@glenbarber.us> <20131125075110.GL59496@kib.kiev.ua> <063D36C2-E1D0-449E-A662-0CCA5A9B887E@FreeBSD.org>
next in thread | previous in thread | raw e-mail | index | archive | help
[-- Attachment #1 --]
On Mon, Nov 25, 2013 at 01:36:15PM +0100, Dimitry Andric wrote:
> On 25 Nov 2013, at 08:51, Konstantin Belousov <kostikbel@gmail.com> wrote:
> > On Sun, Nov 24, 2013 at 11:48:54PM -0500, Glen Barber wrote:
> ...
> >> Index: Makefile
> >> ===================================================================
> >> --- Makefile (revision 258538)
> >> +++ Makefile (working copy)
> >> @@ -42,6 +42,9 @@
> >>
> >> DPADD= ${LIBTERMCAP} ${LIBCRYPT}
> >> LDADD= -ltermcap -lcrypt
> >> +.if ${MK_ICONV} != "no" && ${MK_DYNAMICROOT} != "yes"
> >> +LDADD+= -lc_nonshared
> >> +.endif
> >>
> >> LINKS= ${BINDIR}/csh ${BINDIR}/tcsh
> >>
> >
> > No, this is wrong. As is, static linking is broken and the hack above
> > only fixes one case.
> >
> > What is needed is inclusion of the lib/libc_nonshared object files into
> > static libc.a. I am not sure how to express this in our build system.
>
> Hi Kostik,
>
> You can add the additional object files to ${STATICOBJS}. These will
> only be built for the static and profiled libraries. See for example
> gnu/lib/libgcc/Makefile or lib/libc++/Makefile.
>
The patch we ended up with is available at
http://people.freebsd.org/~kib/misc/iconv_static_linking.1.patch
[-- Attachment #2 --]
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.22 (FreeBSD)
iQIcBAEBAgAGBQJSk6QJAAoJEJDCuSvBvK1BU5UP/173BRM9yTAtdAN49eA7ZpfC
/TZR7GhGhUnlavmB0JZ/j4OL+aG+0+8keoqj/pRkx1MYI2OFQKeLV+MrFjnjNPuJ
CrsZhz/4SD1JSt/PgMUpq8VDz2xucMO0Yhm/jtzLEpt2NpHYkaOBHofNAnPLAgSS
uZkitXtyS1/wK1uxtvt9JqOXmvb2xO1cAKzCyCU3+MQm9+HhsIOUAEcEXCuf+FdO
7R0KdpveQ9KHJMtiNF2Y5gF4nENEfGhYQ03GR1FaohbzPZsvzu78MnosgM7XySs9
R+cb2kj0M7pDRj+v7fHdt2d3qSaYUtwPty8yVihzcjI24VRh/m0SmFAYaGq403Sw
Q351w8vjT1HAMI19m9S8siwzdRARGfMegv4IfT96o5qH6XWORgcWHO0dtoe5s81n
YU/8YlOxff4kyFRg4k9QiqkOLCvoPJVEqgR55bBy9T2JigX+VmAwLgsdgNzzxAuk
FT0aMHoi72/YlNbF0MlW5eBfuUyUyrp3GUNn4YtaPqlIAyZ27dNvAZGUwukk2EtO
c4+Ruxr8iMuUM9vxbJFDleftkQkH3I0eW8E/AIPV8XXrBWY3NmEQaQhXkBG96NRG
toEdjFp3+yLXNcFSXZoNioJ8/MCbY25c/trznjNYonM5PRTmwKymTuN4255ZWUmC
r0rcyZC7L5UIMpFEv4Xr
=2FUy
-----END PGP SIGNATURE-----
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20131125192458.GQ59496>
