Opened 9 years ago

Closed 9 years ago

#12331 closed defect (duplicate)

updating an spkg may render Sage non-relocatable

Reported by: jhpalmieri Owned by: leif
Priority: minor Milestone: sage-duplicate/invalid/wontfix
Component: scripts Keywords: location pkgconfig
Cc: Merged in:
Authors: Reviewers: Jeroen Demeyer
Report Upstream: N/A Work issues:
Branch: Commit:
Dependencies: Stopgaps:

Status badges

Description

Here's an issue possibly arising from #11760: suppose you

  • build and run Sage, so sage-location has been run.
  • then install a new spkg, say python or gsl, which creates a file in local/lib/pkgconfig

That newly created file never gets initialized by sage-location, so it doesn't have a definition of SAGE_ROOT in it, so it never gets updated. So the resulting Sage build might not be relocatable. This is related to these comments in the sage-location script:

    # There's no definition of SAGE_ROOT in the .pc file at all.
    # This should never happen, unless the user modified the file.

and

    # We could of course call initialize_pkgconfig_file(filename)
    # here instead to fix this issue, but unfortunately there's no
    # such function (for a single file) [yet].

Change History (2)

comment:1 Changed 9 years ago by leif

Pinging myself...

In principle, spkgs should properly "initialize" their .pc files by themselves, but analoguous to sage-make_relative(?), sage-spkg could do that as well. (I was thinking of moving the code -- of course rewritten as a simple shell function -- there a long time ago.)

But [regarding the typically endless review process] it's probably easier to rewrite / enhance the code we have where it is; I do have an editor window open with that since a couple of weeks, when IIRC Justin once again ran into and reported this issue on sage-release.

comment:2 Changed 9 years ago by jdemeyer

  • Milestone changed from sage-5.4 to sage-duplicate/invalid/wontfix
  • Resolution set to duplicate
  • Reviewers set to Jeroen Demeyer
  • Status changed from new to closed

Duplicate of #12076. And there is also #13452 which fixes this in a better way.

Note: See TracTickets for help on using tickets.