Package for Ubuntu 24.04 #4
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: "Package for Ubuntu 24.04" | |
on: | |
push: | |
tags: | |
- "v*" | |
workflow_dispatch: | |
env: | |
MUPDF_VERSION: 1.24.8 | |
MUPDF_SHA256SUM: d1a54fcf8de02a8accc3950053f11575f97eb8e206f9385e07b8ff91149775ee | |
jobs: | |
package: | |
name: Package | |
runs-on: ubuntu-24.04 | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
- name: Install Dependencies | |
run: > | |
sudo apt-get update -y; | |
sudo apt-get install -y --no-install-recommends | |
cmake | |
g++ | |
lunzip | |
zlib1g-dev | |
libmupdf-dev | |
libmujs-dev | |
libgumbo-dev | |
libfreetype-dev | |
freeglut3-dev | |
libharfbuzz-dev | |
libjpeg-dev | |
libopenjp2-7-dev | |
libjbig2dec0-dev | |
libqt6svg6-dev | |
qt6-multimedia-dev | |
qt6-tools-dev | |
libpoppler-qt6-dev | |
libqt5svg5-dev | |
qtmultimedia5-dev | |
qttools5-dev | |
libpoppler-qt5-dev | |
- name: Configure with Qt5 + Poppler | |
run: > | |
cmake | |
-B build_qt5_poppler | |
-DUBUNTU_VERSION=24.04 | |
-DUSE_MUPDF=OFF | |
-DUSE_POPPLER=ON | |
-DUSE_QTPDF=OFF | |
-DUSE_EXTERNAL_RENDERER=OFF | |
-DLINK_MUJS=ON | |
-DLINK_GUMBO=ON | |
-DUSE_TRANSLATIONS=ON | |
-DQT_VERSION_MAJOR=5 | |
-DQT_VERSION_MINOR=15 | |
-DGIT_VERSION=OFF | |
-DCMAKE_BUILD_TYPE='Release' | |
-DCPACK_GENERATOR='DEB;' | |
-DCMAKE_INSTALL_PREFIX='/usr' | |
-DCMAKE_INSTALL_SYSCONFDIR='/etc' | |
-DINSTALL_LICENSE=OFF | |
- name: Build with Qt5 + Poppler | |
run: cmake --build build_qt5_poppler | |
- name: Package with Qt5 + Poppler | |
run: | | |
cpack --config build_qt5_poppler/CPackConfig.cmake | |
mv beamerpresenter-poppler-qt5-x86_64.deb beamerpresenter-poppler-qt5-noble-x86_64.deb | |
- name: Archive package with Qt5 + Poppler | |
uses: actions/upload-artifact@v4 | |
with: | |
name: beamerpresenter-poppler-qt5-noble-x86_64.deb | |
path: /home/runner/work/BeamerPresenter/BeamerPresenter/beamerpresenter-poppler-qt5-noble-x86_64.deb | |
- name: Configure with Qt6 + Poppler | |
run: > | |
cmake | |
-B build_qt6_poppler | |
-DUBUNTU_VERSION=24.04 | |
-DUSE_MUPDF=OFF | |
-DUSE_POPPLER=ON | |
-DUSE_QTPDF=OFF | |
-DUSE_EXTERNAL_RENDERER=OFF | |
-DLINK_MUJS=ON | |
-DLINK_GUMBO=ON | |
-DUSE_TRANSLATIONS=ON | |
-DQT_VERSION_MAJOR=6 | |
-DQT_VERSION_MINOR=4 | |
-DGIT_VERSION=OFF | |
-DCMAKE_BUILD_TYPE='Release' | |
-DCPACK_GENERATOR='DEB;' | |
-DCMAKE_INSTALL_PREFIX='/usr' | |
-DCMAKE_INSTALL_SYSCONFDIR='/etc' | |
-DINSTALL_LICENSE=OFF | |
- name: Build with Qt6 + Poppler | |
run: cmake --build build_qt6_poppler | |
- name: Package with Qt6 + Poppler | |
run: | | |
cpack --config build_qt6_poppler/CPackConfig.cmake | |
mv beamerpresenter-poppler-qt6-x86_64.deb beamerpresenter-poppler-qt6-noble-x86_64.deb | |
- name: Archive package with Qt6 + Poppler | |
uses: actions/upload-artifact@v4 | |
with: | |
name: beamerpresenter-poppler-qt6-noble-x86_64.deb | |
path: /home/runner/work/BeamerPresenter/BeamerPresenter/beamerpresenter-poppler-qt6-noble-x86_64.deb | |
- name: Configure with Qt5 + MuPDF | |
run: > | |
cmake | |
-B build_qt5_mupdf | |
-DUBUNTU_VERSION=24.04 | |
-DUSE_MUPDF=ON | |
-DUSE_POPPLER=OFF | |
-DUSE_QTPDF=OFF | |
-DUSE_EXTERNAL_RENDERER=OFF | |
-DLINK_MUJS=ON | |
-DLINK_GUMBO=ON | |
-DUSE_TRANSLATIONS=ON | |
-DQT_VERSION_MAJOR=5 | |
-DQT_VERSION_MINOR=15 | |
-DGIT_VERSION=OFF | |
-DCMAKE_BUILD_TYPE='Release' | |
-DCPACK_GENERATOR='DEB;' | |
-DCMAKE_INSTALL_PREFIX='/usr' | |
-DCMAKE_INSTALL_SYSCONFDIR='/etc' | |
-DINSTALL_LICENSE=OFF | |
- name: Build with Qt5 + MuPDF | |
run: cmake --build build_qt5_mupdf | |
- name: Package with Qt5 + MuPDF | |
run: | | |
cpack --config build_qt5_mupdf/CPackConfig.cmake | |
mv beamerpresenter-mupdf-qt5-x86_64.deb beamerpresenter-mupdf-qt5-noble-x86_64.deb | |
- name: Archive package with Qt5 + MuPDF | |
uses: actions/upload-artifact@v4 | |
with: | |
name: beamerpresenter-mupdf-qt5-noble-x86_64.deb | |
path: /home/runner/work/BeamerPresenter/BeamerPresenter/beamerpresenter-mupdf-qt5-noble-x86_64.deb | |
- name: Configure with Qt6 + MuPDF | |
run: > | |
cmake | |
-B build_qt6_mupdf | |
-DUBUNTU_VERSION=24.04 | |
-DUSE_MUPDF=ON | |
-DUSE_POPPLER=OFF | |
-DUSE_QTPDF=OFF | |
-DUSE_EXTERNAL_RENDERER=OFF | |
-DLINK_MUJS=ON | |
-DLINK_GUMBO=ON | |
-DUSE_TRANSLATIONS=ON | |
-DQT_VERSION_MAJOR=6 | |
-DQT_VERSION_MINOR=4 | |
-DGIT_VERSION=OFF | |
-DCMAKE_BUILD_TYPE='Release' | |
-DCPACK_GENERATOR='DEB;' | |
-DCMAKE_INSTALL_PREFIX='/usr' | |
-DCMAKE_INSTALL_SYSCONFDIR='/etc' | |
-DINSTALL_LICENSE=OFF | |
- name: Build with Qt6 + MuPDF | |
run: cmake --build build_qt6_mupdf | |
- name: Package with Qt6 + MuPDF | |
run: | | |
cpack --config build_qt6_mupdf/CPackConfig.cmake | |
mv beamerpresenter-mupdf-qt6-x86_64.deb beamerpresenter-mupdf-qt6-noble-x86_64.deb | |
- name: Archive package with Qt6 + MuPDF | |
uses: actions/upload-artifact@v4 | |
with: | |
name: beamerpresenter-mupdf-qt6-noble-x86_64.deb | |
path: /home/runner/work/BeamerPresenter/BeamerPresenter/beamerpresenter-mupdf-qt6-noble-x86_64.deb | |
- name: Download and unpack MuPDF | |
run: | | |
wget -q https://mupdf.com/downloads/archive/mupdf-${{ env.MUPDF_VERSION }}-source.tar.lz | |
sha256sum -c - <<< "${{ env.MUPDF_SHA256SUM }} mupdf-${{ env.MUPDF_VERSION }}-source.tar.lz" | |
tar -xf "mupdf-${{ env.MUPDF_VERSION }}-source.tar.lz" | |
- name: Build MuPDF | |
run : | | |
cd "mupdf-${{ env.MUPDF_VERSION }}-source" | |
rm -rf thirdparty/{freeglut,freetype,harfbuzz,jbig2dec,libjpeg,openjpeg,zlib} | |
CFLAGS+=' -fPIC -ffat-lto-objects' | |
CXXFLAGS+=' -fPIC' | |
USE_SYSTEM_LIBS='yes' | |
XCFLAGS+=' -DTOFU -DTOFU_CJK -DTOFU_SIL -DFZ_ENABLE_JS=0' | |
export CFLAGS CXXFLAGS USE_SYSTEM_LIBS XCFLAGS | |
make build=release libs | |
- name: Configure with Qt5 + small MuPDF | |
run: > | |
cmake | |
-B build_qt5_mupdf_small | |
-DUBUNTU_VERSION=24.04 | |
-DUSE_MUPDF=ON | |
-DUSE_POPPLER=OFF | |
-DUSE_QTPDF=OFF | |
-DUSE_EXTERNAL_RENDERER=OFF | |
-DLINK_MUJS=OFF | |
-DLINK_GUMBO=ON | |
-DMUPDF_LIB_PATH="$(pwd)/mupdf-${{ env.MUPDF_VERSION }}-source/build/release/libmupdf.a" | |
-DMUPDF_THIRD_LIB_PATH="$(pwd)/mupdf-${{ env.MUPDF_VERSION }}-source/build/release/libmupdf-third.a" | |
-DMUPDF_INCLUDE_DIR="$(pwd)/mupdf-${{ env.MUPDF_VERSION }}-source/include" | |
-DUSE_TRANSLATIONS=ON | |
-DQT_VERSION_MAJOR=5 | |
-DQT_VERSION_MINOR=15 | |
-DMARK_AS_SMALL=ON | |
-DGIT_VERSION=OFF | |
-DCMAKE_BUILD_TYPE='Release' | |
-DCPACK_GENERATOR='DEB;' | |
-DCMAKE_INSTALL_PREFIX='/usr' | |
-DCMAKE_INSTALL_SYSCONFDIR='/etc' | |
-DINSTALL_LICENSE=OFF | |
- name: Build with Qt5 + small MuPDF | |
run: cmake --build build_qt5_mupdf_small | |
- name: Package with Qt5 + small MuPDF | |
run: | | |
cpack --config build_qt5_mupdf_small/CPackConfig.cmake | |
mv beamerpresenter-mupdf-small-qt5-x86_64.deb beamerpresenter-mupdf-small-qt5-noble-x86_64.deb | |
- name: Archive package with Qt5 + small MuPDF | |
uses: actions/upload-artifact@v4 | |
with: | |
name: beamerpresenter-mupdf-small-qt5-noble-x86_64.deb | |
path: /home/runner/work/BeamerPresenter/BeamerPresenter/beamerpresenter-mupdf-small-qt5-noble-x86_64.deb | |
- name: Configure with Qt6 + small MuPDF | |
run: > | |
cmake | |
-B build_qt6_mupdf_small | |
-DUBUNTU_VERSION=24.04 | |
-DUSE_MUPDF=ON | |
-DUSE_POPPLER=OFF | |
-DUSE_QTPDF=OFF | |
-DUSE_EXTERNAL_RENDERER=OFF | |
-DLINK_MUJS=OFF | |
-DLINK_GUMBO=ON | |
-DMUPDF_LIB_PATH="$(pwd)/mupdf-${{ env.MUPDF_VERSION }}-source/build/release/libmupdf.a" | |
-DMUPDF_THIRD_LIB_PATH="$(pwd)/mupdf-${{ env.MUPDF_VERSION }}-source/build/release/libmupdf-third.a" | |
-DMUPDF_INCLUDE_DIR="$(pwd)/mupdf-${{ env.MUPDF_VERSION }}-source/include" | |
-DUSE_TRANSLATIONS=ON | |
-DQT_VERSION_MAJOR=6 | |
-DQT_VERSION_MINOR=4 | |
-DMARK_AS_SMALL=ON | |
-DGIT_VERSION=OFF | |
-DCMAKE_BUILD_TYPE='Release' | |
-DCPACK_GENERATOR='DEB;' | |
-DCMAKE_INSTALL_PREFIX='/usr' | |
-DCMAKE_INSTALL_SYSCONFDIR='/etc' | |
-DINSTALL_LICENSE=OFF | |
- name: Build with Qt6 + small MuPDF | |
run: cmake --build build_qt6_mupdf_small | |
- name: Package with Qt6 + small MuPDF | |
run: | | |
cpack --config build_qt6_mupdf_small/CPackConfig.cmake | |
mv beamerpresenter-mupdf-small-qt6-x86_64.deb beamerpresenter-mupdf-small-qt6-noble-x86_64.deb | |
- name: Archive package with Qt6 + small MuPDF | |
uses: actions/upload-artifact@v4 | |
with: | |
name: beamerpresenter-mupdf-small-qt6-noble-x86_64.deb | |
path: /home/runner/work/BeamerPresenter/BeamerPresenter/beamerpresenter-mupdf-small-qt6-noble-x86_64.deb | |
- name: Release | |
uses: softprops/action-gh-release@v2 | |
if: startsWith(github.ref, 'refs/tags/') | |
with: | |
files: | | |
beamerpresenter-mupdf-small-qt5-noble-x86_64.deb | |
beamerpresenter-mupdf-small-qt6-noble-x86_64.deb | |
beamerpresenter-mupdf-qt5-noble-x86_64.deb | |
beamerpresenter-mupdf-qt6-noble-x86_64.deb | |
beamerpresenter-poppler-qt5-noble-x86_64.deb | |
beamerpresenter-poppler-qt6-noble-x86_64.deb | |
draft: true | |
token: ${{ secrets.GITHUB_TOKEN }} |