#11280: check XCode version on MacOSX, and bail out if it is 4
-----------------------+----------------------------------------------------
Reporter: dimpase | Owner: GeorgSWeber
Type: defect | Status: needs_info
Priority: blocker | Milestone: sage-4.7
Component: build | Keywords: XCode 4
Work_issues: | Upstream: N/A
Reviewer: | Author: Dmitrii Pasechnik
Merged: | Dependencies:
-----------------------+----------------------------------------------------
Comment(by drkirkby):
Replying to [comment:13 dimpase]:
> Well, I don't follow the 0.9 vs 0.8 question. I really have no idea what
you are talking about, in this respect.
> Please explain if I need to adjust the patch.
>
> I'll fix the point that "latest" must mean "latest, but not Xcode 4",
that's easy.
>
> Dima
Dima,
The way Sage checks it's prerequisites is not my idea of a good way, but
this is how it works:
* There's an executable shell script
{{{$SAGE_ROOT/spkg/base/prereq-0.8-install}}}
* There's a tar file in {{{$SAGE_ROOT/spkg/base/prereq-0.8.tar}}}
* When {{{$SAGE_ROOT/spkg/base/prereq-0.8-install}}} executes, it
extracts the contents of {{{$SAGE_ROOT/spkg/base/prereq-0.8.tar}}}. That
tar file has a "{{{configure}}}" script generated by autoconf. The
"{{{configure}}}" script then executes and does some other tests that are
not in the {{{$SAGE_ROOT/spkg/base/prereq-0.8-install}}}.
You are editing a script (currently prereq-0.8-install). Once edited, the
version number of that script needs to be incremented, like one does
whenever one makes changes to software. The most obvious name in this case
would appear to be rename that script to prereq-0.9-install. (Since it
under revision control, that needs to be done in Mercurial)
The top of the script has a name hard-coded. That will need the obvious
edit.
i.e. change
{{{
TARGET=prereq-0.8
}}}
to
{{{
TARGET=prereq-0.9
}}}
The script opens a tar file - if you look down lower you can see the line:
{{{
tar mxvf "../base/$TARGET.tar"
}}}
So when you change the TARGET, the script will try to open a tar with a
different name.
So basically
{{{
$ tar xf prereq-0.8.tar
$ mv prereq-0.8 prereq-0.9
$ tar cf prereq-0.9.tar prereq-0.9
$ rm prereq-0.8.tar
}}}
Then make your changes to the script prereq-0.8-install, rename it to
prereq-0.9-install, then use Mercurial to rename the prereq-0.8-install
script. I don't know how to do that, though I suspect it is something like
{{{
$ hg rename prereq-0.8-install prereq-0.9-install
}}}
but you will need to check that. You don't need to rename the tar file in
Mercurial as that's listed in .hgignore.
So basically you need to ensure that
* The script has its version incremented - 0.9 is fine by me.
* The TARGET at the top of the script needs to have the version changed
too.
* A tar file needs to be created which also has 0.9 in the name.
BTW, if you want to close another bug (#8566) you can delete the character
"m" from the line
{{{
tar mxvf "../base/$TARGET.tar"
}}}
as that has caused portability issues for a minimal Linux system (slitaz
linux), and serves no useful purpose in Sage.
It's an unusual process this script. I did not design it, and I don't like
it. (Personally I would have used autoconf at the top level to create a
"{{{configure}}}" script, which itself creates "{{{Makefile}}}". Then we
could work like 50% of the open-source UNIX programs around which all use
autoconf/automake, rather than be in the other 50% which each have their
own unique ways.
Dave
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/11280#comment:14>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica,
and MATLAB
--
You received this message because you are subscribed to the Google Groups
"sage-trac" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/sage-trac?hl=en.