Bug 3865 - getconf ARG_MAX returns undefined, confusing configure
Summary: getconf ARG_MAX returns undefined, confusing configure
Status: RESOLVED FIXED
Alias: None
Product: uClibc
Classification: Unclassified
Component: Other (show other bugs)
Version: 0.9.32
Hardware: PC Linux
: P5 minor
Target Milestone: 0.9.33.2
Assignee: unassigned
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-06-17 12:56 UTC by Michael Deutschmann
Modified: 2012-04-19 03:41 UTC (History)
1 user (show)

See Also:
Host:
Target:
Build:


Attachments
Patch to make sysconf always return ARG_MAX (544 bytes, application/octet-stream)
2011-06-17 12:56 UTC, Michael Deutschmann
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Deutschmann 2011-06-17 12:56:36 UTC
Created attachment 3397 [details]
Patch to make sysconf always return ARG_MAX

When uClibc's getconf utility is installed, and uClibc is not built for threads, GNU autoconf scripts will malfunction when determining the maximum length of command-line arguments.

This is because uClibc's sysconf() returns -1, causing getconf to print "undefined".  The autoconf scripts cannot tolerate a non-numeric response there.

Attached is a patch that forces sysconf to return legacy_ARG_MAX as a last resort, rather than -1.
Comment 1 Bernhard Reutner-Fischer 2012-04-17 22:34:58 UTC
Fixed in 4b24c5ad368d0312dbb9cfd6e028a3b21bba48cd

Thanks!
Comment 2 Mike Frysinger 2012-04-19 03:41:45 UTC
the libtool code is broken by not handling "undefined" as a value.  i'll post a patch to them though.