[MacPorts] #64556: ncpp: fetch fails on newer OS versions when git is not installed

MacPorts noreply at macports.org
Fri Jan 28 20:29:04 UTC 2022


#64556: ncpp: fetch fails on newer OS versions when git is not installed
------------------------+----------------------
 Reporter:  ryandesign  |      Owner:  mf2k
     Type:  defect      |     Status:  assigned
 Priority:  Normal      |  Milestone:
Component:  ports       |    Version:  2.7.1
 Keywords:              |       Port:  ncpp
------------------------+----------------------
 The ncpp portfile contains:

 {{{
 fetch {
     # I don't see any provisions for git submodules in MacPorts, so we
 have to clone by hand:
     if {![file exists ${workpath}/${worksrcdir}]} {
         system "${prefix}/bin/git clone --recursive ${git.url}
 ${workpath}/${worksrcdir}"
     }
     system -W ${workpath}/${worksrcdir} "${prefix}/bin/git checkout -q
 ${git.branch}"
 }
 }}}

 It's true tht MacPorts contains no particular support for fetching git
 submodules, but you're not meant to need to override the entire fetch
 phase. Check
 [https://guide.macports.org/#reference.portgroup.github.submodule the
 guide] for the currently recommended procedure for submodules.

 The port also currently fails to fetch on newer OS versions because your
 fetch block uses `${prefix}/bin/git`:

 https://build.macports.org/builders/ports-
 12_arm64-builder/builds/41556/steps/install-port/logs/stdio

 {{{
 sh: /opt/local/bin/git: No such file or directory
 }}}
 MacPorts only adds a dependency on port:git on older systems whose system
 git versions are too old to fetch from GitHub. To accommodate either
 MacPorts git if present or system git if not, your commands should use
 just `git` not `${prefix}/bin/git`.

-- 
Ticket URL: <https://trac.macports.org/ticket/64556>
MacPorts <https://www.macports.org/>
Ports system for macOS


More information about the macports-tickets mailing list