Merge pull request #915 from bowlofeggs/optional_system_doctest

Provide a configure flag to use the system doctest
This commit is contained in:
Tim Stack 2021-09-25 22:37:33 -07:00 committed by GitHub
commit f4d9e51f4c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 5527 additions and 5464 deletions

View File

@ -153,6 +153,27 @@ AS_IF([test "x$enable_simd" = "xyes"], [
])
AC_ARG_WITH([system_doctest],
AS_HELP_STRING(
[--with-system-doctest],
[Use the system provided doctest library rather than the bundled one]
),
[], []
)
AS_IF([test "x$with_system_doctest" = "xyes"], [
AC_CHECK_HEADERS(doctest/doctest.h)
AS_IF([test "x$ac_cv_header_doctest_doctest_h" != "xyes"], [
AC_MSG_ERROR([system doctest not found])dnl
])
AC_DEFINE([DOCTEST_HEADER], ["doctest/doctest.h"], [doctest include path])
])
AS_IF([test "x$with_system_doctest" != "xyes"], [
AC_DEFINE([DOCTEST_HEADER], ["doctest_vendored.hh"], [doctest include path])
AS_VAR_SET(doctest_vendored_h, "doctest_vendored.hh")
AC_SUBST(doctest_vendored_h)
])
LNAV_WITH_JEMALLOC

View File

@ -151,6 +151,9 @@ dist_noinst_DATA = \
$(FORMAT_FILES) \
xterm-palette.json
EXTRA_HEADERS = \
doctest_vendored.hh
noinst_HEADERS = \
all_logs_vtab.hh \
ansi_scrubber.hh \
@ -174,6 +177,7 @@ noinst_HEADERS = \
db_sub_source.hh \
doc_status_source.hh \
doctest.hh \
$(doctest_vendored_h) \
elem_to_json.hh \
environ_vtab.hh \
field_overlay_source.hh \

File diff suppressed because it is too large Load Diff

5464
src/doctest_vendored.hh Normal file

File diff suppressed because it is too large Load Diff