This is a summary.
> > Using openssl-0.9.3a, there appears to be a problem with
> > crypto/md5/Makefile.ssl.
> >
> > /opt/local/bin/perl ./Configure solaris-usparc-cc
> > ...
> > making all in crypto/md5...
> > ...
> > cc -E -DULTRASPARC -DMD5_BLOCK_DATA_ORDER asm/md5-sparcv9.S | \
> > ... as -xarch=v8plus /dev/fd/0 -o asm/md5-sparcv8plus.o
> > as: error: cannot open input file "/dev/fd/0"
> I fail to understand why /dev/fd isn't mounted on your system.
The guy has deliberately commented it out from /etc/vfstab.
> >
> > I modified crypto/md5/Makefile.ssl, changing references to /dev/fd/0 to '-'.
> > ...
> > # ( cd crypto/md5 ; cc -E -DULTRASPARC -DMD5_BLOCK_DATA_ORDER asm/md5-sparcv9.S |
> > /usr/ccs/bin/as -xarch=v8plus - )
> > /usr/ccs/bin/as: "<stdin>", line 31: error: statement syntax
> > ...
> > ld [ % i0 + 12 ], % o3
> Another mistery! Your preprocessor erroneously expands e.g. "#define A
> %o0" as "% o0". Note space between % and o0. Now as far as I know Sun C
> compiler invokes /usr/ccs/lib/cpp ...
Closer look revealed that the fact that cc hires /usr/ccs/lib/cpp is
only true if a .S file is passed as command line argument *and* compiler
is 4.2 or later. If you pass a .c file as an argument, then it's
/opt/SUNWspro/SCx.y/bin/acomp that gets invoked instead! acomp in turn
does insert space between % and anything following it unless this
anything is an '=' sign. Now the catch! The guy has SC4.0 and it turned
that SC4.0 *always* calls /opt/SUNWspro/SC4.0/bin/acomp:-( As a result
it's not possible to compile my .S modules with SC4.0. Damn! I'm getting
tired of this mess... I can see two solutions:
- distribute preprocessed (with SC>=4.2 or gcc) .s files along with .S
and simply call as;
- explicitely hire /usr/ccs/lib/cpp instead of cc -E in Makefiles;
I don't like either... I like $(CC) $(CFLAGS) blah-blah -c foo.S:-)
because if everything would be tidy it would simply work. Yes, very same
command with all compilers in different modes (32 vs. 64) on *both*
Solaris and Linux! BTW. Regarding comment in crypto/md5/Makefile.ssl:
> # ... /usr/ccs/bin/as knows opcodes we need
> # that GNU as has never heard of)
This is apparently not true. GNU as is perfectly capable of assembling
UltraSPARC code. The problem is that the gcc compiler driver never
passes relevant flag to it. You see, Solaris-specific gcc config files
don't really consider GNU as as an option and silently assume bundled
/usr/ccs/bin/as. *But* wherever GNU as happens to be present, it gets
invoked anyway and thrown /usr/ccs/bin/as specific option at. It in turn
silently *ignores* (for "compatibility" reasons) the option and chokes
on v9 instructions...
Well, there is a third solution. Namely equip Makefiles with $(CC)
$(CFLAGS) blah-blah -c foo.S rule (or rather ASFLAGS=$(CFLAGS) line)
which would work in most cases and provide exception rules (and/or
explicit instructions how to accomplish it manually) for SC4.0 guys and
those who don't want to remove GNU as.
Andy.
______________________________________________________________________
OpenSSL Project http://www.openssl.org
Development Mailing List [EMAIL PROTECTED]
Automated List Manager [EMAIL PROTECTED]