Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 190163 - sci-physics/root-5.16.00 fails on sparc, apparently because xrootd/src/xrootd/configure.classic doesn't know about linux/sparc
Summary: sci-physics/root-5.16.00 fails on sparc, apparently because xrootd/src/xrootd...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: Sparc Linux
: High normal (vote)
Assignee: Gentoo Science Physics related packages
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-08-25 12:30 UTC by Ferris McCormick (RETIRED)
Modified: 2007-09-17 14:16 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
Patch to xrootd in root-5.16.00 to allow a clean build on sparc (sparc-root-5.16.00.patch,1.31 KB, patch)
2007-08-28 13:33 UTC, Ferris McCormick (RETIRED)
Details | Diff
patch to root-5.16.00.ebuild to apply the sparc xrootd ebuild patch 129447 (root-5.16.00.ebuild.patch,467 bytes, patch)
2007-08-28 13:37 UTC, Ferris McCormick (RETIRED)
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Ferris McCormick (RETIRED) gentoo-dev 2007-08-25 12:30:30 UTC
First attempt to build root-5.16.00 failed for me on sparc.  Specific message is:

g++: xrootd/src/xrootd/lib/libXrdOuc.a: No such file or directory
g++: xrootd/src/xrootd/lib/libXrdNet.a: No such file or directory
g++: xrootd/src/xrootd/lib/libXrdSys.a: No such file or directory

Initial investigation seems to trace this back to an indication that configure.classic could not identify the architecture, and indeed, configure.classic does not know sparc/linux.  I suspect it needs to configure just as linux, the same way the main configure does.

I'll check later to see if this part of the sparc fix is incorporated:

--- root/xrootd/src/xrootd/configure.classic-   2007-02-09 15:35:58.000000000 +0000
+++ root/xrootd/src/xrootd/configure.classic    2007-02-09 15:37:38.000000000 +0000
@@ -421,6 +421,7 @@
       linux:arm*:*)       arch=arm_linux       ; platform=linux; ccflv=gcc;;
       linux:ppc64:*)      arch=ppc_linux       ; platform=linux; ccflv=gccppc64;;
       linux:ppc*:*)       arch=ppc_linux       ; platform=linux; ccflv=gcc;;
+      linux:sparc*:*)     arch=sparc_linux     ; platform=linux; ccflv=gcc;;
       darwin:power*:7.4*) arch=macosx_74       ; platform=macosx; ccflv=macos;;
       darwin:power*:7*)   arch=ppc_darwin_70   ; platform=macosx; ccflv=macos;;
       darwin:power*:*)    arch=macosx          ; platform=macosx; ccflv=macos;;
(My guess is that it is not, but I'll look more closely later.)
Comment 1 Ferris McCormick (RETIRED) gentoo-dev 2007-08-26 01:09:05 UTC
The problem is almost certainly that none of the xrootd part of the patch in sparc-root-5.14.00c.patch is present.  That is, upstream did fix the first part of that patch (the root/configure patch), but the two patches in xrootd (to xrootd/src/xrootd/configue.classic and to xrootd/src/xrootd/config/ARCHS) are still not there.  If I stop the build and apply them by hand, then the build is successful and root installs.

Now, we can generate a corresponding patch to -5.16.00, but it strikes me as silly to do that, because we are talking a two-line patch here, and upstream has already expressed a willingness to accomodate sparc/linux.  Apparently, they can't test it and did not notice that they left out the patch for xrootd.

Since I don't think anyone with sparc is waiting for -5.16.00 for anything, I'll follow your lead.  If you want a patch guaranteed to apply against -5.16.00, I can make you one (and then the same corresponding ebuild change will be needed for -5.16.00 as for -5.14.00c because we still have to unpack the xrootd .tbz file, apply the patch, and rebuild the tbz file).  If you prefer to push on CERN to apply the complete fix, please go ahead and remove the ~sparc keyword from -5.16.00, because as it is now, it is guaranteed not to build on sparc.

If you just comment on this bug, of course all sparc developers will see how you think is the better way to go.

(Indeed, however, the parallel make problem is fixed.)
Comment 2 Ferris McCormick (RETIRED) gentoo-dev 2007-08-26 01:24:18 UTC
(In reply to comment #1)
>
>  If you
> prefer to push on CERN to apply the complete fix, please go ahead and remove
> the ~sparc keyword from -5.16.00, because as it is now, it is guaranteed not to
> build on sparc.

Um, let's not do that.  Please just comment on the bug and leave the keyword.  We might just package.mask this version until CERN updates the sources.

> 
> If you just comment on this bug, of course all sparc developers will see how
> you think is the better way to go.
> 
> (Indeed, however, the parallel make problem is fixed.)
> 

Comment 3 Sébastien Fabbro (RETIRED) gentoo-dev 2007-08-27 20:35:46 UTC
> >  If you
> > prefer to push on CERN to apply the complete fix, please go ahead and remove
> > the ~sparc keyword from -5.16.00, because as it is now, it is guaranteed not to
> > build on sparc.
> 
> Um, let's not do that.  Please just comment on the bug and leave the keyword. 
> We might just package.mask this version until CERN updates the sources.

Hi,

Thanks for testing.
Masking is a good idea. Is the small patch in the bug Description is all I have to send upstream for sparc to work? If not, could you put it here or send it directly?
Also you might want to test/keyword the cernlib to have a full capable root on sparc. I mask the use flag by default, since it is a pretty heavy library to build.

Sébastien
Comment 4 Ferris McCormick (RETIRED) gentoo-dev 2007-08-27 20:55:41 UTC
The patch is the same, but the line numbers might have changed.  I'll verify tomorrow.  Also, I'll try the cernlib as well.  (Really, it is exactly a two line patch --- just make xrootd aware of linux on sparc.)
Comment 5 Ferris McCormick (RETIRED) gentoo-dev 2007-08-28 13:33:03 UTC
Created attachment 129477 [details, diff]
Patch to xrootd in root-5.16.00 to allow a clean build on sparc

This patch corresponds to files/sparc-root-5.14.00c.patch for previous version of root.  Patch is essentially identical, except that no change is needed to root's main configure file.  I am not sure how to test xrootd, and I have some concerns about the CFLAGS it chooses to build xrootd (i.e., it seems to ignore mine) and whether or not it correctly decides on the endian-ness for sparc.  But at least it does build a version of root which builds and installs on sparc.
Comment 6 Ferris McCormick (RETIRED) gentoo-dev 2007-08-28 13:37:08 UTC
Created attachment 129479 [details, diff]
patch to root-5.16.00.ebuild to apply the sparc xrootd ebuild patch 129447

This patch just illustrates how to change root-5.16.00.ebuild to apply the xrootd patch to allow root-5.16.00 to build on sparc systems.
Comment 7 Ferris McCormick (RETIRED) gentoo-dev 2007-08-28 15:17:06 UTC
(In reply to comment #3)
> > >  If you
> > > prefer to push on CERN to apply the complete fix, please go ahead and remove
> > > the ~sparc keyword from -5.16.00, because as it is now, it is guaranteed not to
> > > build on sparc.
> > 
> > Um, let's not do that.  Please just comment on the bug and leave the keyword. 
> > We might just package.mask this version until CERN updates the sources.
> 
> Hi,
> 
> Thanks for testing.
> Masking is a good idea. Is the small patch in the bug Description is all I have
> to send upstream for sparc to work? If not, could you put it here or send it
> directly?
> Also you might want to test/keyword the cernlib to have a full capable root on
> sparc. I mask the use flag by default, since it is a pretty heavy library to
> build.
> 
> Sébastien
> 

cernlib does build on sparc, and after I unmask USE=cern, root finds cernlib and appears to build with it.  I am not sure how to test it, however.  the tutorial/tree/cernstaff.C test does run, make some nice graphs, and write a cernstaff.root data file.  I do not know if it requires cernlib for this or not however.  (All this assumes the two little attached patches have been incorporated into root-5.16.00 for testing.  And please see Bug 190534 for some concerns about the cernlib build process.)

Comment 8 Sébastien Fabbro (RETIRED) gentoo-dev 2007-08-28 18:50:48 UTC
I've contacted upstream with the small patch. Concerning cernlib, I will take a deeper look for a test.
Thanks.
Comment 9 Sébastien Fabbro (RETIRED) gentoo-dev 2007-09-03 16:11:23 UTC
There is a test suite available. Once installed,
cd /usr/share/doc/root-*/test
make
Then there are a few tests you can try. The tough one seems to be:
./stressHepix
which runs a bunch of othere ones.

Unfortunately the test suite would need more work than just fixing the library paths to include in a src_test routine. I'll take a deeper look soon.

Also these tests don't really make use of the cernlib flag (which create h2root and g2root format translaters).
Comment 10 Sébastien Fabbro (RETIRED) gentoo-dev 2007-09-16 11:50:13 UTC
upstream update might come up in a later version. meanwhile i implemented your patch again. Thanks. (let me know about the cernlib bug as well.)
Comment 11 Ferris McCormick (RETIRED) gentoo-dev 2007-09-17 14:16:11 UTC
Builds just fine on sparc.  Thanks.