RE: Cross-compiling on Fedora 12

From: Philippe Canal <pcanal_at_fnal.gov>
Date: Mon, 1 Mar 2010 14:15:28 -0600


Hi,

rootcint still only generate the dictionary (it only call g++ when the option -p is passed ... and then __only__ has a pre-processor).

So my guess is that core/utils/src/rootcint_tmp is built/linked incorrectly and can not start.

Cheers,
Philippe.

-----Original Message-----
From: owner-roottalk_at_root.cern.ch [mailto:owner-roottalk_at_root.cern.ch] On Behalf Of Konstantin Olchanski
Sent: Monday, March 01, 2010 2:12 PM
To: Vassili Maroussov
Cc: roottalk_at_lxbuild091.cern.ch
Subject: Re: [ROOT] Cross-compiling on Fedora 12

On Sat, Feb 27, 2010 at 01:03:27PM +0100, Vassili Maroussov wrote:
> Generating dictionary core/meta/src/G__TCint.cxx...
> core/utils/src/rootcint_tmp -cint -f core/meta/src/G__TCint.cxx -c
> -DG__API core/meta/inc/TCint.h core/meta/inc/LinkDef_TCint.h
> /usr/bin/ld: i386:x86-64 architecture of input file
> `/usr/lib/gcc/x86_64-redhat-linux/3.4.6/libfrtbegin.a(frtbegin.o)' is
> incompatible with i386 output
> /usr/bin/ld: final link failed: Invalid operation
> collect2: ld returned 1 exit status
> make: *** [bin/g2root] Error 1

Looks like "rootcint" is calling GCC without the "-m32" flag and "/usr/bin/ld"
tries to link against the 64-bit runtime library (libfrtbegin.a).

To be extra user friendly, it (rootcint or Makefile) hides the actual GCC command line,
so it is hard to tell what it going on there.

But perhaps I am confused - it looks as if "rootcint" generates the dictionary source
file and immediately call GCC to compile it. That used to be 2 different steps
in the Makefile and it was easy to add "-m32" to the right place to fix it.

If rootcint invokes GCC directly, it should accept the "-m32/-m64" switch and pass
it to GCC as we cannot read the user mind to tell how they want things to be compiled.

-- 
Konstantin Olchanski
Data Acquisition Systems: The Bytes Must Flow!
Email: olchansk-at-triumf-dot-ca
Snail mail: 4004 Wesbrook Mall, TRIUMF, Vancouver, B.C., V6T 2A3, Canada
Received on Mon Mar 01 2010 - 21:16:08 CET

This archive was generated by hypermail 2.2.0 : Tue Mar 02 2010 - 11:50:01 CET