Commit b722b618 authored by Justin Lebar's avatar Justin Lebar
Browse files

Back out rev 2acd6833, bug 698519 - update to libjpeg 1.2, due to Dromaeo DOM regression.

parent b8118c63
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -181,7 +181,6 @@ LIBJPEG_TURBO_AS = @LIBJPEG_TURBO_AS@
LIBJPEG_TURBO_ASFLAGS = @LIBJPEG_TURBO_ASFLAGS@
LIBJPEG_TURBO_X86_ASM = @LIBJPEG_TURBO_X86_ASM@
LIBJPEG_TURBO_X64_ASM = @LIBJPEG_TURBO_X64_ASM@
LIBJPEG_TURBO_ARM_ASM = @LIBJPEG_TURBO_ARM_ASM@
NS_PRINTING = @NS_PRINTING@
MOZ_PDF_PRINTING = @MOZ_PDF_PRINTING@
MOZ_CRASHREPORTER = @MOZ_CRASHREPORTER@
+7 −22
Original line number Diff line number Diff line
@@ -4605,7 +4605,6 @@ LIBJPEG_TURBO_AS=
LIBJPEG_TURBO_ASFLAGS=
LIBJPEG_TURBO_X86_ASM=
LIBJPEG_TURBO_X64_ASM=
LIBJPEG_TURBO_ARM_ASM=
MOZ_PANGO=1
MOZ_PERMISSIONS=1
MOZ_PLACES=1
@@ -6164,51 +6163,38 @@ if test -n "$MOZ_LIBJPEG_TURBO"; then
    LIBJPEG_TURBO_ASFLAGS="-f win64 -rnasm -pnasm -D__x86_64__ -DPIC -DWIN64 -DMSVC"
    LIBJPEG_TURBO_X64_ASM=1
  ;;
  *:arm*)
    LIBJPEG_TURBO_ASFLAGS="-march=armv7-a -mfpu=neon"
    LIBJPEG_TURBO_ARM_ASM=1
  ;;
  esac

fi

dnl If we're on an x86 or x64 system which supports libjpeg-turbo's asm routines
dnl and --disable-libjpeg-turbo wasn't passed, check for Yasm, and error out if
dnl it doesn't exist or we have too old of a version.
dnl If we're on a system which supports libjpeg-turbo's asm routines and
dnl --disable-libjpeg-turbo wasn't passed, check for yasm, and error out if it
dnl doesn't exist or we have too old of a version.
if test -n "$LIBJPEG_TURBO_X86_ASM" -o -n "$LIBJPEG_TURBO_X64_ASM" ; then
    AC_MSG_CHECKING([for Yasm assembler])
    AC_MSG_CHECKING([for YASM assembler])
    AC_CHECK_PROGS(LIBJPEG_TURBO_AS, yasm, "")

    if test -z "$LIBJPEG_TURBO_AS" ; then
        AC_MSG_ERROR([Yasm is required to build with libjpeg-turbo's optimized JPEG decoding routines, but you do not appear to have Yasm installed.  Either install it or configure with --disable-libjpeg-turbo to use the pure C JPEG decoder.  See https://developer.mozilla.org/en/YASM for more details.])
        AC_MSG_ERROR([yasm is required to build with libjpeg-turbo's optimized JPEG decoding routines, but you do not appear to have yasm installed.  Either install it or configure with --disable-libjpeg-turbo to use the pure C JPEG decoder.  See https://developer.mozilla.org/en/YASM for more details.])
    fi

    dnl Check that we have the right yasm version.  We require 1.0.1 or newer
    dnl on Linux and 1.1 or newer everywhere else.
    if test "$OS_ARCH" = "Linux" ; then
        if test "$_YASM_MAJOR_VERSION" -lt "1" -o \( "$_YASM_MAJOR_VERSION" -eq "1" -a "$_YASM_MINOR_VERSION" -eq "0" -a "$_YASM_RELEASE" -lt "1" \) ; then
            AC_MSG_ERROR([Yasm 1.0.1 or greater is required to build with libjpeg-turbo's optimized JPEG decoding routines, but you appear to have version $_YASM_MAJOR_VERSION.$_YASM_MINOR_VERSION.$_YASM_RELEASE.  Upgrade to the newest version or configure with --disable-libjpeg-turbo to use the pure C JPEG decoder.  See https://developer.mozilla.org/en/YASM for more details.])
            AC_MSG_ERROR([yasm 1.0.1 or greater is required to build with libjpeg-turbo's optimized JPEG decoding routines, but you appear to have version $_YASM_MAJOR_VERSION.$_YASM_MINOR_VERSION.$_YASM_RELEASE.  Upgrade to the newest version or configure with --disable-libjpeg-turbo to use the pure C JPEG decoder.  See https://developer.mozilla.org/en/YASM for more details.])
        fi
    else
        if test "$_YASM_MAJOR_VERSION" -lt "1" -o \( "$_YASM_MAJOR_VERSION" -eq "1" -a "$_YASM_MINOR_VERSION" -lt "1" \) ; then
            AC_MSG_ERROR([Yasm 1.1 or greater is required to build with libjpeg-turbo's optimized JPEG decoding routines, but you appear to have version $_YASM_MAJOR_VERSION.$_YASM_MINOR_VERSION.  Upgrade to the newest version or configure with --disable-libjpeg-turbo to use the pure C JPEG decoder.  See https://developer.mozilla.org/en/YASM for more details.])
            AC_MSG_ERROR([yasm 1.1 or greater is required to build with libjpeg-turbo's optimized JPEG decoding routines, but you appear to have version $_YASM_MAJOR_VERSION.$_YASM_MINOR_VERSION.  Upgrade to the newest version or configure with --disable-libjpeg-turbo to use the pure C JPEG decoder.  See https://developer.mozilla.org/en/YASM for more details.])
        fi
    fi
fi

dnl If we're on an ARM system which supports libjpeg-turbo's asm routines and
dnl --disable-libjpeg-turbo wasn't passed, use the C compiler as the assembler.
if test -n "$LIBJPEG_TURBO_ARM_ASM" ; then
    echo "Using $AS as the assembler for ARM code."
    LIBJPEG_TURBO_AS=$AS
fi

if test -n "$LIBJPEG_TURBO_X86_ASM"; then
    AC_DEFINE(LIBJPEG_TURBO_X86_ASM)
elif test -n "$LIBJPEG_TURBO_X64_ASM"; then
    AC_DEFINE(LIBJPEG_TURBO_X64_ASM)
elif test -n "$LIBJPEG_TURBO_ARM_ASM"; then
    AC_DEFINE(LIBJPEG_TURBO_ARM_ASM)
elif test -n "$MOZ_LIBJPEG_TURBO"; then
    dnl Warn if we're not building the optimized routines, even though the user
    dnl didn't specify --disable-libjpeg-turbo.
@@ -8750,7 +8736,6 @@ AC_SUBST(LIBJPEG_TURBO_AS)
AC_SUBST(LIBJPEG_TURBO_ASFLAGS)
AC_SUBST(LIBJPEG_TURBO_X86_ASM)
AC_SUBST(LIBJPEG_TURBO_X64_ASM)
AC_SUBST(LIBJPEG_TURBO_ARM_ASM)

AC_MSG_CHECKING([for posix_fallocate])
AC_TRY_LINK([#define _XOPEN_SOURCE 600
+6 −30
Original line number Diff line number Diff line
@@ -6,15 +6,9 @@ To upgrade to a new revision of libjpeg-turbo, do the following:

* In a clean clone of mozilla-central, run the following commands

    $ rm -rf media/libjpeg
    $ svn export --ignore-externals /path/to/libjpeg-turbo media/libjpeg
    $ cd media/libjpeg

* Copy win/jsimdcfg.inc to simd/.

* Since libjpeg-turbo normally creates config.h and jconfig.h at build time and
  we use pre-generated versions, changes to jconfig.h.in and win/config.h.in
  should be looked for and noted for later inclusion.
    $ rm -rf jpeg
    $ svn export --ignore-externals /path/to/libjpeg-turbo jpeg
    $ cd jpeg

* Now look through the new files and rm any which are npotb.  When I upgraded
  to libjpeg-turbo 1.1.0, the only files I kept which didn't match
@@ -38,19 +32,13 @@ To upgrade to a new revision of libjpeg-turbo, do the following:

    diff <(ls *.c | sort) <(grep -o '\w*\.c' Makefile.in | sort)

  Of course, libjpeg-turbo might have added some new source files, so you'll
  of course, libjpeg-turbo might have added some new source files, so you'll
  have to look though and figure out which of these files to keep.

* Restore files modified in the Mozilla repository.

    $ hg revert --no-backup config.h jconfig.h Makefile.in MOZCHANGES \
      mozilla.diff simd/Makefile.in

* Update config.h and jconfig.h as noted previously.

* Apply Mozilla-specific changes to upstream files.

    $ patch -p0 -i mozilla.diff
    $ hg revert --no-backup Makefile.in jconfig.h jmorecfg.h simd/Makefile.in \
      simd/jsimdcfg.inc jchuff.c jdhuff.c jdhuff.h MOZCHANGES

* Update Makefile.in to build any new files.

@@ -59,18 +47,6 @@ To upgrade to a new revision of libjpeg-turbo, do the following:
    $ hg addremove


== February 10, 2012 (libjpeg-turbo v1.2.0 r807 2012-02-10) ==

* Imported jchuff.c, jdhuff.c, jdhuff.h under new licensing.

* Created mozilla.diff for the required jmorecfg.h changes and to allow for any
  future changes made by Mozilla to upstream files.

* Removed the following files which are unused by the Mozilla build:

    cderror.h, cdjpeg.h, jconfig.h.in, transupp.h, simd/jsimdcfg.inc.h


== March 28, 2011 (initial commit, libjpeg-turbo v1.1.0 r469 2011-02-27) ==

* Modified jmorecfg.h to define UINT8, UINT16, INT16, and INT32 in terms of
+9 −18
Original line number Diff line number Diff line
@@ -103,7 +103,6 @@ CSRCS += \
		jcphuff.c \
		jcprepct.c \
		jcsample.c \
		jctrans.c \
		$(NULL)

AS=$(LIBJPEG_TURBO_AS)
@@ -116,20 +115,14 @@ ifeq ($(AS),yasm)
endif

# No SIMD support?
ifeq (,$(LIBJPEG_TURBO_X86_ASM)$(LIBJPEG_TURBO_X64_ASM)$(LIBJPEG_TURBO_ARM_ASM))
ifeq (,$(LIBJPEG_TURBO_X86_ASM)$(LIBJPEG_TURBO_X64_ASM))
  CSRCS += jsimd_none.c
endif

ifeq (1,$(LIBJPEG_TURBO_ARM_ASM))
  CSRCS += simd/jsimd_arm.c
  SSRCS += simd/jsimd_arm_neon.S
endif

ifeq (1,$(LIBJPEG_TURBO_X64_ASM))
  CSRCS   += simd/jsimd_x86_64.c
  ASFILES += \
	simd/jccolss2-64.asm \
	simd/jcgrass2-64.asm \
	simd/jcqnts2f-64.asm \
	simd/jcqnts2i-64.asm \
	simd/jcsamss2-64.asm \
@@ -151,8 +144,6 @@ ifeq (1,$(LIBJPEG_TURBO_X86_ASM))
  ASFILES += \
	simd/jccolmmx.asm \
	simd/jccolss2.asm \
	simd/jcgrammx.asm \
	simd/jcgrass2.asm \
	simd/jcqnt3dn.asm \
	simd/jcqntmmx.asm \
	simd/jcqnts2f.asm \
+9 −10
Original line number Diff line number Diff line
libjpeg-turbo note:  This file contains portions of the libjpeg v6b and v8
README files, with additional wordsmithing by The libjpeg-turbo Project.
It is included only for reference, as some parts of it may not apply to
libjpeg-turbo.  Please see README-turbo.txt for information specific to
libjpeg-turbo.
libjpeg-turbo note:  This file is mostly taken from the libjpeg v8b README
file, and it is included only for reference.  Some parts of it may not apply to
libjpeg-turbo.  Please see README-turbo.txt for information specific to the
turbo version.


The Independent JPEG Group's JPEG software
@@ -63,7 +62,7 @@ OVERVIEW
This package contains C software to implement JPEG image encoding, decoding,
and transcoding.  JPEG (pronounced "jay-peg") is a standardized compression
method for full-color and gray-scale images.  JPEG's strong suit is compressing
photographic images or other types of images that have smooth color and
photographic images or other types of images which have smooth color and
brightness transitions between neighboring pixels.  Images with sharp lines or
other abrupt features may not compress well with JPEG, and a higher JPEG
quality may have to be used to avoid visible compression artifacts with such
@@ -257,8 +256,8 @@ ARCHIVE LOCATIONS
The "official" archive site for this software is www.ijg.org.
The most recent released version can always be found there in
directory "files".  This particular version will be archived as
http://www.ijg.org/files/jpegsrc.v8d.tar.gz, and in Windows-compatible
"zip" archive format as http://www.ijg.org/files/jpegsr8d.zip.
http://www.ijg.org/files/jpegsrc.v8b.tar.gz, and in Windows-compatible
"zip" archive format as http://www.ijg.org/files/jpegsr8b.zip.

The JPEG FAQ (Frequently Asked Questions) article is a source of some
general information about JPEG.
@@ -275,7 +274,7 @@ FILE FORMAT WARS
================

The ISO JPEG standards committee actually promotes different formats like
"JPEG 2000" or "JPEG XR", which are incompatible with original DCT-based
"JPEG 2000" or "JPEG XR" which are incompatible with original DCT-based
JPEG.  IJG therefore does not support these formats (see REFERENCES).  Indeed,
one of the original reasons for developing this free software was to help
force convergence on common, interoperable format standards for JPEG files.
@@ -287,4 +286,4 @@ image files indefinitely.)
TO DO
=====

Please send bug reports, offers of help, etc. to jpeg-info@jpegclub.org.
Please send bug reports, offers of help, etc. to jpeg-info@uc.ag.
Loading