File tree Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -103,6 +103,11 @@ cmake_flags=(
103
103
-DENABLE_UNINSTALL=ON
104
104
)
105
105
106
+ # System-installed libmongoc must not prevent fetch-and-build of libmongoc.
107
+ if [[ -z " $( find " ${mongoc_prefix:? } " -name ' bson-config.h' ) " ]]; then
108
+ cmake_flags+=(" -DCMAKE_DISABLE_FIND_PACKAGE_mongoc-1.0=ON" )
109
+ fi
110
+
106
111
_RUN_DISTCHECK=" "
107
112
case " ${OSTYPE:? } " in
108
113
cygwin)
@@ -271,7 +276,7 @@ if [[ -n "$(find "${mongoc_prefix:?}" -name 'bson-config.h')" ]]; then
271
276
exit 1
272
277
}
273
278
fi
274
- else
279
+ elif [[ -n " $( find install -name ' bson-config.h ' ) " ]] ; then
275
280
if [[ " ${BSON_EXTRA_ALIGNMENT:- } " == " 1" ]]; then
276
281
grep -R " #define BSON_EXTRA_ALIGN 1" install || {
277
282
echo " BSON_EXTRA_ALIGN is not 1 despite BSON_EXTRA_ALIGNMENT=1" 1>&2
283
288
exit 1
284
289
}
285
290
fi
291
+ else
292
+ echo " unexpectedly compiled using a system libmongoc library" 1>&2
293
+ exit 1
286
294
fi
You can’t perform that action at this time.
0 commit comments