Skip to content

Commit ebd4e44

Browse files
ferdnycneheb
authored andcommitted
Meson: Fix building conntest sample without curl
1 parent 79eb767 commit ebd4e44

File tree

1 file changed

+7
-8
lines changed

1 file changed

+7
-8
lines changed

meson.build

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -68,13 +68,12 @@ if brotli_dep.found()
6868
endif
6969

7070
if get_option('webready')
71-
curl_dep = dependency('libcurl', disabler: true, required: get_option('curl'))
71+
curl_dep = dependency('libcurl', required: get_option('curl'))
72+
web_dep = declare_dependency(dependencies: [curl_dep])
73+
deps += web_dep
7274
else
73-
curl_dep = dependency('', disabler: true, required: false)
74-
endif
75-
76-
if curl_dep.found()
77-
deps += curl_dep
75+
web_dep = dependency('', disabler: true, required: false)
76+
curl_dep = web_dep
7877
endif
7978

8079
expat_dep = dependency('expat', disabler: true, required: get_option('xmp'))
@@ -118,7 +117,7 @@ cdata.set('EXV_HAVE_XMP_TOOLKIT', expat_dep.found())
118117
cdata.set('EXV_HAVE_BROTLI', brotli_dep.found())
119118
cdata.set('EXV_HAVE_ICONV', iconv_dep.found())
120119
cdata.set('EXV_HAVE_LIBZ', zlib_dep.found())
121-
cdata.set('EXV_ENABLE_WEBREADY', get_option('webready'))
120+
cdata.set('EXV_ENABLE_WEBREADY', web_dep.found())
122121
cdata.set('EXV_USE_CURL', curl_dep.found())
123122
cdata.set('EXV_ENABLE_NLS', intl_dep.found())
124123
cdata.set('EXV_ENABLE_FILESYSTEM', true)
@@ -157,7 +156,7 @@ executable(
157156

158157
samples = {
159158
'addmoddel': [],
160-
'conntest': curl_dep,
159+
'conntest': web_dep,
161160
'convert-test': [],
162161
'easyaccess-test': [],
163162
'exifcomment': [],

0 commit comments

Comments
 (0)