summaryrefslogtreecommitdiffstats
path: root/media/update-libjpeg.sh
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 00:47:55 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 00:47:55 +0000
commit26a029d407be480d791972afb5975cf62c9360a6 (patch)
treef435a8308119effd964b339f76abb83a57c29483 /media/update-libjpeg.sh
parentInitial commit. (diff)
downloadfirefox-26a029d407be480d791972afb5975cf62c9360a6.tar.xz
firefox-26a029d407be480d791972afb5975cf62c9360a6.zip
Adding upstream version 124.0.1.upstream/124.0.1
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'media/update-libjpeg.sh')
-rwxr-xr-xmedia/update-libjpeg.sh28
1 files changed, 28 insertions, 0 deletions
diff --git a/media/update-libjpeg.sh b/media/update-libjpeg.sh
new file mode 100755
index 0000000000..6a1b377bec
--- /dev/null
+++ b/media/update-libjpeg.sh
@@ -0,0 +1,28 @@
+#!/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
+
+revert_files="jconfig.h jconfigint.h moz.build MOZCHANGES mozilla.diff"
+if test -d ${topsrcdir}/.hg; then
+ hg revert --no-backup $revert_files
+elif test -e ${topsrcdir}/.git; then
+ git checkout HEAD -- $revert_files
+fi
+
+patch -p0 -i mozilla.diff