Dr. David Kirkby wrote: > Jaap Spies wrote: >> Hi, >> >> First I installed Solaris 5.11 from an oldish CD Solaris Express Developer >> Edition. >> This looked ok, but is useless because there is no support as this is >> superseded >> by Open Solaris. >> >> Next I downloaded Open Solaris 2009/06 x86. Works like a charm. Building >> sage failed. >> >> Downloaded Solaris 10, installed in VirtualBox, could run it, but ... >> >> Reminded me at the old days: at some time 1986-1989 I was a heayvy SUN user. >> Founded the SUG-NL (Sun User Group The Netherlands) early 1987. >> >> On Solaris 10 I can only login as root. I forgot a lot about how to sysadmin >> a SunOs :( >> >> Lookin now at http://wiki.sagemath.org/solaris >> >> What can I do? Dave? >> >> Jaap > > Hi Jaap, > > it's really pleased me to someone have a go at Sage on Open Solaris. > Sometimes I > feel I'm the only one working on the Solaris build. > > As stated at > > http://wiki.sagemath.org/solaris > > Open Solaris does not build. There are several issues I am aware. I'd suggest > the following approach might be worth taking, but there may be better ones. > You > need to get at least the following > > * A recent gcc > * GNU make > * GNU binutils > * OpenSSL libraries. > > You can do this from the source code, using the the included gcc 4.3.2, or > download them via the Package manager (on the System -> Administration) after > adding a repository. > > http://pkg.opensolaris.org/dev/ > > Use that one, as while not as stable, it has more packages than the default > opensolaris.org repository. > > That will allow you to download GNU make. > > As far as I know, Open Solaris has no recent gcc unless you use some. Check > gcc > --version, but if it is 3.4.3, which I expect it will be, then it is not going > to build Sage. > > You could download gcc 4.3.2 using the Package Manager, or you could build it > from source. Note I believe it might install with the version number appended > to > the names (gcc+4.3.2 etc) if you use the Package Manager. In which case you > will > have to rename them, as many packages in Solaris ignore CC and CXX, so there > is > little point setting them. > Hi Dave,
I tried to build gcc-4.4.2 from source, but failed. Got gcc-4.3.2 from the repo. Put gcc and friends in a directory $HOME/bin, changed my .bashrc so my path is /usr/ccs/bin:/export/home/jaap/bin:/usr/gnu/bin:/usr/bin:/usr/X11/bin:/usr/sbin:/sbin and put make out of the way. > Personally I buit gcc from source. > > bash-3.2$ /usr/local/gcc-4.3.4/bin/gcc -v > Reading specs from > /usr/local/gcc-4.3.4/bin/../lib/gcc/i386-pc-solaris2.11/4.3.4/specs > Target: i386-pc-solaris2.11 > Configured with: ../gcc-4.3.4/configure --prefix=/usr/local/gcc-4.3.4/ > --with-as=/usr/local/binutils-2.20/bin/as --with-ld=/usr/ccs/bin/ld > --without-gnu-ld --enable-languages=c,c++,fortran > Thread model: posix > gcc version 4.3.4 (GCC) > I 'll try again some time with new gcc. > 5) Build OpenSSL - the defaults seem to work well, and produce a 64-bit > binary. > It installs in /usr/local/ssl, which is fine, as python, which needs the > library, looks in. > > Again, you can use the package manager to install that for you. > Built openssl-0.9.8l from source. Seems to work. > 6) Although I've not tried it, I would be tempted to export SAGE64 to 'yes' > and > go directly for a 64-bit build. > > 7) Type make. You will probably hit this bug. > > http://trac.sagemath.org/sage_trac/ticket/7387 > My build stopped at libcrypt: ld: fatal: file /export/home/jaap/Downloads/sage-4.3/local/lib/libgpg-error.so: wrong ELF class: ELFCLASS32 ld: fatal: file processing errors. No output written to .libs/libgcrypt.so.11.5.2 Reinstalling with ./sage -f -m libgpg_error-1.6.p2, ./sage -sh cd spkg/build/libgpg-1.6.p2 changint the spkg-install: CFLAGS="$CFLAGS -fPIC -g -I$SAGE_LOCAL/include" if [ `uname` = "Darwin" -a "$SAGE64" = "yes" ]; then CFLAGS="-m64 -fPIC -g -I$SAGE_LOCAL/include" LDFLAGS="-m64"; export LDFLAGS fi if [ `uname` = "SunOS" -a "$SAGE64" = "yes" ]; then CFLAGS="-m64 -fPIC -g -I$SAGE_LOCAL/include" LDFLAGS="-m64"; export LDFLAGS fi export CFLAGS and run ./spkg-install exit, run make again (no touch spkg/installed/libgpg_error-1.6.p2 needed, because it was already installed) libcrypt builds now in 64 bit mode. But next ld: fatal: file /export/home/jaap/Downloads/sage-4.3/local/lib/libgcrypt.so: wrong ELF class: ELFCLASS64 ld: fatal: file processing errors. No output written to .libs/libopencdk.so.10.0.6 The story gets long ... Same trick as above, this time don't forget to do a touch spg/installed/opencdk-0.6.6.p2 or you will have to do it over again. libpng -s also built in 32 bit This brings me to ticket 7387 ld: fatal: file /export/home/jaap/Downloads/sage-4.3/local/lib/libgcrypt.so: wrong ELF class: ELFCLASS64 ld: fatal: file processing errors. No output written to .libs/libgnutls.so.26.1.2 adding if [ `uname` = "SunOS" -a "$SAGE64" = "yes" ]; then echo "64 bit SunOS" CFLAGS="-O2 -g -m64 "; export CFLAGS CXXFLAGS="-O2 -g -m64 "; export CXXFLAGS fi to the spkg-install did the trick I'll comment on the ticket. > There is a hack listed to get rid of that. > Eventually I have to change a lot os spkg-install files! libz, termcap, readline and I'm certainly not finished :(! > 8) Hopefully you wont hit bug > > http://trac.sagemath.org/sage_trac/ticket/7761 > > as you would have installed OpenSSL libraries. > Building python failed with the same message as on the ticket! After running python manually: sage subshell$ python Python 2.6.2 (r262:71600, Dec 31 2009, 19:17:59) [GCC 4.3.2] on sunos5 Type "help", "copyright", "credits" or "license" for more information. >>> 1+1 2 >>> I declared it ok for the moment, so touch spkg/installed/python-2.6.2.p4 > At that point, you will be up with me really. I've not got much further than > that. I posted a list the other day of packages which do and do not build. I > used > I got stuck at mpir: checking whether to enable maintainer-specific portions of Makefiles... no configure: error: ABI=64 is not among the following valid choices: 32 Failed to configure. I'll look int that later. > $ make -k > > to skip over errors. > > One problem is that SAGE64 is not handled properly in many pacakges, so if you > go for a 64-bit build, you hit that problem. If you use a 32-bit build, I > can't > get a stable python, as the OpenSSL will not pass their self-tests if you try > to > force a 64-bit build of them. > > Hopefully that gives you some ideas, but it seems quite a way from actually > building. > Thanks, Jaap > If I can get > > http://trac.sagemath.org/sage_trac/ticket/7505 > > reviewed, then make some changes to sage-env, it should be possible to get rid > of all this SAGE64 stuff in each spkg-install. That will make the process > somewhat easier. But it looks like it might be a struggle. Even HP-UX looks > easier! > > Dave > -- To post to this group, send an email to sage-devel@googlegroups.com To unsubscribe from this group, send an email to sage-devel+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-devel URL: http://www.sagemath.org