#11243: python spkg build fails on Ubuntu 11.04
----------------------------+-----------------------------------------------
Reporter: pipedream | Owner: GeorgSWeber
Type: defect | Status: new
Priority: major | Milestone: sage-4.7.1
Component: build | Keywords:
Work_issues: | Upstream: None of the above - read trac
for reasoning.
Reviewer: David Kirkby | Author: Jan Groenewald
Merged: | Dependencies:
----------------------------+-----------------------------------------------
Comment(by drkirkby):
Replying to [comment:4 pipedream]:
> Does it matter if it fails? If the string doesn't match, no patch is
applied, as it should be.
Yes it does. It is unprofessional to use a command which fails like this,
as it is disconcerting to those who don't have the command.
A better test is:
{{{
if [ `command -v lsb_release` ] && [ "x`lsb_release -d`" = "xDescription:
Ubuntu 11.04" ] ; then
}}}
Then the second part will only get executed if '{{{lsb_release}}}' exists.
That should be safe on any platform, even Linux systems for which the
command '{{{lsb_release}}}' does not exist. The program '{{{command}}}'
will exist on any operating system conforming to the POSIX standard.
http://pubs.opengroup.org/onlinepubs/9699919799/utilities/command.html
While Linux does not conform to POSIX standards, any distribution I am
aware of will have an executable called '{{{command}}}'
As such, I think that would be a sensible improvement.
The next issue is that the patch copies a revised version of
'{{{patches/Setup.dist}}}'. While it is true the developers guide might
still say to do that, it has been agreed to use '{{{patch}}}'. So you
should create a unified diff patch and apply that patch. Not only does
that save space, but it allows more than one patch to be applied easily,
whereas the use of '{{{cp}}}' caused problems. You can guarantee that
'{{{patch}}}' will be available, as there is a Sage package for that.
Note also your Mercurial patch should have the contents of any patch you
have.
Dave
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/11243#comment:5>
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.