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

sage-location doesn't deal with packages after initialize_pkgconfig_files has run #12076

Closed
sagetrac-mariah mannequin opened this issue Nov 23, 2011 · 14 comments
Closed

Comments

@sagetrac-mariah
Copy link
Mannequin

sagetrac-mariah mannequin commented Nov 23, 2011

sage-4.7.2 with optional package libogg-1.1.4.spkg installed.
Now when I move the sage tree I get:

eno% ./sage
----------------------------------------------------------------------
| Sage Version 4.7.2, Release Date: 2011-10-29                       |
| Type notebook() for the GUI, and license() for information.        |
----------------------------------------------------------------------
The Sage installation tree may have moved
(from /home/mariah/sage/sage-4.7.2-x86_64-Linux-core2-fc to /home/mariah/sage/sage-4.7.2-x86_64-Linux-core2-fc-libogg-test).
Changing various hardcoded paths...
(Please wait at most a few minutes.)
DO NOT INTERRUPT THIS.
Error: sage_location: update_pkgconfig_files():
  File "ogg.pc" doesn't contain a definition of SAGE_ROOT.
  Skipping it...
Done resetting paths.
sage:

Apply:

Both trac_12076.patch and
trac_12076-2.patch.

Component: scripts

Keywords: sd40.5

Author: Mike Hansen

Reviewer: Dan Drake, Karl-Dieter Crisman

Merged: sage-5.1.beta4

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

@sagetrac-mariah sagetrac-mariah mannequin added this to the sage-5.1 milestone Nov 23, 2011
@mwhansen
Copy link
Contributor

comment:1

Attachment: trac_12076.patch.gz

@mwhansen
Copy link
Contributor

Author: Mike Hansen

@mwhansen
Copy link
Contributor

Changed keywords from none to sd40.5

@dandrake
Copy link
Contributor

comment:2

The patch here appears to fix the problem, but I notice that the ogg.pc file looks a little different from all the others:

drake@sagenb:~/s/y5.1.b0/local/lib/pkgconfig$ grep ^prefix= *
bdw-gc.pc:prefix=${SAGE_ROOT}/local
freetype2.pc:prefix=${SAGE_ROOT}/local
gnutls-extra.pc:prefix=${SAGE_ROOT}/local
gnutls.pc:prefix=${SAGE_ROOT}/local
gsl.pc:prefix=${SAGE_ROOT}/local
libpng12.pc:prefix=${SAGE_ROOT}/local
libpng.pc:prefix=${SAGE_ROOT}/local
m4ri.pc:prefix=${SAGE_ROOT}/local
ogg.pc:prefix=/home/drake/s/5.1b0/local
opencdk.pc:prefix=${SAGE_ROOT}/local
pynac.pc:prefix=${SAGE_ROOT}/local
python-2.7.pc:prefix=${SAGE_ROOT}/local
python.pc:prefix=${SAGE_ROOT}/local
sqlite3.pc:prefix=${SAGE_ROOT}/local
zlib.pc:prefix=${SAGE_ROOT}/local

Observe that only ogg.pc has the original SAGE_ROOT in its prefix; all other files have prefix in terms of SAGE_ROOT. Is that what we want? Is that okay?

@mwhansen
Copy link
Contributor

comment:3

After installing the patch, did you move the Sage directory and start it?

@dandrake
Copy link
Contributor

comment:4

Replying to @mwhansen:

After installing the patch, did you move the Sage directory and start it?

I did. And the relocation appears to work properly. I'm mostly just curious about the difference in the .pc file.

@kcrisman
Copy link
Member

comment:5

I can confirm this problem, and that this patch fixes it, and the patch seems right, just abstracting out something.

But Dan and I agree that

        config = config.replace(SAGE_ROOT_absolute, "${SAGE_ROOT}")

seems to not be happening here for some reason. But maybe we are parsing it wrong.

@mwhansen
Copy link
Contributor

comment:6

The new patch, which applies on top of the previous one, should (really!) fix this issue.

@dandrake
Copy link
Contributor

Reviewer: Dan Drake

@dandrake
Copy link
Contributor

comment:7

Attachment: trac_12076-2.patch.gz

Whew! These two patches now fix the problem. To be sure, I'd like one more person to look at this, and then we'll do a positive review.

@dandrake

This comment has been minimized.

@dandrake
Copy link
Contributor

comment:9

Karl-Dieter Crisman tried this and it works as expected. Positive review.

@dandrake
Copy link
Contributor

Changed reviewer from Dan Drake to Dan Drake, Karl-Dieter Crisman

@jdemeyer jdemeyer changed the title optional package libogg-1.1.4.spkg causes error upon SAGE_ROOT relocation sage-location doesn't deal with packages after initialize_pkgconfig_files has run Jun 1, 2012
@jdemeyer
Copy link

Merged: sage-5.1.beta4

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

4 participants