stable/8 kernel-toolchain fails with clang on head

Andriy Gapon avg at FreeBSD.org
Fri Aug 23 12:17:07 UTC 2013


$ /usr/obj/usr/devel/svn/base/stable/8/make.amd64/make kernel-toolchain
WITHOUT_CLANG=1 __MAKE_CONF=/dev/null SRCCONF=/dev/null

...

cc -O2 -pipe -DIN_GCC -DHAVE_CONFIG_H
-DPREFIX=\"/usr/obj/usr/devel/svn/base/stable/8/tmp/usr\"
-I/usr/obj/usr/devel/svn/base/stable/8/tmp/usr/devel/svn/base/stable/8/gnu/usr.bin/cc/cc_int/../cc_tools
-I/usr/devel/svn/base/stable/8/gnu/usr.bin/cc/cc_int/../cc_tools
-I/usr/devel/svn/base/stable/8/gnu/usr.bin/cc/cc_int/../../../../contrib/gcc
-I/usr/devel/svn/base/stable/8/gnu/usr.bin/cc/cc_int/../../../../contrib/gcc/config
-I/usr/devel/svn/base/stable/8/gnu/usr.bin/cc/cc_int/../../../../contrib/gcclibs/include
-I/usr/devel/svn/base/stable/8/gnu/usr.bin/cc/cc_int/../../../../contrib/gcclibs/libcpp/include
-I/usr/devel/svn/base/stable/8/gnu/usr.bin/cc/cc_int/../../../../contrib/gcclibs/libdecnumber
  -I/usr/obj/usr/devel/svn/base/stable/8/tmp/legacy/usr/include
-DTARGET_NAME=\"amd64-undermydesk-freebsd\" -c
/usr/devel/svn/base/stable/8/gnu/usr.bin/cc/cc_int/../../../../contrib/gcc/toplev.c
In file included from
/usr/devel/svn/base/stable/8/gnu/usr.bin/cc/cc_int/../../../../contrib/gcc/toplev.c:58:
/usr/devel/svn/base/stable/8/gnu/usr.bin/cc/cc_int/../../../../contrib/gcc/output.h:123:6:
warning: 'format' attribute argument not supported: __asm_fprintf__
[-Wignored-attributes]
     ATTRIBUTE_ASM_FPRINTF(2, 3);
     ^
/usr/devel/svn/base/stable/8/gnu/usr.bin/cc/cc_int/../../../../contrib/gcc/output.h:113:53:
note: expanded from macro 'ATTRIBUTE_ASM_FPRINTF'
#define ATTRIBUTE_ASM_FPRINTF(m, n) __attribute__ ((__format__ (__asm_fprintf__,
m, n))) ATTRIBUTE_NONNULL(m)
                                                    ^
/usr/devel/svn/base/stable/8/gnu/usr.bin/cc/cc_int/../../../../contrib/gcc/toplev.c:542:1:
error: redefinition of a 'extern inline' function 'floor_log2' is not supported
in C99 mode
floor_log2 (unsigned HOST_WIDE_INT x)
^
/usr/devel/svn/base/stable/8/gnu/usr.bin/cc/cc_int/../../../../contrib/gcc/toplev.h:174:1:
note: previous definition is here
floor_log2 (unsigned HOST_WIDE_INT x)
^
/usr/devel/svn/base/stable/8/gnu/usr.bin/cc/cc_int/../../../../contrib/gcc/toplev.c:577:1:
error: redefinition of a 'extern inline' function 'exact_log2' is not supported
in C99 mode
exact_log2 (unsigned HOST_WIDE_INT x)
^
/usr/devel/svn/base/stable/8/gnu/usr.bin/cc/cc_int/../../../../contrib/gcc/toplev.h:180:1:
note: previous definition is here
exact_log2 (unsigned HOST_WIDE_INT x)
^
1 warning and 2 errors generated.
*** Error code 1

Stop in /usr/devel/svn/base/stable/8/gnu/usr.bin/cc/cc_int.


It seems that the problem is specific to stable/8 and is caused by missing
-std=gnu89.  And that seems to be caused by -DNO_WARNS that is used for
toolchain target.
Dependency between NO_WARNS and CSTD was removed in r198335 + r198365, but those
were never MFC-ed.

What do you think?

-- 
Andriy Gapon


More information about the freebsd-current mailing list