media/update-libjpeg.sh
author Boris Chiou <boris.chiou@gmail.com>
Mon, 18 Mar 2019 18:04:58 +0000
changeset 464927 067a9dac440ab23f16c8034f104911a80773705a
parent 454752 1e76cea31571ed9274acd577b515e2c928cd207b
permissions -rwxr-xr-x
Bug 1425837 - Part 5: AnimationInfo::HasTransformAnimation should check other OMTA transform-like properties r=hiro This function was added for B2G actually, to check if the layer has OMTA for painting high-res layer. However, It's worth to let it also check other OMTA transform-like properties. Depends on D22565 Differential Revision: https://phabricator.services.mozilla.com/D19636

#!/bin/sh

set -v -e -x

if [ $# -lt 1 ]; then
  echo "Usage: update-libjpeg.sh /path/to/libjpeg-turbo/ [tag]"
  exit 1
fi

srcdir=`realpath $(dirname $0)`
topsrcdir=${srcdir}/..
rm -rf $srcdir/libjpeg

repo=$1
tag=${2-HEAD}

(cd $repo; git archive --prefix=media/libjpeg/ $tag) | (cd $srcdir/..; tar xf -)

cd $srcdir/libjpeg
cp win/jsimdcfg.inc simd/

revert_files="1050342.diff assembly-tables.diff externalize-table.diff 1520760-avx2-detection.diff jconfig.h jconfigint.h jpeg_nbits_table.c moz.build MOZCHANGES mozilla.diff simd/jsimdcfg.inc"
if test -d ${topsrcdir}/.hg; then
    hg revert --no-backup $revert_files
elif test -d ${topsrcdir}/.git; then
    git checkout HEAD -- $revert_files
fi

patch -p0 -i mozilla.diff
patch -p0 -i 1050342.diff
patch -p3 -i externalize-table.diff
patch -p3 -i assembly-tables.diff
patch -p0 -i 1520760-avx2-detection.diff