Closed Bug 1168291 Opened 10 years ago Closed 9 years ago

mozalloc.lib is missing in xulrunner-39.0b1.en-US.win32.sdk

Categories

(Firefox Build System :: General, defect)

39 Branch
x86
Windows 7
defect
Not set
normal

Tracking

(firefox39 disabled, firefox40 fixed, firefox41 fixed, firefox42 fixed, firefox43 fixed)

RESOLVED FIXED
mozilla43
Tracking Status
firefox39 --- disabled
firefox40 --- fixed
firefox41 --- fixed
firefox42 --- fixed
firefox43 --- fixed

People

(Reporter: xuchmao, Assigned: glandium)

References

Details

Attachments

(1 file)

User Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/30.0.1599.101 Safari/537.36 Steps to reproduce: I have use xulrunner sdk to build xpcom extension. nss3.lib;xpcomglue_s.lib;xul.lib;mozalloc.lib have been added to the linker addtional dependencies in visual studio. in the latest xulrunner-39.0b1.en-US.win32.sdk, mozalloc.lib is missing. when remove mozalloc.lib from linker dependencies, there will be compliation error. Actual results: The following is complication error without mozalloc.lib in linker addtional dependencies. 1>xpcomglue_s.lib(Unified_cpp_xpcom_glue1.obj) : error LNK2001: unresolved external symbol __imp__moz_free 1>xpcomglue_s.lib(Unified_cpp_xpcom_glue0.obj) : error LNK2001: unresolved external symbol __imp__moz_free 1>xpcomglue_s.lib(Unified_cpp_xpcom_glue2.obj) : error LNK2001: unresolved external symbol __imp__moz_free Expected results: mozalloc.lib should be in xulrunner-39.0b1.en-US.win32.sdk
Summary: mozalloc is missing in xulrunner-39.0b1.en-US.win32.sdk → mozalloc.lib is missing in xulrunner-39.0b1.en-US.win32.sdk
OS: Unspecified → Windows 7
Hardware: Unspecified → x86
How to fix this kind of compliation error ? Which lib can be used instead of mozalloc.lib?
Component: XPCOM → Build Config
Flags: needinfo?(mh+mozilla)
Use mozcrt.lib instead of mozalloc.lib... which I now realize is not in the SDK. Until it is, you might be able to use mozglue.lib.
Flags: needinfo?(mh+mozilla)
Assignee: nobody → mh+mozilla
I have try to use mozglue.lib instead of mozalloc.lib to solve linker error. It seems it has a crash issue when close firefox 39 with our extension enabled. So I deceide to use source code to build xulrunner-39 sdk and find mozcrt.lib in it. The extension works well when use mozcrt.lib. Much thanks for your information, Mike. (In reply to Mike Hommey [:glandium] from comment #2) > Use mozcrt.lib instead of mozalloc.lib... which I now realize is not in the > SDK. Until it is, you might be able to use mozglue.lib.
When building with MOZ_CRT (which is more or less the default when building on Windows with MSVC2013), building e.g. XPCOM components requires linking against mozcrt.lib, so it needs to be shipped in the SDK. On the other hand, mozglue.lib, which is currently shipped, is not useful because it lacks the necessary hacks from mozcrt.lib avoiding crashes for memory allocator mismatch.
Attachment #8612198 - Flags: review?(mshal)
Attachment #8612198 - Flags: review?(mshal) → review+
I'd appreciate feedback on when mozcrt.lib is expected to be shipped with xulrunner sdk. The patch seems to have available for about 2 weeks now, but yesterday's update ain't got it. Would save time to a number of folks...
Depends on: 1173683
The change has been reverted in 39. The SDK for 39.0b7 will have mozalloc.lib again, like before. mozcrt.lib will still be a requirement for 40.
I am interested in having mozcrt.lib in SDK as well. Add it to the SDK, please.
mozalloc.lib is added to xulrunner-39.0.en-US.win32.sdk, but in xulrunner-40.0.en-US.win32.sdk there is still no mozalloc.lib nor mozcrt.lib
I'd appreciate feedback on when to expect mozalloc.lib or mozcrt.lib in xulrunner 40 (win32 (and hopefully win64 as well if Firefox 40 is to be shipped in win64 as well (even if win64 is provided later))). P.S. There's xulrunner-40.0b9.en-US.win64.sdk.zip, but nothing like that for 40.0. P.P.S. Obviously, some extensions can't be updated until this is taken care of, and some of those will become unusable once Firefox 40.0 is released.
Flags: needinfo?(mh+mozilla)
Comment on attachment 8612198 [details] [diff] [review] Install mozcrt.lib instead of mozglue.lib in the SDK Approval Request Comment [Feature/regressing bug #]: bug 868814 [User impact if declined]: Can't use the SDK on Windows because of the missing .lib library that is required to link any binary component. [Describe test coverage new/current, TreeHerder]: SDKs built with the patch will contain mozcrt.lib when they don't without the patch. [Risks and why]: The patch doesn't touch Firefox itself, only the SDK, which, until 42 (I think) is built along Xulrunner. Note that bug 1193177 is going to add the file manually in -release builds, but the -release request is to ensure the same doesn't need to happen if we go with a 40.0.1 release. As for why now and not earlier, that's because there were some legal concerns that needed to be cleared out first. [String/UUID change made/needed]: None
Flags: needinfo?(mh+mozilla)
Attachment #8612198 - Flags: approval-mozilla-release?
Attachment #8612198 - Flags: approval-mozilla-beta?
Attachment #8612198 - Flags: approval-mozilla-aurora?
Status: UNCONFIRMED → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla43
Comment on attachment 8612198 [details] [diff] [review] Install mozcrt.lib instead of mozglue.lib in the SDK We're spinning 40.0.1. This change has no impact on the release build itself. release+ beta+ aurora+
Attachment #8612198 - Flags: approval-mozilla-release?
Attachment #8612198 - Flags: approval-mozilla-release+
Attachment #8612198 - Flags: approval-mozilla-beta?
Attachment #8612198 - Flags: approval-mozilla-beta+
Attachment #8612198 - Flags: approval-mozilla-aurora?
Attachment #8612198 - Flags: approval-mozilla-aurora+
https://hg.mozilla.org/releases/mozilla-release/rev/0f006867249f Landed on m-r for imminent 40.0.1 build. (Still needs an aurora + beta landing)
Product: Core → Firefox Build System
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: