Re: [Gems-users] Problem with compiling Ruby


Date: Wed, 15 Mar 2006 15:46:01 -0800
From: Gene Kishinevsky <genek@xxxxxxxxxxxx>
Subject: Re: [Gems-users] Problem with compiling Ruby
Here is my section from the Makefile.common file.

*CC_VERSION=3.4.4*

## Define the Simics version that is being used. Currently this is only utilized when compiling Opal, because ## the opal/system/simdist12.C file has mm_* functions whose number of arguments differ in Simics 2.0 and 2.2
#SIMICS_VERSION += -DSIMICS_2_0
*SIMICS_VERSION += -DSIMICS_2_2*

ifeq ($(HOST_TYPE),amd64-linux)
 #CC =  /s/gcc-3.4.4/bin/g++
 *CC =  /usr/bin/g++*
 OPT_FLAGS =  -m64 -march=opteron -fPIC
 LDFLAGS += -ggdb -g3 -Wl,-R/s/gcc-3.4.1/lib64
 MODULE_LDFLAGS += -Wl,-R/s/gcc-3.4.1/lib64

I've highlighted the parts I changed. Notice where the CC_version is specified, and also the Simics Version is set to 2.2. Also had to change the CC path. Even though I didn't change the LDFLAGS to match CC version it compiles fine.

I don't believe I touched the other Makefile in Ruby/module directory, and the compilation went through.

I hope this helps. Otherwise someone more knowledgeable will probably have to help you out.

-Gene

Rohit Nair wrote:
Hi Gene,

Thanks for your quick response. I tried to compile with gcc-3.4.4 as well as
gcc-3.2.3 (which came with the linux distribution). Unfortunately, I run
into the same error.
make[2]: Entering directory `/root/Desktop/GEMS/slicc'
make[2]: *** No rule to make target `iomanip', needed by
`amd64-linux/obj/lexer.d'.  Stop.
make[2]: Leaving directory `/root/Desktop/GEMS/slicc'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/root/Desktop/GEMS/slicc'
make: *** [all] Error 2

Step 7 in the setup procedure states:

7. Edit GEMS Makefiles
    * $GEMS/common/Makefile.common -- set the CC for your chosen compiler
    * $GEMS/ruby/module/Makefile -- set the runtime library path (not
necessary if using native compiler)

The Makefile.common file contains the code segment:

	ifeq ($(HOST_TYPE),amd64-linux)
	  CC =  /usr/local/bin/gcc
	  OPT_FLAGS = -m64 -march=opteron -fPIC
LDFLAGS += -ggdb -g3 -Wl,-R/s/gcc-$(CC_VERSION)/lib64 MODULE_LDFLAGS += -Wl,-R/s/gcc-$(CC_VERSION)/lib64
	else

Do I need to modify the paths for LDFLAGS and MODULE_LDFLAGS since the newly
installed gcc resides elsewhere?
Thanks,
Rohit


-----Original Message-----
Date: Tue, 14 Mar 2006 17:31:36 -0800
From: Gene Kishinevsky <genek@xxxxxxxxxxxx>
Subject: Re: [Gems-users] Problem with compiling Ruby
To: Gems Users <gems-users@xxxxxxxxxxx>
Message-ID: <44176E78.4020904@xxxxxxxxxxxx>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed

Hi Rohit,

I am not sure if this is the problem, but I remember some other posts about
problems with the wrong compiler version. I compiled ruby on an amd64-linux
machine with gcc 3.4.4 and it worked fine. If possible you could try an
older version of gcc. Other people might have better suggestions.

Good luck.

-Gene

Rohit Nair wrote:
Hi,

I am a new GEMS user and I have encountered a problem while compiling
Ruby.
I am using the amd64-linux host with gcc version 4.0.0. I completed the steps in the setup page from the documentation available on Wiki successfully. On running the ruby compilation step on the QuickStart page, this is the error that I get:

[root@machine ruby]# make -f Makefile PROTOCOL=MOSI_SMP_bcast DESTINATION=MOSI_SMP_bcast
ls: generated/MOSI_SMP_bcast/*.C: No such file or directory
Ruby: Building protocol: MOSI_SMP_bcast
Ruby: Making slicc
cd ../slicc; make
make[1]: Entering directory `/root/Desktop/GEMS/slicc'
SLICC: Running flex and bison
make generated/generated
make[2]: Entering directory `/root/Desktop/GEMS/slicc'
make[2]: `generated/generated' is up to date.
make[2]: Leaving directory `/root/Desktop/GEMS/slicc'
SLICC: Building slicc executable
make amd64-linux/bin/slicc.exec
make[2]: Entering directory `/root/Desktop/GEMS/slicc'
make[2]: *** No rule to make target `iomanip', needed by `amd64-linux/obj/lexer.d'. Stop.
make[2]: Leaving directory `/root/Desktop/GEMS/slicc'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/root/Desktop/GEMS/slicc'
make: *** [all] Error 2

Please help me in resolving this issue.

Thanks,
Rohit

_______________________________________________
Gems-users mailing list
Gems-users@xxxxxxxxxxx
https://lists.cs.wisc.edu/mailman/listinfo/gems-users
[← Prev in Thread] Current Thread [Next in Thread→]