Closed Bug 1119776 Opened 9 years ago Closed 9 years ago

Don't define snprintf if MSVC provides it (VS2015 and later do)

Categories

(Firefox Build System :: General, defect)

x86_64
Windows 8.1
defect
Not set
normal

Tracking

(firefox36 wontfix, firefox37 fixed, firefox38 fixed, firefox39 fixed, firefox40 fixed)

RESOLVED FIXED
mozilla40
Tracking Status
firefox36 --- wontfix
firefox37 --- fixed
firefox38 --- fixed
firefox39 --- fixed
firefox40 --- fixed

People

(Reporter: briansmith, Assigned: briansmith)

References

Details

Attachments

(10 files, 3 obsolete files)

1.03 KB, patch
ehsan.akhgari
: review+
Details | Diff | Splinter Review
3.06 KB, patch
rillian
: review+
Details | Diff | Splinter Review
1.65 KB, patch
jesup
: review+
Details | Diff | Splinter Review
1.75 KB, patch
Waldo
: review+
Details | Diff | Splinter Review
1.13 KB, patch
jesup
: review+
Details | Diff | Splinter Review
15.95 KB, patch
benjamin
: review+
Details | Diff | Splinter Review
1.91 KB, patch
Details | Diff | Splinter Review
998 bytes, patch
jgilbert
: review+
Details | Diff | Splinter Review
1009 bytes, patch
mozilla
: review+
Details | Diff | Splinter Review
1.58 KB, patch
gw280
: review+
Details | Diff | Splinter Review
These patches are required in order for VS2015 to build mozilla-central correctly.
Ted, I'll check this into the NSPR repository after it is r+d.
Attachment #8546606 - Flags: review?(ted)
Benoit,

I understand that your team upstreams patches to Angle and Skia before landing them in mozilla-central. Could you help me do that for these changes? I think it's likely to be trivial for you, but easy for me to screw up.

Thanks!
Attachment #8546608 - Flags: review?(jacob.benoit.1)
Here's a try run with these patches:
https://treeherder.mozilla.org/#/jobs?repo=try&revision=c63b55fd66a5

I'm not sure what the deal is with Android Mochitest-8. I think maybe I had my local tree based on something that broke that test; I'll verify that before landing any of this.
Attachment #8546607 - Flags: review?(benjamin) → review+
Attachment #8546605 - Flags: review?(mcmanus) → review?(rjesup)
Attachment #8546599 - Flags: review?(ehsan) → review+
Attachment #8546601 - Flags: review?(rjesup) → review+
Comment on attachment 8546605 [details] [diff] [review]
Part 5: Avoid defining snprintf when MSVC provides it (netwerk)

Review of attachment 8546605 [details] [diff] [review]:
-----------------------------------------------------------------

Please send email to Michael Tuexen (Michael Tuexen <tuexen@fh-muenster.de>) with a pointer to this patch so he can land it in upstream.  Thanks!
Attachment #8546605 - Flags: review?(rjesup) → review+
Attachment #8546604 - Flags: review?(jwalden+bmo) → review+
Comment on attachment 8546600 [details] [diff] [review]
Part 2: Avoid defining snprintf when MSVC provides it (video)

Review of attachment 8546600 [details] [diff] [review]:
-----------------------------------------------------------------

Ralph is more up with the play WRT whether we're taking patches directly against libvpx etc, so I'll pass the review to him.
Attachment #8546600 - Flags: review?(cpearce) → review?(giles)
Comment on attachment 8546600 [details] [diff] [review]
Part 2: Avoid defining snprintf when MSVC provides it (video)

Review of attachment 8546600 [details] [diff] [review]:
-----------------------------------------------------------------

Please split the libvpx change into a separate commit.

For libvpx, in addition to the change to vp9_systemdependent.h please add a patch file to media/libvpx/ with the same change and add it to apply_patches() in update.py (see https://github.com/mozilla/gecko-dev/blob/master/media/libvpx/update.py#L530). This will ensure your change isn't clobbered the next time we pull from this library's upstream source.

Stagefright patch looks fine. r=me with these changes.
Attachment #8546600 - Flags: review?(giles) → review+
Attachment #8546606 - Flags: review?(ted) → review+
(In reply to Brian Smith (:briansmith, :bsmith, use NEEDINFO?) from comment #6)
> Ted, I'll check this into the NSPR repository after it is r+d.

I just tagged a new NSPR beta the other day, feel free to tag another one. Given that today is an uplift day, though, we might want to cut a NSPR release from the current trunk and then land this patch for the next version (just to minimize churn when we land the NSPR release changeset on aurora).
Comment on attachment 8546608 [details] [diff] [review]
Part 8: Avoid defining snprintf when MSVC provides it (gfx)

Review of attachment 8546608 [details] [diff] [review]:
-----------------------------------------------------------------

Jeff, could you help me with the review for this patch and to help merge it upstream? I don't have access to the upstream repositories to do the merge myself. Thanks!
Attachment #8546608 - Flags: review?(jacob.benoit.1) → review?(jmuizelaar)
Comment on attachment 8546608 [details] [diff] [review]
Part 8: Avoid defining snprintf when MSVC provides it (gfx)

Review of attachment 8546608 [details] [diff] [review]:
-----------------------------------------------------------------

I'll do what I can. It may be a bit of a long process.
Comment on attachment 8546599 [details] [diff] [review]
Part 1: Avoid defining snprintf when MSVC provides it (dom/media)

https://hg.mozilla.org/integration/mozilla-inbound/rev/4f852d38c615
Attachment #8546599 - Flags: checkin+
Comment on attachment 8546605 [details] [diff] [review]
Part 5: Avoid defining snprintf when MSVC provides it (netwerk)

https://hg.mozilla.org/integration/mozilla-inbound/rev/b44a29a96736
Attachment #8546605 - Flags: checkin+
Comment on attachment 8546606 [details] [diff] [review]
Part 6: Avoid defining snprintf when MSVC provides it (NSPR)

Part 6 was checked into NSPR and then the new version of NSPR was imported into mozilla-inbound/central, so Part 6 isn't needed any more.
Attachment #8546606 - Attachment is obsolete: true
(In reply to Jeff Muizelaar [:jrmuizel] from comment #15)
> I'll do what I can. It may be a bit of a long process.

Thanks Jeff! I appreciate it.

Also, thanks a lot to everybody else that reviewed these patches!
Keywords: leave-open
(In reply to Brian Smith (:briansmith, :bsmith, use NEEDINFO?) from comment #23)

https://twitter.com/sayrer/status/19304989209
This is a backport of just the libstagefright changes from part 2 to reduce variance between firefox 37 and 38.

Approval Request Comment
[Feature/regressing bug #]: MSE
[User impact if declined]: Harder to backport other changes later.
[Describe test coverage new/current, TBPL]: Landed on m-c
[Risks and why]: Minimal. Include changes for MSVC 2015.
[String/UUID change made/needed]: None

Approval is requested for this patch alone.
Attachment #8549728 - Flags: approval-mozilla-aurora?
Comment on attachment 8549728 [details] [diff] [review]
Part 2: Aurora backport of stagefright changes.

Aurora+
Attachment #8549728 - Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
Set tracking flags to reflect uplift status.

This isn't really 'fixed' on firefox 37. We only uplifted the stagefright changes.
Rebased. Any chance of a review of this any time soon? It's been several months now.
Attachment #8546608 - Attachment is obsolete: true
Attachment #8546608 - Flags: review?(jmuizelaar)
Attachment #8586307 - Flags: review?(jmuizelaar)
(In reply to Brian Smith (:briansmith, :bsmith, use NEEDINFO?) from comment #30)
> Created attachment 8586307 [details] [diff] [review]
> Part 8: Avoid defining snprintf when MSVC provides it (gfx) [v2]
> 
> Rebased. Any chance of a review of this any time soon? It's been several
> months now.

Sorry about that. It's probably worth splitting out this patch for skia, angle and harfbuzz and have them reviewed and upstreamed individually. I haven't had a chance to do this for each of the projects. gw280 can deal with skia patch, jgilbert can do the angle part and Jonathan Kew can do the harfbuzz part.
Attachment #8586307 - Flags: review?(jmuizelaar)
Jeff, Jeff M. suggested you are the best person to review and upstream this. All the non-gfx patches in this bug have already been checked in. Thanks in advance!
Attachment #8586307 - Attachment is obsolete: true
Attachment #8586317 - Flags: review?(jgilbert)
Jonathan, Jeff M. suggested you are the best person to review and upstream this. All the non-gfx patches in thus bug have already landed. Thanks in advance!
Attachment #8586321 - Flags: review?(jfkthame)
Attachment #8586317 - Attachment description: Avoid defining snprintf when MSVC provides it (angle) → Part 8: Avoid defining snprintf when MSVC provides it (angle)
George, Jeff M. suggested you are the best person to review and upstream this. All the non-gfx patches in this bug have already landed. Thanks in advance!
Attachment #8586324 - Flags: review?(gwright)
HarfBuzz patch is upstream now.
Comment on attachment 8586317 [details] [diff] [review]
Part 8: Avoid defining snprintf when MSVC provides it (angle)

Review of attachment 8586317 [details] [diff] [review]:
-----------------------------------------------------------------

This is already present in upstream ANGLE.
Attachment #8586317 - Flags: review?(jgilbert) → review+
(In reply to Behdad Esfahbod from comment #35)
> HarfBuzz patch is upstream now.

Great! Can you r+ the patch so I can land it? Thanks!
Attachment #8586321 - Flags: review?(jfkthame) → review+
Comment on attachment 8586324 [details] [diff] [review]
Part 10: Avoid defining snprintf when MSVC provides it (skia)

Review of attachment 8586324 [details] [diff] [review]:
-----------------------------------------------------------------

I'll upstream this
Attachment #8586324 - Flags: review?(gwright) → review+
Comment on attachment 8586321 [details] [diff] [review]
Part 9: Avoid defining snprintf when MSVC provides it (harfbuzz)

https://hg.mozilla.org/integration/mozilla-inbound/rev/25178d030eef
Attachment #8586321 - Flags: checkin+
Thanks for all the reviews! All the patches for this have landed now.
Keywords: leave-open
https://hg.mozilla.org/mozilla-central/rev/25178d030eef
https://hg.mozilla.org/mozilla-central/rev/9b20a8b5edec
Status: ASSIGNED → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: mozilla37 → mozilla40
Calling Fx39 fixed to make my "needs uplift" bug queries happy (I'm assuming we don't intend to backport any further patches from this bug to the release branches).
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: