Skip to content

Commit ad05972

Browse files
committed
Add libd265, openjpeg, poppler for Tropy
1 parent 8d7d28c commit ad05972

File tree

5 files changed

+242
-18
lines changed

5 files changed

+242
-18
lines changed

.github/workflows/build-release.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -31,12 +31,12 @@ jobs:
3131
- 'ubuntu-24.04'
3232
platform:
3333
- 'linux-x64'
34-
- 'linux-armv6'
35-
- 'linuxmusl-x64'
36-
- 'linuxmusl-arm64v8'
37-
- 'linux-ppc64le'
38-
- 'linux-s390x'
39-
- 'wasm32'
34+
#- 'linux-armv6'
35+
#- 'linuxmusl-x64'
36+
#- 'linuxmusl-arm64v8'
37+
#- 'linux-ppc64le'
38+
#- 'linux-s390x'
39+
#- 'wasm32'
4040
- 'win32-ia32'
4141
- 'win32-x64'
4242
- 'win32-arm64v8'

LIBVIPS_VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
8.16.0
1+
8.15.3

THIRD-PARTY-NOTICES.json

Lines changed: 163 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,163 @@
1+
[
2+
{
3+
"name": "aom",
4+
"license": "BSD 2-Clause + Alliance for Open Media Patent License 1.0",
5+
"licenseURL": [
6+
"https://aomedia.googlesource.com/aom/+/refs/heads/master/LICENSE?format=TEXT",
7+
"https://aomedia.googlesource.com/aom/+/refs/heads/master/PATENTS?format=TEXT"
8+
]
9+
},
10+
{
11+
"name": "cairo",
12+
"license": "MPL-2.0",
13+
"licenseURL": "https://gitlab.freedesktop.org/cairo/cairo/-/raw/master/COPYING-MPL-1.1"
14+
},
15+
{
16+
"name": "cgif",
17+
"license": "MIT License",
18+
"licenseURL": "https://raw.githubusercontent.com/dloebl/cgif/refs/heads/main/LICENSE"
19+
},
20+
{
21+
"name": "expat",
22+
"license": "MIT",
23+
"licenseURL": "https://raw.githubusercontent.com/libexpat/libexpat/master/expat/COPYING"
24+
},
25+
{
26+
"name": "fontconfig",
27+
"license": "fontconfig Licence",
28+
"licenseURL": "https://gitlab.freedesktop.org/fontconfig/fontconfig/-/raw/main/COPYING"
29+
},
30+
{
31+
"name": "freetype",
32+
"license": "freetype Licence",
33+
"licenseURL": "https://gitlab.freedesktop.org/freetype/freetype/-/raw/master/LICENSE.TXT"
34+
},
35+
{
36+
"name": "fribidi",
37+
"license": "LGPL-2.1",
38+
"licenseURL": "https://raw.githubusercontent.com/fribidi/fribidi/master/COPYING"
39+
},
40+
{
41+
"name": "glib",
42+
"license": "LGPL-2.1",
43+
"licenseURL": "https://gitlab.gnome.org/GNOME/glib/-/raw/master/COPYING"
44+
},
45+
{
46+
"name": "harfbuzz",
47+
"license": "MIT",
48+
"licenseURL": "https://raw.githubusercontent.com/harfbuzz/harfbuzz/master/COPYING"
49+
},
50+
{
51+
"name": "highway",
52+
"license": "BSD 3-Clause",
53+
"licenseURL": "https://raw.githubusercontent.com/google/highway/refs/heads/master/LICENSE"
54+
},
55+
{
56+
"name": "lcms",
57+
"license": "MIT",
58+
"licenseURL": "https://raw.githubusercontent.com/mm2/Little-CMS/master/COPYING"
59+
},
60+
{
61+
"name": "libarchive",
62+
"license": "BSD 2-Clause",
63+
"licenseURL": "https://raw.githubusercontent.com/libarchive/libarchive/refs/heads/master/COPYING"
64+
},
65+
{
66+
"name": "libexif",
67+
"license": "LGPL-2.1",
68+
"licenseURL": "https://raw.githubusercontent.com/libexif/libexif/master/COPYING"
69+
},
70+
{
71+
"name": "libde265",
72+
"license": "LGPL-3.0",
73+
"licenseURL": "https://raw.githubusercontent.com/strukturag/libde265/master/COPYING"
74+
},
75+
{
76+
"name": "libffi",
77+
"license": "MIT",
78+
"licenseURL": "https://raw.githubusercontent.com/libffi/libffi/master/LICENSE"
79+
},
80+
{
81+
"name": "libheif",
82+
"license": "LGPL-3.0",
83+
"licenseURL": "https://raw.githubusercontent.com/strukturag/libheif/master/COPYING"
84+
},
85+
{
86+
"name": "libimagequant",
87+
"license": "BSD 2-Clause",
88+
"licenseURL": "https://raw.githubusercontent.com/lovell/libimagequant/main/COPYRIGHT"
89+
},
90+
{
91+
"name": "mozjpeg",
92+
"license": "zlib License, IJG License, BSD-3-Clause",
93+
"licenseURL": "https://raw.githubusercontent.com/mozilla/mozjpeg/master/LICENSE.md"
94+
},
95+
{
96+
"name": "libpng",
97+
"license": "libpng License",
98+
"licenseURL": "https://raw.githubusercontent.com/glennrp/libpng/libpng16/LICENSE"
99+
},
100+
{
101+
"name": "librsvg",
102+
"license": "LGPL-2.1",
103+
"licenseURL": "https://gitlab.gnome.org/GNOME/librsvg/-/raw/main/COPYING.LIB"
104+
},
105+
{
106+
"name": "libspng",
107+
"license": "BSD 2-Clause, libpng License",
108+
"licenseURL": "https://raw.githubusercontent.com/randy408/libspng/master/LICENSE"
109+
},
110+
{
111+
"name": "libtiff",
112+
"license": "libtiff License",
113+
"licenseURL": "https://gitlab.com/libtiff/libtiff/-/raw/master/COPYRIGHT"
114+
},
115+
{
116+
"name": "libvips",
117+
"license": "LGPL-2.1",
118+
"licenseURL": "https://raw.githubusercontent.com/libvips/libvips/master/COPYING"
119+
},
120+
{
121+
"name": "libwebp",
122+
"license": "BSD-3-Clause",
123+
"licenseURL": [
124+
"https://chromium.googlesource.com/webm/libwebp/+/refs/heads/main/COPYING?format=TEXT",
125+
"https://chromium.googlesource.com/webm/libwebp/+/refs/heads/main/PATENTS?format=TEXT"
126+
]
127+
},
128+
{
129+
"name": "libxml2",
130+
"license": "MIT",
131+
"licenseURL": "https://gitlab.gnome.org/GNOME/libxml2/-/raw/master/Copyright"
132+
},
133+
{
134+
"name": "openjpeg",
135+
"license": "BDS 2-Clause",
136+
"licenseURL": "https://raw.githubusercontent.com/uclouvain/openjpeg/master/LICENSE"
137+
},
138+
{
139+
"name": "pango",
140+
"license": "GPL-2.0",
141+
"licenseURL": "https://gitlab.gnome.org/GNOME/pango/-/raw/master/COPYING"
142+
},
143+
{
144+
"name": "pixman",
145+
"license": "MIT",
146+
"licenseURL": "https://gitlab.freedesktop.org/pixman/pixman/-/raw/master/COPYING"
147+
},
148+
{
149+
"name": "poppler",
150+
"license": "GPL-2.0",
151+
"licenseURL": "https://gitlab.freedesktop.org/poppler/poppler/-/raw/master/COPYING"
152+
},
153+
{
154+
"name": "proxy-libintl",
155+
"license": "LGPL-2.0",
156+
"licenseURL": "https://raw.githubusercontent.com/frida/proxy-libintl/master/COPYING"
157+
},
158+
{
159+
"name": "zlib-ng",
160+
"license": "zlib Licence",
161+
"licenseURL": "https://raw.githubusercontent.com/zlib-ng/zlib-ng/develop/LICENSE.md"
162+
}
163+
]

build/lin.sh

Lines changed: 67 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,10 @@ VERSION_AOM=3.11.0
129129
VERSION_HEIF=1.19.5
130130
VERSION_CGIF=0.4.1
131131

132+
VERSION_DE265=1.0.15
133+
VERSION_OPENJPEG=2.5.3
134+
VERSION_POPPLER=24.04.0
135+
132136
# Check for newer versions
133137
# Skip by setting the VERSION_LATEST_REQUIRED environment variable to "false"
134138
ALL_AT_VERSION_LATEST=true
@@ -177,6 +181,9 @@ version_latest "rsvg" "$VERSION_RSVG" "5420"
177181
version_latest "aom" "$VERSION_AOM" "17628"
178182
version_latest "heif" "$VERSION_HEIF" "64439"
179183
version_latest "cgif" "$VERSION_CGIF" "dloebl/cgif"
184+
version_latest "de265" "$VERSION_DE265" "11239"
185+
version_latest "openjpeg" "$VERSION_OPENJPEG" "2550"
186+
#version_latest "poppler" "$VERSION_POPPLER" "3686"
180187
if [ "$ALL_AT_VERSION_LATEST" = "false" ]; then exit 1; fi
181188

182189
# Download and build dependencies from source
@@ -259,14 +266,22 @@ AOM_AS_FLAGS="${FLAGS}" cmake -G"Unix Makefiles" \
259266
..
260267
make install/strip
261268

269+
mkdir ${DEPS}/de265
270+
$CURL https://github.com/strukturag/libde265/releases/download/v${VERSION_DE265}/libde265-${VERSION_DE265}.tar.gz | tar xzC ${DEPS}/de265 --strip-components=1
271+
cd ${DEPS}/de265
272+
CFLAGS="${CFLAGS} -O3" CXXFLAGS="${CXXFLAGS} -O3" cmake -G"Unix Makefiles" \
273+
-DCMAKE_TOOLCHAIN_FILE=${ROOT}/Toolchain.cmake -DCMAKE_INSTALL_PREFIX=${TARGET} -DCMAKE_INSTALL_LIBDIR=lib -DCMAKE_BUILD_TYPE=Release \
274+
-DBUILD_SHARED_LIBS=FALSE -DENABLE_ENCODER=FALSE -DENABLE_DECODER=FALSE
275+
make install/strip
276+
262277
mkdir ${DEPS}/heif
263278
$CURL https://github.com/strukturag/libheif/releases/download/v${VERSION_HEIF}/libheif-${VERSION_HEIF}.tar.gz | tar xzC ${DEPS}/heif --strip-components=1
264279
cd ${DEPS}/heif
265280
# Downgrade minimum required CMake version to 3.12 - https://github.com/strukturag/libheif/issues/975
266281
sed -i'.bak' "/^cmake_minimum_required/s/3.16.3/3.12/" CMakeLists.txt
267282
CFLAGS="${CFLAGS} -O3" CXXFLAGS="${CXXFLAGS} -O3" cmake -G"Unix Makefiles" \
268283
-DCMAKE_TOOLCHAIN_FILE=${ROOT}/Toolchain.cmake -DCMAKE_INSTALL_PREFIX=${TARGET} -DCMAKE_INSTALL_LIBDIR=lib -DCMAKE_BUILD_TYPE=Release \
269-
-DBUILD_SHARED_LIBS=FALSE -DBUILD_TESTING=0 -DENABLE_PLUGIN_LOADING=0 -DWITH_EXAMPLES=0 -DWITH_LIBDE265=0 -DWITH_X265=0
284+
-DBUILD_SHARED_LIBS=FALSE -DBUILD_TESTING=0 -DENABLE_PLUGIN_LOADING=0 -DWITH_EXAMPLES=0 -DWITH_LIBDE265=TRUE -DWITH_X265=0
270285
make install/strip
271286

272287
mkdir ${DEPS}/jpeg
@@ -439,6 +454,51 @@ CFLAGS="${CFLAGS} -O3" meson setup _build --default-library=static --buildtype=r
439454
-Dtests=false
440455
meson install -C _build --tag devel
441456

457+
mkdir -p ${DEPS}/openjpeg/build
458+
$CURL https://github.com/uclouvain/openjpeg/archive/v${VERSION_OPENJPEG}.tar.gz | tar xzC ${DEPS}/openjpeg --strip-components=1
459+
cd ${DEPS}/openjpeg/build
460+
LDFLAGS=${LDFLAGS/\$/} cmake .. -G"Unix Makefiles" \
461+
-DCMAKE_TOOLCHAIN_FILE=${ROOT}/Toolchain.cmake -DCMAKE_PREFIX_PATH=${TARGET} -DCMAKE_INSTALL_PREFIX=${TARGET} -DCMAKE_BUILD_TYPE=Release \
462+
-DBUILD_SHARED_LIBS=FALSE -DBUILD_CODEC=OFF
463+
make install/strip
464+
465+
mkdir -p ${DEPS}/poppler/build
466+
$CURL https://gitlab.freedesktop.org/poppler/poppler/-/archive/poppler-${VERSION_POPPLER}/poppler-poppler-${VERSION_POPPLER}.tar.bz2 | tar xjC ${DEPS}/poppler --strip-components=1
467+
cd ${DEPS}/poppler/build
468+
LDFLAGS=${LDFLAGS/\$/} cmake .. -G"Unix Makefiles" \
469+
-DCMAKE_TOOLCHAIN_FILE=${ROOT}/Toolchain.cmake\
470+
-DCMAKE_PREFIX_PATH=${TARGET} \
471+
-DCMAKE_INSTALL_PREFIX=${TARGET} \
472+
-DCMAKE_INSTALL_LIBDIR=lib \
473+
-DCMAKE_BUILD_TYPE=Release \
474+
-DBUILD_SHARED_LIBS=FALSE \
475+
-DBUILD_CPP_TESTS=OFF \
476+
-DBUILD_GTK_TESTS=OFF \
477+
-DBUILD_QT5_TESTS=OFF \
478+
-DBUILD_QT6_TESTS=OFF \
479+
-DBUILD_MANUAL_TESTS=OFF \
480+
-DENABLE_BOOST=OFF \
481+
-DENABLE_CMS=lcms2 \
482+
-DENABLE_CPP=OFF \
483+
-DENABLE_DCTDECODER=libjpeg \
484+
-DENABLE_GLIB=ON \
485+
-DENABLE_GOBJECT_INTROSPECTION=OFF \
486+
-DENABLE_GPGME=OFF \
487+
-DENABLE_GTK_DOC=OFF \
488+
-DENABLE_LIBCURL=OFF \
489+
-DENABLE_LIBOPENJPEG=openjpeg2 \
490+
-DENABLE_LIBPNG=ON \
491+
-DENABLE_LIBTIFF=ON \
492+
-DENABLE_NSS3=OFF \
493+
-DENABLE_QT5=OFF \
494+
-DENABLE_QT6=OFF \
495+
-DENABLE_UNSTABLE_API_ABI_HEADERS=ON \
496+
-DENABLE_UTILS=OFF \
497+
-DENABLE_ZLIB=ON \
498+
-DENABLE_ZLIB_UNCOMPRESS=OFF \
499+
-DEXTRA_WARN=OFF
500+
make install/strip
501+
442502
mkdir ${DEPS}/vips
443503
$CURL https://github.com/libvips/libvips/releases/download/v${VERSION_VIPS}/vips-${VERSION_VIPS}.tar.xz | tar xJC ${DEPS}/vips --strip-components=1
444504
cd ${DEPS}/vips
@@ -464,7 +524,7 @@ sed -i'.bak' "/subdir('man')/{N;N;N;N;d;}" meson.build
464524
CFLAGS="${CFLAGS} -O3" CXXFLAGS="${CXXFLAGS} -O3" meson setup _build --default-library=shared --buildtype=release --strip --prefix=${TARGET} ${MESON} \
465525
-Ddeprecated=false -Dexamples=false -Dintrospection=disabled -Dmodules=disabled -Dcfitsio=disabled -Dfftw=disabled -Djpeg-xl=disabled \
466526
${WITHOUT_HIGHWAY:+-Dhighway=disabled} -Dorc=disabled -Dmagick=disabled -Dmatio=disabled -Dnifti=disabled -Dopenexr=disabled \
467-
-Dopenjpeg=disabled -Dopenslide=disabled -Dpdfium=disabled -Dpoppler=disabled -Dquantizr=disabled \
527+
-Dopenslide=disabled -Dpdfium=disabled -Dquantizr=disabled \
468528
-Dppm=false -Danalyze=false -Dradiance=false \
469529
${LINUX:+-Dcpp_link_args="$LDFLAGS -Wl,-Bsymbolic-functions -Wl,--version-script=$DEPS/vips/vips.map $EXCLUDE_LIBS"}
470530
meson install -C _build --tag runtime,devel
@@ -526,6 +586,7 @@ printf "{\n\
526586
\"cgif\": \"${VERSION_CGIF}\",\n\
527587
\"exif\": \"${VERSION_EXIF}\",\n\
528588
\"expat\": \"${VERSION_EXPAT}\",\n\
589+
\"de265\": \"${VERSION_DE265}\",\n\
529590
\"ffi\": \"${VERSION_FFI}\",\n\
530591
\"fontconfig\": \"${VERSION_FONTCONFIG}\",\n\
531592
\"freetype\": \"${VERSION_FREETYPE}\",\n\
@@ -537,9 +598,11 @@ printf "{\n\
537598
\"imagequant\": \"${VERSION_IMAGEQUANT}\",\n\
538599
\"lcms\": \"${VERSION_LCMS2}\",\n\
539600
\"mozjpeg\": \"${VERSION_MOZJPEG}\",\n\
601+
\"openjpeg\": \"${VERSION_OPENJPEG}\",\n\
540602
\"pango\": \"${VERSION_PANGO}\",\n\
541603
\"pixman\": \"${VERSION_PIXMAN}\",\n\
542604
\"png\": \"${VERSION_PNG16}\",\n\
605+
\"poppler\": \"${VERSION_POPPLER}\",\n\
543606
\"proxy-libintl\": \"${VERSION_PROXY_LIBINTL}\",\n\
544607
\"rsvg\": \"${VERSION_RSVG}\",\n\
545608
\"spng\": \"${VERSION_SPNG}\",\n\
@@ -553,7 +616,7 @@ printf "{\n\
553616
printf "\"${PLATFORM}\"" >platform.json
554617

555618
# Add third-party notices
556-
$CURL -O https://raw.githubusercontent.com/lovell/sharp-libvips/main/THIRD-PARTY-NOTICES.md
619+
$CURL -O https://raw.githubusercontent.com/tropy/sharp-libvips/main/THIRD-PARTY-NOTICES.json
557620

558621
# Create the tarball
559622
ls -al lib
@@ -562,8 +625,7 @@ mv lib-filtered lib
562625
tar chzf ${PACKAGE}/libvips-${VERSION_VIPS}-${PLATFORM}.tar.gz \
563626
include \
564627
lib \
565-
*.json \
566-
THIRD-PARTY-NOTICES.md
628+
*.json
567629

568630
# Allow tarballs to be read outside container
569631
chmod 644 ${PACKAGE}/libvips-${VERSION_VIPS}-${PLATFORM}.tar.*

build/win.sh

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,8 @@ case ${PLATFORM} in
2222
;;
2323
esac
2424

25-
FILENAME="vips-dev-${ARCH}-web-${VERSION_VIPS}-static.zip"
26-
URL="https://github.com/libvips/build-win64-mxe/releases/download/v${VERSION_VIPS}/${FILENAME}"
25+
FILENAME="vips-dev-${ARCH}-tropy-${VERSION_VIPS}.zip"
26+
URL="https://github.com/tropy/build-win64-mxe/releases/download/v${VERSION_VIPS}/${FILENAME}"
2727
echo "Downloading $URL"
2828
$CURL -O $URL
2929
unzip $FILENAME
@@ -37,19 +37,18 @@ cp bin/*.dll lib/
3737
printf "\"${PLATFORM}\"" >platform.json
3838

3939
# Add third-party notices
40-
$CURL -O https://raw.githubusercontent.com/lovell/sharp-libvips/main/THIRD-PARTY-NOTICES.md
40+
$CURL -O https://raw.githubusercontent.com/tropy/sharp-libvips/main/THIRD-PARTY-NOTICES.json
4141

4242
echo "Creating tarball"
4343
tar czf /packaging/libvips-${VERSION_VIPS}-${PLATFORM}.tar.gz \
4444
include \
4545
lib/glib-2.0 \
4646
lib/libvips.lib \
4747
lib/*.dll \
48-
*.json \
49-
THIRD-PARTY-NOTICES.md
48+
*.json
5049

5150
# Allow tarballs to be read outside container
5251
chmod 644 /packaging/libvips-${VERSION_VIPS}-${PLATFORM}.tar.*
5352

5453
# Remove working directories
55-
rm -rf lib include *.json THIRD-PARTY-NOTICES.md
54+
rm -rf lib include *.json

0 commit comments

Comments
 (0)