As far as I can tell from glibc's documentation, this is how you are supposed to do it. glibc chose to always support both 32 and 64 bit APIs for time and file offset and make the normal int size the default. musl chose to switch to 64bit altogether.
https://www.gnu.org/software/libc/manual/html_node/64_002dbit-time-symbol-handling.html /Ola On Tue, Nov 08 2022, Alexander Kanavin wrote: > I suppose what I want to say is - perhaps this should be discussed > with upstreams first? Things should 'just work' without having to set > some magic flags in an external configuration. > > Alex > > On Tue, 8 Nov 2022 at 13:18, Alexander Kanavin via > lists.openembedded.org <alex.kanavin=gmail....@lists.openembedded.org> > wrote: >> >> Is this a recommendation somewhere official? >> >> Alex >> >> On Tue 8. Nov 2022 at 13.04, Niko Mauno <niko.ma...@vaisala.com> wrote: >>> >>> My understanding wrt. Y2038 and 32-bit glibc hosts was such that it >>> makes sense to set said compiler flags globally to ensure user space >>> wide Y2038 compliance. So I encountered this compiler error while >>> building poky reference images with additional effective >>> >>> TARGET_CPPFLAGS += "-D_TIME_BITS=64 -D_FILE_OFFSET_BITS=64" >>> >>> declaration in meta/conf/distro/include/tclibc-glibc.inc. >>> >>> -Niko >>> >>> On 8.11.2022 13.50, Alexander Kanavin wrote: >>> > So you need to set -D_TIME_BITS=64 >>> > -D_FILE_OFFSET_BITS=64 to get some error? But why set that, shouldn’t >>> > the defaults work? >>> > >>> > Alex >>> > >>> > On Tue 8. Nov 2022 at 12.48, Niko Mauno <niko.ma...@vaisala.com >>> > <mailto:niko.ma...@vaisala.com>> wrote: >>> > >>> > I have not studied the issue, but in order to reproduce this error I >>> > add >>> > 'MACHINE = "qemuarm"' to local.conf then issue 'bitbake kbd' against >>> > current master while TARGET_CPPFLAGS value is set to "-D_TIME_BITS=64 >>> > -D_FILE_OFFSET_BITS=64". >>> > >>> > -Niko >>> > >>> > On 8.11.2022 11.14, Alexander Kanavin wrote: >>> > > We do build for 32 bit arm targets, so is this seen only in >>> > specific >>> > > circumstances? What are they? >>> > > >>> > > Alex >>> > > >>> > > On Tue, 8 Nov 2022 at 01:09, Niko Mauno via >>> > lists.openembedded.org >>> > <http://lists.openembedded.org/ >>> > > <niko.mauno=vaisala....@lists.openembedded.org >>> > <mailto:vaisala....@lists.openembedded.org>> wrote: >>> > >> >>> > >> For now add exemption in order to avoid following failure during >>> > >> do_compile() >>> > >> >>> > >> | >>> > >>> > .../build/tmp/work/cortexa15t2hf-neon-poky-linux-gnueabi/kbd/2.5.1-r0/recipe-sysroot-native/usr/bin/arm-poky-linux-gnueabi/../../libexec/arm-poky-linux-gnueabi/gcc/arm-poky-linux-gnueabi/12.2.0/ld:.libs/libtswrap.ver:2: >>> > syntax error in VERSION script >>> > >> | collect2: error: ld returned 1 exit status >>> > >> >>> > >> Signed-off-by: Niko Mauno <niko.ma...@vaisala.com >>> > <mailto:niko.ma...@vaisala.com>> >>> > >> --- >>> > >> meta/recipes-core/kbd/kbd_2.5.1.bb >>> > <http://kbd_2.5.1.bb/ >>> > >> 1 file changed, 3 insertions(+) >>> > >> >>> > >> diff --git a/meta/recipes-core/kbd/kbd_2.5.1.bb >>> > <http://kbd_2.5.1.bb/ >>> > >> index aa3ab6e121..b623aecd36 100644 >>> > >> --- a/meta/recipes-core/kbd/kbd_2.5.1.bb >>> > <http://kbd_2.5.1.bb/ >>> > >> +++ b/meta/recipes-core/kbd/kbd_2.5.1.bb >>> > <http://kbd_2.5.1.bb/ >>> > >> @@ -18,6 +18,9 @@ SRC_URI = >>> > "${KERNELORG_MIRROR}/linux/utils/${BPN}/${BP}.tar.xz \ >>> > >> >>> > >> SRC_URI[sha256sum] = >>> > "ccdf452387a6380973d2927363e9cbb939fa2068915a6f937ff9d24522024683" >>> > >> >>> > >> +# Compiling 64 bit time for 32 bit host is broken >>> > >> +GLIBC_64BIT_TIME_CPPFLAGS = "" >>> > >> + >>> > >> PACKAGECONFIG ?= "${@bb.utils.filter('DISTRO_FEATURES', 'pam', >>> > d)} \ >>> > >> " >>> > >> >>> > >> -- >>> > >> 2.36.1 >>> > >> >>> > >> >>> > >> >>> > >> >>> > >> >> >> >> > [4. ATT00001.txt --- text/plain; ATT00001.txt]...
-=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#172969): https://lists.openembedded.org/g/openembedded-core/message/172969 Mute This Topic: https://lists.openembedded.org/mt/94880633/21656 Group Owner: openembedded-core+ow...@lists.openembedded.org Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-