[Pkg-xen-devel] Bug#909668: FTBFS in buster and sid (probably, due to gcc-8)

Ian Jackson ijackson at chiark.greenend.org.uk
Wed Sep 26 15:18:14 BST 2018


Package: xen
Version: 4.11.1~pre.20180911.5acdd26fdc+dfsg-1~exp1
Severity: serious

In buster chroots on porterboxes.

i386:

md/../../tools/include  -c -o xenpmd.o xenpmd.c 
xenpmd.c: In function ‘write_battery_info_to_xenstore’:
xenpmd.c:354:23: error: ‘%02x’ directive output may be truncated writing between 2 and 8 bytes into a region of size 3 [-Werror=format-truncation=]
     snprintf(val, 3, "%02x",
                       ^~~~
xenpmd.c:354:22: note: directive argument in the range [40, 2147483778]
     snprintf(val, 3, "%02x",
                      ^~~~~~
xenpmd.c:354:5: note: ‘snprintf’ output between 3 and 9 bytes into a destination of size 3
     snprintf(val, 3, "%02x",
     ^~~~~~~~~~~~~~~~~~~~~~~~
              (unsigned int)(9*4 +
              ~~~~~~~~~~~~~~~~~~~~
                             strlen(info->model_number) +
                             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
                             strlen(info->serial_number) +
                             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
                             strlen(info->battery_type) +
                             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
                             strlen(info->oem_info) + 4));
                             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
make[5]: *** [/home/iwj/Xen/xen/debian/build/build-utils_i386/tools/xenpmd/../../tools/Rules.mk:227: xenpmd.o] Error 1
make[5]: Leaving directory '/home/iwj/Xen/xen/debian/build/build-utils_i386/tools/xenpmd'
make[4]: *** [/home/iwj/Xen/xen/debian/build/build-utils_i386/tools/../tools/Rules.mk:251: subdir-all-xenpmd] Error 2
make[4]: Leaving directory '/home/iwj/Xen/xen/debian/build/build-utils_i386/tools'
make[3]: *** [/home/iwj/Xen/xen/debian/build/build-utils_i386/tools/../tools/Rules.mk:246: subdirs-all] Error 2
make[3]: Leaving directory '/home/iwj/Xen/xen/debian/build/build-utils_i386/tools'
make[2]: *** [debian/rules.real:112: debian/stamps/build-utils_i386] Error 2
make[2]: Leaving directory '/home/iwj/Xen/xen'
make[1]: *** [debian/rules.gen:84: build-arch_i386_real] Error 2
make[1]: Leaving directory '/home/iwj/Xen/xen'
make: *** [debian/rules:24: build-arch] Error 2
dpkg-buildpackage: error: debian/rules build subprocess returned exit status 2
(buster_i386-dchroot)iwj at barriere:~/Xen/xen$ 

arm64:

iwj/Xen/xen/debian/build/build-utils_arm64/tools/libxl/../../tools/config.h  -c -o libxl_arm_acpi.o libxl_arm_acpi.c 
libxl_arm_acpi.c: In function ‘make_acpi_header’:
libxl_arm_acpi.c:208:5: error: ‘memcpy’ forming offset [5, 6] is out of the bounds [0, 4] [-Werror=array-bounds]
     memcpy(h->oem_id, ACPI_OEM_ID, sizeof(h->oem_id));
     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
libxl_arm_acpi.c:209:5: error: ‘memcpy’ forming offset [5, 8] is out of the bounds [0, 4] [-Werror=array-bounds]
     memcpy(h->oem_table_id, ACPI_OEM_TABLE_ID, sizeof(h->oem_table_id));
     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
libxl_arm_acpi.c:211:5: error: ‘memcpy’ forming offset 4 is out of the bounds [0, 3] [-Werror=array-bounds]
     memcpy(h->asl_compiler_id, ACPI_ASL_COMPILER_ID,
     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
            sizeof(h->asl_compiler_id));
            ~~~~~~~~~~~~~~~~~~~~~~~~~~~
In function ‘make_acpi_rsdp.isra.4’,
    inlined from ‘libxl__prepare_acpi’ at libxl_arm_acpi.c:389:5:
libxl_arm_acpi.c:193:5: error: ‘memcpy’ forming offset [5, 6] is out of the bounds [0, 4] [-Werror=array-bounds]
     memcpy(rsdp->oem_id, ACPI_OEM_ID, sizeof(rsdp->oem_id));
     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
make[5]: *** [/home/iwj/Xen/xen/debian/build/build-utils_arm64/tools/libxl/../../tools/Rules.mk:227: libxl_arm_acpi.o] Error 1
make[5]: Leaving directory '/home/iwj/Xen/xen/debian/build/build-utils_arm64/tools/libxl'
make[4]: *** [/home/iwj/Xen/xen/debian/build/build-utils_arm64/tools/../tools/Rules.mk:251: subdir-all-libxl] Error 2
make[4]: Leaving directory '/home/iwj/Xen/xen/debian/build/build-utils_arm64/tools'
make[3]: *** [/home/iwj/Xen/xen/debian/build/build-utils_arm64/tools/../tools/Rules.mk:246: subdirs-all] Error 2
make[3]: Leaving directory '/home/iwj/Xen/xen/debian/build/build-utils_arm64/tools'
make[2]: *** [debian/rules.real:112: debian/stamps/build-utils_arm64] Error 2
make[2]: Leaving directory '/home/iwj/Xen/xen'
make[1]: *** [debian/rules.gen:66: build-arch_arm64_real] Error 2
make[1]: Leaving directory '/home/iwj/Xen/xen'
make: *** [debian/rules:24: build-arch] Error 2
dpkg-buildpackage: error: debian/rules build subprocess returned exit status 2
(buster_arm64-dchroot)iwj at amdahl:~/Xen/xen$ 

I think armhf will fail too, but harris is a bit slow so I don't have
the full log yet.

In my own sid amd64 chroot:

gcc  -m64 -DBUILD_ID -fno-strict-aliasing -std=gnu99 -Wall -Wstrict-prototypes -Wdeclaration-after-statement -Wno-unused-but-set-variable -Wno-unused-local-typedefs   -O2 -fomit-frame-pointer -D__XEN_INTERFACE_VERSION__=__XEN_LATEST_INTERFACE_VERSION__ -MMD -MF .xc_pm.o.d -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_GNU_SOURCE -g -O2 -fdebug-prefix-map=/<<BUILDDIR>>/xen-4.8.4+xsa273+shim4.10.1+xsa273=. -fstack-protector-strong -Wformat -Werror=format-security -I../../xen/common/libelf -Werror -Wmissing-prototypes -I. -I./include -I/<<BUILDDIR>>/xen-4.8.4+xsa273+shim4.10.1+xsa273/debian/build/build-utils_amd64/tools/libxc/../../tools/include -D__XEN_TOOLS__ -pthread -I/<<BUILDDIR>>/xen-4.8.4+xsa273+shim4.10.1+xsa273/debian/build/build-utils_amd64/tools/libxc/../../tools/libs/toollog/include -I/<<BUILDDIR>>/xen-4.8.4+xsa273+shim4.10.1+xsa273/debian/build/build-utils_amd64/tools/libxc/../../tools/include -I/<<BUILDDIR>>/xen-4.8.4+xsa273+shim4.10.1+xsa273/debian/build/build-utils_amd64/tools/libxc/../../tools/libs/evtchn/include -I/<<BUILDDIR>>/xen-4.8.4+xsa273+shim4.10.1+xsa273/debian/build/build-utils_amd64/tools/libxc/../../tools/include -include /<<BUILDDIR>>/xen-4.8.4+xsa273+shim4.10.1+xsa273/debian/build/build-utils_amd64/tools/libxc/../../tools/config.h -I/<<BUILDDIR>>/xen-4.8.4+xsa273+shim4.10.1+xsa273/debian/build/build-utils_amd64/tools/libxc/../../tools/libs/call/include -I/<<BUILDDIR>>/xen-4.8.4+xsa273+shim4.10.1+xsa273/debian/build/build-utils_amd64/tools/libxc/../../tools/include -I/<<BUILDDIR>>/xen-4.8.4+xsa273+shim4.10.1+xsa273/debian/build/build-utils_amd64/tools/libxc/../../tools/libs/foreignmemory/include -I/<<BUILDDIR>>/xen-4.8.4+xsa273+shim4.10.1+xsa273/debian/build/build-utils_amd64/tools/libxc/../../tools/include -I/<<BUILDDIR>>/xen-4.8.4+xsa273+shim4.10.1+xsa273/debian/build/build-utils_amd64/tools/libxc/../../tools/libs/gnttab/include -I/<<BUILDDIR>>/xen-4.8.4+xsa273+shim4.10.1+xsa273/debian/build/build-utils_amd64/tools/libxc/../../tools/include -I/<<BUILDDIR>>/xen-4.8.4+xsa273+shim4.10.1+xsa273/debian/build/build-utils_amd64/tools/libxc/../../tools/libs/gnttab/include -I/<<BUILDDIR>>/xen-4.8.4+xsa273+shim4.10.1+xsa273/debian/build/build-utils_amd64/tools/libxc/../../tools/include  -c -o xc_pm.o xc_pm.c 
xc_pm.c: In function 'xc_set_cpufreq_gov':
xc_pm.c:308:5: error: 'strncpy' specified bound 16 equals destination size [-Werror=stringop-truncation]
     strncpy(scaling_governor, govname, CPUFREQ_NAME_LEN);
     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors

Ian.

-- 
Ian Jackson <ijackson at chiark.greenend.org.uk>   These opinions are my own.

If I emailed you from an address @fyvzl.net or @evade.org.uk, that is
a private address which bypasses my fierce spamfilter.


More information about the Pkg-xen-devel mailing list