> On 21 Feb 2022, at 17:06, Ryan Schmidt <[email protected]> wrote: > > On Feb 19, 2022, at 11:06, Gerben Wierda wrote: > >> But how does one (a) find out the dependency exists and (b) make sure the >> software finds python from MacPorts? > > General-purpose answers to either question are not possible. Each affected > port will need to be investigated and fixed in its own unique way. > > /usr/bin/python might be used > > * directly by the Portfile specifying /usr/bin/python somewhere > * in a patchfile that references /usr/bin/python explicitly > * as a shebang line (e.g. "#!/usr/bin/python" or "#!/usr/bin/env python") in > files used by the port at build time and/or installed by the port > * by a build system that uses the first binary it finds named "python" > * in unknowable other ways > > To tell the build system to use a particular python, one might need to > > * set the PYTHON environment variable at configure time -- this is > accomplished by setting the configure.python option > * specify some other configure environment variable or argument > * patch files > * do something else
For a test I was planning to adapt the migration approach. Save the ‘requested’ list. Uninstall all ports. Temporary mv /usr/bin/python out of the way. Build the requested list. I can do this on a secondary system. This would tell me at least that the ports I have installed all install without /usr/bin/python, which takes care of any build dependencies. Gerben Wierda (LinkedIn <https://www.linkedin.com/in/gerbenwierda>) R&A IT Strategy <https://ea.rna.nl/> (main site) Book: Chess and the Art of Enterprise Architecture <https://ea.rna.nl/the-book/> Book: Mastering ArchiMate <https://ea.rna.nl/the-book-edition-iii/>
