Skip to content

Commit

Permalink
Add mesa-freeworld plugin
Browse files Browse the repository at this point in the history
See also #110
  • Loading branch information
kwizart committed Jan 8, 2023
1 parent 1c77fb4 commit fe01dad
Show file tree
Hide file tree
Showing 3 changed files with 35 additions and 0 deletions.
13 changes: 13 additions & 0 deletions plugins/mesa-freeworld.plugin/install.sh
@@ -0,0 +1,13 @@
#!/bin/bash

for i in va vdpau ; do
_package=0
rpm -q --quiet mesa-${i}-drivers
_package=$?
if [ ${_package} == 0 ] ; then
dnf swap mesa-${i}-drivers mesa-${i}-drivers-freeworld -y
else
dnf install mesa-${i}-drivers-freeworld -y
fi
done

18 changes: 18 additions & 0 deletions plugins/mesa-freeworld.plugin/metadata.json
@@ -0,0 +1,18 @@
{
"icon": "mesa-freeworld",
"label": "mesa-freeworld",
"description": "Video HW codec drivers from mesa (AMD mostly)",
"license": "MIT",
"category": "Drivers",
"scripts": {
"exec": {
"label": "Install",
"command": "run-as-root -s install.sh"
},
"undo": {
"label": "Remove",
"command": "run-as-root -s remove.sh"
},
"status": { "command": "rpm --quiet --query mesa-va-drivers mesa-vdpau-drivers" }
}
}
4 changes: 4 additions & 0 deletions plugins/mesa-freeworld.plugin/remove.sh
@@ -0,0 +1,4 @@
#!/bin/bash

dnf remove mesa-va-drivers-freeworld mesa-vdpau-drivers-freeworld -y

0 comments on commit fe01dad

Please sign in to comment.