Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 548962 - >dev-build/autoconf-2.13 incorrectly handles detection of 32 bit off_t
Summary: >dev-build/autoconf-2.13 incorrectly handles detection of 32 bit off_t
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo's Team for Core System packages
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: lfs-tracker
  Show dependency tree
 
Reported: 2015-05-09 06:34 UTC by Adam Feldman
Modified: 2024-04-24 23:15 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
autoconf-all-32bit_off_t_fix.patch (file_548962.txt,1.11 KB, text/plain)
2015-05-09 06:34 UTC, Adam Feldman
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Adam Feldman gentoo-dev 2015-05-09 06:34:14 UTC
Created attachment 402876 [details]
autoconf-all-32bit_off_t_fix.patch

This is an upstream issue.  I'm unaware if upstream is aware of the issue.  All versions in tree including 9999 but excluding 2.13 are affected.

To detect the size of off_t, autoconf does a bitshift of 62 when dealing with both 64bit and 32 bit code.  This is handled appropriately by shifting by 31 twice.  The attached patch is from Debian.
Comment 1 SpanKY gentoo-dev 2015-05-10 16:40:26 UTC
it does not look like Debian notified upstream.  this really should be sent there first.

also worth noting: any package using 32bit off_t in Gentoo is broken and needs to be fixed in which case this report is mostly moot :).  see bug 471102 for details.
Comment 2 Ian Delaney (RETIRED) gentoo-dev 2015-05-21 08:00:44 UTC
Just to do it formally have you sent this / notified upstream? Otehr potential viewers will also know.
Comment 3 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2024-04-24 23:08:56 UTC
commit a1d8293f3bfa2516f9a0424e3a6e63c2f8e93c6e
Author: Paul Eggert <eggert@cs.ucla.edu>
Date:   Mon Jun 29 16:51:08 2020 -0700

    Fix undefined behavior in AC_SYS_LARGEFILE

    * lib/autoconf/specific.m4 (_AC_SYS_LARGEFILE_TEST_INCLUDES):
    Avoid undefined behavior on platforms where off_t is 32 bits.  See:
    https://bugs.debian.org/742780

$ git tag --contains a1d8293f3bfa2516f9a0424e3a6e63c2f8e93c6e
v2.69b
v2.69c
v2.69d
v2.69e
v2.70
v2.71
v2.72
v2.72a
v2.72b
v2.72c
v2.72d
v2.72e

so, fixed in autoconf-2.70.