This line: > lib/node_modules/npm/node_modules/node-gyp/lib/configure.js: var python = gyp.opts.python || process.env.PYTHON || 'python2' defaults to the wrong python executable name: python2 It should be python2.7 This causes failures like this: > gyp ERR! configure error > gyp ERR! stack Error: Can't find Python executable "/usr/local/bin/python2", you can set the PYTHON env variable.
@Yuri This is a blanket candidate: Approved by: portmgr (blanket: ports/framework (python) compliance)
(In reply to Kubilay Kocak from comment #1) Thanks, Kubilay! Fix committed.
A commit references this bug: Author: yuri Date: Wed May 29 08:18:07 UTC 2019 New revision: 502940 URL: https://svnweb.freebsd.org/changeset/ports/502940 Log: www/npm: Fix the python executable name PR: 238204 Reported by: run failure Approved by: portmgr (blanket: ports/framework (python) compliance) Changes: head/www/npm/Makefile head/www/npm/files/patch-lib_node__modules_npm_node__modules_node-gyp_lib_configure.js
No MFH?
A commit references this bug: Author: koobs Date: Mon Jul 1 07:02:27 UTC 2019 New revision: 505545 URL: https://svnweb.freebsd.org/changeset/ports/505545 Log: MFH: r502940 r503843 www/npm: Fix the python executable name PR: 238204 Reported by: run failure Approved by: portmgr (blanket: ports/framework (python) compliance) Compile and install .pyc files for node-gyp - Bump PORTREVISION for package change PR: 238243 Submitted by: Hiroki Tagato <tagattie@yandex.com> Approved by: ports-secteam (blanket(s): run/packaging fix, ports (python) compliance) Changes: _U branches/2019Q2/ branches/2019Q2/www/npm/Makefile branches/2019Q2/www/npm/files/patch-lib_node__modules_npm_node__modules_node-gyp_lib_configure.js branches/2019Q2/www/npm/pkg-plist
Merged to 2019Q2 (quarterly)
This patch was apparently deleted by ports r505851. I was trying to get rails 6.0 working and it was very confusing! 'export PYTHON=python2.7' before 'rails new app' is a workaround. This bug should probably be reopened.
Actually, since rails seems to install multiple ruby and node packages on its own, I'll let the www/rails60 maintainer know about what happened, it's not clear that this bug needs to be reopened at this time.