Various failures to install sage-3.4.2.spkg

3 views
Skip to first unread message

Kevin Horton

unread,
May 19, 2009, 10:28:29 AM5/19/09
to spd...@googlegroups.com
I have spd running, but there are some portions of sage that I
desire. So, I attempted to install the sage-3.4.2.spkg. This failed
with:

sage-3.4.2/README.txt
sage-3.4.2/clib.py
Finished extraction
****************************************************
Host system
uname -a:
Linux asus-1034110973 2.6.21.4-eeepc #6 Mon May 5 11:38:34 EDT 2008
i686 GNU/Linux
****************************************************
****************************************************
GCC Version
gcc -v
Using built-in specs.
Target: i486-linux-gnu
Configured with: ../src/configure -v --enable-languages=c,c+
+,fortran,objc,obj-c++,treelang --prefix=/usr --enable-shared --with-
system-zlib --libexecdir=/usr/lib --without-included-gettext --enable-
threads=posix --enable-nls --program-suffix=-4.1 --enable-__cxa_atexit
--enable-clocale=gnu --enable-libstdcxx-debug --enable-mpfr --with-
tune=i686 --enable-checking=release i486-linux-gnu
Thread model: posix
gcc version 4.1.2 20061115 (prerelease) (Debian 4.1.1-21)
****************************************************
mv: cannot stat `/home/user/apps/spd-3.4.2spd2/devel/sage-main': No
such file or directory
./spkg-install: line 44: scons: command not found
./spkg-install: line 120: sage: command not found
ERROR installing SAGE

real 0m1.984s
user 0m0.250s
sys 0m1.520s
sage: An error occurred while installing sage-3.4.2
Please email sage-devel http://groups.google.com/group/sage-devel
explaining the problem and send the relevant part of

=
=
=
=
========================================================================
Despite the error message stating that devel/sage-main does not exist,
there is in fact such a directory:

% cd devel/sage-main
% pwd
/home/user/apps/spd-3.4.2spd2/devel/sage-main

=
=
=
=
========================================================================
Seeing that the missing directory was actually there, I tried again.
This attempt got further, but failed with:

./spkg-install: line 44: scons: command not found
Traceback (most recent call last):
File "/usr/local/bin/hg", line 11, in ?
from mercurial import demandimport; demandimport.enable()
ImportError: No module named mercurial
Traceback (most recent call last):
File "/usr/local/bin/hg", line 11, in ?
from mercurial import demandimport; demandimport.enable()
ImportError: No module named mercurial
Traceback (most recent call last):
File "/usr/local/bin/hg", line 11, in ?
from mercurial import demandimport; demandimport.enable()
ImportError: No module named mercurial
Traceback (most recent call last):
File "/usr/local/bin/hg", line 11, in ?
from mercurial import demandimport; demandimport.enable()
ImportError: No module named mercurial
Deleting the scons target.
./spkg-install: line 98: scons: command not found
./spkg-install: line 99: scons: command not found
./spkg-install: line 102: /home/user/apps/spd-3.4.2spd2/sage: No such
file or directory
Error building new version of SAGE.
You might try typing 'sage -ba' or write to sage-support with as much
information as possible.
=
=
=
=
========================================================================

I note that unlike the python with sage, the python with spd does not
include the mercurial module.

% spd -python
Python 2.5.2 (r252:60911, May 18 2009, 15:14:00)
[GCC 4.1.2 20061115 (prerelease) (Debian 4.1.1-21)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import mercurial
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ImportError: No module named mercurial
>>>

I also note that the sage-python at spd-3.4.2spd2/local/bin does not
in fact launch, as the sage-python script attempts to call sage, which
is not installed. The whole suite of sage-* scripts need to be
reworked to call spd, rather than sage. I'll raise a ticket on this.

--
Kevin Horton
Ottawa, Canada

Ondrej Certik

unread,
May 19, 2009, 1:45:05 PM5/19/09
to spd...@googlegroups.com
On Tue, May 19, 2009 at 7:28 AM, Kevin Horton <khor...@rogers.com> wrote:
>
> I have spd running, but there are some portions of sage that I

Just curious -- what exactly?

> desire.  So, I attempted to install the sage-3.4.2.spkg.  This failed
> with:
>
> sage-3.4.2/README.txt
> sage-3.4.2/clib.py

[...]


It's because you are missing the dependencies for sage. You should be
able to install Sage without any problems, however, you need to
install all (or almost all) the packages that are in Sage. So if this
is what you need, you can download the whole Sage tarball and do
"make" and that's it.

I need SPD because I want to add new packages to it and I don't really
need Sage and still I want it to compile quick and be as small as
possible.

========================================================================
>
> I note that unlike the python with sage, the python with spd does not
> include the mercurial module.
>
> % spd -python
> Python 2.5.2 (r252:60911, May 18 2009, 15:14:00)
> [GCC 4.1.2 20061115 (prerelease) (Debian 4.1.1-21)] on linux2
> Type "help", "copyright", "credits" or "license" for more information.
>  >>> import mercurial
> Traceback (most recent call last):
>   File "<stdin>", line 1, in <module>
> ImportError: No module named mercurial
>  >>>
>
> I also note that the sage-python at spd-3.4.2spd2/local/bin does not
> in fact launch, as the sage-python script attempts to call sage, which

Note that "spd -python" (after fixing it) will be exactly equivalent
to just calling "spd" (after fixing the bug below). That's because
"spd" doesn't use preparsing, so it's just python.

> is not installed.  The whole suite of sage-* scripts need to be
> reworked to call spd, rather than sage.  I'll raise a ticket on this.

Excellent, thanks! Indeed, I'll fix it in the next release, this has
to be fixed:

$ ./spd a.py
/home/ondrej/ext/spd-3.4.2spd2-ubuntu-64bit/local/bin/sage-python:
line 2: sage: command not found


Ondrej

Kevin Horton

unread,
May 19, 2009, 2:07:10 PM5/19/09
to spd...@googlegroups.com
On 19 May 2009, at 13:45, Ondrej Certik wrote:

>
> On Tue, May 19, 2009 at 7:28 AM, Kevin Horton <khor...@rogers.com>
> wrote:
>>
>> I have spd running, but there are some portions of sage that I
>
> Just curious -- what exactly?

I want the find_fit function, for example. It is a very nice wrapper
to some stuff in scipy. I guess I could pull it out into a python
module, and import that. But, I also like some aspects of the sage
preparser, e.g. replacing '^' with '**' (I cannot understand why
python uses ** for powers, when everyone else uses ^).


>
>
>> desire. So, I attempted to install the sage-3.4.2.spkg. This failed
>> with:
>>
>> sage-3.4.2/README.txt
>> sage-3.4.2/clib.py
> [...]
>
>
> It's because you are missing the dependencies for sage. You should be
> able to install Sage without any problems, however, you need to
> install all (or almost all) the packages that are in Sage. So if this
> is what you need, you can download the whole Sage tarball and do
> "make" and that's it.
>
> I need SPD because I want to add new packages to it and I don't really
> need Sage and still I want it to compile quick and be as small as
> possible.

I am slowly coming to the conclusion that SPD, as it sits now, may not
be the right solution for me. For me, the perceived advantage was to
save perhaps 1GB disk space. The disadvantage is that I will lose
some of the stuff I like with sage, and I will be dealing with quite a
few rough edges. I would rather delete some stuff from my hard drive
than fight with the rough edges when I am trying to get some work done.

For me, the ideal situation would look like this:

A user can install SPD, and the sage.spkg. The sage package would
install, without needing any other large dependencies. Obviously many
sage functions would not work, as they require uninstalled packages.
But, if a user knew that he needed a subset of sage functions, he
could install just the packages that those functions depended on.

One big question is how the user could easily determine which packages
he needed to install to activate particular sage functions. Would it
be possible to create a software tool that inspected a complete sage
installation, and created a database of dependencies for each sage
function? If so, users could use the info in that database to help
them decide which packages to install. And, if they later attempted
to use a sage function that failed because it lacked a dependency, spd
could catch the exception, look up the dependency info in the
database, and tell the user "function adcd is not available. If you
wish to use this function, you must first install the following sage
packages: package1, package2, etc. Should I install those packages
now? [Y/n]".

I will keep playing with SPD, and reporting any glitches I see, as I
am interested in the long term success of this project. But I will
also bit the bullet on disk space, and install sage to do my work.

--
Kevin Horton
6730 Parkway Road
Greely, ON K4P 1E3
Canada

613-821-7862 (H)
613-952-4319 (W)

mabshoff

unread,
May 19, 2009, 2:21:36 PM5/19/09
to spd-dev


On May 19, 11:07 am, Kevin Horton <khorto...@rogers.com> wrote:
> On 19 May 2009, at 13:45, Ondrej Certik wrote:

<SNIP>

> One big question is how the user could easily determine which packages  
> he needed to install to activate particular sage functions.

You cannot. It can be hacked around if you know what you do, but for
someone not deeply familiar with the import structure of Sage
(assuming you can get it to build with reduced dependencies) it is
impossible. The main hurdle is to get it to build. If you lack the
space to install Sage don't use it.

Cheers,

Michael

Brian Granger

unread,
May 19, 2009, 3:06:04 PM5/19/09
to spd...@googlegroups.com
> I have spd running, but there are some portions of sage that I
> desire.

I think that once you are into this land, you should just install
Sage. Otherwise you are making things much more difficult than they
need to be.

Cheers,

Brian
Reply all
Reply to author
Forward
0 new messages