This repository has been archived by the owner on May 1, 2024. It is now read-only.
Fix build with libjpeg-turbo #41
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Ubuntu | |
on: | |
pull_request: | |
push: | |
branches: master | |
release: | |
types: [published] | |
jobs: | |
build-cmake: | |
strategy: | |
matrix: | |
include: | |
- branch: 'current' | |
runs-on: 'ubuntu-latest' | |
continue-on-error: ${{ matrix.branch != 'current' }} | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/setup-python@v2 | |
with: | |
python-version: '3.x' | |
- name: 'Install python dependencies' | |
run: | | |
python -m pip install -r requirements.txt | |
- name: 'Download pdfium sources' | |
run: | | |
python pdfium_download.py --branch "${{ matrix.branch }}" --destination "pdfium" | |
- name: 'Download Ubuntu packages' | |
run: | | |
sudo apt-get install libfreetype-dev libicu-dev libjpeg-dev libopenjp2-7-dev libpng-dev libtiff-dev zlib1g-dev | |
- name: 'Configure, build and install static pdfium' | |
run: | | |
cmake -S cmake -B build_static \ | |
-DPDFIUM_ROOT="${{ github.workspace }}/pdfium" \ | |
-DCMAKE_INSTALL_PREFIX=staticprefix \ | |
-DBUILD_SHARED_LIBS=OFF | |
cmake --build build_static --parallel | |
cmake --build build_static --target install | |
- name: 'Configure, build and install shared pdfium' | |
run: | | |
cmake -S cmake -B build_shared \ | |
-DPDFIUM_ROOT="${{ github.workspace }}/pdfium" \ | |
-DCMAKE_INSTALL_PREFIX=sharedprefix \ | |
-DBUILD_SHARED_LIBS=ON | |
cmake --build build_shared --parallel | |
cmake --build build_shared --target install |