[MacPorts] #67055: python portgroup overwrites PYTHONPATH in test.env
MacPorts
noreply at macports.org
Tue Mar 14 00:49:31 UTC 2023
#67055: python portgroup overwrites PYTHONPATH in test.env
----------------------+------------------------
Reporter: dgilman | Owner: reneeotten
Type: defect | Status: assigned
Priority: Normal | Milestone:
Component: ports | Version:
Resolution: | Keywords:
Port: |
----------------------+------------------------
Comment (by jmroot):
My suggested fix would be something like this:
{{{#!diff
--- a/_resources/port1.0/group/python-1.0.tcl
+++ b/_resources/port1.0/group/python-1.0.tcl
@@ -572,5 +572,8 @@ pre-livecheck {
pre-test {
# set PYTHONPATH
- test.env-append PYTHONPATH=[join [glob -nocomplain
${worksrcpath}/build/lib*] :]
+ set libdirs [glob -nocomplain -directory ${worksrcpath}/build lib*]
+ if {$libdirs ne "" && [lsearch ${test.env} PYTHONPATH=*] == -1} {
+ test.env-append PYTHONPATH=[join $libdirs :]
+ }
}
}}}
--
Ticket URL: <https://trac.macports.org/ticket/67055#comment:9>
MacPorts <https://www.macports.org/>
Ports system for macOS
More information about the macports-tickets
mailing list