#16233 closed defect (fixed)
Leopard environment variable issue remains
Reported by: | ryandesign (Ryan Carsten Schmidt) | Owned by: | macports-tickets@… |
---|---|---|---|
Priority: | Normal | Milestone: | MacPorts 1.7.0 |
Component: | base | Version: | 1.7.0 |
Keywords: | Cc: | afb@…, blb@… | |
Port: |
Description
The Leopard environment variable issue remains even after r36719 and r36722 which were supposed to fix it. The following test is with MacPorts base @39006 on Mac OS X 10.5.4 with Xcode 3.1 on Intel.
Make sure that nmap and py25-numpy are not installed. Then try to install umit, which depends on both.
$ port install umit ---> Fetching nmap ---> Verifying checksum(s) for nmap ---> Extracting nmap ---> Configuring nmap ---> Building nmap ---> Staging nmap into destroot ---> Installing nmap @4.68_0 ---> Activating nmap @4.68_0 ---> Cleaning nmap ---> Fetching py25-numpy ---> Verifying checksum(s) for py25-numpy ---> Extracting py25-numpy ---> Applying patches to py25-numpy ---> Configuring py25-numpy ---> Building py25-numpy Error: Target org.macports.build returned: shell command " cd "/mp/var/macports/build/_Users_rschmidt_macports_dports_python_py25-numpy/work/numpy-1.1.1" && /mp/bin/python2.5 setup.py build " returned error 1 Command output: Running from numpy source directory. non-existing path in 'numpy/distutils': 'site.cfg' F2PY Version 2_5585 blas_opt_info: FOUND: extra_link_args = ['-Wl,-framework', '-Wl,Accelerate'] define_macros = [('NO_ATLAS_INFO', 3)] extra_compile_args = ['-msse3', '-I/System/Library/Frameworks/vecLib.framework/Headers'] lapack_opt_info: FOUND: extra_link_args = ['-Wl,-framework', '-Wl,Accelerate'] define_macros = [('NO_ATLAS_INFO', 3)] extra_compile_args = ['-msse3'] running build running scons customize UnixCCompiler Could not locate executable -fno-strict-aliasing error: Could not find compiler executable info for scons Error: The following dependencies failed to build: py25-gtk py25-cairo py25-numpy py25-sqlite3 Error: Status 1 encountered during processing. $
Cleaning py25-numpy and trying again allows it to proceed.
$ port clean --work py25-numpy ---> Cleaning py25-numpy $ port install umit ---> Fetching py25-numpy ---> Verifying checksum(s) for py25-numpy ---> Extracting py25-numpy ---> Applying patches to py25-numpy ---> Configuring py25-numpy ---> Building py25-numpy ---> Staging py25-numpy into destroot ---> Installing py25-numpy @1.1.1_0 ---> Activating py25-numpy @1.1.1_0 ---> Cleaning py25-numpy ---> Fetching py25-cairo [snip]
Change History (15)
comment:1 follow-up: 5 Changed 16 years ago by blb@…
comment:2 Changed 16 years ago by afb@…
Bugs in Leopard's Tcl are best fixed by Apple, all MacPorts can hope for is workarounds... But it does seem like more of those are needed, since "unset env" is broken and needs working around everywhere.
comment:3 Changed 16 years ago by afb@…
The buggy Darwin component is http://www.opensource.apple.com/darwinsource/10.5.4/tcl-64/, which hasn't been modified since http://www.opensource.apple.com/darwinsource/10.5/tcl-64/
comment:4 Changed 16 years ago by afb@…
MacPorts test case: http://trac.macports.org/browser/trunk/base/src/pextlib1.0/tests/unsetenv.tcl
comment:5 Changed 16 years ago by afb@…
Replying to blb@macports.org:
There are three places where
array unset env
are used:
- macports1.0/macports.tcl fixed in r39016
- port/port.tcl fixed in r39017
- port1.0/portutil.tcl fixed in r36722
comment:6 follow-up: 8 Changed 16 years ago by ryandesign (Ryan Carsten Schmidt)
Anders, you're awesome. That seems to fix it.
My remaining concern is that everywhere we want to unset environment variables now, we have to call two procedures. Can there be a single procedure that takes care of everything we need? Do we still need "array unset env
" now that we have "unsetenv
"? If we do still need both, then it would be good to have a wrapper function which we can call which itself calls both of those.
comment:7 Changed 16 years ago by ryandesign (Ryan Carsten Schmidt)
Bryan, you're awesome too, for the fix suggested in #16010 and for finding where all the issue needed to be fixed. :)
comment:8 Changed 16 years ago by afb@…
Thank you. :-)
We could make an "array_unset_env" wrapper, to call both of them in sequence.
comment:9 Changed 16 years ago by blb@…
Just note that the 'array unset env' is all that should be needed, but until Apple fixes their @%^$, both are needed. We could do a wrapper like afb says, but then again it'd only be needed until tclsh is fixed. On the other hand, it could be 10.6 that fixes it...
comment:10 Changed 16 years ago by afb@…
And of course, having to remember to type "array_unset_env" instead of "array unset env" isn't much easier than remembering to call unsetenv. And since unsetenv requires pextlib to be loaded first, combining the two into a wrapper isn't possible for all uses either. So I think we'll avoid the whole wrapper idea.
comment:11 Changed 16 years ago by afb@…
Still not fixed in http://www.opensource.apple.com/darwinsource/10.5.5/tcl-64/.
Probably waiting for Snow Leopard, so not likely to see any fixes in Leopard...
comment:14 Changed 16 years ago by ryandesign (Ryan Carsten Schmidt)
Resolution: | → fixed |
---|---|
Status: | new → closed |
No problem now! Must've been fixed by the recent improvements.
comment:15 Changed 16 years ago by blb@…
Milestone: | MacPorts base bugs → MacPorts 1.7.0 |
---|
There are three places where
array unset env
are used:Perhaps a good fix for #16010 would fix this as well? I didn't provide a patch there since I wasn't sure if moving the
package require Pextlib 1.0
before the environment handling is a good idea, or if the env handling should be moved after thepackage require
bits, or something else entirely.