mainAutoconf - Support: sr #110983, AC_SYS_LARGEFILE doesn't honor...

 
 

sr #110983: AC_SYS_LARGEFILE doesn't honor AC_LANG setting

Submitter:  Zack Weinberg <zackw>
Submitted:  Tue 19 Dec 2023 06:36:10 PM UTC
   
 
Priority:  * 3 - Release N+1 Severity:  4 - Important
Status:  Done Privacy:  Public
Assigned to:  None Open/Closed:  Open
Operating System:  None
* Mandatory Fields

Add a New Comment Rich Markup
   

Jump to the original submission

Wed 24 Apr 2024 09:52:10 PM UTC, comment #6: 

I installed a patch; please give it a try. In the meantime I am boldly closing this bug report.

Paul Eggert <eggert>
Group administrator
Sat 13 Apr 2024 06:12:04 AM UTC, comment #5: 

Hi,

The attached patch seems to fix AC_SYS_LARGEFILE and co. with C++ for me (and test suite passes on i686).

Jakub Bogusz <qboosh at pld-linux.org>

(file #55940)

Anonymous
Tue 19 Dec 2023 06:47:37 PM UTC, comment #4: 

@Paul Eggert: Not today, hopefully tomorrow.

Zack Weinberg <zackw>
Group administrator
Tue 19 Dec 2023 06:46:25 PM UTC, comment #3: 

As a workaround, make sure to invoke AC_SYS_LARGEFILE and/or AC_SYS_YEAR2038 early in configure.ac (this is a good idea anyway, as they can affect the results of later checks), in C mode, even if nothing else uses the C compiler.  For example:


AC_INIT([my-C++-program], [1.0], ...)
AC_PROG_CC
AC_SYS_LARGEFILE
AC_PROG_CXX
AC_LANG([C++])
# rest of the configure script
AC_OUTPUT


Zack Weinberg <zackw>
Group administrator
Tue 19 Dec 2023 06:40:15 PM UTC, comment #2: 

Do you have an idea for a patch? We could put the patch into Gnulib's copy of AC_SYS_LARGEFILE now, and it'll see more real-worldish testing that way.

Paul Eggert <eggert>
Group administrator
Tue 19 Dec 2023 06:36:38 PM UTC, comment #1: 

I don't want to mess with AC_SYS_LARGEFILE this close to a release, but we should prioritize fixing this very soon afterward.

Zack Weinberg <zackw>
Group administrator
Tue 19 Dec 2023 06:36:10 PM UTC, original submission:  

_AC_SYS_LARGEFILE_PROBE unconditionally modifies $CC, regardless of the current AC_LANG setting. Therefore, a configure script like this


AC_INIT
AC_LANG([C++])
AC_SYS_LARGEFILE
AC_OUTPUT


will not enable large file support, on a system where it's off by default but can be enabled.  Because it put -D_FILE_OFFSET_BITS=64 into $CC, where AC_COMPILE_IFELSE won't pick it up because we're using $CXX instead.

Since AC_SYS_YEAR2038 depends on AC_SYS_LARGEFILE, this affects that macro as well.

Zack Weinberg <zackw>
Group administrator

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

Attached Files
file #55940:  autoconf-largefile.patch added by None (1KiB - text/x-patch - Append flags to language-agnostic variable used by AC_COMPILE_IFELSE)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by eggert (Posted a comment)
  • -email is unavailable- added by zackw (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only logged-in users can vote.

     

    Follow 5 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2024-04-24 eggert StatusConfirmed Done
    2024-04-13 None Attached File- Added autoconf-largefile.patch, #55940
    2023-12-19 zackw Priority5 - Unprioritized 3 - Release N+1
        Severity3 - Normal 4 - Important
        Operating SystemSolaris None

    Back to the top

    Powered by Savane 3.13-02a9.
    Corresponding source code