aboutsummaryrefslogtreecommitdiff
path: root/libjava/classpath/lib
diff options
context:
space:
mode:
authorRainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>2025-05-08 09:39:26 +0200
committerRainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>2025-05-08 09:39:26 +0200
commit1df8fffba30bf4022dda762bf61acf16ac704c67 (patch)
treecd4c35b521194ce0d0f35bb8e0796d7a3a495bc8 /libjava/classpath/lib
parent8c73c99b6a8c3a562fef360bc269bd60bab36076 (diff)
downloadgcc-1df8fffba30bf4022dda762bf61acf16ac704c67.zip
gcc-1df8fffba30bf4022dda762bf61acf16ac704c67.tar.gz
gcc-1df8fffba30bf4022dda762bf61acf16ac704c67.tar.bz2
cobol: Allow for undefined NAME_MAX [PR119217]
All users of symbols.h fail to compile on Solaris: /vol/gcc/src/hg/master/local/gcc/cobol/symbols.h: At global scope: /vol/gcc/src/hg/master/local/gcc/cobol/symbols.h:1365:13: error: ‘NAME_MAX’ was not declared in this scope 1365 | char name[NAME_MAX]; | ^~~~~~~~ NAME_MAX being undefined is allowed by POSIX.1, actually: it's listed for <limits.h> under "Pathname Variable Values": A definition of one of the symbolic constants in the following list shall be omitted from the <limits.h> header on specific implementations where the corresponding value is equal to or greater than the stated minimum, but where the value can vary depending on the file to which it is applied. The actual value supported for a specific pathname shall be provided by the pathconf() function. As a hack, this patch provides a fallback definition to allow the build to finish. In fact it turned out that cbl_funtion_t.name isn't filename related and never set at all, so this patch serves as a mere stopgap fix to unbreak the build until a real solution can be figured out. Bootstrapped without regressions on amd64-pc-solaris2.11, sparcv9-sun-solaris2.11, and x86_64-pc-linux-gnu. 2025-04-08 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE> gcc/cobol: PR cobol/119217 * symbols.h (NAME_MAX): Define fallback.
Diffstat (limited to 'libjava/classpath/lib')
0 files changed, 0 insertions, 0 deletions