From 0c151e8b67dcf30a79159435e8e827c3e4e600d0 Mon Sep 17 00:00:00 2001 From: mid-kid Date: Mon, 3 Oct 2016 18:31:18 +0200 Subject: [PATCH] Volumeicon gtk2 support added --- astronaut/astronaut | 8 ++++---- satellites/volumeicon.sat | 11 +++++++++++ 2 files changed, 15 insertions(+), 4 deletions(-) diff --git a/astronaut/astronaut b/astronaut/astronaut index 972c468..ecd4760 100755 --- a/astronaut/astronaut +++ b/astronaut/astronaut @@ -155,7 +155,7 @@ _mksum() { } safe_sed() { - echo "$1" | sed 's/[[\.*^$/]/\\&/g' + echo "$1" | sed 's/[[&\.*^$/]/\\&/g' } download() { @@ -170,7 +170,7 @@ download() { _msg "Downloading $filename" [ "$3" ] && local cmd="$3" || local cmd="$cmd_download" - eval $(echo "$cmd" | sed -e "s/{dst}/'$(safe_sed "$path")'/g" -e "s@{src}@'$(safe_sed "$1")'@g") + eval $(echo "$cmd" | sed -e "s/{dst}/'$(safe_sed "$path")'/g" -e "s/{src}/'$(safe_sed "$1")'/g") checksum="$(_mksum "$path")" if [ "$2" -a "$checksum" != "$2" ]; then @@ -197,12 +197,12 @@ extrafile() { dlextract() { download "$1" "$2" - extract "$(basename $(echo "$1" | cut -d? -f1))" + extract "$(basename "$(echo "$1" | cut -d? -f1)")" } dlfile() { download "$1" "$2" - getfile "$(basename $(echo "$1" | cut -d? -f1))" + getfile "$(basename "$(echo "$1" | cut -d? -f1)")" } option() { diff --git a/satellites/volumeicon.sat b/satellites/volumeicon.sat index 78ef3f9..e69ae89 100644 --- a/satellites/volumeicon.sat +++ b/satellites/volumeicon.sat @@ -4,11 +4,22 @@ name=volumeicon version=0.5.1 update_url="http://nullwise.com/$name.html" +define_option 'gtk3: Build with gtk3 support' + dlextract "http://nullwise.com/files/$name/$name-$version.tar.gz" \ '48230f3a1843fa4cc4ec97d0da35c3f5' + +if option !gtk3; then + dlfile 'https://aur.archlinux.org/cgit/aur.git/plain/gtk2.patch?h=volumeicon-gtk2&id=213b105a3ead8ad197d2b9c41484abc5dc6627ab' \ + 'eee04eeff1c5cfdd58e47c4528ee91a1' +fi header_end cd "$name-$version" +if option !gtk3; then + patch -p2 -i ../gtk2.patch + autoreconf -i +fi sed -i -e 's/-DCOMPILEWITH_NOTIFY/ &/' ./configure compile_configure -- --enable-notify