-
Notifications
You must be signed in to change notification settings - Fork 30k
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
upgrade gyp and refactor openssl.gyp #723
Conversation
The changes look reasonable to me, let's see what the CI thinks: https://jenkins-iojs.nodesource.com/view/iojs/job/iojs+any-pr+multi/149/ I noticed that OS X 10.10 seems unhappy right from the start: https://jenkins-iojs.nodesource.com/view/iojs/job/iojs+any-pr+multi/149/nodes=osx1010/console |
I'm fine with update, except some (mostly) style nits. |
armv6/7 and freebsd failures appear unrelated. |
@bnoordhuis @indutny Thanks for your review. I can reproduce the configure error on my MacOS by uninstalling XCode and using only command line tools. Probably it comes from a upstream bug. I continue to investigate it. |
Filed the gyp issues without XCode on MacOS to the upstream in https://code.google.com/p/gyp/issues/detail?id=477 |
I thought that @indutny's gyp patch addressed that? Or is that something else? |
The bug seems to be introduced in https://code.google.com/p/gyp/source/detail?r=1863 which was about 3 months later from the last @indutny 's gyp commit of a05dae2 . I think this is a new one. |
@bnoordhuis should we land it? |
@bnoordhuis @indutny No reply from upstream until now. I've just made 1ee5b6d for a tentative fix of gyp. How is this? |
Can we get a new run on jenkins please? |
don't trust the windows results on run 222, this PR needs to be rebased against v1.x to get the vcbuild.bat updates to make that run the tests properly. |
`therefor` is a typo of `therefore`, and was fixed. There were also two places where the website WG was directly linked, where they should have put the WG's name/repo; that was fixed as well. PR-URL: nodejs#1022 Reviewed-By: Mikeal Rogers <mikeal.rogers@gmail.com> Reviewed-By: Christian Tellnes <christian@tellnes.no>
Updated gyp has "else if" syntax in condition. Use this for target_arch and OS switches. Several defines, rules and libraries variables moved to openssl.gypi
This issue has already submitted to the upstream in https://code.google.com/p/gyp/issues/detail?id=477 Use this commit until the upstream is to be fixed.
@rvagg I've just rebased it. Could you please run tests again? |
@shigeki I was tinkering earlier today and I think it'll need more advanced work for armv8, I can build it if I run a |
@rvagg Yes, there seems to have an issue of
|
Yeah, configure needs some work, it's all |
@shigeki does this help at all? https://gist.github.com/rvagg/3ab9a1a7e16b576caef5 the Makefile and opensslconf.h created by Currently we only have This currently is my diff for configure: diff --git a/configure b/configure
index d632326..9f237ff 100755
--- a/configure
+++ b/configure
@@ -403,6 +403,11 @@ def cc_macros():
k[key] = val
return k
+def is_arch_arm64():
+ """Check for ARMv8-64 instructions"""
+ cc_macros_cache = cc_macros()
+ return ('__aarch64__' in cc_macros_cache)
+
def is_arch_armv7():
"""Check for ARMv7 instructions"""
@@ -439,6 +444,7 @@ def host_arch_cc():
'__x86_64__' : 'x64',
'__i386__' : 'ia32',
'__arm__' : 'arm',
+ '__aarch64__' : 'arm',
'__mips__' : 'mips',
}
@@ -476,7 +482,11 @@ def configure_arm(o):
else:
arm_float_abi = 'default'
- if is_arch_armv7():
+ if is_arch_arm64():
+ o['variables']['arm_fpu'] = 'vfpv4'
+ o['variables']['arm_version'] = '8'
+ elif is_arch_armv7():
o['variables']['arm_fpu'] = 'vfpv3'
o['variables']['arm_version'] = '7'
else: |
@rvagg Thanks. Seeing your gist, I'm very surprised at OpenSSL in armv8 was configured as |
@shigeki not so simple because it's behind a jump-host on the Linaro cluster. I might be able to set up a tunnel for you to work with but I'd better check out the Linaro terms before I go doing that! Leave it with me, in the mean time feel free to make branches on your io.js fork and point me to them to try out. |
@rvagg Okay, I'll make an another branch to work on armv8. |
This is a patch from @rvagg in nodejs#723 (comment)
In #1028 , a new target-cpu of |
@shigeki wouldn't this branch patch that away once it's working as intended? |
@jbergstroem Sure. Closing this for now and I will submit a new PR. |
Just to be clear, I didn't mean that you had to close the issue - just that openssl support for that architecture was disabled because it was broken, and the fact that your patch would make it work again. |
@jbergstroem Thanks for clarification. I will create an another branch and submit a new PR after solving of gyp bug and arm64 support because there are too much rebases now. |
My gyp fix was also asked to the gyp-developer mailing list in https://groups.google.com/d/msg/gyp-developer/G3pVpn7lDpo/W2H87C9IwksJ |
A new branch is https://github.com/shigeki/io.js/tree/upgrade_gyp_refactor_openssl_gyp with supporting arm64 with no-asm openssl-1.0.1. PR will be submitted after resolving spawnSync issue on arm64. |
I would like to use openssl-1.0.2 on iojs but openssl.gyp is so large and complicated that I think it need some refactoring before updating to openssl-1.0.2.
This PR has the following commits as
Testing is hard to confirm this in all platforms. I made two tests as below.
WIP branch for openssl102 is in https://github.com/shigeki/io.js/tree/WIP_upgrade_openssl102 . It's working on only x86_64 of Linux and MacOSX.
CC: @bnoordhuis @indutny