[Cbe-oss-dev] elfspe/elfspe2 source code (SRPMS)?
Wang, Baojun
wangbj at lzu.edu.cn
Mon Aug 6 19:33:30 EST 2007
On Monday 06 August 2007 16:36, Sebastian Siewior wrote:
> * Wang, Baojun | 2007-08-06 15:40:19 [+0800]:
> >I've installed gentoo 2007.0 (ppc64, 64bit userland) on ps3 successfully,
> > and I'm trying to build the spu toolchain on ps3, the toolchain has been
> > built successfully, which is including:
> >
> >spu-binutils, spu-gcc, spu-gcc-c++, libspe, libspe2, spu-newlib and
> > spu-gdb.
> >
> >spu-gcc can generate executable, the problem is I can't got it (the
> > standalone spu program) run on the gentoo/ps3 box. however, the
> > executable (hello, spu-gcc -o hello hello.c, hello world example.) can
> > run on systemsim (SDK 2.1) and yellowdog Linux (5.04) on ps3. I have
> > follow all instructions from the documentation (althrough not for gentoo)
> > including:
> >
> >1) build all above packages (spu-binutils, spu-gcc, ...) via src.rpm on
> > ps3.
> >
> > rpm -Uvh xxx.src.rpm
> > rpmbuild -ba --nodeps --target=ppc64 /usr/src/rpms/SPECS/xxx.spec
> > rpm -Uvh --nodeps /usr/src/rpms/RPMS/ppc64/xxx.rpm
> >
> >2) install elfspe2-xxx.ppc.rpm, elfspe/elfspe2 package is ONLY BINARY
> >AVALIABLE (which I think cause problem in my example):
> >
> > rpm -Uvh --nodeps elfspe2-xxx.ppc.rpm
>
> Until here I can't really follow. It seems that you compiled everything
> from rpms except the elfspe2 library.
Sorry, I didn't describe clearly. elfspe wasn't provided as a src.rpm, so I
can't build it from source, but it's part of libspe2, it's under a directory
of libspe2, which is fixed already.
> > a) standalone spu program is not working:
> >
> > spu-gcc hello.c -o hello-spu
> >
> > when I ran:
> >
> > ./hello-spu
> >
> > I got the following error message:
> >
> > bash: ./hello: Accessing a corrupted shared library
> >
> > b) mixed spu/ppu program is working:
>
> Did you compile the mixed spu+ppu on your own or did you use the
> precompiled ones? Anyway, which arch is it (ppc32 or ppc64)
I'm using ppc64 userland, ppu toolchain is from the distro (gentoo 2007.0, gcc
is 4.1.2 for ppc64). and I've built all spu stuff as ppc64.
> >Is there any thing wrong in my configuration? Is elfspe/elfspe2 source
> >avaliable ( I can't found it and I've googled many times) so I can build
> > it from source, or is it possible elfspe/elfspe2 source code being
> > avialiable later?
>
> I guess the problem is your 64bit userland. Do a
> ldd /usr/bin/elfspe
>
> It may point to a 32bit libspe2 which you may not run. I *assume* that
> your elfspe binary is 64bit while the libspe2 library is 32bit.
> Yellow dog ships 32bit user land and a few libs in order to run 64bit
> apps (like gdb).
> If you want to continue using 64bit userland you should recompile
> libspe2 which is available on sf [1].
yup, ydl is shipping 32bit libspe and 32bit elfspe, I've compiled libspe and
libspe2 as 64bit, so I can't use elfspe from the distro, I didn't realize
elfspe is from libspe2, so I have the problem until I found it under libspe2
source tree, stupid me :(
> [1]
> http://sourceforge.net/project/showfiles.php?group_id=189201&package_id=221
>530&release_id=503161
The problem now is resolved by (replace the broken /usr/bin/elfspe):
cd /usr/src/rpm/BUILD/libspe2-2.1.0/elfspe
make
cp -pv elfspe /usr/bin/elfspe
/etc/init.d/elfspe restart
Any way, thanks very much!
> >Thanks in advance!
> >
> > Regards,
> >
> >Wang
>
> Sebastian
Regards,
Wang
--
Wang, Baojun Lanzhou University
Distributed & Embedded System Lab http://dslab.lzu.edu.cn
School of Information Science and Engeneering wangbj at lzu.edu.cn
Tianshui South Road 222. Lanzhou 730000 .P.R.China
Tel:+86-931-8912025 Fax:+86-931-8912022
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://lists.ozlabs.org/pipermail/cbe-oss-dev/attachments/20070806/ffe25e3b/attachment.pgp>
More information about the cbe-oss-dev
mailing list