Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 12 Dec 2014 09:50:13 +0100
From:      Willem Jan Withagen <wjw@digiware.nl>
To:        "stable@freebsd.org" <stable@freebsd.org>
Subject:   Re: missing /usr/lib/libc_nonshared.a
Message-ID:  <548AAC45.8080800@digiware.nl>
In-Reply-To: <54837FAC.801@digiware.nl>
References:  <54837FAC.801@digiware.nl>

next in thread | previous in thread | raw e-mail | index | archive | help
On 2014-12-06 23:14, Willem Jan Withagen wrote:
> Hi,
>
> Still trying to upgrade from 9.3 to 10.1, which seemed to get going.
> Completely started over again with cleaned out /etc/{make.src}.conf.
> Then build/installed 9.3 again which also included clang this time.
>
> but building the toolchain generates:
> --------------------------------------------------------------
>>>> stage 2.3: build tools
> --------------------------------------------------------------
> cd /usr/src10; MAKEOBJDIRPREFIX=/usr/obj  INSTALL="sh
> /usr/src10/tools/install.sh"
> PATH=/usr/obj/usr/src10/tmp/legacy/usr/sbin:/usr/obj/usr/src10/tmp/legacy/usr/bin:/usr/obj/usr/src10/tmp/legacy/usr/games:/usr/obj/usr/src10/tmp/legacy/bin:/sbin:/bin:/usr/sbin:/usr/bin
>   WORLDTMP=/usr/obj/usr/src10/tmp  VERSION="FreeBSD 10.1-STABLE amd64
> 1001503"  MAKEFLAGS="-m /usr/src10/tools/build/mk  -m
> /usr/src10/share/mk"  COMPILER_TYPE=gcc
> /usr/obj/usr/src10/make.amd64/bmake  -f Makefile.inc1  TARGET=amd64
> TARGET_ARCH=amd64  DESTDIR=  BOOTSTRAPPING=903506  SSP_CFLAGS=
> -DNO_LINT  -DNO_CPU_CFLAGS -DNO_WARNS -DNO_CTF -DEARLY_BUILD -DNO_TESTS
> build-tools
> ===> bin/csh (obj,build-tools)
> grep 'ERR_' /usr/src10/bin/csh/../../contrib/tcsh/sh.err.c | grep
> '^#define' >> sh.err.h
> cc -E -O2 -pipe -I. -I/usr/src10/bin/csh
> -I/usr/src10/bin/csh/../../contrib/tcsh -D_PATH_TCSHELL='"/bin/csh"'
> -std=gnu99 -I/usr/obj/usr/src10/tmp/legacy/usr/include
> /usr/src10/bin/csh/../../contrib/tcsh/tc.const.c
> /usr/src10/bin/csh/../../contrib/tcsh/sh.char.h
> /usr/src10/bin/csh/config.h
> /usr/src10/bin/csh/../../contrib/tcsh/config_f.h
> /usr/src10/bin/csh/../../contrib/tcsh/sh.types.h sh.err.h -D_h_tc_const
> |  grep 'Char STR' |  sed -e 's/Char \([a-zA-Z0-9_]*\)\(.*\)/extern Char
> \1[];/' |  sort >> tc.const.h
> cc -o gethost  -L/usr/obj/usr/src10/tmp/legacy/usr/lib -O2 -pipe -I.
> -I/usr/src10/bin/csh -I/usr/src10/bin/csh/../../contrib/tcsh
> -D_PATH_TCSHELL='"/bin/csh"' -std=gnu99
> -I/usr/obj/usr/src10/tmp/legacy/usr/include
> /usr/src10/bin/csh/../../contrib/tcsh/gethost.c
> /usr/bin/ld: cannot find /usr/lib/libc_nonshared.a
> *** Error code 1
> -----------------
>
> Now I can fudge around this, by getting this lib from another 10.x
> system, but changes are that things are nog 100% compatible.
>
> So how do I get this lib first, before starting to build bin/csh.
>
> The other question is:
> 	why am I still using gcc for the toolchain even since I now have
> 	clang onboard?

Turn out that the only way I could cheat make in to going anywhere was to:
	cd /usr/src/lib/libc_nonshared
	make
	make install

And only then the build seems to progress.

This all even though the /usr/obj tree holds:
[~] wjw > locate libc_non
/usr/objs/amd64/usr/src10/lib/libc_nonshared
/usr/objs/amd64/usr/src10/lib/libc_nonshared/.depend
/usr/objs/amd64/usr/src10/lib/libc_nonshared/__iconv.o
/usr/objs/amd64/usr/src10/lib/libc_nonshared/__iconv_free_list.o
/usr/objs/amd64/usr/src10/lib/libc_nonshared/__iconv_get_list.o
/usr/objs/amd64/usr/src10/lib/libc_nonshared/__stub.o
/usr/objs/amd64/usr/src10/lib/libc_nonshared/iconv.o
/usr/objs/amd64/usr/src10/lib/libc_nonshared/iconv_canonicalize.o
/usr/objs/amd64/usr/src10/lib/libc_nonshared/iconv_close.o
/usr/objs/amd64/usr/src10/lib/libc_nonshared/iconv_open.o
/usr/objs/amd64/usr/src10/lib/libc_nonshared/iconv_open_into.o
/usr/objs/amd64/usr/src10/lib/libc_nonshared/iconv_set_relocation_prefix.o
/usr/objs/amd64/usr/src10/lib/libc_nonshared/iconvctl.o
/usr/objs/amd64/usr/src10/lib/libc_nonshared/iconvlist.o
/usr/objs/amd64/usr/src10/lib/libc_nonshared/libc_nonshared.a
/usr/objs/amd64/usr/src10/tmp/usr/lib/libc_nonshared.a

And I would expect csh to be build against:
/usr/objs/amd64/usr/src10/tmp/usr/lib/libc_nonshared.a

But for what happened, I conclude that it is linked against /usr/lib.

--WjW





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