Opened 13 years ago
Closed 9 years ago
#32581 closed defect (fixed)
reduce-algebra: don't break when runtime OS version != build-time OS version
Reported by: | ryandesign (Ryan Carsten Schmidt) | Owned by: | mbrethen |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 2.0.3 |
Keywords: | haspatch | Cc: | kurthindenburg (Kurt Hindenburg) |
Port: | reduce-algebra |
Description
If the version of OS X changes (even a minor version, for example updating from 10.7.2 to 10.7.3), redpsl no longer runs:
$ /opt/local/libexec/reduce-algebra/bin/redpsl Failed to find a version of bpsl that you have built try ./configure --with-psl; make to build one.
This is because at build time, it runs its copy of config.guess to determine the OS name and full version, and uses that in a directory name that gets installed. Then at runtime, it again runs that config.guess to find the directory. config.guess returns the running OS's name and version, so this fails if the OS version at build time is different from the OS version at runtime. This is also significant if the user receives a pre-compiled binary built by our buildbot, because the buildbot's version of OS X might not be identical to the user's.
The attached patch is one way we could fix this.
Attachments (1)
Change History (6)
Changed 13 years ago by ryandesign (Ryan Carsten Schmidt)
Attachment: | reduce-algebra-config.guess.diff added |
---|
comment:1 Changed 13 years ago by mbrethen@…
This won't work; config-guess returns 'x86_64-apple-darwin11.2.0' but reduce build uses 2 scripts: findos.sh and findhost.sh in /scripts to create the directory name (e.g. 'x86_64-mac_10.7_lion-darwin11.2.0').
comment:2 Changed 13 years ago by ryandesign (Ryan Carsten Schmidt)
As far as I can tell my fix should work correctly. My patch replaces the config.guess that gets installed with a simple script that echoes the value config.guess had at build time. At runtime, findos.sh and findhost.sh will call that modified script and thus be able to find the directory by the name it has, even if the OS version has since changed.
comment:3 Changed 13 years ago by mbrethen@…
You're right, I didn't look at it that way before. In effect, you're just saving a "snapshot" of the current system for future reference.
I'm currently looking at the linux install setup and think we can circumvent the need for config.guess entirely, as well as a wrapper in ${prefix}/bin.
comment:5 Changed 9 years ago by kurthindenburg (Kurt Hindenburg)
Resolution: | → fixed |
---|---|
Status: | new → closed |
replaced_by reduce - if I understand the issue, it looks like this patch was basically added to the Portfile.
proposed patch