mirror of https://github.com/tstack/lnav.git
[build] rejigger doctest inclusion a bit
This commit is contained in:
parent
4ba892677e
commit
954e368974
|
@ -1,6 +1,6 @@
|
|||
|
||||
# aminclude_static.am generated automatically by Autoconf
|
||||
# from AX_AM_MACROS_STATIC on Thu Sep 9 16:09:09 PDT 2021
|
||||
# from AX_AM_MACROS_STATIC on Sun Sep 26 21:58:01 PDT 2021
|
||||
|
||||
|
||||
# Code coverage
|
||||
|
|
|
@ -166,12 +166,9 @@ AS_IF([test "x$with_system_doctest" = "xyes"], [
|
|||
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)
|
||||
CPPFLAGS="-I\$(top_srcdir)/src/third-party/doctest-root $CPPFLAGS"
|
||||
])
|
||||
|
||||
|
||||
|
|
|
@ -151,9 +151,6 @@ dist_noinst_DATA = \
|
|||
$(FORMAT_FILES) \
|
||||
xterm-palette.json
|
||||
|
||||
EXTRA_HEADERS = \
|
||||
doctest_vendored.hh
|
||||
|
||||
noinst_HEADERS = \
|
||||
all_logs_vtab.hh \
|
||||
ansi_scrubber.hh \
|
||||
|
@ -176,8 +173,6 @@ noinst_HEADERS = \
|
|||
data_parser.hh \
|
||||
db_sub_source.hh \
|
||||
doc_status_source.hh \
|
||||
doctest.hh \
|
||||
$(doctest_vendored_h) \
|
||||
elem_to_json.hh \
|
||||
environ_vtab.hh \
|
||||
field_overlay_source.hh \
|
||||
|
@ -300,6 +295,7 @@ nodist_libdiag_a_SOURCES = \
|
|||
|
||||
THIRD_PARTY_SRCS = \
|
||||
third-party/backward-cpp/backward.hpp \
|
||||
third-party/doctest-root/doctest/doctest.h \
|
||||
third-party/sqlite/ext/dbdump.c \
|
||||
third-party/sqlite/ext/series.c
|
||||
|
||||
|
|
|
@ -31,7 +31,7 @@
|
|||
|
||||
#include <iostream>
|
||||
|
||||
#include "doctest.hh"
|
||||
#include "doctest/doctest.h"
|
||||
|
||||
#include "base/humanize.hh"
|
||||
|
||||
|
|
|
@ -31,7 +31,7 @@
|
|||
|
||||
#include <iostream>
|
||||
|
||||
#include "doctest.hh"
|
||||
#include "doctest/doctest.h"
|
||||
|
||||
#include "base/humanize.network.hh"
|
||||
|
||||
|
|
|
@ -31,7 +31,7 @@
|
|||
|
||||
#include <chrono>
|
||||
#include <iostream>
|
||||
#include "doctest.hh"
|
||||
#include "doctest/doctest.h"
|
||||
|
||||
#include "humanize.time.hh"
|
||||
|
||||
|
|
|
@ -32,7 +32,7 @@
|
|||
#include <zlib.h>
|
||||
#include <iostream>
|
||||
|
||||
#include "doctest.hh"
|
||||
#include "doctest/doctest.h"
|
||||
|
||||
#include "base/lnav.gzip.hh"
|
||||
|
||||
|
|
|
@ -31,7 +31,7 @@
|
|||
|
||||
#include <iostream>
|
||||
|
||||
#include "doctest.hh"
|
||||
#include "doctest/doctest.h"
|
||||
|
||||
#include "base/strnatcmp.h"
|
||||
#include "base/string_util.hh"
|
||||
|
|
|
@ -30,4 +30,4 @@
|
|||
#include "config.h"
|
||||
|
||||
#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN
|
||||
#include "doctest.hh"
|
||||
#include "doctest/doctest.h"
|
||||
|
|
|
@ -1,38 +0,0 @@
|
|||
/**
|
||||
* Copyright (c) 2021, LNAV Project
|
||||
*
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions are met:
|
||||
*
|
||||
* * Redistributions of source code must retain the above copyright notice, this
|
||||
* list of conditions and the following disclaimer.
|
||||
* * Redistributions in binary form must reproduce the above copyright notice,
|
||||
* this list of conditions and the following disclaimer in the documentation
|
||||
* and/or other materials provided with the distribution.
|
||||
* * Neither the name of Timothy Stack nor the names of its contributors
|
||||
* may be used to endorse or promote products derived from this software
|
||||
* without specific prior written permission.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ''AS IS'' AND ANY
|
||||
* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
|
||||
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
||||
* DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR ANY
|
||||
* DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
|
||||
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
|
||||
* LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
|
||||
* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*
|
||||
* @file doctest.hh
|
||||
*
|
||||
* This module provides a convient way to import the requested doctest (the
|
||||
* vendored version, or the system-provided one, as configured at build time)
|
||||
* without having to remember to use the DOCTEST_HEADER macro in new files.
|
||||
*/
|
||||
|
||||
#include "config.h"
|
||||
|
||||
#include DOCTEST_HEADER
|
|
@ -30,7 +30,7 @@
|
|||
#include "config.h"
|
||||
|
||||
#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN
|
||||
#include "doctest.hh"
|
||||
#include "doctest/doctest.h"
|
||||
|
||||
#include "byte_array.hh"
|
||||
#include "lnav_config.hh"
|
||||
|
|
|
@ -34,7 +34,7 @@
|
|||
#include "fmt/format.h"
|
||||
|
||||
#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN
|
||||
#include "doctest.hh"
|
||||
#include "doctest/doctest.h"
|
||||
#include "relative_time.hh"
|
||||
|
||||
using namespace std;
|
||||
|
|
Loading…
Reference in New Issue