[LLVMbugs] [Bug 2817] New: clang can't build autoconfed applications: checking size of short... configure: error: cannot determine a size for short
bugzilla-daemon at cs.uiuc.edu
bugzilla-daemon at cs.uiuc.edu
Mon Sep 22 03:14:01 PDT 2008
http://llvm.org/bugs/show_bug.cgi?id=2817
Summary: clang can't build autoconfed applications: checking size
of short... configure: error: cannot determine a size
for short
Product: clang
Version: unspecified
Platform: PC
OS/Version: Linux
Status: NEW
Severity: normal
Priority: P2
Component: Semantic Analyzer
AssignedTo: unassignedbugs at nondot.org
ReportedBy: edwintorok at gmail.com
CC: llvmbugs at cs.uiuc.edu
The problem is that 'switch (0) case 0: case sizeof(short) == 2):;' fails too:
Switch constants must all be same type as switch value!
switch i32 0, label %sw.epilog [
i32 0, label %sw.bb
i64 1, label %sw.bb1
]
Broken module found, compilation aborted!
clang[0x73923f]
/lib/libc.so.6[0x3e93231f80]
/lib/libc.so.6(gsignal+0x35)[0x3e93231ef5]
/lib/libc.so.6(abort+0x183)[0x3e93233413]
clang[0x6f6710]
clang(_ZN4llvm13FPPassManager13runOnFunctionERNS_8FunctionE+0x14c)[0x6d073c]
clang(_ZN4llvm23FunctionPassManagerImpl3runERNS_8FunctionE+0x7b)[0x6d0b8b]
clang(_ZN4llvm19FunctionPassManager3runERNS_8FunctionE+0x3e)[0x6d0cfe]
clang(_ZN4llvm14verifyFunctionERKNS_8FunctionENS_21VerifierFailureActionE+0x264)[0x6ea874]
clang(_ZN5clang7CodeGen15CodeGenFunction14FinishFunctionENS_14SourceLocationE+0x80)[0x518860]
clang(_ZN5clang7CodeGen15CodeGenFunction12GenerateCodeEPKNS_12FunctionDeclEPN4llvm8FunctionE+0x3ce)[0x518ebe]
clang(_ZN5clang7CodeGen13CodeGenModule28EmitGlobalFunctionDefinitionEPKNS_12FunctionDeclE+0x39b)[0x4ea78b]
clang(_ZN5clang7CodeGen13CodeGenModule20EmitGlobalDefinitionEPKNS_9ValueDeclE+0x65)[0x4ea9a5]
clang(_ZN5clang7CodeGen13CodeGenModule10EmitGlobalEPKNS_9ValueDeclE+0xcc)[0x4eaa7c]
clang(_ZN5clang7CodeGen13CodeGenModule16EmitTopLevelDeclEPNS_4DeclE+0x1c5)[0x4eacb5]
clang[0x4e652c]
clang(_ZN5clang8ParseASTERNS_12PreprocessorEPNS_11ASTConsumerEb+0x15b)[0x5996eb]
clang[0x4deb62]
clang(main+0x7dd)[0x4e273d]
/lib/libc.so.6(__libc_start_main+0xe6)[0x3e9321e1a6]
clang(_ZNSt8ios_base4InitD1Ev+0x41)[0x4beaf9]
configure:12964: checking size of short
configure:12994: /home/edwin/llvm-svn/llvm/tools/clang/utils/ccc -c -U __GNUC__
-m32 conftest.c >&5
clang -emit-llvm-bc -x c -o conftest.o conftest.c -U__GNUC__
conftest.c:52:25: error: duplicate case value '0'
switch (0) case 0: case (sizeof (short) == 4):;
^
conftest.c:52:17: error: previous case value occurrence defined here
switch (0) case 0: case (sizeof (short) == 4):;
^
2 diagnostics generated.
configure:13000: $? = 1
configure: failed program was:
| /* confdefs.h. */
| #define PACKAGE_NAME "clamav"
| #define PACKAGE_TARNAME "clamav"
| #define PACKAGE_VERSION "devel"
| #define PACKAGE_STRING "clamav devel"
| #define PACKAGE_BUGREPORT "http://bugs.clamav.net/"
| #define PACKAGE PACKAGE_NAME
| #define VERSION "devel-20080922"
| #define HAVE_SYS_TYPES_H 1
| #define HAVE_SYS_STAT_H 1
| #define HAVE_STDLIB_H 1
| #define HAVE_STRING_H 1
| #define HAVE_MEMORY_H 1
| #define HAVE_STRINGS_H 1
| #define HAVE_INTTYPES_H 1
| #define HAVE_STDINT_H 1
| #define HAVE_UNISTD_H 1
| #define HAVE_DLFCN_H 1
| #define LT_OBJDIR ".libs/"
| #define SCANBUFF 131072
| #define FILEBUFF 8192
| #define WORDS_BIGENDIAN 0
| #define HAVE_STDINT_H 1
| #define HAVE_UNISTD_H 1
| #define HAVE_DLFCN_H 1
| #define HAVE_INTTYPES_H 1
| #define HAVE_MEMORY_H 1
| #define HAVE_STDLIB_H 1
| #define HAVE_STRINGS_H 1
| #define HAVE_STRING_H 1
| #define HAVE_SYS_MMAN_H 1
| #define HAVE_SYS_PARAM_H 1
| #define HAVE_SYS_STAT_H 1
| #define HAVE_SYS_TYPES_H 1
| #define HAVE_MALLOC_H 1
| #define HAVE_POLL_H 1
| #define HAVE_LIMITS_H 1
| #define HAVE_SYS_UIO_H 1
| #define HAVE_TERMIOS_H 1
| #define HAVE_STDBOOL_H 1
| #define HAVE_PWD_H 1
| #define HAVE_GRP_H 1
| #define USE_SYSLOG 1
| /* end confdefs.h. */
| #include "confdefs.h"
| #include <sys/types.h>
|
|
| int
| main ()
| {
| switch (0) case 0: case (sizeof (short) == 4):;
| ;
| return 0;
| }
configure:12994: /home/edwin/llvm-svn/llvm/tools/clang/utils/ccc -c -U __GNUC__
-m32 conftest.c >&5
clang -emit-llvm-bc -x c -o conftest.o conftest.c -U__GNUC__
conftest.c:52:25: error: duplicate case value '0'
switch (0) case 0: case (sizeof (short) == 8):;
^
conftest.c:52:17: error: previous case value occurrence defined here
switch (0) case 0: case (sizeof (short) == 8):;
^
2 diagnostics generated.
configure:13000: $? = 1
configure: failed program was:
| /* confdefs.h. */
| #define PACKAGE_NAME "clamav"
| #define PACKAGE_TARNAME "clamav"
| #define PACKAGE_VERSION "devel"
| #define PACKAGE_STRING "clamav devel"
| #define PACKAGE_BUGREPORT "http://bugs.clamav.net/"
| #define PACKAGE PACKAGE_NAME
| #define VERSION "devel-20080922"
| #define HAVE_SYS_TYPES_H 1
| #define HAVE_SYS_STAT_H 1
| #define HAVE_STDLIB_H 1
| #define HAVE_STRING_H 1
| #define HAVE_MEMORY_H 1
| #define HAVE_STRINGS_H 1
| #define HAVE_INTTYPES_H 1
| #define HAVE_STDINT_H 1
| #define HAVE_UNISTD_H 1
| #define HAVE_DLFCN_H 1
| #define LT_OBJDIR ".libs/"
| #define SCANBUFF 131072
| #define FILEBUFF 8192
| #define WORDS_BIGENDIAN 0
| #define HAVE_STDINT_H 1
| #define HAVE_UNISTD_H 1
| #define HAVE_DLFCN_H 1
| #define HAVE_INTTYPES_H 1
| #define HAVE_MEMORY_H 1
| #define HAVE_STDLIB_H 1
| #define HAVE_STRINGS_H 1
| #define HAVE_STRING_H 1
| #define HAVE_SYS_MMAN_H 1
| #define HAVE_SYS_PARAM_H 1
| #define HAVE_SYS_STAT_H 1
| #define HAVE_SYS_TYPES_H 1
| #define HAVE_MALLOC_H 1
| #define HAVE_POLL_H 1
| #define HAVE_LIMITS_H 1
| #define HAVE_SYS_UIO_H 1
| #define HAVE_TERMIOS_H 1
| #define HAVE_STDBOOL_H 1
| #define HAVE_PWD_H 1
| #define HAVE_GRP_H 1
| #define USE_SYSLOG 1
| /* end confdefs.h. */
| #include "confdefs.h"
| #include <sys/types.h>
|
|
| int
| main ()
| {
| switch (0) case 0: case (sizeof (short) == 8):;
| ;
| return 0;
| }
configure:12994: /home/edwin/llvm-svn/llvm/tools/clang/utils/ccc -c -U __GNUC__
-m32 conftest.c >&5
clang -emit-llvm-bc -x c -o conftest.o conftest.c -U__GNUC__
conftest.c:52:25: error: duplicate case value '0'
switch (0) case 0: case (sizeof (short) == 1):;
^
conftest.c:52:17: error: previous case value occurrence defined here
switch (0) case 0: case (sizeof (short) == 1):;
^
2 diagnostics generated.
configure:13000: $? = 1
configure: failed program was:
| /* confdefs.h. */
| #define PACKAGE_NAME "clamav"
| #define PACKAGE_TARNAME "clamav"
| #define PACKAGE_VERSION "devel"
| #define PACKAGE_STRING "clamav devel"
| #define PACKAGE_BUGREPORT "http://bugs.clamav.net/"
| #define PACKAGE PACKAGE_NAME
| #define VERSION "devel-20080922"
| #define HAVE_SYS_TYPES_H 1
| #define HAVE_SYS_STAT_H 1
| #define HAVE_STDLIB_H 1
| #define HAVE_STRING_H 1
| #define HAVE_MEMORY_H 1
| #define HAVE_STRINGS_H 1
| #define HAVE_INTTYPES_H 1
| #define HAVE_STDINT_H 1
| #define HAVE_UNISTD_H 1
| #define HAVE_DLFCN_H 1
| #define LT_OBJDIR ".libs/"
| #define SCANBUFF 131072
| #define FILEBUFF 8192
| #define WORDS_BIGENDIAN 0
| #define HAVE_STDINT_H 1
| #define HAVE_UNISTD_H 1
| #define HAVE_DLFCN_H 1
| #define HAVE_INTTYPES_H 1
| #define HAVE_MEMORY_H 1
| #define HAVE_STDLIB_H 1
| #define HAVE_STRINGS_H 1
| #define HAVE_STRING_H 1
| #define HAVE_SYS_MMAN_H 1
| #define HAVE_SYS_PARAM_H 1
| #define HAVE_SYS_STAT_H 1
| #define HAVE_SYS_TYPES_H 1
| #define HAVE_MALLOC_H 1
| #define HAVE_POLL_H 1
| #define HAVE_LIMITS_H 1
| #define HAVE_SYS_UIO_H 1
| #define HAVE_TERMIOS_H 1
| #define HAVE_STDBOOL_H 1
| #define HAVE_PWD_H 1
| #define HAVE_GRP_H 1
| #define USE_SYSLOG 1
| /* end confdefs.h. */
| #include "confdefs.h"
| #include <sys/types.h>
|
|
| int
| main ()
| {
| switch (0) case 0: case (sizeof (short) == 1):;
| ;
| return 0;
| }
configure:12994: /home/edwin/llvm-svn/llvm/tools/clang/utils/ccc -c -U __GNUC__
-m32 conftest.c >&5
clang -emit-llvm-bc -x c -o conftest.o conftest.c -U__GNUC__
Switch constants must all be same type as switch value!
switch i32 0, label %sw.epilog [
i32 0, label %sw.bb
i64 1, label %sw.bb1
]
Broken module found, compilation aborted!
clang[0x73923f]
/lib/libc.so.6[0x3e93231f80]
/lib/libc.so.6(gsignal+0x35)[0x3e93231ef5]
/lib/libc.so.6(abort+0x183)[0x3e93233413]
clang[0x6f6710]
clang(_ZN4llvm13FPPassManager13runOnFunctionERNS_8FunctionE+0x14c)[0x6d073c]
clang(_ZN4llvm23FunctionPassManagerImpl3runERNS_8FunctionE+0x7b)[0x6d0b8b]
clang(_ZN4llvm19FunctionPassManager3runERNS_8FunctionE+0x3e)[0x6d0cfe]
clang(_ZN4llvm14verifyFunctionERKNS_8FunctionENS_21VerifierFailureActionE+0x264)[0x6ea874]
clang(_ZN5clang7CodeGen15CodeGenFunction14FinishFunctionENS_14SourceLocationE+0x80)[0x518860]
clang(_ZN5clang7CodeGen15CodeGenFunction12GenerateCodeEPKNS_12FunctionDeclEPN4llvm8FunctionE+0x3ce)[0x518ebe]
clang(_ZN5clang7CodeGen13CodeGenModule28EmitGlobalFunctionDefinitionEPKNS_12FunctionDeclE+0x39b)[0x4ea78b]
clang(_ZN5clang7CodeGen13CodeGenModule20EmitGlobalDefinitionEPKNS_9ValueDeclE+0x65)[0x4ea9a5]
clang(_ZN5clang7CodeGen13CodeGenModule10EmitGlobalEPKNS_9ValueDeclE+0xcc)[0x4eaa7c]
clang(_ZN5clang7CodeGen13CodeGenModule16EmitTopLevelDeclEPNS_4DeclE+0x1c5)[0x4eacb5]
clang[0x4e652c]
clang(_ZN5clang8ParseASTERNS_12PreprocessorEPNS_11ASTConsumerEb+0x15b)[0x5996eb]
clang[0x4deb62]
clang(main+0x7dd)[0x4e273d]
/lib/libc.so.6(__libc_start_main+0xe6)[0x3e9321e1a6]
clang(_ZNSt8ios_base4InitD1Ev+0x41)[0x4beaf9]
configure:13000: $? = 250
configure: failed program was:
| /* confdefs.h. */
| #define PACKAGE_NAME "clamav"
| #define PACKAGE_TARNAME "clamav"
| #define PACKAGE_VERSION "devel"
| #define PACKAGE_STRING "clamav devel"
| #define PACKAGE_BUGREPORT "http://bugs.clamav.net/"
| #define PACKAGE PACKAGE_NAME
| #define VERSION "devel-20080922"
| #define HAVE_SYS_TYPES_H 1
| #define HAVE_SYS_STAT_H 1
| #define HAVE_STDLIB_H 1
| #define HAVE_STRING_H 1
| #define HAVE_MEMORY_H 1
| #define HAVE_STRINGS_H 1
| #define HAVE_INTTYPES_H 1
| #define HAVE_STDINT_H 1
| #define HAVE_UNISTD_H 1
| #define HAVE_DLFCN_H 1
| #define LT_OBJDIR ".libs/"
| #define SCANBUFF 131072
| #define FILEBUFF 8192
| #define WORDS_BIGENDIAN 0
| #define HAVE_STDINT_H 1
| #define HAVE_UNISTD_H 1
| #define HAVE_DLFCN_H 1
| #define HAVE_INTTYPES_H 1
| #define HAVE_MEMORY_H 1
| #define HAVE_STDLIB_H 1
| #define HAVE_STRINGS_H 1
| #define HAVE_STRING_H 1
| #define HAVE_SYS_MMAN_H 1
| #define HAVE_SYS_PARAM_H 1
| #define HAVE_SYS_STAT_H 1
| #define HAVE_SYS_TYPES_H 1
| #define HAVE_MALLOC_H 1
| #define HAVE_POLL_H 1
| #define HAVE_LIMITS_H 1
| #define HAVE_SYS_UIO_H 1
| #define HAVE_TERMIOS_H 1
| #define HAVE_STDBOOL_H 1
| #define HAVE_PWD_H 1
| #define HAVE_GRP_H 1
| #define USE_SYSLOG 1
| /* end confdefs.h. */
| #include "confdefs.h"
| #include <sys/types.h>
|
|
| int
| main ()
| {
| switch (0) case 0: case (sizeof (short) == 2):;
| ;
| return 0;
| }
configure:12994: /home/edwin/llvm-svn/llvm/tools/clang/utils/ccc -c -U __GNUC__
-m32 conftest.c >&5
clang -emit-llvm-bc -x c -o conftest.o conftest.c -U__GNUC__
conftest.c:52:25: error: duplicate case value '0'
switch (0) case 0: case (sizeof (short) == 16):;
^
conftest.c:52:17: error: previous case value occurrence defined here
switch (0) case 0: case (sizeof (short) == 16):;
^
2 diagnostics generated.
configure:13000: $? = 1
configure: failed program was:
| /* confdefs.h. */
| #define PACKAGE_NAME "clamav"
| #define PACKAGE_TARNAME "clamav"
| #define PACKAGE_VERSION "devel"
| #define PACKAGE_STRING "clamav devel"
| #define PACKAGE_BUGREPORT "http://bugs.clamav.net/"
| #define PACKAGE PACKAGE_NAME
| #define VERSION "devel-20080922"
| #define HAVE_SYS_TYPES_H 1
| #define HAVE_SYS_STAT_H 1
| #define HAVE_STDLIB_H 1
| #define HAVE_STRING_H 1
| #define HAVE_MEMORY_H 1
| #define HAVE_STRINGS_H 1
| #define HAVE_INTTYPES_H 1
| #define HAVE_STDINT_H 1
| #define HAVE_UNISTD_H 1
| #define HAVE_DLFCN_H 1
| #define LT_OBJDIR ".libs/"
| #define SCANBUFF 131072
| #define FILEBUFF 8192
| #define WORDS_BIGENDIAN 0
| #define HAVE_STDINT_H 1
| #define HAVE_UNISTD_H 1
| #define HAVE_DLFCN_H 1
| #define HAVE_INTTYPES_H 1
| #define HAVE_MEMORY_H 1
| #define HAVE_STDLIB_H 1
| #define HAVE_STRINGS_H 1
| #define HAVE_STRING_H 1
| #define HAVE_SYS_MMAN_H 1
| #define HAVE_SYS_PARAM_H 1
| #define HAVE_SYS_STAT_H 1
| #define HAVE_SYS_TYPES_H 1
| #define HAVE_MALLOC_H 1
| #define HAVE_POLL_H 1
| #define HAVE_LIMITS_H 1
| #define HAVE_SYS_UIO_H 1
| #define HAVE_TERMIOS_H 1
| #define HAVE_STDBOOL_H 1
| #define HAVE_PWD_H 1
| #define HAVE_GRP_H 1
| #define USE_SYSLOG 1
| /* end confdefs.h. */
| #include "confdefs.h"
| #include <sys/types.h>
|
|
| int
| main ()
| {
| switch (0) case 0: case (sizeof (short) == 16):;
| ;
| return 0;
| }
configure:13020: error: cannot determine a size for short
--
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
More information about the llvm-bugs
mailing list