Code Monkey home page Code Monkey logo

Comments (7)

TooTallNate avatar TooTallNate commented on May 16, 2024

Could you try updating to node v0.6.14?

from node-gyp.

renaudleo avatar renaudleo commented on May 16, 2024

Seems to do the trick, sorry about that!

from node-gyp.

TooTallNate avatar TooTallNate commented on May 16, 2024

No worries :)

from node-gyp.

JackWells avatar JackWells commented on May 16, 2024

Ok - looks like the same problem, but I am using node v0.6.14I

I also tried with v0.6.15 first and downgraded to .14 after reading this thread. Same error either way. All ideas appreciated.
I have updated node-gyp successfully.

spawn python [ '/root/.node-gyp/0.6.14/tools/gyp_addon',
'binding.gyp',
'-I/usr/local/src/node/node-v0.6.14/node_modules/contextify/build/config.gypi',
'-f',
'make' ]
Traceback (most recent call last):
File "/root/.node-gyp/0.6.14/tools/gyp_addon", line 14, in ?
import gyp
File "/root/.node-gyp/0.6.14/tools/gyp/pylib/gyp/init.py", line 8, in ?
import gyp.input
File "/root/.node-gyp/0.6.14/tools/gyp/pylib/gyp/input.py", line 14, in ?
import gyp.common
File "/root/.node-gyp/0.6.14/tools/gyp/pylib/gyp/common.py", line 373
with open(source_path) as source_file:
^
SyntaxError: invalid syntax
ERR! Error: gyp_addon failed with exit code: 1
at Array.0 (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/configure.js:196:18)
at EventEmitter._tickCallback (node.js:192:40)
ERR! not ok

ERR! [email protected] install: node-gyp rebuild
ERR! sh "-c" "node-gyp rebuild" failed with 1
ERR!
ERR! Failed at the [email protected] install script.
ERR! This is most likely a problem with the contextify package,
ERR! not with npm itself.
ERR! Tell the author that this fails on your system:
ERR! node-gyp rebuild
ERR! You can get their info via:
ERR! npm owner ls contextify
ERR! There is likely additional logging output above.
ERR!
ERR! System Linux 2.6.18-274.17.1.el5xen
ERR! command "node" "/usr/local/bin/npm" "install" "contextify"
ERR! cwd /usr/local/src/node/node-v0.6.14
ERR! node -v v0.6.14
ERR! npm -v 1.1.12
ERR! code ELIFECYCLE
ERR! message [email protected] install: node-gyp rebuild
ERR! message sh "-c" "node-gyp rebuild" failed with 1
ERR! errno {}
verbose exit [ 1, true ]

from node-gyp.

TooTallNate avatar TooTallNate commented on May 16, 2024

@JackWells Update to python v2.7

from node-gyp.

JackWells avatar JackWells commented on May 16, 2024

Yes, thanks - I discovered that too from "invalid syntax" - should have seen that sooner. Unfortunately, CentOS requires separate installs of newer Pythons to avoid breaking things. The "latest default" is 2.4.

After trying many ln likings to try to fool it (that didn't work), I ended up moving the "default" python to /tmp, making a link there to python26, running the install, then putting everything back. To the next CentOS-er who finds this, that will work, though I am sure there is a more elegant solution.

from node-gyp.

TooTallNate avatar TooTallNate commented on May 16, 2024

If you have another (newer) version of Python installed you can pass the PYTHON=python26 env variable or --python=python26 switch to specify a different python executable.

$ PYTHON=python26 node-gyp configure build
$ node-gyp configure build --python=python26

from node-gyp.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.