pkgsrc-Users archive

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

Ruby builds - Sun assembler intolerant of spaces


I've been bashing away at this for a few days... and have got to the
bottom of this issue, so thought I would share it.

Regardless of which Ruby I try to build, I always run into an error at
this phase:

cc -I. -I../../../.ext/include/sparc-solaris2.9 -I../../.././include
-I../../.././ext/-test-/bug-3662 -DRUBY_EXTCONF_H=\"extconf.h\"
-D_REENTRANT -I/usr/include -I/opt/omnibus/bootstrap/include/db4
-I/opt/omnibus/bootstrap/include -D_FILE_OFFSET_BITS=64  -fPIC -O
-D_REENTRANT -I/usr/include -I/opt/omnibus/bootstrap/include/db4
-I/opt/omnibus/bootstrap/include -fPIC -obug.o -c bug.c
/usr/ccs/bin/as: error: no input filename given
usage: /usr/ccs/bin/as [-V] [-Q{y,n}] [-f[O][if]#] [-q] [-s]
          [-S] [-K {pic,PIC}] [-o objfile] [-L] [-T]
          [-P [[-Ipath] [-Dname] [-Dname=def] [-Uname]]...]
          [-m [-Ym,path]] [-n] [-ul] [-xF] [-xarch=v7] [-xarch=v8]
[-xarch=v8a] [-xarch=v8plus] [-xarch=v8plusa] [-xarch=v8plusb]
[-xarch=v9] [-xarch=v9a] [-xarch=v9b]  [-xcode={pic13,pic32}]
*** Error code 1
If you look very closely at the compile line, you'll notice that we're
building an external module.  Makefiles for external modules are
automatically generated.  In this case, the compile line specifies
the objfile *without a space*:


If you edit the makefile, and locate the OUTFLAG and COUTFLAG macros,
and append $(empty), and rebuild, you'll find you get to the next

The Makefile generation code is in lib/mkmf.rb.  If you find the
COMPILE_C and COMPILE_CXX constants, you'll see that they explicitly
do not add a space between $(COUTFLAG) and $@.

I added a space in there, and Ruby built.

Many thanks to Mandy Waite, whose  blog gave me the lead on this issue.

Again - I share this in case anyone else gets stuck on this, but once
more, my question is - what's the actual fix.  Is this something that
shold be raised with upstream?  Is it something which should have a
pkgsrc patch?



Home | Main Index | Thread Index | Old Index