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

Fix build for win32, remove --enable-gczeal that snuck back in #71

Merged
merged 6 commits into from Jan 21, 2016

Conversation

@vvuk
Copy link
Contributor

vvuk commented Jan 6, 2016

For some reason, gcc isn't generating public symbols for setTracingLocation if they're defined inline in the class declaration in the header. There's probably an attribute we could apply or something, but this was the simplest way to get this to work.

Review on Reviewable

@vvuk
Copy link
Contributor Author

vvuk commented Jan 6, 2016

Someone should test this on linux/osx with the removing of --enable-gczeal, but without the second patch -- we should see if this is a windows-specific gcc issue, or if we're doing something we shouldn't be.

@jdm
Copy link
Member

jdm commented Jan 6, 2016

I'd like @michaelwu to take a look at the second commit.

@vvuk
Copy link
Contributor Author

vvuk commented Jan 7, 2016

I think the original linking problem may be due to -fno-keep-inline-dllexport that is added to the gcc flags in configure... but haven't tested without, would rather get static linking working properly.

@vvuk vvuk force-pushed the vvuk:win32 branch 4 times, most recently from 177f8c3 to 1a58f44 Jan 7, 2016
@asajeffrey
Copy link
Member

asajeffrey commented Jan 10, 2016

Should this be two separate PRs? One to remove --enable-gc-zeal and one to fix building on windows?

@vvuk
Copy link
Contributor Author

vvuk commented Jan 10, 2016

@vvuk vvuk force-pushed the vvuk:win32 branch from 53421c9 to fd63b28 Jan 10, 2016
@michaelwu
Copy link
Contributor

michaelwu commented Jan 13, 2016

An alternative to moving setTracingLocation and other functions is to remove those from the bindings - I don't think we need those functions, and they appear to be gone from upstream SM anyway. I'm fine with either solution though, since these functions are going to disappear in the future.

@larsbergstrom
Copy link
Contributor

larsbergstrom commented Jan 13, 2016

Currently failing on linux with:

In file included from /home/larsberg/servo/target/debug/build/mozjs_sys-6e42204b6e19049d/out/js/src/Unified_cpp_js_src7.cpp:110:0:
/home/larsberg/mozjs/mozjs/js/src/jsapi.cpp: In function ‘bool JS_CallOnce(JSCallOnceType*, JSInitCallback)’:
/home/larsberg/mozjs/mozjs/js/src/jsapi.cpp:5830:80: error: ‘PR_CallOnceWithArg’ was not declared in this scope
     return PR_CallOnceWithArg(once, CallOnce, JS_FUNC_TO_DATA_PTR(void *, func)) == PR_SUCCESS;
                                                                                ^
make[4]: *** [Unified_cpp_js_src7.o] Error 1
make[3]: *** [js/src/target] Error 2
make[2]: *** [compile] Error 2
make[1]: *** [default] Error 2
make: *** [all] Error 2
thread '<main>' panicked at 'assertion failed: result.success()', build.rs:17
@larsbergstrom
Copy link
Contributor

larsbergstrom commented Jan 13, 2016

@vvuk You may already know, but if not, here's a note on the hackery so you don't need to allocate/delete critical sections - http://joeduffyblog.com/2006/11/28/windows-keyed-events-critical-sections-and-new-vista-synchronization-features/

@vvuk
Copy link
Contributor Author

vvuk commented Jan 13, 2016

Arg, PR_CallOnceWithArg went away in m-c sm, but I guess not here. I'll fix shortly. Same with just removing those methods from the tracer.

As for critical sections... I had no idea about SRWLs. Since we're already depending on >= Vista, I'll switch to using them.

@vvuk vvuk force-pushed the vvuk:win32 branch from fd63b28 to d221277 Jan 14, 2016
@larsbergstrom
Copy link
Contributor

larsbergstrom commented Jan 16, 2016

It looks like this is passing CI builds now. @vvuk Is this ready to be reviewed/landed?

@larsbergstrom
Copy link
Contributor

larsbergstrom commented Jan 19, 2016

@vvuk and @michaelwu Is there anything more that needs to be done here to land this? I think it's the last piece we need before we land the Win32 changes to Servo master.

@michaelwu
Copy link
Contributor

michaelwu commented Jan 19, 2016

I'm happy with the approach here.

@larsbergstrom
Copy link
Contributor

larsbergstrom commented Jan 20, 2016

@vvuk, @Jayflux and I are now getting missing setTracingLocation and friends with this and the landed rust-mozjs fixes. Is there something we're missing?

@vvuk
Copy link
Contributor Author

vvuk commented Jan 20, 2016

Did rust-mozjs changes land, that had the removal of that in the bindings?

@vvuk
Copy link
Contributor Author

vvuk commented Jan 20, 2016

@larsbergstrom
Copy link
Contributor

larsbergstrom commented Jan 20, 2016

Great, thanks! That did it for me :-)

I'm opening the servo/servo PR, since it can land independently of these changes (which switch to static linking). That will let me start working on the CI/builder stuff.

@larsbergstrom
Copy link
Contributor

larsbergstrom commented Jan 21, 2016

@bors-servo r=michaelwu

(confirmed on IRC with @jdm and @Ms2ger)

@bors-servo
Copy link
Contributor

bors-servo commented Jan 21, 2016

📌 Commit d221277 has been approved by michaelwu

@bors-servo
Copy link
Contributor

bors-servo commented Jan 21, 2016

Testing commit d221277 with merge 5ac9991...

bors-servo added a commit that referenced this pull request Jan 21, 2016
Fix build for win32, remove --enable-gczeal that snuck back in

For some reason, gcc isn't generating public symbols for setTracingLocation if they're defined inline in the class declaration in the header.  There's probably an attribute we could apply or something, but this was the simplest way to get this to work.

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/mozjs/71)
<!-- Reviewable:end -->
@bors-servo
Copy link
Contributor

bors-servo commented Jan 21, 2016

☀️ Test successful - travis

@bors-servo bors-servo merged commit d221277 into servo:master Jan 21, 2016
2 checks passed
2 checks passed
continuous-integration/travis-ci/pr The Travis CI build passed
Details
homu Test successful
Details
bors-servo added a commit to servo/servo that referenced this pull request Jan 23, 2016
…oal95

Win32 support

r? @frewsxcv for python stuff
r? @pcwalton for the "remove usage of Gaol" stuff for Win32
r? anybody else for misc cargo.lock updates, etc.

This replaces #7878.

This works best with servo/mozjs#71, too, to enable static linking, but can be run without (via some PATH hackery).

The instructions are here, and will be added to a .md file in the repo once the mozjs changes also land:
https://hackpad.com/Servo-on-Windows-C1LPcI2bP25

I'd like to get these changes landed because I've been rebasing them for months, they're otherwise quite stable, and don't affect our other platforms and targets.

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9385)
<!-- Reviewable:end -->
gecko-dev-updater pushed a commit to marco-c/gecko-dev-comments-removed that referenced this pull request Oct 1, 2019
…sxcv,pcwalton,jdm,ecoal95

r? frewsxcv for python stuff
r? pcwalton for the "remove usage of Gaol" stuff for Win32
r? anybody else for misc cargo.lock updates, etc.

This replaces #7878.

This works best with servo/mozjs#71, too, to enable static linking, but can be run without (via some PATH hackery).

The instructions are here, and will be added to a .md file in the repo once the mozjs changes also land:
https://hackpad.com/Servo-on-Windows-C1LPcI2bP25

I'd like to get these changes landed because I've been rebasing them for months, they're otherwise quite stable, and don't affect our other platforms and targets.

Source-Repo: https://github.com/servo/servo
Source-Revision: 525e77f64fc65ea2397b4ff3849f5b1f39386698

UltraBlame original commit: e89451f650e7a23ae482833c8f6c658e3ccc0b33
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified-and-comments-removed that referenced this pull request Oct 1, 2019
…sxcv,pcwalton,jdm,ecoal95

r? frewsxcv for python stuff
r? pcwalton for the "remove usage of Gaol" stuff for Win32
r? anybody else for misc cargo.lock updates, etc.

This replaces #7878.

This works best with servo/mozjs#71, too, to enable static linking, but can be run without (via some PATH hackery).

The instructions are here, and will be added to a .md file in the repo once the mozjs changes also land:
https://hackpad.com/Servo-on-Windows-C1LPcI2bP25

I'd like to get these changes landed because I've been rebasing them for months, they're otherwise quite stable, and don't affect our other platforms and targets.

Source-Repo: https://github.com/servo/servo
Source-Revision: 525e77f64fc65ea2397b4ff3849f5b1f39386698

UltraBlame original commit: e89451f650e7a23ae482833c8f6c658e3ccc0b33
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified that referenced this pull request Oct 1, 2019
…sxcv,pcwalton,jdm,ecoal95

r? frewsxcv for python stuff
r? pcwalton for the "remove usage of Gaol" stuff for Win32
r? anybody else for misc cargo.lock updates, etc.

This replaces #7878.

This works best with servo/mozjs#71, too, to enable static linking, but can be run without (via some PATH hackery).

The instructions are here, and will be added to a .md file in the repo once the mozjs changes also land:
https://hackpad.com/Servo-on-Windows-C1LPcI2bP25

I'd like to get these changes landed because I've been rebasing them for months, they're otherwise quite stable, and don't affect our other platforms and targets.

Source-Repo: https://github.com/servo/servo
Source-Revision: 525e77f64fc65ea2397b4ff3849f5b1f39386698

UltraBlame original commit: e89451f650e7a23ae482833c8f6c658e3ccc0b33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

6 participants
You can’t perform that action at this time.