Sage 3.3.rc0 binary for MacIntel OSX 10.5

2 views
Skip to first unread message

mabshoff

unread,
Feb 12, 2009, 11:44:44 AM2/12/09
to sage-devel
Hi,

since someone asked in IRC I build a 3.3.rc0 on a MacIntel running OSX
10.5. It can be found at

http://sage.math.washington.edu/home/mabshoff/release-cycles-3.3/sage-3.3.rc0-OSX10.5-i386-Darwin.dmg
[311 MB]

Note that this build has the spiffy new app bundle, so you can play
with that now before the official 3.3 is released :)

Note that there is a known bug: If you rename the app to have spaces
in it Sage won't start. I have a fix, so that should be fixed in the
final 3.3.

Cheers,

Michael

mark mcclure

unread,
Feb 12, 2009, 7:55:44 PM2/12/09
to sage-devel
On Feb 12, 11:44 am, mabshoff <mabsh...@googlemail.com> wrote:
> Hi,
>
> since someone asked in IRC I build a 3.3.rc0 on a MacIntel running OSX
> 10.5. It can be found at
> http://sage.math.washington.edu/home/mabshoff/release-cycles-3.3/sage...
> [311 MB]

Didn't quite work for me. When trying diff(x^2,x), I get:
------------------------------------------------------
Traceback (click to the left for traceback)
...
RuntimeError: Unable to start maxima

Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/Users/mcmcclure/.sage/sage_notebook/worksheets/admin/0/code/
2.py", line 7, in <module>
diff(x**_sage_const_2 ,x)
File "/Applications/Sage.app/Contents/Resources/sage/local/lib/
python2.5/site-packages/SQLAlchemy-0.4.6-py2.5.egg/", line 1, in
<module>

File "/Users/mabshoff/sage-3.3.rc0/local/lib/python2.5/site-packages/
sage/calculus/functional.py", line 129, in derivative
File "/Users/mabshoff/sage-3.3.rc0/local/lib/python2.5/site-packages/
sage/calculus/calculus.py", line 2141, in derivative
File "/Users/mabshoff/sage-3.3.rc0/local/lib/python2.5/site-packages/
sage/calculus/calculus.py", line 4693, in variables
File "/Users/mabshoff/sage-3.3.rc0/local/lib/python2.5/site-packages/
sage/calculus/calculus.py", line 3492, in simplify
File "/Users/mabshoff/sage-3.3.rc0/local/lib/python2.5/site-packages/
sage/calculus/calculus.py", line 9214, in
evaled_symbolic_expression_from_maxima_string
File "/Users/mabshoff/sage-3.3.rc0/local/lib/python2.5/site-packages/
sage/interfaces/expect.py", line 931, in eval
File "/Users/mabshoff/sage-3.3.rc0/local/lib/python2.5/site-packages/
sage/interfaces/maxima.py", line 605, in _eval_line
File "/Users/mabshoff/sage-3.3.rc0/local/lib/python2.5/site-packages/
sage/interfaces/maxima.py", line 472, in _sendline
File "/Users/mabshoff/sage-3.3.rc0/local/lib/python2.5/site-packages/
sage/interfaces/expect.py", line 828, in _sendstr
File "/Users/mabshoff/sage-3.3.rc0/local/lib/python2.5/site-packages/
sage/interfaces/maxima.py", line 450, in _start
File "/Users/mabshoff/sage-3.3.rc0/local/lib/python2.5/site-packages/
sage/interfaces/expect.py", line 464, in _start
RuntimeError: Unable to start maxima
--------------------------------------------------

Perhaps, something is hardcoded that shouldn't be?

Mark McClure

mabshoff

unread,
Feb 12, 2009, 8:08:02 PM2/12/09
to sage-devel


On Feb 12, 4:55 pm, mark mcclure <mcmcc...@unca.edu> wrote:
> On Feb 12, 11:44 am, mabshoff <mabsh...@googlemail.com> wrote:
>
> > Hi,

Hi,

> > since someone asked in IRC I build a 3.3.rc0 on a MacIntel running OSX
> > 10.5. It can be found at
> >http://sage.math.washington.edu/home/mabshoff/release-cycles-3.3/sage...
> > [311 MB]
>
> Didn't quite work for me.  When trying diff(x^2,x), I get:
> ------------------------------------------------------
> Traceback (click to the left for traceback)

<SNIP>

> RuntimeError: Unable to start maxima
> --------------------------------------------------
>
> Perhaps, something is hardcoded that shouldn't be?

I have seen that odd behavior by binaries build on that machines
before (William's bsd box), but I don't have any other OSX 10.5 box
with fast upload speed. I do think William does build 10.5 binaries on
that box, so it might be something odd about my users account that
causes this. If he doesn't it must be something else odd on that box.

Let me download the dmg to my local 10.5 MacIntel box and see if I can
reproduce this. For now you can force a rebuild of the Maxima.spkg to
fix this. Note that since this is a binary you will need to delete the
placeholder file and Sage should just download the maxima.spkg again
and build it.

Maybe it is something completely orthogonal related to the app bundle,
but I will poke around once I have the dmg locally.

> Mark McClure

Cheers,

Michael

Nick Alexander

unread,
Feb 12, 2009, 9:34:36 PM2/12/09
to sage-...@googlegroups.com

On 12-Feb-09, at 5:08 PM, mabshoff wrote:

>
>
>
> On Feb 12, 4:55 pm, mark mcclure <mcmcc...@unca.edu> wrote:
>> On Feb 12, 11:44 am, mabshoff <mabsh...@googlemail.com> wrote:
>>
>>> Hi,
>
> Hi,
>
>>> since someone asked in IRC I build a 3.3.rc0 on a MacIntel running
>>> OSX
>>> 10.5. It can be found at
>>> http://sage.math.washington.edu/home/mabshoff/release-cycles-3.3/sage
>>> ...
>>> [311 MB]
>>
>> Didn't quite work for me. When trying diff(x^2,x), I get:

I copied the internal sage folder to my home directory, renamed,
modified SAGE_ROOT, and this works for me.

Nick

mabshoff

unread,
Feb 12, 2009, 9:39:53 PM2/12/09
to sage-devel


On Feb 12, 6:34 pm, Nick Alexander <ncalexan...@gmail.com> wrote:
> On 12-Feb-09, at 5:08 PM, mabshoff wrote:

<SNIP>

> >> Didn't quite work for me.  When trying diff(x^2,x), I get:
>
> I copied the internal sage folder to my home directory, renamed,  
> modified SAGE_ROOT, and this works for me.

Ok, that gives me a good idea what is wrong and a likely lead how to
fix this. When I looked at the patch it seems to set SAGE_ROOT
dynamically, so I am not yet 100% sure what goes wrong.

My download from sage.math is *dog slow*, i.e. 40kb/s, so ironically I
could have build Sage faster locally than download it. Obviously this
isn't going to help me fix this problem, so stay tuned. I am glad that
if this really a bug in the app bundle that we caught it before
building OSX binaries and having to look for brown paper bags to hide
under in shame after screwing up the release :)

> Nick

Cheers,

Michael

mabshoff

unread,
Feb 13, 2009, 5:34:29 AM2/13/09
to sage-devel
Ok, I figured it out. After downloading the dmg I dragged it to my
desktop and double clicked on it to start. It came up, but Maxima/
clisp did not start.

So, after quitting I run that sage on the command line and low and
behold the rebase script ran:

Sprocketer:sage michaelabshoff$ ./sage
----------------------------------------------------------------------
| Sage Version 3.3.rc0, Release Date: 2009-02-11 |
| Type notebook() for the GUI, and license() for information. |
----------------------------------------------------------------------
The SAGE install tree may have moved.
Regenerating Python.pyo and .pyc files that hardcode the install PATH
(please wait at
most a few minutes)...
Do not interrupt this.

Afterwards Maxima and clisp work:

sage: !maxima
Maxima 5.16.3 http://maxima.sourceforge.net
Using Lisp CLISP 2.46 (2008-07-02)
Distributed under the GNU Public License. See the file COPYING.
Dedicated to the memory of William Schelter.
The function bug_report() provides bug reporting information.
(%i1) 2+2;
(%o1) 4
(%i2)
sage: !clisp
i i i i i i i ooooo o ooooooo ooooo ooooo
I I I I I I I 8 8 8 8 8 o 8 8
I \ `+' / I 8 8 8 8 8 8
\ `-+-' / 8 8 8 ooooo 8oooo
`-__|__-' 8 8 8 8 8
| 8 o 8 8 o 8 8
------+------ ooooo 8oooooo ooo8ooo ooooo 8

Welcome to GNU CLISP 2.46 (2008-07-02) <http://clisp.cons.org/>

Copyright (c) Bruno Haible, Michael Stoll 1992, 1993
Copyright (c) Bruno Haible, Marcus Daniels 1994-1997
Copyright (c) Bruno Haible, Pierpaolo Bernardi, Sam Steingold 1998
Copyright (c) Bruno Haible, Sam Steingold 1999-2000
Copyright (c) Sam Steingold, Bruno Haible 2001-2008

Type :h and hit Enter for context help.

[1]>
Bye.
sage:
Exiting SAGE (CPU time 0m0.12s, Wall time 0m21.46s).
Sprocketer:sage michaelabshoff$


This is now a critical ticket for 3.3 at #5254. Should we default to
creating app bundles for OSX [which I assume we want :)] this must be
fixed. I plan to change a couple things and fix a few bugs I noticed
in the App bundle anyway.

So if you want the App bundle to work well on OSX please download the
above and after manually starting the sage script once in
$SAGE_APP_ROOT/Contents/Resources/sage give it a spin and try to break
it.

The four issues besides this one above I tend to fix are:

* default the name to Sage-x.y.z.app - that way you can have many
Sage releases in parallel :)
* fix a bug that causes the app to fail to start if the name of the
app contains spaces
* remove the extra copyright work in credits as well as give credit
to "William Stein and the Sage Development Team"
* do not put the app skeleton in a tar.gz in the ext repo since it
makes applying patches very expensive and opaque

Mark: Thanks again for pointing out this bug. We would have had a log
of egg on our face should this have slipped through :)

Cheers,

Michael

mark mcclure

unread,
Feb 13, 2009, 12:53:12 PM2/13/09
to sage-devel
On Feb 13, 5:34 am, mabshoff <mabsh...@googlemail.com> wrote:
> Ok, I figured it out. After downloading the dmg I dragged it to my
> desktop and double clicked on it to start. It came up, but Maxima/
> clisp did not start.
>
> So, after quitting I run that sage on the command line and low and
> behold the rebase script ran:

Thanks for the info. Unfortunately, Maxima still doesn't work for me.
I included the error messages below. Also, I built sage from source,
assuming that would work. I get virtually identical error messages
with only the directory names changed.

> Mark: Thanks again for pointing out this bug. We would have had a log
> of egg on our face should this have slipped through :)

Good, glad I helped!


-------- Bad sage session -----------
mcmcclure$ /Applications/Sage.app/Contents/Resources/sage/sage
----------------------------------------------------------------------
| Sage Version 3.3.rc0, Release Date: 2009-02-11 |
| Type notebook() for the GUI, and license() for information. |
----------------------------------------------------------------------
The SAGE install tree may have moved.
Regenerating Python.pyo and .pyc files that hardcode the install PATH
(please wait at
most a few minutes)...
Do not interrupt this.
sage: diff(x^2,x)
---------------------------------------------------------------------------
RuntimeError Traceback (most recent call
last)

/Users/mcmcclure/<ipython console> in <module>()

/Applications/Sage.app/Contents/Resources/sage/local/lib/python2.5/
site-packages/sage/calculus/functional.py in derivative(f, *args,
**kwds)
127 """
128 try:
--> 129 return f.derivative(*args, **kwds)
130 except AttributeError:
131 pass

/Applications/Sage.app/Contents/Resources/sage/local/lib/python2.5/
site-packages/sage/calculus/calculus.py in derivative(self, *args)
2139 raise TypeError, "arguments must be
SymbolicVariable objects"
2140
-> 2141 vars = self.variables()
2142
2143 if len(vars) == 0:

/Applications/Sage.app/Contents/Resources/sage/local/lib/python2.5/
site-packages/sage/calculus/calculus.py in variables(self)
4691 """
4692 if not self._has_been_simplified():
-> 4693 return self.simplify().variables()
4694
4695 try:

/Applications/Sage.app/Contents/Resources/sage/local/lib/python2.5/
site-packages/sage/calculus/calculus.py in simplify(self)
3490 return self._simp
3491 except AttributeError:
-> 3492 S = evaled_symbolic_expression_from_maxima_string
(self._maxima_init_())
3493 S._simp = None
3494 self._simp = S

/Applications/Sage.app/Contents/Resources/sage/local/lib/python2.5/
site-packages/sage/calculus/calculus.py in
evaled_symbolic_expression_from_maxima_string(x)
9212 [ 0 y^4], 1]
9213 """
-> 9214 return symbolic_expression_from_maxima_string(maxima.eval
(x))
9215
9216 def first_var(expr):

/Applications/Sage.app/Contents/Resources/sage/local/lib/python2.5/
site-packages/sage/interfaces/expect.py in eval(self, code, strip,
synchronize, **kwds)
929 try:
930 with gc_disabled():
--> 931 return '\n'.join([self._eval_line(L, **kwds)
for L in code.split('\n') if L != ''])
932 except KeyboardInterrupt:
933 # DO NOT CATCH KeyboardInterrupt, as it is being
caught

/Applications/Sage.app/Contents/Resources/sage/local/lib/python2.5/
site-packages/sage/interfaces/maxima.py in _eval_line(self, line,
allow_use_file, wait_for_prompt, reformat, error_check)
603 return repr(a)
604 else:
--> 605 self._sendline(line)
606
607 if not wait_for_prompt:

/Applications/Sage.app/Contents/Resources/sage/local/lib/python2.5/
site-packages/sage/interfaces/maxima.py in _sendline(self, str)
470
471 def _sendline(self, str):
--> 472 self._sendstr(str)
473 os.write(self._expect.child_fd, os.linesep)
474

/Applications/Sage.app/Contents/Resources/sage/local/lib/python2.5/
site-packages/sage/interfaces/expect.py in _sendstr(self, str)
826 """
827 if self._expect is None:
--> 828 self._start()
829 try:
830 os.write(self._expect.child_fd, str)

/Applications/Sage.app/Contents/Resources/sage/local/lib/python2.5/
site-packages/sage/interfaces/maxima.py in _start(self)
448 True
449 """
--> 450 Expect._start(self)
451 self._sendline(r":lisp (defun tex-derivative (x l r)
(tex (if $derivabbrev (tex-dabbrev x) (tex-d x '\\partial)) l r lop
rop ))")
452 self._eval_line('0;')

/Applications/Sage.app/Contents/Resources/sage/local/lib/python2.5/
site-packages/sage/interfaces/expect.py in _start(self, alt_message,
block_during_init)
462 self._session_number = BAD_SESSION
463 failed_to_start.append(self.__name)
--> 464 raise RuntimeError, "Unable to start
%s"%self.__name
465 self._expect.timeout = None
466 with gc_disabled():

William Stein

unread,
Feb 13, 2009, 12:55:59 PM2/13/09
to sage-...@googlegroups.com
On Fri, Feb 13, 2009 at 9:53 AM, mark mcclure <mcmc...@unca.edu> wrote:
>
> On Feb 13, 5:34 am, mabshoff <mabsh...@googlemail.com> wrote:
>> Ok, I figured it out. After downloading the dmg I dragged it to my
>> desktop and double clicked on it to start. It came up, but Maxima/
>> clisp did not start.
>>
>> So, after quitting I run that sage on the command line and low and
>> behold the rebase script ran:
>
> Thanks for the info. Unfortunately, Maxima still doesn't work for me.
> I included the error messages below. Also, I built sage from source,
> assuming that would work. I get virtually identical error messages
> with only the directory names changed.

What happens when you type:

./sage -maxima

?

William
--
William Stein
Associate Professor of Mathematics
University of Washington
http://wstein.org

mabshoff

unread,
Feb 13, 2009, 1:01:30 PM2/13/09
to sage-devel


On Feb 13, 9:55 am, William Stein <wst...@gmail.com> wrote:
> On Fri, Feb 13, 2009 at 9:53 AM, mark mcclure <mcmcc...@unca.edu> wrote:

Hi,

> > On Feb 13, 5:34 am, mabshoff <mabsh...@googlemail.com> wrote:
> >> Ok, I figured it out. After downloading the dmg I dragged it to my
> >> desktop and double clicked on it to start. It came up, but Maxima/
> >> clisp did not start.
>
> >> So, after quitting I run that sage on the command line and low and
> >> behold the rebase script ran:
>
> > Thanks for the info.  Unfortunately, Maxima still doesn't work for me.
> > I included the error messages below.  Also, I built sage from source,
> > assuming that would work.

Does it not?

>  I get virtually identical error messages
> > with only the directory names changed.

Ok, do you have another global Sage install? Does the user you start
Sage with does have write permission for the Sage.app?

> What happens when you type:
>
> ./sage -maxima

Yep, I would also be curious if

./sage -sh
clisp

from inside the Sage.app did anything useful. Once that works I see no
reason why Maxima would not work.

> ?
>
> William
>
>

Cheers,

Michael

mark mcclure

unread,
Feb 13, 2009, 1:02:07 PM2/13/09
to sage-devel
On Feb 13, 12:55 pm, William Stein <wst...@gmail.com> wrote:
> On Fri, Feb 13, 2009 at 9:53 AM, mark mcclure <mcmcc...@unca.edu> wrote:
> What happens when you type:
>
> ./sage -maxima

I get the error message shown below. I had tried that
already, since I frequently use sage precisely to access
maxima.

---------------- Bad sage -maxima session -------------
mcmcclure$ /Applications/Sage.app/Contents/Resources/sage/sage -maxima
Maxima 5.16.3 http://maxima.sourceforge.net
Using Lisp CLISP 2.46 (2008-07-02)
Distributed under the GNU Public License. See the file COPYING.
Dedicated to the memory of William Schelter.
The function bug_report() provides bug reporting information.
Unknown plot option specified: gnuplot_pipes_term
-- an error. To debug this try debugmode(true);
Maxima encountered a Lisp error:


THROW: there is no CATCHer for tag MACSYMA-QUIT

Automatically continuing.
To reenable the Lisp debugger set *debugger-hook* to nil.

*** - THROW: there is no CATCHer for tag RETURN-FROM-DEBUGGER
The following restarts are available:
MACSYMA-QUIT :R1 Maxima top-level
Break 1 [1]>

mabshoff

unread,
Feb 13, 2009, 1:14:48 PM2/13/09
to sage-devel


On Feb 13, 10:02 am, mark mcclure <mcmcc...@unca.edu> wrote:
> On Feb 13, 12:55 pm, William Stein <wst...@gmail.com> wrote:

Hi Mark,

> > On Fri, Feb 13, 2009 at 9:53 AM, mark mcclure <mcmcc...@unca.edu> wrote:
> > What happens when you type:
>
> > ./sage -maxima
>
> I get the error message shown below.  I had tried that
> already, since I frequently use sage precisely to access
> maxima.
>
> ---------------- Bad sage -maxima session -------------
> mcmcclure$ /Applications/Sage.app/Contents/Resources/sage/sage -maxima
> Maxima 5.16.3http://maxima.sourceforge.net
> Using Lisp CLISP 2.46 (2008-07-02)
> Distributed under the GNU Public License. See the file COPYING.
> Dedicated to the memory of William Schelter.
> The function bug_report() provides bug reporting information.
> Unknown plot option specified:  gnuplot_pipes_term
>  -- an error.  To debug this try debugmode(true);

Hmm, any chance you have gnuplot installed on your system? There is an
issue when gnuplot is provided by Fink or MacPorts since it then links
to Apple's IOKit which also provides a libpng which has some renamed/
added symbols which do clash with Sage's libpng. Since
DYLD_LIBRARY_PATH is set by Sage in its env to pick up its own libpng
first things go boom, i.e. gnuplot should fail at start. The issue
with Sage's libpng and IOKit clashing will be fixed once and for all
in 3.3.rc1.

If you have gnuplot installed you might want to try to take it out of
$PATH to see if the problem goes away. There is also the chance that
clisp blows up - unfortunately clisp segfaulting or doing something
dumb has been the source of many problems with Maxima in Sage. Clisp
2.46 also still has the problem that if you have a file with umlauts
or accents, i.e. something not 7 bit ascii, in $HOME it will blow up
on startup. Oh well, insert rant about the state of OS lisp
implementations here, I have done it often enough :)

> Maxima encountered a Lisp error:
>
> THROW: there is no CATCHer for tag MACSYMA-QUIT
>
> Automatically continuing.
> To reenable the Lisp debugger set *debugger-hook* to nil.
>
> *** - THROW: there is no CATCHer for tag RETURN-FROM-DEBUGGER
> The following restarts are available:
> MACSYMA-QUIT   :R1      Maxima top-level

Interesting that the macro still refers to MACSYMA.

> Break 1 [1]>

Cheers,

Michael

William Stein

unread,
Feb 13, 2009, 1:21:56 PM2/13/09
to sage-...@googlegroups.com
On Fri, Feb 13, 2009 at 10:14 AM, mabshoff <mabs...@googlemail.com> wrote:
>
>
>
> On Feb 13, 10:02 am, mark mcclure <mcmcc...@unca.edu> wrote:
>> On Feb 13, 12:55 pm, William Stein <wst...@gmail.com> wrote:
>
> Hi Mark,
>
>> > On Fri, Feb 13, 2009 at 9:53 AM, mark mcclure <mcmcc...@unca.edu> wrote:
>> > What happens when you type:
>>
>> > ./sage -maxima
>>
>> I get the error message shown below. I had tried that
>> already, since I frequently use sage precisely to access
>> maxima.
>>
>> ---------------- Bad sage -maxima session -------------
>> mcmcclure$ /Applications/Sage.app/Contents/Resources/sage/sage -maxima
>> Maxima 5.16.3http://maxima.sourceforge.net
>> Using Lisp CLISP 2.46 (2008-07-02)
>> Distributed under the GNU Public License. See the file COPYING.
>> Dedicated to the memory of William Schelter.
>> The function bug_report() provides bug reporting information.
>> Unknown plot option specified: gnuplot_pipes_term
>> -- an error. To debug this try debugmode(true);
>
> Hmm, any chance you have gnuplot installed on your system? There is an
> issue when gnuplot is provided by Fink or MacPorts since it then links

I'm also very suspicious that gnuplot is the source of this problem.
Notice the lines above that say:

Unknown plot option specified: gnuplot_pipes_term
-- an error. To debug this try debugmode(true);

That's of course the error. When I start maxima on my OS X I definitely
don't see anything related to gnuplot.

I'm guessing you have gnuplot dev libs somewhere on your system, or
even just gnuplot in your path, and this is confusing the maxima build
or startup process.

William

mark mcclure

unread,
Feb 13, 2009, 1:35:23 PM2/13/09
to sage-devel
On Feb 13, 1:14 pm, mabshoff <mabsh...@googlemail.com> wrote:
> Hmm, any chance you have gnuplot installed on your system? There
> is an issue when gnuplot is provided by Fink or MacPorts ...

Well, yes, I sure do. In fact, I installed MacPorts recently.
Unfortunately,
I set my $PATH to the minimum and the problem persists. Perhaps, I
don't need to worry about this very long at all, if I understand the
following
sentence correctly:

> The issue with Sage's libpng and IOKit clashing will be fixed once and
> for all in 3.3.rc1.

> Interesting that the macro still refers to MACSYMA.

Yeah, I noticed that too. :)

Thanks for the help,
Mark McClure

Georg S. Weber

unread,
Feb 15, 2009, 4:58:55 AM2/15/09
to sage-devel


On 13 Feb., 11:34, mabshoff <mabsh...@googlemail.com> wrote:
> Ok, I figured it out. After downloading the dmg I dragged it to my
> desktop and double clicked on it to start. It came up, but Maxima/
> clisp did not start.
>
> So, after quitting I run that sage on the command line and low and
> behold the rebase script ran:
>
> Sprocketer:sage michaelabshoff$ ./sage
> ----------------------------------------------------------------------
> | Sage Version 3.3.rc0, Release Date: 2009-02-11                     |
> | Type notebook() for the GUI, and license() for information.        |
> ----------------------------------------------------------------------
> The SAGE install tree may have moved.
> Regenerating Python.pyo and .pyc files that hardcode the install PATH
> (please wait at
> most a few minutes)...
> Do not interrupt this.
>
> Afterwards Maxima and clisp work:
>
> sage: !maxima
> Maxima 5.16.3http://maxima.sourceforge.net
Hi,

a patch is up for review at #5254.

Cheers,
gsw

Georg S. Weber

unread,
Feb 15, 2009, 4:59:14 AM2/15/09
to sage-devel


On 13 Feb., 11:34, mabshoff <mabsh...@googlemail.com> wrote:
> Ok, I figured it out. After downloading the dmg I dragged it to my
> desktop and double clicked on it to start. It came up, but Maxima/
> clisp did not start.
>
> So, after quitting I run that sage on the command line and low and
> behold the rebase script ran:
>
> Sprocketer:sage michaelabshoff$ ./sage
> ----------------------------------------------------------------------
> | Sage Version 3.3.rc0, Release Date: 2009-02-11                     |
> | Type notebook() for the GUI, and license() for information.        |
> ----------------------------------------------------------------------
> The SAGE install tree may have moved.
> Regenerating Python.pyo and .pyc files that hardcode the install PATH
> (please wait at
> most a few minutes)...
> Do not interrupt this.
>
> Afterwards Maxima and clisp work:
>
> sage: !maxima
> Maxima 5.16.3http://maxima.sourceforge.net
Hi,

a patch is up for review at #5254.

Cheers,
gsw

mark mcclure

unread,
Feb 15, 2009, 9:46:16 AM2/15/09
to sage-devel
On Feb 15, 4:59 am, "Georg S. Weber" <GeorgSWe...@googlemail.com>
wrote:
> a patch is up for review at #5254.

George,

I applied your patch without success on my laptop at home.
However, the problem could very well be that I've got OS
10.4.11 at home while Michael built Sage.app for 10.5. I
can try it on 10.5 tomorrow at work but, since I've never
applied a patch before, I'd like to describe what I intend
to try to make sure I'm doing it correctly. As I
understand it, I should try the following:
* Install Sage.app afresh from the .dmg file.
* Download your attachement from trac, which appears
to be a simple bash script.
* Name the attachment 'script' and place it in
/Applications/Sage.app/Contents/Resources,
overwriting the previous version.
* Set the permissions to 755.
* Double click on Sage.app.

One other issue though. The patch only seems applicable
to Sage.app, not to the command line. That is, I'd like
to be able to type:
/Applications/Sage.app/Contents/Resources/sage/sage
but I don't think your script ever even runs in that case.

Thanks,
Mark McClure

mabshoff

unread,
Feb 15, 2009, 9:52:15 AM2/15/09
to sage-devel


On Feb 15, 6:46 am, mark mcclure <mcmcc...@unca.edu> wrote:
> On Feb 15, 4:59 am, "Georg S. Weber" <GeorgSWe...@googlemail.com>
> wrote:

Hi Mark,

> > a patch is up for review at #5254.
>
> George,
>
> I applied your patch without success on my laptop at home.
> However, the problem could very well be that I've got OS
> 10.4.11 at home while Michael built Sage.app for 10.5.

The binary build on OSX 10.5 will not work on OSX 10.4. The other way
around we have seen that it does work (at least on occasion), but
since the vast majority of Sage devs have moved on to 10.5 and we are
having a hard time finding even a 10.4 Intel build box I don't see us
providing OSX 10.4 binaries for 10.4 and 10.5 any time soon. Note that
once Apple releases 10.6 in the summer they will likely end support
for 10.4, too. I can see us providing 10.4 binaries until the hardware
physically implodes we use to build or XCode running on OSX 10.4 will
cease to build Sage from sources. Both are unlikely to happen any time
soon, but as we still get requests for OSX 10.3 binaries on occasion
it seems that some people keep running on the no longer supported
releases.

> I can try it on 10.5 tomorrow at work but, since I've never
> applied a patch before, I'd like to describe what I intend
> to try to make sure I'm doing it correctly.  As I
> understand it, I should try the following:
>   * Install Sage.app afresh from the .dmg file.
>   * Download your attachement from trac, which appears
>     to be a simple bash script.
>   * Name the attachment 'script' and place it in
>     /Applications/Sage.app/Contents/Resources,
>     overwriting the previous version.
>   * Set the permissions to 755.
>   * Double click on Sage.app.

Yep, pretty much.

> One other issue though.  The patch only seems applicable
> to Sage.app, not to the command line.  That is, I'd like
> to be able to type:
> /Applications/Sage.app/Contents/Resources/sage/sage
> but I don't think your script ever even runs in that case.

The script should only trigger if you move the Sage install. If you
manually triggered it already once in its current location there will
be no change until you move Sage again.

> Thanks,
> Mark McClure

Cheers,

Michael

Georg S. Weber

unread,
Feb 15, 2009, 2:26:34 PM2/15/09
to sage-devel
Hi Mark,
hi Michael,

actually I am using Mac OS X 10.4.11 on the Intel Core2Duo MacBook
where I tested it. I should have noted that I did download the source
distribution .tar and did build on this box my own "10.4" .dmg with
which I tested the new version of the script. (Aha -- I did rename the
original build directory to get it out the way, but is it possible
that e.g. the Maxima dynamic lib had stayed somehow in RAM and was
just reused?)

This is because Michael is right (and I knew it), that the OS X 10.5
built binary most probably would fail on OS X 10.4. (Though I can't
point my finger to a specific reason, is it Xcode 3.0/OS X 10.5 vs.
Xcode 2.5/OS X 10.4? But Xcode 2.5 is at least available for OS X
10.5, too.)

What you did was exactly the recipe for you to be done (I hope "755"
is the right chmod magic, I always mess this up).

Since I know persons (me, myself and I) that tend to move OS X app
bundles around from one place to another, I hardcoded in the script
that everytime you double-click the Sage app, it checks whether the
location has moved (calling the script for this, named "sage-
location").

The reason why this is not done in general, i.e. in "/Applications/
Sage.app/Contents/Resources/sage/sage" itself, is the following use
case:

On certain sites, Sage is not a per-user install, but is installed by
the admin in a central place where not every user has write
permissions. So it would be fatal if a "normal" user starting Sage up
would require per default that some files were to be written. Let
alone if the startup would vitally depend on this.

But e.g. for Mac OS X app bundles, it should be safe to call the "sage-
location" script each and every time at the startup of Sage --- the
additional time needed is negligible in the "good" case, and extremely
welcomed in the "bad" case.


@Michael and all others:
What do you think about a patch of the sage script (or, say, "sage-
sage"; maybe "sage-run", too) along these lines --- right after sage-
env do check e.g. for UNAME==Darwin and then if so call "sage-
location" at every start of Sage?


Cheers,
gsw

Georg S. Weber

unread,
Feb 15, 2009, 2:33:07 PM2/15/09
to sage-devel
Hi,

maybe off-topic, I deem it on-topic here:

Probably I will use OS X 10.4.11 for quite some more time, and I build
Sage rather often for testing, and/or for my own personal use. Would
it help if I provided, say, the OS X 10.4 .dmg files (Intel Core2Duo
regularly and sometimes even PPC G4)? My time and my Internet upload
connection do certainly allow for that.

Cheers,
gsw

kcrisman

unread,
Feb 15, 2009, 3:53:54 PM2/15/09
to sage-devel

>
> Probably I will use OS X 10.4.11 for quite some more time, and I build
> Sage rather often for testing, and/or for my own personal use. Would
> it help if I provided, say, the OS X 10.4 .dmg files (Intel Core2Duo
> regularly and sometimes even PPC G4)? My time and my Internet upload
> connection do certainly allow for that.

I suspect if this is available people will take advantage of it. Many
of us have perfectly serviceable computers which can't handle/can't
afford the upgrade. I would just build from source as a dev wannabe,
but having this available for platforms not even three years old seems
pretty reasonable. So if mabshoff/wstein can't make them at some
point in the future, having someone in the wings is very wise.

Written on my OSX.3 almost last of the eMacs (from which I only use
sagenb.org !),
- kcrisman

mabshoff

unread,
Feb 15, 2009, 8:22:30 PM2/15/09
to sage-devel


On Feb 15, 11:26 am, "Georg S. Weber" <GeorgSWe...@googlemail.com>
wrote:
> Hi Mark,
> hi Michael,

<SNIP>

> But e.g. for Mac OS X app bundles, it should be safe to call the "sage-
> location" script each and every time at the startup of Sage --- the
> additional time needed is negligible in the "good" case, and extremely
> welcomed in the "bad" case.
>
> @Michael and all others:
> What do you think about a patch of the sage script (or, say, "sage-
> sage"; maybe "sage-run", too) along these lines --- right after sage-
> env do check e.g. for UNAME==Darwin and then if so call "sage-
> location" at every start of Sage?

sage-location should already be called every time Sage is started, so
I am not sure what you want to change.

Making sage-location rewrite all pyc files is an expensive operation,
especially on OSX, and there might be permission problems if invoked
by a user anyway.

> Cheers,
> gsw

Cheers,

Michael

mabshoff

unread,
Feb 15, 2009, 8:24:44 PM2/15/09
to sage-devel


On Feb 15, 11:33 am, "Georg S. Weber" <GeorgSWe...@googlemail.com>
wrote:
> Hi,

Hi Georg,
We do have access to a OSX 10.4.11 PPC box that will be there for the
foreseeable future, the main problem is a lack of a 10.4 MacIntel box,
so binaries for that would be appreciated. The box should not have
Fink or MacPorts installed and it would be helpful to get the binary
in a somewhat narrow window, i.e. in the 48 hours after the final
tarball is announced.

> Cheers,
> gsw

Cheers,

Michael

mabshoff

unread,
Feb 15, 2009, 8:27:39 PM2/15/09
to sage-devel


On Feb 15, 12:53 pm, kcrisman <kcris...@gmail.com> wrote:

<SNIP>

> I suspect if this is available people will take advantage of it.  Many
> of us have perfectly serviceable computers which can't handle/can't
> afford the upgrade.  I would just build from source as a dev wannabe,
> but having this available for platforms not even three years old seems
> pretty reasonable.  So if mabshoff/wstein can't make them at some
> point in the future, having someone in the wings is very wise.
>
> Written on my OSX.3 almost last of the eMacs (from which I only use
> sagenb.org !)

Well, the major point here is that you should never connect a PC/Mac
to the net with an unsupported operating system, i.e. one where in
your case Apple no longer provides security updates. In general OSX
10.3 seems to be the minimum release that various important software
projects seem to support, but I have seen and read about enough
breakage with 10.3 so that I expect this won't be true much longer. As
I mentioned: Judging from the last 10.4 to 10.5 transition it will go
very fast when most Sage devs run 10.6 once it is out.

> - kcrisman

Cheers,

Michael

mark mcclure

unread,
Feb 16, 2009, 11:48:33 AM2/16/09
to sage-devel
On Feb 15, 4:59 am, "Georg S. Weber" <GeorgSWe...@googlemail.com>
wrote:
> a patch is up for review at #5254.

Well, still no luck. It's clear that the script has had
some effect, since the error messages no longer refer to
mabshoff's machine, but Maxima still doesn't start.
Error logs post-patch and pre-patch are below. In both
cases, Sage.app issued the "SAGE install tree may have
moved" statement. The error is caused by any statement
that uses Maxima, like "diff(x^2,x)".

This is all on my Mac Pro running 10.5.5. Also, I don't
think I have GnuPlot installed on this machine, although
I do have Macports.

Thanks,
Mark McClure


------- Post Patch error log --------
Traceback (click to the left for traceback)
...
RuntimeError: Unable to start maxima

Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/Users/mcmcclure/.sage/sage_notebook/worksheets/admin/0/code/
2.py", line 7, in <module>
diff(x**_sage_const_2 ,x)
File "/Applications/Sage.app/Contents/Resources/sage/local/lib/
python2.5/site-packages/SQLAlchemy-0.4.6-py2.5.egg/", line 1, in
<module>

File "/Applications/Sage.app/Contents/Resources/sage/local/lib/
python2.5/site-packages/sage/calculus/functional.py", line 129, in
derivative
return f.derivative(*args, **kwds)
File "/Applications/Sage.app/Contents/Resources/sage/local/lib/
python2.5/site-packages/sage/calculus/calculus.py", line 2141, in
derivative
vars = self.variables()
File "/Applications/Sage.app/Contents/Resources/sage/local/lib/
python2.5/site-packages/sage/calculus/calculus.py", line 4693, in
variables
return self.simplify().variables()
File "/Applications/Sage.app/Contents/Resources/sage/local/lib/
python2.5/site-packages/sage/calculus/calculus.py", line 3492, in
simplify
S = evaled_symbolic_expression_from_maxima_string
(self._maxima_init_())
File "/Applications/Sage.app/Contents/Resources/sage/local/lib/
python2.5/site-packages/sage/calculus/calculus.py", line 9214, in
evaled_symbolic_expression_from_maxima_string
return symbolic_expression_from_maxima_string(maxima.eval(x))
File "/Applications/Sage.app/Contents/Resources/sage/local/lib/
python2.5/site-packages/sage/interfaces/expect.py", line 931, in eval
return '\n'.join([self._eval_line(L, **kwds) for L in code.split
('\n') if L != ''])
File "/Applications/Sage.app/Contents/Resources/sage/local/lib/
python2.5/site-packages/sage/interfaces/maxima.py", line 605, in
_eval_line
self._sendline(line)
File "/Applications/Sage.app/Contents/Resources/sage/local/lib/
python2.5/site-packages/sage/interfaces/maxima.py", line 472, in
_sendline
self._sendstr(str)
File "/Applications/Sage.app/Contents/Resources/sage/local/lib/
python2.5/site-packages/sage/interfaces/expect.py", line 828, in
_sendstr
self._start()
File "/Applications/Sage.app/Contents/Resources/sage/local/lib/
python2.5/site-packages/sage/interfaces/maxima.py", line 450, in
_start
Expect._start(self)
File "/Applications/Sage.app/Contents/Resources/sage/local/lib/
python2.5/site-packages/sage/interfaces/expect.py", line 464, in
_start
raise RuntimeError, "Unable to start %s"%self.__name
RuntimeError: Unable to start maxima



--------- Pre Patch error -----------

Traceback (click to the left for traceback)
...
RuntimeError: Unable to start maxima

mark mcclure

unread,
Feb 17, 2009, 3:07:45 PM2/17/09
to sage-devel
I finally got Sage.app working. Still there seems
something a bit odd about the fix. I had, in my home
directory, a .maxima directory with a file named
maxima-init.mac that sets certain maxima preferences.
Once I deleted this file, everything worked fine. As I
understand it though, the sage directory is supposed to be
independent of the rest of the system. Evidently, the
latest version of sage is reading information from my
home directory. My old sage (v3.0.1) runs fine without
removing the file, however.

The two lines in the maxima-init file were exactly the
following:
set_plot_option([gnuplot_term, aqua]);
set_plot_option([gnuplot_pipes_term, aqua]);

Of course, now I can no longer plot from my standalone
copy of maxima. :)

One final comment: George's patch was unnecessary. I
hope I didn't send you on a wild goose chase.

Mark McClure

mabshoff

unread,
Feb 17, 2009, 3:13:31 PM2/17/09
to sage-devel


On Feb 17, 12:07 pm, mark mcclure <mcmcc...@unca.edu> wrote:

Hi Mark,

> I finally got Sage.app working.  Still there seems
> something a bit odd about the fix.  I had, in my home
> directory, a .maxima directory with a file named
> maxima-init.mac that sets certain maxima preferences.
> Once I deleted this file, everything worked fine.  As I
> understand it though, the sage directory is supposed to be
> independent of the rest of the system.  

Well, it doesn't *write* to anything outside $SAGE_ROOT and $DOT_SAGE
and it is not supposed to pick up any external config files, but some
times this still happens.

> Evidently, the
> latest version of sage is reading information from my
> home directory.  My old sage (v3.0.1) runs fine without
> removing the file, however.

ok. I believe we since upgraded Maxima.

> The two lines in the maxima-init file were exactly the
> following:
> set_plot_option([gnuplot_term, aqua]);
> set_plot_option([gnuplot_pipes_term, aqua]);
>
> Of course, now I can no longer plot from my standalone
> copy of maxima. :)
>
> One final comment: George's patch was unnecessary.  I
> hope I didn't send you on a wild goose chase.

Nah, that was a real bug.

> Mark McClure

I made this http://trac.sagemath.org/sage_trac/ticket/5295

Cheers,

Michael

mark mcclure

unread,
Feb 17, 2009, 3:25:29 PM2/17/09
to sage-devel
On Feb 17, 3:13 pm, mabshoff <mabsh...@googlemail.com> wrote:
> > One final comment: George's patch was unnecessary.  I
> > hope I didn't send you on a wild goose chase.
>
> Nah, that was a real bug.
>
> I made thishttp://trac.sagemath.org/sage_trac/ticket/5295

Good. One other little issue remains. When Sage.app quits,
MacOS gives me the message:
"The application lisp.run quit unexpectedly."
Not a problem as far as I'm concerned, but a bit strange.

Mark McClure
Reply all
Reply to author
Forward
0 new messages