-
Notifications
You must be signed in to change notification settings - Fork 254
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
Precompiled binary support #407
Conversation
Updated to libxmljs 0.17.1 and everything compiles fine on Windows. The issue now is that the The doctype base URL issue should be easy to debug. For some reason libxml is having trouble resolving the relative path to the doctype declaration file. I'm not sure why Node 0.10 abruptly exits at some point during the test. Something must be causing a segfault. This issue might be harder to solve. |
Note: Prior to updating my branch to 0.17.1, libxmljs compiled fine on all versions of Node and all tests ran successfully. |
squash commits |
@polotek can you setup appveyor? or add us as administrators on this repo so we can do it? or move the repo to one of our accounts? |
@defunctzombie @polotek I put all the configuration info that AppVeyor needs to build libxmljs into the config file, so it should be as simple as creating an AppVeyor account and pointing it to this GitHub Repo. Before we merge this PR in, I'd like to see all the AppVeyor builds/tests passing first. Maybe I should create a separate pull request that fixes the original build problem on windows ( I thought that this PR was good to go before I updated to 0.17.1 and ran into these issues. Other Windows users may have the same issues I mentioned earlier about the tests not passing and crashing in early versions of Node. That being said, libxmljs would at least build on Windows with the correct #ifdef's merged in a separate PR. |
Also, if the libxml version bump is causing the instability issues on Windows, then it will probably take more time solve these issues. Alternatively, we could disable the unit testing on AppVeyor and just use the Windows build status/binary uploading as-is. |
Is this discrepancy intentional?
Should this be 2015 in the install call as well? |
@gagern It's there to ensure that it will compile on older versions as well. I've changed the config to do this via an environment variable instead. The issue where the test suite seemed to be crashing was actually this. All the tests are working fine, it's just that there's an issue with nodeunit in Windows where the output can be cut off. Now I just need to resolve the failing DTD baseUrl test. |
@@ -56,6 +56,12 @@ module.exports.recoverable_parse = function(assert) { | |||
}; | |||
|
|||
module.exports.baseurl_xml = function(assert) { | |||
if (/^win/.test(process.platform)) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
NOTE: Ignoring the baseurl_xml
test on Windows until we find out why libxml isn't resolving the relative path.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there a bug report to track this? If so it would be nice to see its number cross referenced, perhaps both here in the discussion and in the source code comment.
The @defunctzombie @gagern I just need to squash the commits and make sure the builds all succeed. Then this PR should be ready for review and possible release into 0.17.2. |
@@ -1,6 +1,8 @@ | |||
# Libxmljs | |||
[![Build Status](https://secure.travis-ci.org/polotek/libxmljs.svg?branch=master)](http://travis-ci.org/polotek/libxmljs) | |||
|
|||
[![AppVeyor Build Status](https://ci.appveyor.com/api/projects/status/cf862a98w7qsajpl?svg=true)](https://ci.appveyor.com/project/rchipka/libxmljs) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
will need to reference this repo url right?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is the link to the polotek/libxmljs builds on my account. You, or anyone else for that matter, can create an AppVeyor account, point it to this repo, and it'll build and test exactly the same.
So it doesn't really matter which or how many different AppVeyor accounts point to this repo, as long as we link to one of them we'll have a badge and a link to the build/test logs.
You or I could create an AppVeyor account named "libxmljs" or "polotek" and then email the credentials to @polotek. That way he owns the AppVeyor account in the Readme.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome. As long as it works, good with me. Will it automatically build when we push new code?
As soon as @polotek adds an AppVeyor webhook, it will build for all branches and only upload binaries when there's tagged commit on the master branch. The badge shows the current build status of the master branch. The webhook URL for "polotek/libxmljs" on my account is https://ci.appveyor.com/api/github/webhook?id=cf862a98w7qsajpl |
@rchipka we've moved the repo to a new libxmljs organization. This will let us all manage it better. Let me know what I need to setup on the repo webhook wise to get the builds going. |
@defunctzombie Should be the same process. Project settings -> Webhooks -> Add Webhook. From there just put in the previously mentioned webhook URL and then you can choose which messages it will receive (commits, etc.) |
@rchipka which messages should it receive? |
@defunctzombie I believe it works fine if you check "Just the push event" |
@rchipka added |
"module_name" : "xmljs", | ||
"module_path" : "./build/Release/", | ||
"host" : "https://github.com", | ||
"remote_path" : "./polotek/libxmljs/releases/download/v{version}/", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
probably should be updated or org path now
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
update the repo and bugs url while you're in here since we moved the repo
LGTM |
@@ -0,0 +1,87 @@ | |||
environment: | |||
github_release_token: | |||
secure: en/UnoFHA3RsSAHM5c6zb3RAMa4V01lC3pYG1YrHSeOPFu78SUA/0lOjNe3pp8RG |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is this something that should be secret?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nope, this string is encrypted using AppVeyor's secure variables feature.
@polotek If you'd like AppVeyor to also build/test each pull request you have to enable the "pull request" event in the webhook settings. So "push" and "pull request" should be checked. |
This is good to merge for now. The discussed Windows issues/improvements can be made once we have a working Windows release. |
Any updates on this, by chance? |
@fafnirical Still good to merge as far as I'm concerned. |
Bump. Not only do I need this, but I'm waiting to see if it works so that I can do the moral equivalent in a couple of other packages. |
Merging because:
|
@rchipka why not use node-pre-gyp-github within appveyor.yml ps section so that the command to upload the binary will be cross platform? This will make it easier in the future to add precompiled binary support to Linux one day which in my opinion is important too? |
This pull request addresses issue #395 by uploading Windows binaries to GitHub Releases. If a user installs libxmljs on Windows, node-pre-gyp will use one of the precompiled binaries.
This also fixes issue #392 and adds AppVeyor CI testing for Windows builds.