From fd2abdd6bc1d035b90c0b5238bdc097461bc87ab Mon Sep 17 00:00:00 2001 From: Jan200101 Date: Sun, 19 Nov 2023 03:36:24 +0100 Subject: kernel 6.5.11 Steam Deck fixes add patching scripts, update configs for the Steam Deck (Dual Role Device support is now required for USB interfacing) --- TOOLS/bumpspec.sh | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100755 TOOLS/bumpspec.sh (limited to 'TOOLS/bumpspec.sh') diff --git a/TOOLS/bumpspec.sh b/TOOLS/bumpspec.sh new file mode 100755 index 0000000..00062b8 --- /dev/null +++ b/TOOLS/bumpspec.sh @@ -0,0 +1,25 @@ +#!/usr/bin/env bash +set -eu + +if [[ $# != 2 ]]; then + >&2 echo "error: bumpspec requires 2 arguments" + exit 1 +fi + +COMMENT="${1}" +SPEC="${2}" + +SPECRELEASE="$(grep "%define specrelease " ${SPEC})" +# assumes the release number is 3 digits +SPECRELEASE_NUMBER="$(echo ${SPECRELEASE} | cut -b 21-23)" + +NEW_SPECRELEASE_NUMBER="$(( ${SPECRELEASE_NUMBER} + 1))" +NEW_SPECRELEASE="${SPECRELEASE/${SPECRELEASE_NUMBER}/${NEW_SPECRELEASE_NUMBER}}" + +echo ${NEW_SPECRELEASE} + +sed -i "s|${SPECRELEASE}|${NEW_SPECRELEASE}|g" ${SPEC} + +rpmdev-bumpspec --comment="${COMMENT}" ${SPEC} + +sed -i "s|%{pkg_release}.1|%{pkg_release}|g" ${SPEC} -- cgit v1.2.3