Closed Bug 836696 Opened 7 years ago Closed 7 years ago

Followup fix for VS2008/VC9 for Bug 828789 (Update to pixman 0.27.2)

Categories

(Core :: Graphics, defect)

x86
Windows 7
defect
Not set

Tracking

()

RESOLVED WORKSFORME

People

(Reporter: philip.chee, Assigned: philip.chee)

References

Details

Attachments

(1 file, 1 obsolete file)

c:/t1/hg/comm-central/mozilla/gfx/cairo/libpixman/src/pixman-srgb.c(5) : fatal error C1083: Cannot open include file: 'stdint.h': No such file or directory

Note: VC9 does not have stdint.h
Note: I tried to include pixman.h because it looks like it has code to deal with a missing stdint.h but this just introduced even more errors.
Attachment #708518 - Flags: review?(jmuizelaar)
Attachment #708518 - Flags: feedback?(bill)
> /* WARNING: This file is generated by make-srgb.pl.
>  * Please edit that file instead of this one.
I couldn't find this file anywhere in mozilla-central??
Comment on attachment 708518 [details] [diff] [review]
Patch using mozilla/StandardInteger.h

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

This should be using pixman.h like the rest of pixman.
Attachment #708518 - Flags: review?(jmuizelaar) → review-
Comment on attachment 708518 [details] [diff] [review]
Patch using mozilla/StandardInteger.h

That said, this patch does work for me for my Firefox build using VC9.
Attachment #708518 - Flags: feedback?(bill) → feedback+
(In reply to Jeff Muizelaar [:jrmuizel] from comment #3)
> Comment on attachment 708518 [details] [diff] [review]
> Patch using mozilla/StandardInteger.h
> 
> Review of attachment 708518 [details] [diff] [review]:
> -----------------------------------------------------------------
> 
> This should be using pixman.h like the rest of pixman.

Merely replacing the include stdint.h with include pixman.h here will not work for 2 reasons:

1.  pixman.h is alredy included here via the #include "pixman-private.h" a few lines later.
2.  The code in pixman.h will not cover this becuase we seem to define "PIXMAN_DONT_DEFINE_STDINT" all over the place.

/gfx/layers/basic/BasicLayerManager.cpp (View Hg log or Hg annotations)

    line 20 -- #define PIXMAN_DONT_DEFINE_STDINT

/widget/gtk2/nsWindow.cpp (View Hg log or Hg annotations)

    line 101 -- #define PIXMAN_DONT_DEFINE_STDINT

/widget/qt/nsWindow.cpp (View Hg log or Hg annotations)

    line 120 -- #define PIXMAN_DONT_DEFINE_STDINT

/widget/windows/nsWindowGfx.cpp (View Hg log or Hg annotations)

    line 53 -- #define PIXMAN_DONT_DEFINE_STDINT

Therefore the patch to replace this with mozilla/StandardInteger.h might be the safest way to go.
Actually looking at the pixman-srgb.c file itself, nothing there uses stdint.h at all, if I just delete the #include <stdint.h> line, I can continue building. I'll see if the completed build crashes or anything.
> Actually looking at the pixman-srgb.c file itself, nothing there uses stdint.h
> at all, if I just delete the #include <stdint.h> line, I can continue
> building. I'll see if the completed build crashes or anything.
Well build starts up and works normally. No crashiness or anything.
Attachment #708518 - Attachment is obsolete: true
Attachment #709033 - Flags: review?(jmuizelaar)
Someone will need to fix the Perl file make-srgb.pl and upstream the fix.
FWIW, pixman-srgb.c has gone away upstream.
(In reply to Philip Chee from comment #7)
> Created attachment 709033 [details] [diff] [review]
> Patch v1.1 just delete stdint.h
> 
> > Actually looking at the pixman-srgb.c file itself, nothing there uses stdint.h
> > at all, if I just delete the #include <stdint.h> line, I can continue
> > building. I'll see if the completed build crashes or anything.
> Well build starts up and works normally. No crashiness or anything.

This works for me on windows using vc9.  testing now on linux where stdint.h is present and my android build.  I do not have a way to test on a MAC.
This works on my 32 and 64-bit Linux, Android and Windows builds using VC9.
Fixed by 828789 (Update to pixman 0.27.2)
Status: ASSIGNED → RESOLVED
Closed: 7 years ago
Resolution: --- → WORKSFORME
Attachment #709033 - Flags: review?(jmuizelaar)
You need to log in before you can comment on or make changes to this bug.