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
Add appveyor.yml for Windows CI #623
Conversation
@@ -67,7 +67,11 @@ ELSE() | |||
ADD_COMPILE_FLAG("-Wextra") | |||
ADD_COMPILE_FLAG("-Wno-unused-parameter") | |||
ADD_COMPILE_FLAG("-fno-omit-frame-pointer") | |||
ADD_COMPILE_FLAG("-fPIC") | |||
IF(WIN32) | |||
ADD_COMPILE_FLAG("-D_GNU_SOURCE") |
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.
Without it, MinGW job fails at 76% like https://ci.appveyor.com/project/jasonwilliams200OK/binaryen/build/1.0.36/job/36pvx89h7g52g09n#L110.
Ok, I logged into appveyor, but I'm not sure where to find the dropdown you mention? |
When you log on with GitHub Account, it would show a dropdown menu to select organization before proceeding to dashboard (given you are a member of WebAssembly org on GitHub). |
It's all green now https://ci.appveyor.com/project/jasonwilliams200OK/binaryen/build/1.0.37 😄 |
Hmm, I logged in with my github account, but I just get sent to what I guess is the dashboard (a big mostly empty page with "Welcome to your new AppVeyor account!" If I try to create a new project it asks for more oath permissions (admin access to webhooks etc.) and has a bunch of options there. Is that the right thing? |
This is how it appears to me: Before login: After login with GitHub account: When I select the organization name from the drop down menu and press GitHub button again on the second screen, it takes me to https://ci.appveyor.com/projects where it lists the projects of this organization which are being monitored by AppVeyor. If it is some existing project which hasn't been configured yet, then we press the New Project button on top and list GitHub, BitBucket and so on in the left menu and the available projects in the right. Did you grant it access to your public repositories and organizations? Had you opted for no, then you can change it again by going to https://ci.appveyor.com/account, where you can revoke the github access and reauthorize .. this time permissively. 😄 |
Ok, it might be those extra auths. I granted them now. However while granting them it said that for the webassembly org in particular I can just ask for access. So I asked for it, it said it emailed the owners. |
Ok, all that should be ok now. But after I logging in I still get sent straight to the dashboard. Should I just create a new project? When I do that I get https://ci.appveyor.com/project/kripken/binaryen which looks empty |
I think your issue seems to be related to appveyor/ci#801 (comment) and appveyor/ci#802. What I have gathered from this situation (which the issues probably don't list yet) is that if you are a collaborator to an organization and your membership is not visible publicly (GitHub profile such as in your profile WebAssembly is not listed to public), then AppVeyor doesn't recognize the membership. If you make the membership to WebAssembly visible and Revoke->then->Authorize again, does it then land you to the second-step login screen? you can make your membership back to invisible after configuring the repo :) |
Yeah, I thought it might be that earlier so I edited myself to public. That was almost an hour ago but I still don't see the WebAssembly group among my public groups on my profile though... @dschuff, maybe you can try to do this? (you have equal collaborator status as I do on this repo) It should just be logging in as per the first comment in this PR, so just a few seconds to see if you don't hit whatever weirdness is blocking me. |
I wonder if it's not the status on the repo but on the WebAssembly organization that makes a difference. Neither of us is actually an owner of that organization. |
I was able to make a build ( https://ci.appveyor.com/project/dschuff/binaryen ) that seems to be from the WebAssembly binaryen repo. I don't know if it matters that it's project/dschuff rather than project/WebAssembly or some such? |
Great, then it probably doesn't matter if it is observing the upstream rather than the fork (which is another kind of weirdness since that is suppose to only happen at https://ci.appveyor.com/project/WebAssembly/binaryen). You can also view the settings page of this repo to find AppVeyor generic webhook: https://github.com/WebAssembly/binaryen/settings/hooks (just to validate everything is fine). It should be something like Please let me know if the webhook is there so i can amend the commit. :) |
@kripken, regarding the publicly visible membership, there seems to be a profile setting on GitHub, which lists the organizations under the display picture on profile page (https://github.com/kripken) for public. For example I can only see Unity3D logo on your profile. Probably AppVeyor is relying on the same kind of scope. |
I don't appear to have access to the settings of WebAssembly/binaryen. I might be some kind of contributor or commiter rather than an owner. |
@dschuff, I googled the issue again and found this: http://help.appveyor.com/discussions/questions/1154-appveyor-account-for-github-organizations. This probably translates to our scenario like this:
If that works then we will have https://ci.appveyor.com/project/WebAssembly/binaryen and this PR is good to go as is. :) Would you give it a try? Otherwise i will update the URL in readme. |
https://ci.appveyor.com/project/WebAssembly/binaryen Seems to work. |
Actually it looks like that's not a problem according to http://help.appveyor.com/discussions/questions/1118-how-to-change-my-plan-to-free-for-open-source-projects so we should be good. |
Great! Thanks @dschuff. Then this PR as is ready. :) I have re-pushed the commit to see if AppVeyor shows up on the PR, but it does not. Seems like this solution might work: http://stackoverflow.com/questions/32607885/appveyor-doesnt-update-github-pull-request-with-the-build-status. |
OK, I tried revoking and re-authorizing. |
Also tried a test PR: #624 but it doesn't appear to have triggered a build. |
@FeodorFitsner (from AppVeyor) could you please suggest what steps need to be taken in this case to make AppVeyor build trigger in PR? Here is the account setup https://ci.appveyor.com/project/WebAssembly/binaryen and this PR is adding appveyor.yml but it is not triggering the build. |
Make sure AppVeyor's webhook is added to the repo. You can see webhook URL on General tab of AppVeyor project settings. |
Thanks Feodor. I think we need someone with access to https://github.com/WebAssembly/binaryen/settings/hooks to verify if the appveyor webhook "Payload URL" value is same as the value of "Webhook URL" at https://ci.appveyor.com/project/WebAssembly/binaryen/settings. This normally gets added automatically and we never have to visit the settings page, but in this case we might have different URL. |
IIRC @kripken is the owner of the repo. (If not, then @jfbastien should be able to check). |
No, I'm just a collaborator like you, @dschuff. The owners are I guess the WebAssembly group owners that created the repo for us. |
I think I just installed the hook properly. LMK if that's not the case. |
Cool. Things seem to be happening now on my test PR: #624 |
Thanks. I pushed a test commit, apparently it didn't triggered. :( |
The hook only included 'push' but not 'pull request'. since my PR was on a branch in the WebAssembly repo itself, and yours was on a forked repo, maybe that explains the different. I added the 'pull_request' event too. try again? |
Actually, hold off 1 sec. |
oh it did work that time. cool. |
Yay, it worked! Thanks Derek. :) The whole job matrix takes about an hour to build. We may want to remove the |
So right now we have Debug/Release x (Msys x 32/64 + VS2015 x 32/64)? |
Oh wow, it is taking 12 mins! I guess its a paid account thing (since the account is in trial period). So it spawns one VM per job on Azure cloud. For regular account it probably builds on their local servers using some first-come-first-serve / merry-go-round protocol. 😄 |
Maybe for now let's drop the debug builds for Msys and 32-bit VS. (I would expect users wanting to debug would prefer VS and be using 64-bit). We can always tweak later. |
We have: { |
* Added jobs for MinGW (64 bit) and MSVC (32 and 64 bits) with Release configurations as well as MSVC (64 bit) with Debug configuration. * Added badge to README.
Amended; now we have mingw64 and msvcr{32,64} in Release, as well as msvc64 in Debug. Total of four jobs. |
Great! I think this can go now, we can tweak as needed. |
@FeodorFitsner, the badge URL https://ci.appveyor.com/api/projects/status/github/WebAssembly/binaryen?svg=true (public repo format) is rendering failure , while the build on master head is passing. Given that this account is trail and considered paid until the account expired while the repo is public, would we have to wait until the trail expired to get green status from badge using public URL format? |
I guess there is another project using the same GitHub repo. To use this format the repo should be unique in AppVeyor database. |
I'll switch it to use the unique one from the appveyor project: #626 |
configurations as well as MSVC (64 bit) with Debug configuration.
Commit 005929e build status: https://ci.appveyor.com/project/jasonwilliams200OK/binaryen/build/1.0.37
@kripken, to set it up, please login to AppVeyor with your GitHub account and chose WebAssembly org from the drop down (post login). Then add binaryen project from top menu and press build.
I have also added
ctest
command (doing nothing atm) which would function if we configure the tests in CMakeLists with ctest runner (aka cross-platform tests,: https://cmake.org/cmake/help/v3.0/manual/ctest.1.html). Examples can be found here: https://github.com/search?l=cmake&q=cmake+ENABLE_TESTING&type=Code&utf8=✓