From 19fcec84d8d7d21e796c7624e521b60d28ee21ed Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sun, 7 Apr 2024 20:45:59 +0200 Subject: Adding upstream version 16.2.11+ds. Signed-off-by: Daniel Baumann --- .../build/cmake/contrib/gen_html/CMakeLists.txt | 30 ++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 src/zstd/build/cmake/contrib/gen_html/CMakeLists.txt (limited to 'src/zstd/build/cmake/contrib/gen_html/CMakeLists.txt') diff --git a/src/zstd/build/cmake/contrib/gen_html/CMakeLists.txt b/src/zstd/build/cmake/contrib/gen_html/CMakeLists.txt new file mode 100644 index 000000000..8fdd61131 --- /dev/null +++ b/src/zstd/build/cmake/contrib/gen_html/CMakeLists.txt @@ -0,0 +1,30 @@ +# ################################################################ +# Copyright (c) 2015-present, Yann Collet, Facebook, Inc. +# All rights reserved. +# +# This source code is licensed under both the BSD-style license (found in the +# LICENSE file in the root directory of this source tree) and the GPLv2 (found +# in the COPYING file in the root directory of this source tree). +# ################################################################ + +project(gen_html) +include(GetZstdLibraryVersion) + +set(CMAKE_INCLUDE_CURRENT_DIR TRUE) + +# Define programs directory, where sources and header files are located +set(LIBRARY_DIR ${ZSTD_SOURCE_DIR}/lib) +set(PROGRAMS_DIR ${ZSTD_SOURCE_DIR}/programs) +set(GENHTML_DIR ${ZSTD_SOURCE_DIR}/contrib/gen_html) +set(GENHTML_BINARY ${PROJECT_BINARY_DIR}/gen_html${CMAKE_EXECUTABLE_SUFFIX}) +include_directories(${PROGRAMS_DIR} ${LIBRARY_DIR} ${LIBRARY_DIR}/common ${GENHTML_DIR}) + +add_executable(gen_html ${GENHTML_DIR}/gen_html.cpp) + +GetZstdLibraryVersion(${LIBRARY_DIR}/zstd.h VMAJOR VMINOR VRELEASE) +set(LIBVERSION "${VMAJOR}.${VMINOR}.${VRELEASE}") +add_custom_target(zstd_manual.html ALL + ${GENHTML_BINARY} "${LIBVERSION}" "${LIBRARY_DIR}/zstd.h" "${PROJECT_BINARY_DIR}/zstd_manual.html" + DEPENDS gen_html COMMENT "Update zstd manual") + +install(FILES "${PROJECT_BINARY_DIR}/zstd_manual.html" DESTINATION "${CMAKE_INSTALL_DOCDIR}") -- cgit v1.2.3