Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ilegal 'grep -o' causes problems installing optional packages on Solaris #8509

Closed
sagetrac-drkirkby mannequin opened this issue Mar 12, 2010 · 16 comments
Closed

Ilegal 'grep -o' causes problems installing optional packages on Solaris #8509

sagetrac-drkirkby mannequin opened this issue Mar 12, 2010 · 16 comments

Comments

@sagetrac-drkirkby
Copy link
Mannequin

sagetrac-drkirkby mannequin commented Mar 12, 2010

Hardware

  • Sun Blade 1000
  • 2 x 900 MHz UltraSPARC III+ CPUs.
  • 2 GB RAM

== Software ==

  • Solaris 10 03/2005 (the first release)
  • Sage 4.3.4.alpha1 (The first Sage release to build and pass all doctests on Solaris)

The problem

Despite the fact that Sage builds and pass all doctests (including the long ones), installing optional packages is problematic, as it would appear something is calling 'grep' with the '-o' option which is not POSIX compatible

http://www.opengroup.org/onlinepubs/9699919799/utilities/grep.html

This causes the problems below:

sage: for X in optional_packages()[1]:  install_package(X)
....: 
Force installing ace-5.0.p0
Calling sage-spkg on ace-5.0.p0
Warning: Attempted to overwrite SAGE_ROOT environment variable
ace-5.0.p0
Machine:
SunOS redstart 5.10 Generic sun4u sparc SUNW,Sun-Blade-1000
Deleting directories from past builds of previous/current versions of ace-5.0.p0
/export/home/drkirkby/sage-4.3.4.alpha1/local/bin/sage-spkg: file ace-5.0.p0 does not exist
Attempting to download it.
grep: illegal option -- o
Usage: grep -hblcnsviw pattern file . . .
Searching for latest version of ace-5.0.p0
Could not find a version for ace-5.0.p0.

Force installing biopython-1.53.p0
Calling sage-spkg on biopython-1.53.p0
Warning: Attempted to overwrite SAGE_ROOT environment variable
biopython-1.53.p0
Machine:
SunOS redstart 5.10 Generic sun4u sparc SUNW,Sun-Blade-1000
Deleting directories from past builds of previous/current versions of biopython-1.53.p0
/export/home/drkirkby/sage-4.3.4.alpha1/local/bin/sage-spkg: file biopython-1.53.p0 does not exist
Attempting to download it.
grep: illegal option -- o
Usage: grep -hblcnsviw pattern file . . .
Searching for latest version of biopython-1.53.p0
Could not find a version for biopython-1.53.p0.

CC: @jhpalmieri

Component: porting: Solaris

Author: David Kirkby, John Palmieri

Reviewer: Dmitrii Pasechnik

Merged: sage-4.4.alpha0

Issue created by migration from https://trac.sagemath.org/ticket/8509

@sagetrac-drkirkby sagetrac-drkirkby mannequin added this to the sage-4.4 milestone Mar 12, 2010
@sagetrac-drkirkby sagetrac-drkirkby mannequin self-assigned this Mar 12, 2010
@sagetrac-drkirkby
Copy link
Mannequin Author

sagetrac-drkirkby mannequin commented Mar 13, 2010

Attachment: sage-spkg.gz

Revised sage-spkg removing the -o option

@sagetrac-drkirkby
Copy link
Mannequin Author

sagetrac-drkirkby mannequin commented Mar 13, 2010

comment:1

Thanks to John Palmieri who suggested this solution, which does work.

@sagetrac-drkirkby
Copy link
Mannequin Author

sagetrac-drkirkby mannequin commented Mar 13, 2010

Author: David Kirkby, John Palmieri

@jhpalmieri
Copy link
Member

comment:2

sage-spkg should be under revision control: either run Mercurial from the directory SAGE_ROOT/local/bin, or while running sage, use "hg_scripts" (instead of "hg_sage").

@sagetrac-drkirkby
Copy link
Mannequin Author

sagetrac-drkirkby mannequin commented Mar 13, 2010

comment:3

Oops, my mistake. I was not aware of that. I'm attaching a Mercurial patch

@sagetrac-drkirkby
Copy link
Mannequin Author

sagetrac-drkirkby mannequin commented Mar 13, 2010

Attachment: sage-spkg.patch.gz

Mercurial patch (replaces the earlier one, which was just from 'diff')

@dimpase
Copy link
Member

dimpase commented Mar 15, 2010

comment:4

Replying to @sagetrac-drkirkby:

Oops, my mistake. I was not aware of that. I'm attaching a Mercurial patch

Dave, $SAGE_ROOT/local/bin is not under hg.
You should create a patch for the corresponding source place, i.e.
for a script in sage_scripts-4.3.4.alpha1.spkg

That's the only way to make it into the release, AFAIK.

@jhpalmieri
Copy link
Member

comment:5

Replying to @dimpase:

Replying to @sagetrac-drkirkby:

Oops, my mistake. I was not aware of that. I'm attaching a Mercurial patch

Dave, $SAGE_ROOT/local/bin is not under hg.

It is, actually; as I said before, it's the "scripts" repository discussed in the Sage developer's guide.

@sagetrac-drkirkby
Copy link
Mannequin Author

sagetrac-drkirkby mannequin commented Mar 15, 2010

comment:6

I created that while running Mercurial from $SAGE_ROOT/local/bin which is what you said John. I did not use 'hg_scripts'. (I tend to prefer using 'hg' as it means one can apply patches to Sage before even building it.

I'll try use 'hg_scripts' later, but for now I need to do something more pressing. I'm in the middle of decorating and my wife will be coming home in a few days expecting to see it done. Like all these things, it takes a lot longer than one thinks. So this patch is going to have to wait a bit.

If anyone want to replace my patch with one more suitable, feel free, but otherwise I'll sort this out when I've got the more important jobs out of the way.

Dave

@jhpalmieri
Copy link
Member

comment:7

Running "hg_scripts" from within Sage is, as far as I know, equivalent to running "hg" or "sage -hg" from the command line while in the directory $SAGE_ROOT/local/bin. So you don't need to produce a new patch.

@sagetrac-drkirkby
Copy link
Mannequin Author

sagetrac-drkirkby mannequin commented Mar 15, 2010

comment:8

Thank you John.

That makes sense. I think I just need to put a note for the release manager to sage what repository it goes in, but apart from that, I think it will be ok.

All we need now is someone to review it! Since it was your idea, and I tested and wrote it, then neither of us can review it.

Dave

@sagetrac-drkirkby
Copy link
Mannequin Author

sagetrac-drkirkby mannequin commented Mar 15, 2010

comment:9

** Note to the release manager - this patch is for the sage shell scripts repository.**

@dimpase
Copy link
Member

dimpase commented Mar 17, 2010

comment:10

Replying to @sagetrac-drkirkby:

All we need now is someone to review it! Since it was your idea, and I tested and wrote it, then neither of us can review it.

Works on t2 (and on a Linux install, just to check it doesn't break anything badly).
So, thumbs up!

@jhpalmieri
Copy link
Member

comment:11

Merged "sage-spkg.patch" into 4.4.alpha0.

@jhpalmieri
Copy link
Member

Merged: sage-4.4.alpha0

@jhpalmieri
Copy link
Member

Reviewer: Dmitrii Pasechnik

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants