jurplel / install-qt-action

Install Qt on your Github Actions workflows with just one simple action
MIT License
446 stars 78 forks source link

add support for OpenSUSE containers #232

Closed firewave closed 3 months ago

firewave commented 3 months ago
name: job

on: [pull_request, push]

jobs:
  build:

    runs-on: ubuntu-22.04

    container:
      image: "opensuse/tumbleweed:latest"

    steps:
      - name: Install Qt 6.7.0
        uses: jurplel/install-qt-action@v3
        with:
          version: 6.7.0
          modules: 'qtcharts'
          cache: true
          install-deps: nosudo
/usr/bin/docker exec  017081bdefcc1e919aefa32aaf1cfdf179b9c91850dd95d4c6e00b417546bad1 sh -c "cat /etc/*release | grep ^ID"
Error: Error: Unable to locate executable file: apt-get. Please verify either the file path exists or the file can be found within a directory specified by the PATH environment variable. Also check the file mode to verify the file is executable.
firewave commented 3 months ago

Ah - I see. I can work around this by disabling install-deps and install those myself.

firewave commented 3 months ago

To make things easy I simply installed the Qt system packages and removed them again afterwards leaving all the dependencies installed.

But it turns out I do not need to install the dependencies in my case because I only require the headers. So I cannot test if this approach is actually sufficient but I think it should get you there most of the way.

jurplel commented 3 months ago

Ah - I see. I can work around this by disabling install-deps and install those myself.

Yes, I think this is how you should do it. I only coded in support for ubuntu packages because I am only supporting the hosted runners for this convenience feature. I can't possibly support every distro.

An improvement to make here might be checking the distro via some command before running install-deps, and throwing an error if it is not allowed