Rakashazi / emu-ex-plus-alpha

Multi-platform computer & game console emulation system including supporting code (EmuFramework) and core engine (Imagine)
GNU General Public License v3.0
714 stars 153 forks source link

bash makeAll-android.sh install Fail【clang options needed to detect all undeclared functions... cannot detect】 #215

Closed xiaoyvyv closed 3 years ago

xiaoyvyv commented 3 years ago

Error Log

checking for /usr/local/android-sdk/android-sdk-linux/ndk/android-ndk-r22b/toolchains/llvm/prebuilt/linux-x86_64/bin/clang options needed to detect all undeclared functions... cannot detect
configure: error: in `/tmp/imagine-bundle/libarchive/build/android-x86_64':
configure: error: cannot make /usr/local/android-sdk/android-sdk-linux/ndk/android-ndk-r22b/toolchains/llvm/prebuilt/linux-x86_64/bin/clang report undeclared builtins
See `config.log' for more details
make: *** [common.mk:56: /tmp/imagine-bundle/libarchive/build/android-x86_64/Makefile] Error 1

Details

configure:17387: checking for /usr/local/android-sdk/android-sdk-linux/ndk/ndk-r23/toolchains/llvm/prebuilt/linux-x86_64/bin/clang options needed to detect all undeclared functions
configure:17409: /usr/local/android-sdk/android-sdk-linux/ndk/ndk-r23/toolchains/llvm/prebuilt/linux-x86_64/bin/clang -c -DNDEBUG -DANDROID -fno-common -target aarch64-none-linux-android21  -no-canonical-prefixes -fpic -pipe -fvisibility=hidden -Ofast -fomit-frame-pointer -fno-stack-protector -fno-asynchronous-unwind-tables  -flto -ffunction-sections -fdata-sections -Wall -Wextra -Werror=return-type -Wno-comment -Wno-unused -Wno-unused-parameter  -Wdisabled-optimization -Wno-attributes -Wno-missing-braces -I/root/imagine-sdk/android-arm64/lib/pkgconfig/../../include   -Wformat -Wformat-security   conftest.c >&5
conftest.c:111:8: warning: implicitly declaring library function 'strchr' with type 'char *(const char *, int)' [-Wimplicit-function-declaration]
(void) strchr;
       ^
conftest.c:111:8: note: include the header <string.h> or explicitly provide a declaration for 'strchr'
1 warning generated.
configure:17409: $? = 0
configure:17409: /usr/local/android-sdk/android-sdk-linux/ndk/ndk-r23/toolchains/llvm/prebuilt/linux-x86_64/bin/clang -c -DNDEBUG -DANDROID -fno-common -target aarch64-none-linux-android21  -no-canonical-prefixes -fpic -pipe -fvisibility=hidden -Ofast -fomit-frame-pointer -fno-stack-protector -fno-asynchronous-unwind-tables  -flto -ffunction-sections -fdata-sections -Wall -Wextra -Werror=return-type -Wno-comment -Wno-unused -Wno-unused-parameter  -Wdisabled-optimization -Wno-attributes -Wno-missing-braces -I/root/imagine-sdk/android-arm64/lib/pkgconfig/../../include   -Wformat -Wformat-security -fno-builtin  conftest.c >&5
conftest.c:111:8: error: use of undeclared identifier 'strchr'
(void) strchr;
       ^
1 error generated.
configure:17409: $? = 1
configure: failed program was:
| /* confdefs.h */
| #define PACKAGE_NAME "libarchive"
| #define PACKAGE_TARNAME "libarchive"
| #define PACKAGE_VERSION "3.5.1"
| #define PACKAGE_STRING "libarchive 3.5.1"
| #define PACKAGE_BUGREPORT "libarchive-discuss@googlegroups.com"
| #define PACKAGE_URL ""
| #define PACKAGE "libarchive"
| #define VERSION "3.5.1"
| #define __LIBARCHIVE_CONFIG_H_INCLUDED 1
| #define LIBARCHIVE_VERSION_STRING "3.5.1"
| #define LIBARCHIVE_VERSION_NUMBER "3005001"
| #define BSDCPIO_VERSION_STRING "3.5.1"
| #define BSDTAR_VERSION_STRING "3.5.1"
| #define BSDCAT_VERSION_STRING "3.5.1"
| #define HAVE_STDIO_H 1
| #define HAVE_STDLIB_H 1
| #define HAVE_STRING_H 1
| #define HAVE_INTTYPES_H 1
| #define HAVE_STDINT_H 1
| #define HAVE_STRINGS_H 1
| #define HAVE_SYS_STAT_H 1
| #define HAVE_SYS_TYPES_H 1
| #define HAVE_UNISTD_H 1
| #define HAVE_WCHAR_H 1
| #define HAVE_SYS_TIME_H 1
| #define STDC_HEADERS 1
| #define _ALL_SOURCE 1
| #define _DARWIN_C_SOURCE 1
| #define _GNU_SOURCE 1
| #define _HPUX_ALT_XOPEN_SOCKET_API 1
| #define _NETBSD_SOURCE 1
| #define _OPENBSD_SOURCE 1
| #define _POSIX_PTHREAD_SEMANTICS 1
| #define __STDC_WANT_IEC_60559_ATTRIBS_EXT__ 1
| #define __STDC_WANT_IEC_60559_BFP_EXT__ 1
| #define __STDC_WANT_IEC_60559_DFP_EXT__ 1
| #define __STDC_WANT_IEC_60559_FUNCS_EXT__ 1
| #define __STDC_WANT_IEC_60559_TYPES_EXT__ 1
| #define __STDC_WANT_LIB_EXT2__ 1
| #define __STDC_WANT_MATH_SPEC_FUNCS__ 1
| #define _TANDEM_SOURCE 1
| #define __EXTENSIONS__ 1
| #define HAVE_DLFCN_H 1
| #define LT_OBJDIR ".libs/"
| #define HAVE_DIRENT_H 1
| #define HAVE_SYS_WAIT_H 1
| #define HAVE_CTYPE_H 1
| #define HAVE_ERRNO_H 1
| #define HAVE_FCNTL_H 1
| #define HAVE_GRP_H 1
| #define HAVE_INTTYPES_H 1
| #define HAVE_LANGINFO_H 1
| #define HAVE_LIMITS_H 1
| #define HAVE_LINUX_FIEMAP_H 1
| #define HAVE_LINUX_FS_H 1
| #define HAVE_LINUX_MAGIC_H 1
| #define HAVE_LINUX_TYPES_H 1
| #define HAVE_WORKING_FS_IOC_GETFLAGS 1
| #define HAVE_LOCALE_H 1
| #define HAVE_PATHS_H 1
| #define HAVE_POLL_H 1
| #define HAVE_PTHREAD_H 1
| #define HAVE_PWD_H 1
| #define HAVE_SIGNAL_H 1
| #define HAVE_SPAWN_H 1
| #define HAVE_STDARG_H 1
| #define HAVE_STDINT_H 1
| #define HAVE_STDLIB_H 1
| #define HAVE_STRING_H 1
| #define HAVE_SYS_CDEFS_H 1
| #define HAVE_SYS_IOCTL_H 1
| #define HAVE_SYS_MOUNT_H 1
| #define HAVE_SYS_PARAM_H 1
| #define HAVE_SYS_POLL_H 1
| #define HAVE_SYS_SELECT_H 1
| #define HAVE_SYS_STATFS_H 1
| #define HAVE_SYS_STATVFS_H 1
| #define HAVE_SYS_SYSMACROS_H 1
| #define HAVE_SYS_TIME_H 1
| #define HAVE_SYS_UTSNAME_H 1
| #define HAVE_SYS_VFS_H 1
| #define HAVE_SYS_XATTR_H 1
| #define HAVE_TIME_H 1
| #define HAVE_UNISTD_H 1
| #define HAVE_UTIME_H 1
| #define HAVE_WCHAR_H 1
| #define HAVE_WCTYPE_H 1
| #define HAVE_ZLIB_H 1
| #define HAVE_LIBZ 1
| #define HAVE_LZMA_H 1
| #define HAVE_LIBLZMA 1
| #define HAVE_LZMA_STREAM_ENCODER_MT 1
| #define HAVE_REGEX_H 1
| #define uid_t int
| #define gid_t int
| #define mode_t int
| #define off_t long long
| #define size_t unsigned int
| #define id_t unsigned long
| #define uintptr_t unsigned int
| #define HAVE_UNSIGNED_LONG_LONG_INT 1
| #define HAVE_LONG_LONG_INT 1
| #define intmax_t long long int
| #define uintmax_t unsigned long long int
| /* end confdefs.h.  */
| 
| int
| main (void)
| {
| (void) strchr;
|   ;
|   return 0;
| }
configure:17436: /usr/local/android-sdk/android-sdk-linux/ndk/ndk-r23/toolchains/llvm/prebuilt/linux-x86_64/bin/clang -c -DNDEBUG -DANDROID -fno-common -target aarch64-none-linux-android21  -no-canonical-prefixes -fpic -pipe -fvisibility=hidden -Ofast -fomit-frame-pointer -fno-stack-protector -fno-asynchronous-unwind-tables  -flto -ffunction-sections -fdata-sections -Wall -Wextra -Werror=return-type -Wno-comment -Wno-unused -Wno-unused-parameter  -Wdisabled-optimization -Wno-attributes -Wno-missing-braces -I/root/imagine-sdk/android-arm64/lib/pkgconfig/../../include   -Wformat -Wformat-security -fno-builtin  conftest.c >&5
In file included from conftest.c:110:
/usr/local/android-sdk/android-sdk-linux/ndk/ndk-r23/toolchains/llvm/prebuilt/linux-x86_64/lib64/clang/12.0.5/include/stddef.h:46:23: error: cannot combine with previous 'int' declaration specifier
typedef __SIZE_TYPE__ size_t;
                      ^
conftest.c:99:25: note: expanded from macro 'size_t'
#define size_t unsigned int
                        ^
1 error generated.
configure:17436: $? = 1
configure: failed program was:
| /* confdefs.h */
| #define PACKAGE_NAME "libarchive"
| #define PACKAGE_TARNAME "libarchive"
| #define PACKAGE_VERSION "3.5.1"
| #define PACKAGE_STRING "libarchive 3.5.1"
| #define PACKAGE_BUGREPORT "libarchive-discuss@googlegroups.com"
| #define PACKAGE_URL ""
| #define PACKAGE "libarchive"
| #define VERSION "3.5.1"
| #define __LIBARCHIVE_CONFIG_H_INCLUDED 1
| #define LIBARCHIVE_VERSION_STRING "3.5.1"
| #define LIBARCHIVE_VERSION_NUMBER "3005001"
| #define BSDCPIO_VERSION_STRING "3.5.1"
| #define BSDTAR_VERSION_STRING "3.5.1"
| #define BSDCAT_VERSION_STRING "3.5.1"
| #define HAVE_STDIO_H 1
| #define HAVE_STDLIB_H 1
| #define HAVE_STRING_H 1
| #define HAVE_INTTYPES_H 1
| #define HAVE_STDINT_H 1
| #define HAVE_STRINGS_H 1
| #define HAVE_SYS_STAT_H 1
| #define HAVE_SYS_TYPES_H 1
| #define HAVE_UNISTD_H 1
| #define HAVE_WCHAR_H 1
| #define HAVE_SYS_TIME_H 1
| #define STDC_HEADERS 1
| #define _ALL_SOURCE 1
| #define _DARWIN_C_SOURCE 1
| #define _GNU_SOURCE 1
| #define _HPUX_ALT_XOPEN_SOCKET_API 1
| #define _NETBSD_SOURCE 1
| #define _OPENBSD_SOURCE 1
| #define _POSIX_PTHREAD_SEMANTICS 1
| #define __STDC_WANT_IEC_60559_ATTRIBS_EXT__ 1
| #define __STDC_WANT_IEC_60559_BFP_EXT__ 1
| #define __STDC_WANT_IEC_60559_DFP_EXT__ 1
| #define __STDC_WANT_IEC_60559_FUNCS_EXT__ 1
| #define __STDC_WANT_IEC_60559_TYPES_EXT__ 1
| #define __STDC_WANT_LIB_EXT2__ 1
| #define __STDC_WANT_MATH_SPEC_FUNCS__ 1
| #define _TANDEM_SOURCE 1
| #define __EXTENSIONS__ 1
| #define HAVE_DLFCN_H 1
| #define LT_OBJDIR ".libs/"
| #define HAVE_DIRENT_H 1
| #define HAVE_SYS_WAIT_H 1
| #define HAVE_CTYPE_H 1
| #define HAVE_ERRNO_H 1
| #define HAVE_FCNTL_H 1
| #define HAVE_GRP_H 1
| #define HAVE_INTTYPES_H 1
| #define HAVE_LANGINFO_H 1
| #define HAVE_LIMITS_H 1
| #define HAVE_LINUX_FIEMAP_H 1
| #define HAVE_LINUX_FS_H 1
| #define HAVE_LINUX_MAGIC_H 1
| #define HAVE_LINUX_TYPES_H 1
| #define HAVE_WORKING_FS_IOC_GETFLAGS 1
| #define HAVE_LOCALE_H 1
| #define HAVE_PATHS_H 1
| #define HAVE_POLL_H 1
| #define HAVE_PTHREAD_H 1
| #define HAVE_PWD_H 1
| #define HAVE_SIGNAL_H 1
| #define HAVE_SPAWN_H 1
| #define HAVE_STDARG_H 1
| #define HAVE_STDINT_H 1
| #define HAVE_STDLIB_H 1
| #define HAVE_STRING_H 1
| #define HAVE_SYS_CDEFS_H 1
| #define HAVE_SYS_IOCTL_H 1
| #define HAVE_SYS_MOUNT_H 1
| #define HAVE_SYS_PARAM_H 1
| #define HAVE_SYS_POLL_H 1
| #define HAVE_SYS_SELECT_H 1
| #define HAVE_SYS_STATFS_H 1
| #define HAVE_SYS_STATVFS_H 1
| #define HAVE_SYS_SYSMACROS_H 1
| #define HAVE_SYS_TIME_H 1
| #define HAVE_SYS_UTSNAME_H 1
| #define HAVE_SYS_VFS_H 1
| #define HAVE_SYS_XATTR_H 1
| #define HAVE_TIME_H 1
| #define HAVE_UNISTD_H 1
| #define HAVE_UTIME_H 1
| #define HAVE_WCHAR_H 1
| #define HAVE_WCTYPE_H 1
| #define HAVE_ZLIB_H 1
| #define HAVE_LIBZ 1
| #define HAVE_LZMA_H 1
| #define HAVE_LIBLZMA 1
| #define HAVE_LZMA_STREAM_ENCODER_MT 1
| #define HAVE_REGEX_H 1
| #define uid_t int
| #define gid_t int
| #define mode_t int
| #define off_t long long
| #define size_t unsigned int
| #define id_t unsigned long
| #define uintptr_t unsigned int
| #define HAVE_UNSIGNED_LONG_LONG_INT 1
| #define HAVE_LONG_LONG_INT 1
| #define intmax_t long long int
| #define uintmax_t unsigned long long int
| /* end confdefs.h.  */
| #include <float.h>
| #include <limits.h>
| #include <stdarg.h>
| #include <stddef.h>
| extern void ac_decl (int, char *);
| 
| int
| main (void)
| {
| (void) ac_decl (0, (char *) 0);
|   (void) ac_decl;
| 
|   ;
|   return 0;
| }
configure:17453: result: cannot detect
configure:17457: error: in `/tmp/imagine-bundle/libarchive/build/android-arm64':
configure:17459: error: cannot make /usr/local/android-sdk/android-sdk-linux/ndk/ndk-r23/toolchains/llvm/prebuilt/linux-x86_64/bin/clang report undeclared builtins
See `config.log' for more details

Compile Log

config.log

pkg-config

[root@localhost all]$ pkg-config --version
0.29.2

aclocal-1.16

[root@localhost all]$ aclocal-1.16 --version
aclocal (GNU automake) 1.16
Copyright (C) 2018 Free Software Foundation, Inc.
License GPLv2+: GNU GPL version 2 or later <https://gnu.org/licenses/gpl-2.0.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

Written by Tom Tromey <tromey@redhat.com>
       and Alexandre Duret-Lutz <adl@gnu.org>.
Rakashazi commented 3 years ago

Hi, this is the same issue as #197, now fixed.