buildworld/buildkernel broken: undefined reference to `_ThreadRuneLocale'

From: O. Hartmann <ohartman_at_zedat.fu-berlin.de>
Date: Sun, 04 Mar 2012 21:41:39 +0100
While trying to build world or even build kernel, FreeBSD
10.0-CURRENT/amd64 built with CLANG and going to be build with CLANG
starts failing.

Attached you'll find my src.conf. /etc/make.conf contains the
"traditional" CLANG stuff, nothing chaged in make.conf since the last
successful build:
###
###     CLANG
###

.if !defined(NO_CLANG)
#.if ${.CURDIR:M/usr/src*} || ${.CURDIR:M/usr/obj*} || ${.CURDIR:M/sys*}
.if !defined(CC) || ${CC} == "cc"
CC=                     clang
.endif
.if !defined(CXX) || ${CXX} == "c++"
CXX=                    clang++
.endif
.if !defined(CPP) || ${CPP} == "cpp"
CPP=                    clang-cpp
.endif
## Don't die on warnings
NO_WERROR=
WERROR=
### Don't forget this when using Jails!
#NO_FSCHG=
#
CFLAGS+=               -pipe -O3 -fno-strict-aliasing
COPTFLAGS+=            -pipe -O3
#.endif
.endif



Starting "make buildkernel" in /usr/src ends upd with:

--------------------------------------------------------------
>>> stage 2.3: build tools
--------------------------------------------------------------
cd /usr/obj/usr/src/sys/THOR;
PATH=/usr/obj/usr/src/tmp/legacy/usr/sbin:/usr/obj/usr/src/tmp/legacy/usr/bin:/usr/obj/usr/src/tmp/legacy/usr/games:/sbin:/bin:/usr/sbin:/usr/bin
 MAKESRCPATH=/usr/src/sys/dev/aic7xxx/aicasm  make SSP_CFLAGS=
-DNO_CPU_CFLAGS -DNO_CTF  -f /usr/src/sys/dev/aic7xxx/aicasm/Makefile
Warning: Object directory not changed from original
/usr/obj/usr/src/sys/THOR
yacc -b aicasm_gram  -d -o aicasm_gram.c
/usr/src/sys/dev/aic7xxx/aicasm/aicasm_gram.y
yacc -b aicasm_macro_gram -p mm -d -o aicasm_macro_gram.c
/usr/src/sys/dev/aic7xxx/aicasm/aicasm_macro_gram.y
clang -O2 -pipe -O2 -fno-strict-aliasing -pipe -nostdinc -I/usr/include
-I. -I/usr/src/sys/dev/aic7xxx/aicasm -std=gnu99  -Wsystem-headers -Wall
-Wno-format-y2k -W -Wno-unused-parameter -Wstrict-prototypes
-Wmissing-prototypes -Wpointer-arith -Wreturn-type -Wcast-qual
-Wwrite-strings -Wswitch -Wshadow -Wunused-parameter -Wcast-align
-Wno-pointer-sign -c /usr/src/sys/dev/aic7xxx/aicasm/aicasm.c
clang -O2 -pipe -O2 -fno-strict-aliasing -pipe -nostdinc -I/usr/include
-I. -I/usr/src/sys/dev/aic7xxx/aicasm -std=gnu99  -Wsystem-headers -Wall
-Wno-format-y2k -W -Wno-unused-parameter -Wstrict-prototypes
-Wmissing-prototypes -Wpointer-arith -Wreturn-type -Wcast-qual
-Wwrite-strings -Wswitch -Wshadow -Wunused-parameter -Wcast-align
-Wno-pointer-sign -c /usr/src/sys/dev/aic7xxx/aicasm/aicasm_symbol.c
clang -O2 -pipe -O2 -fno-strict-aliasing -pipe -nostdinc -I/usr/include
-I. -I/usr/src/sys/dev/aic7xxx/aicasm -std=gnu99  -Wsystem-headers -Wall
-Wno-format-y2k -W -Wno-unused-parameter -Wstrict-prototypes
-Wmissing-prototypes -Wpointer-arith -Wreturn-type -Wcast-qual
-Wwrite-strings -Wswitch -Wshadow -Wunused-parameter -Wcast-align
-Wno-pointer-sign -c aicasm_gram.c
clang -O2 -pipe -O2 -fno-strict-aliasing -pipe -nostdinc -I/usr/include
-I. -I/usr/src/sys/dev/aic7xxx/aicasm -std=gnu99  -Wsystem-headers -Wall
-Wno-format-y2k -W -Wno-unused-parameter -Wstrict-prototypes
-Wmissing-prototypes -Wpointer-arith -Wreturn-type -Wcast-qual
-Wwrite-strings -Wswitch -Wshadow -Wunused-parameter -Wcast-align
-Wno-pointer-sign -c aicasm_macro_gram.c
lex -t   /usr/src/sys/dev/aic7xxx/aicasm/aicasm_scan.l > aicasm_scan.c
clang -O2 -pipe -O2 -fno-strict-aliasing -pipe -nostdinc -I/usr/include
-I. -I/usr/src/sys/dev/aic7xxx/aicasm -std=gnu99  -Wsystem-headers -Wall
-Wno-format-y2k -W -Wno-unused-parameter -Wstrict-prototypes
-Wmissing-prototypes -Wpointer-arith -Wreturn-type -Wcast-qual
-Wwrite-strings -Wswitch -Wshadow -Wunused-parameter -Wcast-align
-Wno-pointer-sign -c aicasm_scan.c
lex -t  -Pmm /usr/src/sys/dev/aic7xxx/aicasm/aicasm_macro_scan.l >
aicasm_macro_scan.c
clang -O2 -pipe -O2 -fno-strict-aliasing -pipe -nostdinc -I/usr/include
-I. -I/usr/src/sys/dev/aic7xxx/aicasm -std=gnu99  -Wsystem-headers -Wall
-Wno-format-y2k -W -Wno-unused-parameter -Wstrict-prototypes
-Wmissing-prototypes -Wpointer-arith -Wreturn-type -Wcast-qual
-Wwrite-strings -Wswitch -Wshadow -Wunused-parameter -Wcast-align
-Wno-pointer-sign -c aicasm_macro_scan.c
clang -O2 -pipe -O2 -fno-strict-aliasing -pipe -nostdinc -I/usr/include
-I. -I/usr/src/sys/dev/aic7xxx/aicasm -std=gnu99  -Wsystem-headers -Wall
-Wno-format-y2k -W -Wno-unused-parameter -Wstrict-prototypes
-Wmissing-prototypes -Wpointer-arith -Wreturn-type -Wcast-qual
-Wwrite-strings -Wswitch -Wshadow -Wunused-parameter -Wcast-align
-Wno-pointer-sign  -o aicasm aicasm.o aicasm_symbol.o aicasm_gram.o
aicasm_macro_gram.o aicasm_scan.o aicasm_macro_scan.o -ll
clang: warning: argument unused during compilation: '-nostdinc'
clang: warning: argument unused during compilation: '-std=gnu99'
aicasm.o: In function `main':
/usr/src/sys/dev/aic7xxx/aicasm/aicasm.c:(.text+0x88f): undefined
reference to `_ThreadRuneLocale'
aicasm_symbol.o: In function `symtable_dump':
/usr/src/sys/dev/aic7xxx/aicasm/aicasm_symbol.c:(.text+0x7a4): undefined
reference to `_ThreadRuneLocale'
clang: error: linker command failed with exit code 1 (use -v to see
invocation)
*** [aicasm] Error code 1

Stop in /usr/obj/usr/src/sys/THOR.
*** [buildkernel] Error code 1

Stop in /usr/src.
*** [buildkernel] Error code 1

Stop in /usr/src.


Starting "make buildworld" in /usr/src ends up with

===> games/fortune/strfile (obj,depend,all,install)
/usr/obj/usr/src/tmp/usr/src/games/fortune/strfile created for
/usr/src/games/fortune/strfile
rm -f .depend
CC='clang' mkdep -f .depend -a
-I/usr/obj/usr/src/tmp/legacy/usr/include -std=gnu99
/usr/src/games/fortune/strfile/strfile.c
echo strfile: /usr/lib/libc.a
/usr/obj/usr/src/tmp/legacy/usr/lib/libegacy.a >> .depend
clang -O2 -pipe -O2 -fno-strict-aliasing -pipe -std=gnu99
-I/usr/obj/usr/src/tmp/legacy/usr/include -c
/usr/src/games/fortune/strfile/strfile.c
clang -O2 -pipe -O2 -fno-strict-aliasing -pipe -std=gnu99
-I/usr/obj/usr/src/tmp/legacy/usr/include  -static
-L/usr/obj/usr/src/tmp/legacy/usr/lib -o strfile strfile.o -legacy
clang: warning: argument unused during compilation: '-std=gnu99'
strfile.o: In function `main':
/usr/src/games/fortune/strfile/strfile.c:(.text+0x2e0): undefined
reference to `_ThreadRuneLocale'
/usr/src/games/fortune/strfile/strfile.c:(.text+0x382): undefined
reference to `_ThreadRuneLocale'
strfile.o: In function `cmp_str':
/usr/src/games/fortune/strfile/strfile.c:(.text+0x860): undefined
reference to `_ThreadRuneLocale'
/usr/src/games/fortune/strfile/strfile.c:(.text+0x8bb): undefined
reference to `_ThreadRuneLocale'
/usr/src/games/fortune/strfile/strfile.c:(.text+0x9b4): undefined
reference to `_ThreadRuneLocale'
strfile.o:/usr/src/games/fortune/strfile/strfile.c:(.text+0xa0e): more
undefined references to `_ThreadRuneLocale' follow
clang: error: linker command failed with exit code 1 (use -v to see
invocation)
*** [strfile] Error code 1
1 error
*** [bootstrap-tools] Error code 2
1 error
*** [_bootstrap-tools] Error code 2
1 error
*** [buildworld] Error code 2
1 error

Received on Sun Mar 04 2012 - 19:41:41 UTC

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