diff --git a/3rdparty/dtl/CMakeLists.txt b/3rdparty/dtl/CMakeLists.txt new file mode 100644 index 0000000000..d1c5f4c003 --- /dev/null +++ b/3rdparty/dtl/CMakeLists.txt @@ -0,0 +1,23 @@ +cmake_minimum_required(VERSION 3.1) + +set(LYX_IPO_SUPPORTED FALSE) +if (POLICY CMP0069) + cmake_policy(SET CMP0069 NEW) + if (LYX_USE_IPO MATCHES "ON") + set(LYX_IPO_SUPPORTED YES) + endif() +endif() +if (POLICY CMP0075) + cmake_policy(SET CMP0075 NEW) +endif() + +set(CMAKE_ALLOW_LOOSE_LOOP_CONSTRUCTS ON) + +project(dt2dv C) + +if (WIN32) + #set_source_files_properties(dt2dv.c dv2dt.c PROPERTIES LANGUAGE C COMPILE_FLAGS _CRT_SECURE_NO_WARNINGS) +endif() +add_executable(dt2dv dt2dv.c) +add_executable(dv2dt dv2dt.c) +install(TARGETS dv2dt dt2dv DESTINATION ${LYX_UTILITIES_INSTALL_PATH}) diff --git a/CMakeLists.txt b/CMakeLists.txt index 72a8cd7215..cf1c930cc7 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -151,6 +151,7 @@ LYX_COMBO(USE_IPO "Interprocedural optimization" OFF AUTO ON) #LYX_OPTION(3RDPARTY_BUILD "Build 3rdparty libs" OFF ALL) LYX_OPTION(DISABLE_CALLSTACK_PRINTING "do not print a callstack when crashing" OFF ALL) LYX_OPTION(EXTERNAL_Z "OFF := Build 3rdparty lib zlib" ON ALL) +LYX_OPTION(EXTERNAL_DTL "OFF := Build 3rdparty commands dt2dv and dv2dt" ON ALL) LYX_OPTION(EXTERNAL_ICONV "OFF := Build 3rdparty lib iconvlib" ON ALL) LYX_OPTION(EXTERNAL_HUNSPELL "OFF := Build 3rdparty lib hunspelllib" ON ALL) LYX_COMBO(EXTERNAL_MYTHES "OFF := Build 3rdparty lib mytheslib" AUTO OFF ON) @@ -880,6 +881,10 @@ else() add_subdirectory(3rdparty/zlib) endif() +if(NOT LYX_EXTERNAL_DTL) + add_subdirectory(3rdparty/dtl) +endif() + if(LYX_USE_STD_REGEX) # Set only include path. # Use internal boost, which is known to exist