#1095984 warning: '_GLIBCXX_TIME_BITS64_ABI_TAG' redefined

#1095984#5
Date:
2025-02-14 16:35:38 UTC
From:
To:
Dear Maintainer,

The following warning occurs in most c++ compilations and it will
cause many testsuite fails:

In file included from /<<PKGBUILDDIR>>/src/libstdc++-v3/libsupc++/cxxabi.h:51,
                 from ../../../../src/libstdc++-v3/libsupc++/atexit_arm.cc:24:
/<<PKGBUILDDIR>>/build/hppa-linux-gnu/libstdc++-v3/include/hppa-linux-gnu/bits/c++config.h:947:9: warning: '_GLIBCXX_TIME_BITS64_ABI_TAG' redefined
  947 | #define _GLIBCXX_TIME_BITS64_ABI_TAG
      |         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /<<PKGBUILDDIR>>/build/hppa-linux-gnu/libstdc++-v3/include/hppa-linux-gnu/bits/c++config.h:719:
/<<PKGBUILDDIR>>/build/hppa-linux-gnu/libstdc++-v3/include/hppa-linux-gnu/bits/os_defines.h:92:12: note: this is the location of the previous definition
   92 | #   define _GLIBCXX_TIME_BITS64_ABI_TAG [[__gnu__::__abi_tag__("__time64")]]
      |            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~

I believe the _GLIBCXX_TIME_BITS64_ABI_TAG defines are added by the
Debian build system.

Regards,
Dave Anglin

#1095984#10
Date:
2025-05-02 13:57:54 UTC
From:
To:
This is caused by debian/patch pr99832-distro.diff.

Dave

#1095984#15
Date:
2025-05-16 18:48:12 UTC
From:
To:
See comment #6 in pr99832:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=99832

Dave

#1095984#20
Date:
2025-05-23 23:41:37 UTC
From:
To:
Hi,

Attached is an updated version of pr99832-distro.diff.  It fixes many
test failures on hppa but acats tests didn't run.

Test results for gcc-15.1.0-4 with this patch are posted here:
https://gcc.gnu.org/pipermail/gcc-testresults/2025-May/847808.html

Please review and install.

Regards,
Dave Anglin

#1095984#25
Date:
2025-06-10 00:36:36 UTC
From:
To:
A fix for bug pr99832 was committed to gcc trunk:
https://gcc.gnu.org/cgit/gcc/commit/?id=d045eb13b0b42870a1f081895df3901112a358f0

See the commit message regarding the effect of defining _TIME_BITS=64 on
std::chrono::system_clock::to_time_t.

This affects release architectures as well as hppa (armel and armhf).

The debian patch is broken in that _GLIBCXX_TIME_BITS64_ABI_TAG is redefined to
an empty string which does nothing other than generate a warning.  The warning
breaks hundreds of tests and makes it impossible to assess build quality.

Hope this can be fixed.

Dave