Index: PKGBUILD =================================================================== --- PKGBUILD (revision 103826) +++ PKGBUILD (working copy) @@ -6,19 +6,28 @@ pkgname=unetbootin pkgver=585 -pkgrel=1 +pkgrel=2 arch=('x86_64' 'i686') license=('GPL') pkgdesc='Create bootable Live USB drives' url='http://unetbootin.sourceforge.net/' -depends=('syslinux' 'p7zip' 'qt4' 'mtools' 'polkit' 'guisu') -optdepends=('polkit-gnome: to run unetbootin directly from menu') +depends=('syslinux' 'p7zip' 'qt4' 'mtools') +optdepends=('polkit: to run unetbootin directly from menu') install=$pkgname.install source=("http://downloads.sourceforge.net/project/$pkgname/UNetbootin/$pkgver/$pkgname-source-$pkgver.tar.gz" - 'org.archlinux.pkexec.unetbootin.policy') + 'org.archlinux.pkexec.unetbootin.policy' + 'unetbootin_polkit') sha256sums=('63ee0459045c955b1ac7a6ae35be80363556e0f169565b29235e67b708ac9ccb' - '4de02f754f86707c92d20b1c7cfda323893d3d4ed54047b06c036588e677a87c') + 'b7000761e119694761538fe4eaa89b159728e86938f288c9fdda640667cdf8ce' + 'b662e7082873602e9c224a291752e3c2274fb751018bfa23a7560f79c6ecb88f') +prepare() { + cd "$srcdir" + + # Modify desktop file + sed -i "s|Exec=/usr/bin/unetbootin|Exec=/usr/bin/unetbootin_polkit|" unetbootin.desktop +} + build() { cd "$srcdir" @@ -29,9 +38,7 @@ package() { cd "$srcdir" - install -Dm755 "$pkgname" "$pkgdir/usr/bin/$pkgname.elf" - ln -s /usr/bin/guisu "$pkgdir/usr/bin/$pkgname" - + install -Dm755 "$pkgname" "$pkgdir/usr/bin/$pkgname" mkdir -p "$pkgdir/usr/share/$pkgname" install -m644 "$pkgname"_*.qm "$pkgdir/usr/share/$pkgname/" install -Dm644 "$pkgname.desktop" \ @@ -40,6 +47,7 @@ install -D "${pkgname}_${i}.png" \ "$pkgdir/usr/share/icons/hicolor/${i}x${i}/apps/$pkgname.png" done + install -m755 'unetbootin_polkit' "$pkgdir/usr/bin/unetbootin_polkit" install -Dm644 'org.archlinux.pkexec.unetbootin.policy' \ "$pkgdir/usr/share/polkit-1/actions/org.archlinux.pkexec.unetbootin.policy" } Index: org.archlinux.pkexec.unetbootin.policy =================================================================== Cannot display: file marked as a binary type. svn:mime-type = application/xml Index: unetbootin.install =================================================================== --- unetbootin.install (revision 103826) +++ unetbootin.install (working copy) @@ -1,16 +1,13 @@ post_install() { xdg-icon-resource forceupdate - echo 'If you use a lightweight windowmanager, remember to run' - echo '/usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1 to enable' - echo 'graphical authentication, which may be needed for pkexec to work.' } post_upgrade() { - xdg-icon-resource forceupdate + post_install } post_remove() { - xdg-icon-resource forceupdate + post_install } # vim:set ts=2 sw=2 et: Index: unetbootin_polkit =================================================================== --- unetbootin_polkit (revision 0) +++ unetbootin_polkit (working copy) @@ -0,0 +1,6 @@ +#!/bin/bash +if [ $(which pkexec) ]; then + pkexec --disable-internal-agent "/usr/bin/unetbootin" "$@" +else + /usr/bin/unetbootin "$@" +fi