[Date Index][Thread Index]
[Date Prev][Date Next][Thread Prev][Thread Next]

[BUG REPORT] WML 1.7.2, sparc-sun-solaris2.6



BUG REPORT

Package: WML 1.7.2
Operating System: sparc-sun-solaris2.6

Problem Description:
| When attempting to install WML on Solaris with gcc as
| the only working C compiler installed, the make fails
| with:
| 
| ===> wml_backend/p9_slice
| V=`./etc/newvers -l perl -D slice_vers.pl`; \
| sed -e "s|\@SLICE_VERSION\@|$V|" <slice.pod >/tmp/slice; \
| (cd /tmp; pod2man --section=1 \
|         --center="Ralf S. Engelschall" \
|                 --release="EN Tools" \
|                 slice ) >slice.1; rm -f /tmp/slice
| ./etc/newvers: /tmp/getopt: not found
| *** Error code 2
| make: Fatal error: Command failed for target `slice.1'
| 
| There turns out to be 2 issues with the various
| "newvers" scripts:
| 
| 1) "newvers" method of testing for the existence of
| getopt(1) is not portable:
| 
|    eval "$getopt" >/dev/null 2>&1
| 
| Under Solaris (and probably other System V Unixes,
| and AIX) getopt(1) fails if it is not given any
| arguments.
| I checked the BSD and Solaris man pages and don't see
| a defined behavior for getopt with no arguments.
| BSD getopt(1) prints just "--" and exits with success,
| while Solaris getopt(1) prints:
| 
|    usage: getopt legal-args $*
| 
| and exits with an error status.
| I worked around this issue by changing the "newvers"
| scripts to do this instead:
| 
|    eval "$getopt ''" >/dev/null 2>&1
| 
| My thought is that this is more likely to elicit
| defined behavior since getopt(1) actually has an
| argument which it can pass to getopt(3).
| 
| Another option would be to test for the
| getopt command with autoconf, and AC_OUTPUT the
| "newvers" script(s).
| 
| 2) The "newvers" script in "wml_backend/p9_slice/etc"
|    (probably an older revision?) doesn't detect the
|    system-provided getopt(1) because of the issue
|    above but then proceeds to attempt to compile its
|    own using "cc" (which is hard-coded) rather than the
|    compiler discovered by configure.  This, of course,
|    fails on machines with gcc, but no working cc
|    installed.  (This must be a known issue because
|    some of the other "newvers" scripts suppled with
|    WML do check for gcc.)
| 
| Thanks,
| Dave

______________________________________________________________________
Website META Language (WML)                www.engelschall.com/sw/wml/
Official Support Mailing List                   sw-wml@engelschall.com
Automated List Manager                       majordomo@engelschall.com