diff options
author | Benjamin Otte <otte@redhat.com> | 2021-03-31 19:50:18 +0200 |
---|---|---|
committer | Benjamin Otte <otte@redhat.com> | 2021-04-07 16:19:32 +0200 |
commit | 790cf31a7c48fc6bfd3729c5a2d868fdb5bec820 (patch) | |
tree | e9461c7c06ce6504666cc93c8975ea033a7ae5a2 | |
parent | c4953f0398e1f86b3723171a89c6c468365ef174 (diff) | |
download | gdk-pixbuf-790cf31a7c48fc6bfd3729c5a2d868fdb5bec820.tar.gz |
build: Add a libjpeg fallback wrap
-rw-r--r-- | meson.build | 5 | ||||
-rw-r--r-- | subprojects/libjpeg.wrap | 12 |
2 files changed, 17 insertions, 0 deletions
diff --git a/meson.build b/meson.build index 93fde6629..df1800df3 100644 --- a/meson.build +++ b/meson.build @@ -315,6 +315,11 @@ if get_option('jpeg') and not native_windows_loaders # so look for it as well when jpeg.lib cannot be found jpeg_dep = cc.find_library('libjpeg', required: false) endif + + if not jpeg_dep.found() + jpeg_dep = dependency('libjpeg', required: false, fallback: 'libjpeg') + endif + if jpeg_dep.found() and cc.has_function('jpeg_destroy_decompress', dependencies: jpeg_dep) enabled_loaders += 'jpeg' loaders_deps += jpeg_dep diff --git a/subprojects/libjpeg.wrap b/subprojects/libjpeg.wrap new file mode 100644 index 000000000..1433fce3a --- /dev/null +++ b/subprojects/libjpeg.wrap @@ -0,0 +1,12 @@ +[wrap-file] +directory = jpeg-9c +source_url = http://ijg.org/files/jpegsrc.v9c.tar.gz +source_filename = jpegsrc.v9c.tar.gz +source_hash = 650250979303a649e21f87b5ccd02672af1ea6954b911342ea491f351ceb7122 +patch_url = https://wrapdb.mesonbuild.com/v1/projects/libjpeg/9c/3/get_zip +patch_filename = libjpeg-9c-3-wrap.zip +patch_hash = 2d66676d254be9198d8b6b62a798d6858c7f7cea9ed0e93809d6c035351a9bba + +[provide] +libjpeg = jpeg_dep + |