NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: bin/41503: netbsd-5 LDSTATIC=-static amd build does not

The following reply was made to PR bin/41503; it has been noted by GNATS.

From: "Greg A. Woods" <>
Cc: Hauke Fath <>
Subject: Re: bin/41503: netbsd-5 LDSTATIC=-static amd build does not
Date: Fri, 29 May 2009 18:42:48 -0400

 Content-Type: text/plain; charset=US-ASCII
 Content-Transfer-Encoding: quoted-printable
 At Fri, 29 May 2009 08:20:01 +0000 (UTC), Hauke Fath 
 e> wrote:
 Subject: bin/41503: netbsd-5 LDSTATIC=3D-static amd build does not
 >      A run with LDSTATIC=3D-static (mac68k cross-build here,
 >      but doesn't really make a difference) fails to build amd(8)
 >      with
 Somewhere along the line there's a linker flag being added telling it to
 die on the warnings:
 It shouldn't be coming from though:
        # Set linker warnings to be fatal
        # XXX no proper way to avoid "FOO is a patented algorithm" warnings
        # XXX on linking static libs
        .if (!defined(MKPIC) || ${MKPIC} !=3D "no") && \
            (!defined(LDSTATIC) || ${LDSTATIC} !=3D "-static")
        LDFLAGS+=3D       -Wl,--fatal-warnings
 unless somehow LDSTATIC isn't seen to be set as a make variable at the
 right place....
 Maybe if you move the LDSTATIC=3D-static setting into /etc/mk.conf instead
 of setting it in's environment?  LDSTATIC isn't directly
 supported by, for what it's worth.  Also, FYI, I use "env -i"
 in my wrapper to as otherwise reproducible builds can be much
 more difficult to achieve:
        # make sure we start out with a very clean environment!
        if [ x"$_MY_BUILD_CLEAN" !=3D x"true" ]; then
                exec env -i USER=3D${USER} SHELL=3D/bin/ksh 
_MY_BUILD_CLEAN=3Dtrue "$0" $=
 Try checking all the various relevant make variables after moving
 LDSTATIC=3D-static to /etc/mk.conf, like this
     18:36 [298] $ pwd
     18:37 [299] $ nbmake-i386 -V LDFLAGS    =20
     18:37 [300] $ nbmake-i386 -V LDFLAGS.amd=20
     18:37 [301] $ nbmake-i386 -V LDSTATIC   =20
     18:38 [302] $=20
 I don't build amd myself (MKAMD=3Dno), but I'm sure other programs I do
 build would encounter the same problem, and as shown above for me
 LDSTATIC=3D-static somehow does prevent setting LDFLAGS with the fatal
 warning option.
                                                Greg A. Woods
                                                Planix, Inc.
 <>       +1 416 218-0099
 Content-Type: application/pgp-signature
 Content-Transfer-Encoding: 7bit
 Version: GnuPG v1.4.9 (NetBSD)

Home | Main Index | Thread Index | Old Index