From 9211f80ed71432223e15a4f80283f6138dd63174 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jack=C2=B7Boos=C2=B7Yu?= <47264268+JackBoosY@users.noreply.github.com> Date: Thu, 27 Aug 2020 20:24:39 -0700 Subject: [bigint/zxing-cpp] Adapter xcode 5.1.1 and set it as a dependency of zxing-cpp (#13129) * [bigint] Adapter xcode 5.1.1 * [bigint] Add vcpkg-cmake-wrapper * [zxing-cpp] use vcpkg bigint instead --- ports/zxing-cpp/0003-fix-dependency-bigint.patch | 50 ++++++++++++++++++++++++ ports/zxing-cpp/CONTROL | 4 +- ports/zxing-cpp/portfile.cmake | 3 ++ 3 files changed, 56 insertions(+), 1 deletion(-) create mode 100644 ports/zxing-cpp/0003-fix-dependency-bigint.patch (limited to 'ports/zxing-cpp') diff --git a/ports/zxing-cpp/0003-fix-dependency-bigint.patch b/ports/zxing-cpp/0003-fix-dependency-bigint.patch new file mode 100644 index 000000000..1601d3e39 --- /dev/null +++ b/ports/zxing-cpp/0003-fix-dependency-bigint.patch @@ -0,0 +1,50 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 54071bd..0edd0e9 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -44,6 +44,12 @@ if(WIN32) + set(CMAKE_DEBUG_POSTFIX -debug) + endif() + ++# Bigint ++find_package(bigint CONFIG REQUIRED) ++ ++include_directories(${BIGINT_INCLUDE_DIRS}) ++link_libraries(${BIGINT_LIBRARIES}) ++ + # OpenCV classes + if(WITH_OPENCV) + find_package(OpenCV REQUIRED) +diff --git a/source_files.cmake b/source_files.cmake +index db3d8d4..39abe82 100644 +--- a/source_files.cmake ++++ b/source_files.cmake +@@ -1,28 +1,4 @@ + set(LIBZXING_FILES +- core/src/bigint/BigInteger.cc +- core/src/bigint/BigInteger.cc +- core/src/bigint/BigInteger.hh +- core/src/bigint/BigInteger.hh +- core/src/bigint/BigIntegerAlgorithms.cc +- core/src/bigint/BigIntegerAlgorithms.cc +- core/src/bigint/BigIntegerAlgorithms.hh +- core/src/bigint/BigIntegerAlgorithms.hh +- core/src/bigint/BigIntegerLibrary.hh +- core/src/bigint/BigIntegerLibrary.hh +- core/src/bigint/BigIntegerUtils.cc +- core/src/bigint/BigIntegerUtils.cc +- core/src/bigint/BigIntegerUtils.hh +- core/src/bigint/BigIntegerUtils.hh +- core/src/bigint/BigUnsigned.cc +- core/src/bigint/BigUnsigned.cc +- core/src/bigint/BigUnsigned.hh +- core/src/bigint/BigUnsigned.hh +- core/src/bigint/BigUnsignedInABase.cc +- core/src/bigint/BigUnsignedInABase.cc +- core/src/bigint/BigUnsignedInABase.hh +- core/src/bigint/BigUnsignedInABase.hh +- core/src/bigint/NumberlikeArray.hh +- core/src/bigint/NumberlikeArray.hh + core/src/zxing/aztec/AztecDetectorResult.cpp + core/src/zxing/aztec/AztecDetectorResult.h + core/src/zxing/aztec/AztecReader.cpp diff --git a/ports/zxing-cpp/CONTROL b/ports/zxing-cpp/CONTROL index 89a07a222..4f661dd19 100644 --- a/ports/zxing-cpp/CONTROL +++ b/ports/zxing-cpp/CONTROL @@ -1,7 +1,9 @@ Source: zxing-cpp -Version: 3.3.3-7 +Version: 3.3.3 +Port-Version: 8 Homepage: https://github.com/glassechidna/zxing-cpp Description: Barcode detection and decoding library. +Build-Depends: bigint Default-Features: opencv, iconv Feature: opencv diff --git a/ports/zxing-cpp/portfile.cmake b/ports/zxing-cpp/portfile.cmake index 3e9666390..f6fd43351 100644 --- a/ports/zxing-cpp/portfile.cmake +++ b/ports/zxing-cpp/portfile.cmake @@ -9,9 +9,12 @@ vcpkg_from_github( PATCHES 0001-opencv4-compat.patch 0002-improve-features.patch + 0003-fix-dependency-bigint.patch ) file(REMOVE ${SOURCE_PATH}/cmake/FindModules/FindIconv.cmake) +# Depends on port bigint +file(REMOVE_RECURSE ${SOURCE_PATH}/core/src/bigint) vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS FEATURES -- cgit v1.2.3