diff --git a/ports/libarchive/CONTROL b/ports/libarchive/CONTROL index e15f1da44e99cd..a16b6179e27b2f 100644 --- a/ports/libarchive/CONTROL +++ b/ports/libarchive/CONTROL @@ -1,6 +1,6 @@ Source: libarchive Version: 3.4.3 -Port-Version: 2 +Port-Version: 3 Homepage: https://github.com/libarchive/libarchive Description: Library for reading and writing streaming archives Build-Depends: zlib diff --git a/ports/libarchive/portfile.cmake b/ports/libarchive/portfile.cmake index df7b6ce779d59f..148042d31ce8d0 100644 --- a/ports/libarchive/portfile.cmake +++ b/ports/libarchive/portfile.cmake @@ -64,6 +64,22 @@ vcpkg_configure_cmake( ) vcpkg_install_cmake() + +# create a very simple cmake config that just includes the required packages that have their own cmake configs +set(LIBARCHIVE_CONFIG "") +if(FEATURES MATCHES "lz4") + set(LIBARCHIVE_CONFIG "${LIBARCHIVE_CONFIG}find_package(lz4 REQUIRED)\n") +endif() +if(FEATURES MATCHES "lzma") + set(LIBARCHIVE_CONFIG "${LIBARCHIVE_CONFIG}find_package(liblzma REQUIRED)\n") +endif() +if(FEATURES MATCHES "zstd") + set(LIBARCHIVE_CONFIG "${LIBARCHIVE_CONFIG}find_package(zstd REQUIRED)\n") +endif() +if(LIBARCHIVE_CONFIG) + file(WRITE ${CURRENT_PACKAGES_DIR}/share/libarchive/libarchiveConfig.cmake "${LIBARCHIVE_CONFIG}") +endif() + vcpkg_copy_pdbs() foreach(_feature IN LISTS FEATURE_OPTIONS) diff --git a/ports/tesseract/CONTROL b/ports/tesseract/CONTROL index 530abc04dc7cea..715682442dbd54 100644 --- a/ports/tesseract/CONTROL +++ b/ports/tesseract/CONTROL @@ -1,6 +1,6 @@ Source: tesseract Version: 4.1.1 -Port-Version: 5 +Port-Version: 6 Homepage: https://github.com/tesseract-ocr/tesseract Description: An OCR Engine that was developed at HP Labs between 1985 and 1995... and now at Google. Build-Depends: leptonica, libarchive diff --git a/ports/tesseract/portfile.cmake b/ports/tesseract/portfile.cmake index d08e319071dd3d..932efffd27ce5f 100644 --- a/ports/tesseract/portfile.cmake +++ b/ports/tesseract/portfile.cmake @@ -47,7 +47,8 @@ find_package(ZLIB REQUIRED) find_package(BZip2 REQUIRED) find_package(LibXml2 REQUIRED) find_package(zstd REQUIRED) -find_package(LibLZMA REQUIRED)" TESSERACT_CONFIG "${TESSERACT_CONFIG}") +find_package(LibLZMA REQUIRED) +find_package(libarchive REQUIRED)" TESSERACT_CONFIG "${TESSERACT_CONFIG}") file(WRITE ${CURRENT_PACKAGES_DIR}/share/tesseract/TesseractConfig.cmake "${TESSERACT_CONFIG}") vcpkg_copy_tools(TOOL_NAMES tesseract AUTO_CLEAN)