#11232: we should not build patch on Cygwin
----------------------------+-----------------------------------------------
Reporter: dimpase | Owner: tbd
Type: defect | Status: needs_work
Priority: major | Milestone: sage-4.7
Component: cygwin | Keywords:
Author: | Upstream: N/A
Reviewer: David Kirkby | Merged:
Work_issues: |
----------------------------+-----------------------------------------------
Changes (by drkirkby):
* status: needs_review => needs_work
* reviewer: => David Kirkby
Comment:
The test is not working. I changed it a little, so it worked on Solaris
instead of Cygwin. My changes are:
{{{
if [ "x$UNAME" = xSunOS ] ; then
if ! patch --version | grep >/dev/null 'patch '; then
echo "On Cygwin you must have patch installed"
echo "via the Cygwin setup.exe program"
exit 1
fi
exit 0
fi
}}}
then I created a script called 'patch', which just echos "foo"
{{{
drkirkby@laptop:~/patch-2.5.9.p1$ patch
foo
}}}
Now when I run spkg-install, it does not detect I don't have a usable
'patch; command:
{{{
drkirkby@laptop:~/patch-2.5.9.p1$ ./spkg-install
SAGE_LOCAL undefined ... exiting
Maybe run 'sage -sh'?
drkirkby@laptop:~/patch-2.5.9.p1$
}}}
There's no message I need to install patch.
I'm not sure exactly what you are trying to achieve here - this is not the
way I would write a test. But the exit code of grep should be 0 in the
case of a match and non-zero for the case of no match or an error.
I would also suggest putting the test to see if 'SAGE_ROOT' is set at the
top, as it is with every other package.
A better place to check for the existence of 'patch' is actually in the
prereq script, as we should let users know as soon as possible if their
system needs extra things installed.
Dave
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/11232#comment:3>
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.