[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#1012985: libpfm4: ftbfs with GCC-12



Package: src:libpfm4
Version: 4.11.1+git32-gd0b85fb-1
Severity: normal
Tags: sid bookworm
User: debian-gcc@lists.debian.org
Usertags: ftbfs-gcc-12

[This bug is targeted to the upcoming bookworm release]

Please keep this issue open in the bug tracker for the package it
was filed for.  If a fix in another package is required, please
file a bug for the other package (or clone), and add a block in this
package. Please keep the issue open until the package can be built in
a follow-up test rebuild.

The package fails to build in a test rebuild on at least amd64 with
gcc-12/g++-12, but succeeds to build with gcc-11/g++-11. The
severity of this report will be raised before the bookworm release.

The full build log can be found at:
http://qa-logs.debian.net/2022/06/09/gcc12/libpfm4_4.11.1+git32-gd0b85fb-1_unstable_gcc12.log
The last lines of the build log are at the end of this report.

To build with GCC 11, either set CC=gcc-11 CXX=g++-11 explicitly,
or install the gcc, g++, gfortran, ... packages from experimental.

  apt-get -t=experimental install g++ 

Common build failures are new warnings resulting in build failures with
-Werror turned on, or new/dropped symbols in Debian symbols files.
For other C/C++ related build failures see the porting guide at
http://gcc.gnu.org/gcc-11/porting_to.html

GCC 11 defaults to the GNU++17 standard.  If your package installs
header files in /usr/include, please don't work around C++17 issues
by choosing a lower C++ standard for the package build, but fix these
issues to build with the C++17 standard.

[...]
rm -f -f *.o self self_basic self_count task task_attach_timeout syst notify_self notify_group task_smpl self_smpl_multi self_pipe syst_count task_cpu syst_smpl evt2raw branch_smpl rtop *~
make[2]: Leaving directory '/<<PKGBUILDDIR>>/perf_examples'
make[2]: Entering directory '/<<PKGBUILDDIR>>/include'
make[2]: Nothing to be done for 'clean'.
make[2]: Leaving directory '/<<PKGBUILDDIR>>/include'
make[2]: Entering directory '/<<PKGBUILDDIR>>/docs'
make[2]: Nothing to be done for 'clean'.
make[2]: Leaving directory '/<<PKGBUILDDIR>>/docs'
rm -f -f tags
make[1]: Leaving directory '/<<PKGBUILDDIR>>'
   dh_clean
 debian/rules binary
dh  binary
   dh_update_autotools_config
   dh_autoreconf
   dh_auto_configure
   debian/rules override_dh_auto_build
make[1]: Entering directory '/<<PKGBUILDDIR>>'
dh_auto_build -- 
	make -j8 "INSTALL=install --strip-program=true"
make[2]: Entering directory '/<<PKGBUILDDIR>>'
Compiling for 'x86_64' target
Compiling for 'Linux' system
make[3]: Entering directory '/<<PKGBUILDDIR>>/lib'
cc -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/lib/../include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX -D_REENTRANT -I. -fvisibility=hidden -DCONFIG_PFMLIB_ARCH_X86 -DCONFIG_PFMLIB_ARCH_X86_64 -I. -c pfmlib_common.c
cc -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/lib/../include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX -D_REENTRANT -I. -fvisibility=hidden -DCONFIG_PFMLIB_ARCH_X86 -DCONFIG_PFMLIB_ARCH_X86_64 -I. -c pfmlib_perf_event_pmu.c
cc -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/lib/../include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX -D_REENTRANT -I. -fvisibility=hidden -DCONFIG_PFMLIB_ARCH_X86 -DCONFIG_PFMLIB_ARCH_X86_64 -I. -c pfmlib_perf_event.c
cc -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/lib/../include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX -D_REENTRANT -I. -fvisibility=hidden -DCONFIG_PFMLIB_ARCH_X86 -DCONFIG_PFMLIB_ARCH_X86_64 -I. -c pfmlib_perf_event_raw.c
cc -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/lib/../include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX -D_REENTRANT -I. -fvisibility=hidden -DCONFIG_PFMLIB_ARCH_X86 -DCONFIG_PFMLIB_ARCH_X86_64 -I. -c pfmlib_intel_x86_perf_event.c
cc -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/lib/../include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX -D_REENTRANT -I. -fvisibility=hidden -DCONFIG_PFMLIB_ARCH_X86 -DCONFIG_PFMLIB_ARCH_X86_64 -I. -c pfmlib_amd64_perf_event.c
cc -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/lib/../include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX -D_REENTRANT -I. -fvisibility=hidden -DCONFIG_PFMLIB_ARCH_X86 -DCONFIG_PFMLIB_ARCH_X86_64 -I. -c pfmlib_intel_netburst_perf_event.c
cc -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/lib/../include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX -D_REENTRANT -I. -fvisibility=hidden -DCONFIG_PFMLIB_ARCH_X86 -DCONFIG_PFMLIB_ARCH_X86_64 -I. -c pfmlib_intel_snbep_unc_perf_event.c
cc -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/lib/../include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX -D_REENTRANT -I. -fvisibility=hidden -DCONFIG_PFMLIB_ARCH_X86 -DCONFIG_PFMLIB_ARCH_X86_64 -I. -c pfmlib_amd64.c
cc -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/lib/../include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX -D_REENTRANT -I. -fvisibility=hidden -DCONFIG_PFMLIB_ARCH_X86 -DCONFIG_PFMLIB_ARCH_X86_64 -I. -c pfmlib_intel_core.c
cc -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/lib/../include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX -D_REENTRANT -I. -fvisibility=hidden -DCONFIG_PFMLIB_ARCH_X86 -DCONFIG_PFMLIB_ARCH_X86_64 -I. -c pfmlib_intel_x86.c
cc -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/lib/../include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX -D_REENTRANT -I. -fvisibility=hidden -DCONFIG_PFMLIB_ARCH_X86 -DCONFIG_PFMLIB_ARCH_X86_64 -I. -c pfmlib_intel_x86_arch.c
cc -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/lib/../include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX -D_REENTRANT -I. -fvisibility=hidden -DCONFIG_PFMLIB_ARCH_X86 -DCONFIG_PFMLIB_ARCH_X86_64 -I. -c pfmlib_intel_atom.c
cc -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/lib/../include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX -D_REENTRANT -I. -fvisibility=hidden -DCONFIG_PFMLIB_ARCH_X86 -DCONFIG_PFMLIB_ARCH_X86_64 -I. -c pfmlib_intel_nhm_unc.c
cc -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/lib/../include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX -D_REENTRANT -I. -fvisibility=hidden -DCONFIG_PFMLIB_ARCH_X86 -DCONFIG_PFMLIB_ARCH_X86_64 -I. -c pfmlib_intel_nhm.c
In function ‘perf_table_alloc_event’,
    inlined from ‘gen_tracepoint_table’ at pfmlib_perf_event_pmu.c:373:8:
pfmlib_perf_event_pmu.c:268:47: error: pointer may be used after ‘realloc’ [-Werror=use-after-free]
  268 |         perf_pe_free = new_pe + (perf_pe_free - perf_pe);
      |                                               ^
pfmlib_perf_event_pmu.c:264:18: note: call to ‘realloc’ here
  264 |         new_pe = realloc(perf_pe, perf_pe_count * sizeof(perf_event_t));
      |                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In function ‘perf_table_alloc_umask’,
    inlined from ‘gen_tracepoint_table’ at pfmlib_perf_event_pmu.c:434:10:
pfmlib_perf_event_pmu.c:304:47: error: pointer may be used after ‘realloc’ [-Werror=use-after-free]
  304 |         perf_um_free = new_um + (perf_um_free - perf_um);
      |                                               ^
pfmlib_perf_event_pmu.c:300:18: note: call to ‘realloc’ here
  300 |         new_um = realloc(perf_um, perf_um_count * sizeof(*new_um));
      |                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
cc -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/lib/../include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX -D_REENTRANT -I. -fvisibility=hidden -DCONFIG_PFMLIB_ARCH_X86 -DCONFIG_PFMLIB_ARCH_X86_64 -I. -c pfmlib_intel_wsm.c
cc -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/lib/../include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX -D_REENTRANT -I. -fvisibility=hidden -DCONFIG_PFMLIB_ARCH_X86 -DCONFIG_PFMLIB_ARCH_X86_64 -I. -c pfmlib_intel_snb.c
cc -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/lib/../include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX -D_REENTRANT -I. -fvisibility=hidden -DCONFIG_PFMLIB_ARCH_X86 -DCONFIG_PFMLIB_ARCH_X86_64 -I. -c pfmlib_intel_snb_unc.c
cc -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX  -g -Wall -Werror -Wextra -Wno-unused-parameter -I. -I/<<PKGBUILDDIR>>/lib/../include -DCONFIG_PFMLIB_DEBUG -DCONFIG_PFMLIB_OS_LINUX -D_REENTRANT -I. -fvisibility=hidden -DCONFIG_PFMLIB_ARCH_X86 -DCONFIG_PFMLIB_ARCH_X86_64 -I. -c pfmlib_intel_ivb.c
cc1: all warnings being treated as errors
make[3]: *** [/<<PKGBUILDDIR>>/lib/../rules.mk:30: pfmlib_perf_event_pmu.o] Error 1
make[3]: *** Waiting for unfinished jobs....
make[3]: Leaving directory '/<<PKGBUILDDIR>>/lib'
make[2]: *** [Makefile:49: all] Error 2
make[2]: Leaving directory '/<<PKGBUILDDIR>>'
dh_auto_build: error: make -j8 "INSTALL=install --strip-program=true" returned exit code 2
make[1]: *** [debian/rules:30: override_dh_auto_build] Error 25
make[1]: Leaving directory '/<<PKGBUILDDIR>>'
make: *** [debian/rules:27: binary] Error 2
dpkg-buildpackage: error: debian/rules binary subprocess returned exit status 2


Reply to: