Skip to content

Commit

Permalink
improve bin dependency checking
Browse files Browse the repository at this point in the history
png, libtiff, lcms2 dep checking
can be conditional.
Remove zlib dependency as nobody is using it.
  • Loading branch information
Stéphane Cerveau committed Oct 25, 2021
1 parent d5eb510 commit c482bad
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ openjp2_c_args = []
foreach exe : ['opj_decompress', 'opj_compress', 'opj_dump']
exe_c = exe + '.c'
exe_src = [exe_c] + common_srcs
exe_deps = [libopenjp2_dep, libpng_dep, libtiff_dep, liblcms2_dep, zlib_dep, rt_dep, m_dep]
exe_deps = [libopenjp2_dep, libpng_dep, libtiff_dep, liblcms2_dep, rt_dep, m_dep]
exe_exe = executable (exe, exe_src
, c_args : openjp2_c_args
, include_directories : inc_dirs
Expand Down
8 changes: 3 additions & 5 deletions subprojects/packagefiles/libopenjp2/src/bin/meson.build~HEAD
Original file line number Diff line number Diff line change
Expand Up @@ -2,21 +2,19 @@

cappdata = configuration_data()

zlib_dep = dependency('zlib')

libpng_dep = dependency('libpng')
libpng_dep = dependency('libpng', required : false)
if libpng_dep.found()
cappdata.set('OPJ_HAVE_LIBPNG', 1)
cappdata.set('OPJ_HAVE_PNG_H', 1)
endif

libtiff_dep = dependency('libtiff-4')
libtiff_dep = dependency('libtiff-4', required : false)
if libtiff_dep.found()
cappdata.set('OPJ_HAVE_LIBTIFF', 1)
cappdata.set('OPJ_HAVE_TIFF_H', 1)
endif

liblcms2_dep = dependency('lcms2')
liblcms2_dep = dependency('lcms2', required : false)
if liblcms2_dep.found()
cappdata.set('OPJ_HAVE_LIBLCMS2', 1)
cappdata.set('OPJ_HAVE_LCMS2_H', 1)
Expand Down

0 comments on commit c482bad

Please sign in to comment.