Skip to content

A fast, helpful, and open-source document parser

make tesseract available

Logan Markewichafcf97d996f8
diff --git a/.github/workflows/ci-node.yml b/.github/workflows/ci-node.yml
index fd52cf0..a36bdfa 100644
--- a/.github/workflows/ci-node.yml
+++ b/.github/workflows/ci-node.yml
@@ -76,6 +76,11 @@ jobs:
target
key: ${{ runner.os }}-${{ matrix.target }}-cargo-node-${{ hashFiles('**/Cargo.lock') }}
+ - name: Force Ninja generator (Windows)
+ if: runner.os == 'Windows'
+ run: echo "CMAKE_GENERATOR=Ninja" >> $GITHUB_ENV
+ shell: bash
+
- name: Install dependencies
working-directory: packages/node
run: npm ci
diff --git a/.github/workflows/ci-python.yml b/.github/workflows/ci-python.yml
index 2515f2f..5b89cd4 100644
--- a/.github/workflows/ci-python.yml
+++ b/.github/workflows/ci-python.yml
@@ -60,6 +60,11 @@ jobs:
if: runner.os == 'macOS'
run: brew install tesseract leptonica
+ - name: Force Ninja generator (Windows)
+ if: runner.os == 'Windows'
+ run: echo "CMAKE_GENERATOR=Ninja" >> $GITHUB_ENV
+ shell: bash
+
- uses: actions/cache@v4
with:
path: |
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index 8e1694e..143ff5e 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -55,23 +55,6 @@ jobs:
if: runner.os == 'macOS'
run: brew install tesseract leptonica
- - name: Install system dependencies (Windows)
- if: runner.os == 'Windows'
- shell: pwsh
- run: |
- $vcpkg = $env:VCPKG_INSTALLATION_ROOT
- & "$vcpkg\vcpkg" install tesseract:x64-windows
-
- - name: Set vcpkg env vars (Windows)
- if: runner.os == 'Windows'
- shell: pwsh
- run: |
- $vcpkg = $env:VCPKG_INSTALLATION_ROOT
- echo "VCPKG_ROOT=$vcpkg" >> $env:GITHUB_ENV
- echo "VCPKG_DEFAULT_TRIPLET=x64-windows" >> $env:GITHUB_ENV
- echo "TESSERACT_INCLUDE_PATH=$vcpkg\installed\x64-windows\include" >> $env:GITHUB_ENV
- echo "TESSERACT_LIB_PATH=$vcpkg\installed\x64-windows\lib" >> $env:GITHUB_ENV
-
- uses: actions/cache@v4
with:
path: |
@@ -83,6 +66,11 @@ jobs:
target
key: ${{ runner.os }}-cargo-build-${{ hashFiles('**/Cargo.lock') }}
+ - name: Force Ninja generator (Windows)
+ if: runner.os == 'Windows'
+ run: echo "CMAKE_GENERATOR=Ninja" >> $GITHUB_ENV
+ shell: bash
+
- run: cargo build --workspace --all-targets --exclude liteparse-python --exclude liteparse-napi
- run: cargo test --workspace --exclude liteparse-python --exclude liteparse-napi
diff --git a/.github/workflows/release-node.yml b/.github/workflows/release-node.yml
index 59d66dd..ba96581 100644
--- a/.github/workflows/release-node.yml
+++ b/.github/workflows/release-node.yml
@@ -82,6 +82,11 @@ jobs:
sudo apt-get install -y gcc-aarch64-linux-gnu g++-aarch64-linux-gnu
echo "CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER=aarch64-linux-gnu-gcc" >> $GITHUB_ENV
+ - name: Force Ninja generator (Windows)
+ if: runner.os == 'Windows'
+ run: echo "CMAKE_GENERATOR=Ninja" >> $GITHUB_ENV
+ shell: bash
+
- uses: actions/cache@v4
with:
path: |
diff --git a/.github/workflows/release-python.yml b/.github/workflows/release-python.yml
index efd87eb..fe12ba2 100644
--- a/.github/workflows/release-python.yml
+++ b/.github/workflows/release-python.yml
@@ -81,6 +81,11 @@ jobs:
if: runner.os == 'macOS'
run: brew install tesseract leptonica
+ - name: Force Ninja generator (Windows)
+ if: runner.os == 'Windows'
+ run: echo "CMAKE_GENERATOR=Ninja" >> $GITHUB_ENV
+ shell: bash
+
- uses: actions/cache@v4
with:
path: |