Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bump nan to v2 #702

Merged
merged 8 commits into from Sep 16, 2015
Merged

Bump nan to v2 #702

merged 8 commits into from Sep 16, 2015

Conversation

johnhaley81
Copy link
Collaborator

No description provided.

@ssreekanth
Copy link

👍

@tbranyen
Copy link
Member

nodejs/node#2798

@saper
Copy link
Collaborator

saper commented Sep 14, 2015

I think there's nothing node-specific in those failure - it's just a problem with OpenSSL (using clang on FreeBSD here):

../vendor/openssl/openssl/ssl/s3_clnt.c:3262:60: error: use of undeclared identifier 'EVP_PKT_EXP'

https://gist.github.com/01e3c98204e251e8b2d9

@tbranyen
Copy link
Member

@saper we're locked to a copy of openssl that builds just fine using the compilers on Travis-CI, for some reason node-gyp isn't cooperating with it (not sure why it's even affecting it).

@saper
Copy link
Collaborator

saper commented Sep 14, 2015

This particular problem is worked around by #707. It can be applied to master independently.

@tbranyen
Copy link
Member

@saper thanks so much for looking into this, I just rebased your work and changed our test matrix to use Node 4.0 (removing iojs) fingers crossed.

@tbranyen
Copy link
Member

Awesome, looking great on Linux and OS X now. Back to the Windows drawing board :-p

@saper
Copy link
Collaborator

saper commented Sep 14, 2015 via email

@tbranyen
Copy link
Member

@saper Ah I'm referring to the CI, we run Node 0.12 and Node 4.0 in Linux and OS X and both are passing ATM.

@saper
Copy link
Collaborator

saper commented Sep 14, 2015 via email

@tbranyen
Copy link
Member

but it gives me a green check mark 😸

@saper
Copy link
Collaborator

saper commented Sep 15, 2015

https://github.com/saper/nodegit/tree/mynode my attempts to improve the build (esp. with AppVeyor)

@saper
Copy link
Collaborator

saper commented Sep 15, 2015

So Windows failures are caused by the wrong path of the Win32 "delay hook". I have posted nodejs/node-gyp#732 with description.

@saper
Copy link
Collaborator

saper commented Sep 16, 2015

After #717 got merged there, this PR causes note.js tests to fail:

1) Note "before each" hook for "can be created":
     Error: Reference 'refs/remotes/master/HEAD' not found
      at Error (native)

@saper
Copy link
Collaborator

saper commented Sep 17, 2015

can you git clean -dxf and try again?

@ChristianMurphy
Copy link

I ran

git clean -dxf
npm install

on node 4.0 and got same error, checking on 4.1 now

EDIT:
Node 4.1 has same message

@njj
Copy link

njj commented Sep 17, 2015

Everything works for me by cloning this repo into my node_modules and manually running npm install inside the repo.

@saper
Copy link
Collaborator

saper commented Sep 17, 2015 via email

@ChristianMurphy
Copy link

@saper @tbranyen
Okay when I clone nodegit using git and build, it builds correctly.
If I download latest using NPM from "nodegit/nodegit" and it tries to build from there, the build fails with the libssh2 error.

@tbranyen
Copy link
Member

I'm not sure why that would be, maybe try specifying the latest SHA.

@ChristianMurphy
Copy link

I tried "nodegit/nodegit#60e3f2aff7be57afb8d76d5e9adbf0b2459a6232" as well same result

@maxkorp
Copy link
Collaborator

maxkorp commented Sep 17, 2015

Ooh, do you have openssl-dev or whatever it's called installed? IIRC that's required to configure libssh2, which is what appears to be dying. I know it usually gets installed with most build-chains in ubuntu, but it's very plausible it didn't for you.

@saper
Copy link
Collaborator

saper commented Sep 17, 2015 via email

@maxkorp
Copy link
Collaborator

maxkorp commented Sep 17, 2015

@saper Really? I've used that to great success. That's unfortunate if so.

I know they have a lot of issues with build lifecycle with nodegit manually works around currently though, and that seems to just go in a loop of "so why do we need this". Don't think they gave up on that at least.

@saper
Copy link
Collaborator

saper commented Sep 17, 2015 via email

@maxkorp
Copy link
Collaborator

maxkorp commented Sep 17, 2015

Yeah I've been shaving those down bit by bit as I get the chance. If I could find a good gypfile for libssh2, we could remove them almost entirely.

@saper
Copy link
Collaborator

saper commented Sep 17, 2015 via email

@maxkorp
Copy link
Collaborator

maxkorp commented Sep 17, 2015

Yeah, I know. Very unfortunate, really :/
I've found one or two that seem to work cross platform for smaller applications, but no idea how tested they are etc. We can't get rid of the lifecyclescirpts without getting rid of the autoconf, though.

@ChristianMurphy
Copy link

@maxkorp

you have openssl-dev or whatever it's called installed?

I have openssl, libssl-dev and libssh-dev installed my system.

@ChristianMurphy
Copy link

git fetching is very tricky to get right. I think npm gave up in fixing this.

@saper

I checked my file system and it appears that NPM did fetch the correct version of the code down.

I'm wondering if possibly pulling the code from Git using NPM might trigger the .npmignore instead of the .gitignore and leave out a file needed to build.

@maxkorp
Copy link
Collaborator

maxkorp commented Sep 17, 2015

It will respect both the .gitignore AND the .npmignore, ignoring anything specified by either (but explicit includes from one, will not override excludes by the other). That said, that was never a problem before.
#715 may be related however.

@saper
Copy link
Collaborator

saper commented Sep 17, 2015 via email

@maxkorp
Copy link
Collaborator

maxkorp commented Sep 17, 2015

Oh totally. Not a fan either. Do note however that it was npm install --ignore-scripts which prevents anything from calling lifecyclescripts (blocking an infinite recursion)`. We can dig into this in the other issue if needed though. (if we can confirm that it is an issue)

@saper
Copy link
Collaborator

saper commented Sep 17, 2015

@ChristianMurphy can you try #726

npm install 'git://github.com/saper/nodegit#configurestays'

It lets me to go past the configure step.

Why the hell our beautiful code full of promises is unable to produce an error message
that configure is missing:

[nodegit] Configuring libssh2.
npm WARN unmet dependency /home/saper/node_modules/node-sass requires nan@'^2.0.8' but will load
npm WARN unmet dependency /home/saper/node_modules/nan,
npm WARN unmet dependency which is version 2.0.5
npm WARN unmet dependency /home/saper/node_modules/node-sass requires request@'^2.61.0' but will load
npm WARN unmet dependency /home/saper/node_modules/request,
npm WARN unmet dependency which is version 2.55.1
nodegit@0.4.1 nodegit
├── promisify-node@0.2.1
├── which-native-nodish@1.1.3 (find-parent-dir@0.3.0, nodegit-promise@1.0.2)
├── nodegit-promise@3.0.2 (asap@2.0.3)
├── fs-extra@0.18.4 (jsonfile@2.2.2, graceful-fs@3.0.8, rimraf@2.4.3)
├── node-pre-gyp@0.6.10
└── npm@2.14.3

Not to mention it would be nice to return an error code so that npm stops. Also #713.

@ChristianMurphy
Copy link

@saper installing from git://github.com/saper/nodegit#configurestays succeeded 🎉

@saper
Copy link
Collaborator

saper commented Sep 17, 2015 via email

@ssreekanth
Copy link

@saper Is the nodegit build working on windows now?

I tried installing from

nodegit/nodegit#330abdb21dc3619c495bb4e975563fab1561659d

but still failing on windows -

npm ERR! nodegit@0.4.1 install: `node lifecycleScripts/install`
npm ERR! Exit status 13

However, on Linux/OSX, it works fine.

@saper
Copy link
Collaborator

saper commented Sep 18, 2015

@ssreekanth This is means that the compilation failed. Do you get anything more than that? Error messages from the compiler?

@ssreekanth
Copy link

@saper These are the error messages I got -

[nodegit] Everything is ready to go, attempting compilation
[nodegit] Building native node module.
{ [Error: Command failed: C:\Windows\system32\cmd.exe /s /c "SET HOME=%HOME%\.atom-shell-gyp&&  C:\Users\sandbox\nodegit-test\node_modules\nodegit\node_modules\.bin\node-gyp rebuild --target=0.33.0  --dist-url=https://gh-contractor-zcbenz.s3.amazonaws.com/atom-shell/dist"
gyp ERR! build error
gyp ERR! stack Error: `C:\Program Files (x86)\MSBuild\12.0\bin\msbuild.exe` failed with exit code: 1
gyp ERR! stack     at ChildProcess.onExit (C:\Users\sandbox\nodegit-test\node_modules\nodegit\node_modules\node-gyp\lib\build.js:270:23)
gyp ERR! stack     at emitTwo (events.js:87:13)
gyp ERR! stack     at ChildProcess.emit (events.js:172:7)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:200:12)
gyp ERR! System Windows_NT 6.1.7601
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\sandbox\\nodegit-test\\node_modules\\nodegit\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild" "--target=0.33.0" "--dist-url=https://gh-contractor-zcbenz.s3.amazonaws.com/atom-shell/dist"
gyp ERR! cwd C:\Users\sandbox\nodegit-test\node_modules\nodegit
gyp ERR! node -v v4.1.0
gyp ERR! node-gyp -v v3.0.3
gyp ERR! not ok
]
  killed: false,
  code: 1,
  signal: null,
  cmd: 'C:\\Windows\\system32\\cmd.exe /s /c "SET HOME=%HOME%\\.atom-shell-gyp&&  C:\\Users\\sandbox\\nodegit-test\\node_modules\\nodegit\\node_modules\\.bin\\node-gyp rebuild --target=0.33.0  --dist-url=https://gh-contractor-zcbenz.s3.amazonaws.com/atom-shell/dist"' }
undefined
npm ERR! Windows_NT 6.1.7601
npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install"
npm ERR! node v4.1.0
npm ERR! npm  v2.14.3
npm ERR! code ELIFECYCLE

npm ERR! nodegit@0.4.1 install: `node lifecycleScripts/install`
npm ERR! Exit status 13
npm ERR!
npm ERR! Failed at the nodegit@0.4.1 install script 'node lifecycleScripts/install'.
npm ERR! This is most likely a problem with the nodegit package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     node lifecycleScripts/install
npm ERR! You can get their info via:
npm ERR!     npm owner ls nodegit
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR!     C:\Users\sandbox\nodegit-test\npm-debug.log

And my package.json is

{
  "name": "Sample",
  "version": "1.0.0",
  "description": "",
  "main": "main.js",
  "scripts": {
    "test": "echo \"Error: no test specified\" && exit 1"
  },
  "engines": {
    "atom-shell": "0.33.0",
    "electron": "0.33.0"
  },
  "dependencies": {
    "nodegit": "nodegit/nodegit#330abdb21dc3619c495bb4e975563fab1561659d"
  },
  "devDependencies": {
    "electron-prebuilt": "0.33.0",
    "electron-rebuild": "^1.0.0"
  }
}

@saper
Copy link
Collaborator

saper commented Sep 20, 2015

@ssreekanth Can you check if #729 fixes the issue.

@ssreekanth
Copy link

@saper it is still failing with #729 ..

[nodegit] Everything is ready to go, attempting compilation
[nodegit] Building native node module.
{ [Error: Command failed: C:\Windows\system32\cmd.exe /s /c "C:\Users\sandbox\nodegit-test\node_modules\nodegit\node_modules\.bin\node-gyp rebuild --target=0.33.0  --dist-url=https://gh-contractor-zcbenz.s3.amazonaws.com/atom-shell/dist"
gyp ERR! build error
gyp ERR! stack Error: `C:\Program Files (x86)\MSBuild\12.0\bin\msbuild.exe` failed with exit code: 1
gyp ERR! stack     at ChildProcess.onExit (C:\Users\sandbox\nodegit-test\node_modules\nodegit\node_modules\node-gyp\lib\build.js:270:23)
gyp ERR! stack     at emitTwo (events.js:87:13)
gyp ERR! stack     at ChildProcess.emit (events.js:172:7)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:200:12)
gyp ERR! System Windows_NT 6.1.7601
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\sandbox\\nodegit-test\\node_modules\\nodegit\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild" "--target=0.33.0" "--dist-url=https://gh-contractor-zcbenz.s3.amazonaws.com/atom-shell/dist"
gyp ERR! cwd C:\Users\sandbox\nodegit-test\node_modules\nodegit
gyp ERR! node -v v4.1.0
gyp ERR! node-gyp -v v3.0.3
gyp ERR! not ok
]
  killed: false,
  code: 1,
  signal: null,
  cmd: 'C:\\Windows\\system32\\cmd.exe /s /c "C:\\Users\\sandbox\\nodegit-test\\node_modules\\nodegit\\node_modules\\.bin\\node-gyp rebuild --target=0.33.0  --dist-url=https://gh-contractor-zcbenz.s3.amazonaws.com/atom-shell/dist"' }
undefined
npm ERR! Windows_NT 6.1.7601
npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install" "nodegit"
npm ERR! node v4.1.0
npm ERR! npm  v2.14.3
npm ERR! code ELIFECYCLE

npm ERR! nodegit@0.4.1 install: `node lifecycleScripts/install`
npm ERR! Exit status 13

@deyhle
Copy link

deyhle commented Sep 20, 2015

When will this be released to npm?

@johnhaley81
Copy link
Collaborator Author

@deyhle it's out now as 0.5.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

9 participants