Skip to content

Commit

Permalink
Try to fix CI
Browse files Browse the repository at this point in the history
  • Loading branch information
Fanda Vacek committed Oct 7, 2024
1 parent 05b1030 commit 3c764eb
Show file tree
Hide file tree
Showing 4 changed files with 46 additions and 38 deletions.
54 changes: 31 additions & 23 deletions .github/actions/cmake/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,9 @@ inputs:
qt_version:
description: "Specify Qt version to use"
required: true
default: "6.5.3"
qt_arch:
description: "Specify Qt version to use"
description: "Specify Qt arch to use"
default: "gcc_64"
use_qt6:
description: "Specify whether we're using Qt 5 or Qt 6"
Expand All @@ -21,11 +22,11 @@ runs:
using: "composite"
steps:
# Linux deps
- name: Install/cache clazy, ninja, openldap, doctest libfuse, and Qt's dependencies
- name: Install apt packages
if: runner.os != 'Windows'
uses: awalsh128/cache-apt-pkgs-action@v1.3.0
uses: awalsh128/cache-apt-pkgs-action@v1.4.2
with:
packages: ninja-build libgl1-mesa-dev libpulse-dev libxcb-icccm4 libxcb-image0 libxcb-keysyms1 libxcb-randr0 libxcb-render-util0 libxcb-shape0 libxcb-util1 libxcb-xinerama0 libxkbcommon-x11-0 libxcb-cursor-dev clazy libfuse-dev libgstreamer-gl1.0-0 libgstreamer-plugins-base1.0-0
packages: libgl1-mesa-dev libpulse-dev libxcb-icccm4 libxcb-image0 libxcb-keysyms1 libxcb-randr0 libxcb-render-util0 libxcb-shape0 libxcb-util1 libxcb-xinerama0 libxkbcommon-x11-0 libxcb-cursor-dev clazy libfuse-dev
version: 1.0

# Windows deps
Expand All @@ -45,27 +46,34 @@ runs:
arch: ${{ inputs.qt_arch }}
install-deps: false
modules: ${{ inputs.modules }}

#- name: Setup Ninja
# uses: ashutoshvarma/setup-ninja@master
# with:
# # ninja version to download. Default: 1.10.0
# version: 1.10.0

extra: --autodesktop

- name: WASM-specific stuff
if: inputs.qt_arch == 'wasm_singlethread'
run: |
chmod +x "${Qt6_DIR}/bin/qt-cmake"
echo cmake_extra_args="'-DBUILD_SHARED_LIBS=OFF' '-DQT_HOST_PATH=$(realpath "${Qt6_DIR}/../gcc_64")'" >> "$GITHUB_ENV"
echo CMAKE_BIN="${Qt6_DIR}/bin/qt-cmake" >> "$GITHUB_ENV"
shell: bash

- name: ccache
uses: hendrikmuhs/[email protected]
with:
key: ${{ github.job }}

- name: Configure CMake
run: |
# Enable these when all warnings are fixed :^)
# CFLAGS="-Werror ${CFLAGS}" \
# CXXFLAGS="-Werror ${CXXFLAGS}" \
# -G Ninja \
cmake \
-S '${{github.workspace}}' \
-B '${{github.workspace}}/build' \
-DQF_BUILD_QML_PLUGINS=ON \
-DCMAKE_BUILD_TYPE=Release \
-DBUILD_TESTING=OFF \
-DCMAKE_EXPORT_COMPILE_COMMANDS=ON \
-DUSE_QT6=${{ inputs.use_qt6 }} \
${{ env.cmake_extra_args }} \
${{ inputs.additional_cmake_args }}
"${CMAKE_BIN:-cmake}" \
-S '${{github.workspace}}' \
-B '${{github.workspace}}/build' \
-DCMAKE_BUILD_TYPE=Release \
-DBUILD_TESTING=OFF \
-DCMAKE_C_COMPILER_LAUNCHER=ccache \
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache \
-DCMAKE_EXPORT_COMPILE_COMMANDS=ON \
-DUSE_QT6=${{ inputs.use_qt6 }} \
${{ env.cmake_extra_args }} \
${{ inputs.additional_cmake_args }}
shell: bash
16 changes: 8 additions & 8 deletions .github/workflows/installer.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,17 @@ name: Installer

on:
push:
branches: [ "master", "qe3" ]
branches: [ "master", "qe3", "fix-ci" ]
pull_request:
branches: [ "master", "qe3" ]
branches: [ "master", "qe3", "fix-ci" ]

jobs:
windows:
name: Qt 6.7 / Windows
runs-on: windows-2022
steps:
- name: Clone the repository
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
submodules: true

Expand All @@ -30,12 +30,12 @@ jobs:
# C:/Program Files/PostgreSQL/14/bin/libpq.dll
# key: ${{ runner.os }}-library-cache

- name: Get libraries
# - name: Get libraries
# if: steps.cache-libs.outputs.cache-hit != 'true'
run: |
choco install openssl.light --params "/InstallDir:C:\openssl" --version 1.1.1 -y
choco install postgresql14 --version 14.5.1 -y
shell: cmd
# run: |
# choco install openssl.light --params "/InstallDir:C:\openssl" --version 1.1.1 -y
# choco install postgresql14 --version 14.5.1 -y
# shell: cmd

- name: Setup CMake
uses: ./.github/actions/cmake
Expand Down
12 changes: 6 additions & 6 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -39,16 +39,16 @@ if(Qt_FOUND)
message(STATUS "Building libqf and qsqlmon only")
add_subdirectory(tools/qsqlmon)
else()
add_subdirectory(libsiut)
add_subdirectory(libquickevent)
add_subdirectory(quickevent)
add_subdirectory(quickhttpd)
# add_subdirectory(libsiut)
# add_subdirectory(libquickevent)
# add_subdirectory(quickevent)
# add_subdirectory(quickhttpd)
add_subdirectory(quickshow)
add_subdirectory(tools/qsqlmon)
# add_subdirectory(tools/qsqlmon)
if(WITH_QE_SHVAPI)
set(LIBSHV_WITH_BROKER OFF CACHE BOOL "")
set(LIBSHV_WITH_VISU OFF CACHE BOOL "")
add_subdirectory(3rdparty/libshv)
# add_subdirectory(3rdparty/libshv)
endif()
endif()
else()
Expand Down
2 changes: 1 addition & 1 deletion libqf/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
add_subdirectory(libqfcore)
add_subdirectory(libqfqmlwidgets)
# add_subdirectory(libqfqmlwidgets)

if(USE_QT6 AND QF_BUILD_QML_PLUGINS)
add_subdirectory(plugins)
Expand Down

0 comments on commit 3c764eb

Please sign in to comment.