https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68931
Daniel Santos <daniel.santos at pobox dot com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |daniel.santos at pobox dot com --- Comment #4 from Daniel Santos <daniel.santos at pobox dot com> --- Hello. This is still a problem in 10.2 and I'm definitely going to need to solve this. As near as I can tell, the underlying issue is libgo/config.h incorrectly being populated with HAVE_OFF64_T. configure:11206: checking for off64_t configure:11206: /home/daniel/proj/embedded/openwrt/head/build_dir/toolchain-mipsel_24kc_gcc-10.2.0_musl/gcc-10.2.0-final/./gcc/xgcc -B/home/daniel/proj/embedded/openwrt/head/build_dir/toolchain-mipsel_24kc_gcc-10.2.0_musl/gcc-10.2.0-final/./gcc/ -B/home/daniel/proj/embedded/openwrt/head/staging_dir/toolchain-mipsel_24kc_gcc-10.2.0_musl/mipsel-openwrt-linux-musl/bin/ -B/home/daniel/proj/embedded/openwrt/head/staging_dir/toolchain-mipsel_24kc_gcc-10.2.0_musl/mipsel-openwrt-linux-musl/lib/ -isystem /home/daniel/proj/embedded/openwrt/head/staging_dir/toolchain-mipsel_24kc_gcc-10.2.0_musl/mipsel-openwrt-linux-musl/include -isystem /home/daniel/proj/embedded/openwrt/head/staging_dir/toolchain-mipsel_24kc_gcc-10.2.0_musl/mipsel-openwrt-linux-musl/sys-include -c -Os -pipe -mno-branch-likely -mips32r2 -mtune=24kc -g3 -fno-caller-saves -fno-plt -fhonour-copts -Wno-error=unused-but-set-variable -Wno-error=unused-result -msoft-float -Wformat -Werror=format-security -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE conftest.c >&5 configure:11206: $? = 0 configure:11206: /home/daniel/proj/embedded/openwrt/head/build_dir/toolchain-mipsel_24kc_gcc-10.2.0_musl/gcc-10.2.0-final/./gcc/xgcc -B/home/daniel/proj/embedded/openwrt/head/build_dir/toolchain-mipsel_24kc_gcc-10.2.0_musl/gcc-10.2.0-final/./gcc/ -B/home/daniel/proj/embedded/openwrt/head/staging_dir/toolchain-mipsel_24kc_gcc-10.2.0_musl/mipsel-openwrt-linux-musl/bin/ -B/home/daniel/proj/embedded/openwrt/head/staging_dir/toolchain-mipsel_24kc_gcc-10.2.0_musl/mipsel-openwrt-linux-musl/lib/ -isystem /home/daniel/proj/embedded/openwrt/head/staging_dir/toolchain-mipsel_24kc_gcc-10.2.0_musl/mipsel-openwrt-linux-musl/include -isystem /home/daniel/proj/embedded/openwrt/head/staging_dir/toolchain-mipsel_24kc_gcc-10.2.0_musl/mipsel-openwrt-linux-musl/sys-include -c -Os -pipe -mno-branch-likely -mips32r2 -mtune=24kc -g3 -fno-caller-saves -fno-plt -fhonour-copts -Wno-error=unused-but-set-variable -Wno-error=unused-result -msoft-float -Wformat -Werror=format-security -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE conftest.c >&5 conftest.c: In function 'main': conftest.c:146:22: error: expected expression before ')' token 146 | if (sizeof ((off64_t))) | ^ configure:11206: $? = 1 configure: failed program was: | /* confdefs.h */ | #define PACKAGE_NAME "package-unused" | #define PACKAGE_TARNAME "libgo" | #define PACKAGE_VERSION "version-unused" | #define PACKAGE_STRING "package-unused version-unused" | #define PACKAGE_BUGREPORT "" | #define PACKAGE_URL "" | #define STDC_HEADERS 1 | #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 USE_LIBFFI 1 | #define HAVE_GETIPINFO 1 | #define HAVE_SCHED_H 1 | #define HAVE_SEMAPHORE_H 1 | #define HAVE_SYS_FILE_H 1 | #define HAVE_SYS_MMAN_H 1 | #define HAVE_SYSCALL_H 1 | #define HAVE_SYS_EPOLL_H 1 | #define HAVE_SYS_INOTIFY_H 1 | #define HAVE_SYS_PTRACE_H 1 | #define HAVE_SYS_SYSCALL_H 1 | #define HAVE_SYS_USER_H 1 | #define HAVE_SYS_UTSNAME_H 1 | #define HAVE_SYS_SELECT_H 1 | #define HAVE_SYS_SOCKET_H 1 | #define HAVE_NET_IF_H 1 | #define HAVE_NET_IF_ARP_H 1 | #define HAVE_NET_ROUTE_H 1 | #define HAVE_NETPACKET_PACKET_H 1 | #define HAVE_SYS_PRCTL_H 1 | #define HAVE_SYS_MOUNT_H 1 | #define HAVE_SYS_VFS_H 1 | #define HAVE_SYS_STATFS_H 1 | #define HAVE_SYS_TIMEX_H 1 | #define HAVE_SYS_SYSINFO_H 1 | #define HAVE_UTIME_H 1 | #define HAVE_LINUX_FS_H 1 | #define HAVE_LINUX_PTRACE_H 1 | #define HAVE_LINUX_REBOOT_H 1 | #define HAVE_NETINET_IP_H 1 | #define HAVE_NETINET_IF_ETHER_H 1 | #define HAVE_NETINET_ICMP6_H 1 | #define HAVE_LINUX_FILTER_H 1 | #define HAVE_LINUX_IF_ADDR_H 1 | #define HAVE_LINUX_IF_ETHER_H 1 | #define HAVE_LINUX_IF_TUN_H 1 | #define HAVE_LINUX_NETLINK_H 1 | #define HAVE_LINUX_RTNETLINK_H 1 | #define HAVE_STRERROR_R 1 | #define HAVE_STRSIGNAL 1 | #define HAVE_WAIT4 1 | #define HAVE_MINCORE 1 | #define HAVE_SETENV 1 | #define HAVE_UNSETENV 1 | #define HAVE_DL_ITERATE_PHDR 1 | #define HAVE_MEMMEM 1 | #define HAVE_ACCEPT4 1 | #define HAVE_DUP3 1 | #define HAVE_EPOLL_CREATE1 1 | #define HAVE_FACCESSAT 1 | #define HAVE_FALLOCATE 1 | #define HAVE_FCHMODAT 1 | #define HAVE_FCHOWNAT 1 | #define HAVE_FUTIMESAT 1 | #define HAVE_GETXATTR 1 | #define HAVE_INOTIFY_ADD_WATCH 1 | #define HAVE_INOTIFY_INIT 1 | #define HAVE_INOTIFY_INIT1 1 | #define HAVE_INOTIFY_RM_WATCH 1 | #define HAVE_LISTXATTR 1 | #define HAVE_MKDIRAT 1 | #define HAVE_MKNODAT 1 | #define HAVE_OPEN64 1 | #define HAVE_OPENAT 1 | #define HAVE_PIPE2 1 | #define HAVE_REMOVEXATTR 1 | #define HAVE_RENAMEAT 1 | #define HAVE_SETXATTR 1 | #define HAVE_SYNC_FILE_RANGE 1 | #define HAVE_SPLICE 1 | #define HAVE_SYSCALL 1 | #define HAVE_TEE 1 | #define HAVE_UNLINKAT 1 | #define HAVE_UNSHARE 1 | #define HAVE_UTIMENSAT 1 | #define HAVE_COSL 1 | #define HAVE_EXPL 1 | #define HAVE_LOGL 1 | #define HAVE_SINL 1 | #define HAVE_TANL 1 | #define HAVE_ACOSL 1 | #define HAVE_ASINL 1 | #define HAVE_ATANL 1 | #define HAVE_ATAN2L 1 | #define HAVE_EXPM1L 1 | #define HAVE_LDEXPL 1 | #define HAVE_LOG10L 1 | #define HAVE_LOG1PL 1 | #define HAVE_SEM_TIMEDWAIT 1 | /* end confdefs.h. */ | #include <stdio.h> | #ifdef HAVE_SYS_TYPES_H | # include <sys/types.h> | #endif | #ifdef HAVE_SYS_STAT_H | # include <sys/stat.h> | #endif | #ifdef STDC_HEADERS | # include <stdlib.h> | # include <stddef.h> | #else | # ifdef HAVE_STDLIB_H | # include <stdlib.h> | # endif | #endif | #ifdef HAVE_STRING_H | # if !defined STDC_HEADERS && defined HAVE_MEMORY_H | # include <memory.h> | # endif | # include <string.h> | #endif | #ifdef HAVE_STRINGS_H | # include <strings.h> | #endif | #ifdef HAVE_INTTYPES_H | # include <inttypes.h> | #endif | #ifdef HAVE_STDINT_H | # include <stdint.h> | #endif | #ifdef HAVE_UNISTD_H | # include <unistd.h> | #endif | int | main () | { | if (sizeof ((off64_t))) | return 0; | ; | return 0; | } configure:11206: result: yes Incidentally, here's musl's note on off64_t: https://wiki.musl-libc.org/faq.html#Q:-Do-I-need-to-define-%3Ccode%3E_LARGEFILE64_SOURCE%3C/code%3E-to-get-64bit-%3Ccode%3Eoff_t%3C/code%3E?