Showing posts with label pkgbuild. Show all posts
Showing posts with label pkgbuild. Show all posts

Friday, May 28, 2010

How to submit a package to Aur Unsupported

Was asked to upload the MadPablo Openbox theme to AUR.

What you have to do.
Make the package.
What I had to do for this was to compress the usr/share/themes/maddpable/openbox-3 folder

and upload it to ompload.org; used gompload for that.
Result is a downloadlink at: http://omploader.org/vNGZoOA.bz2
Had to md5sum the madpablo.tar.bz2
or terminal in the directory of your PKGBUILD, and to generate md5sum do this:

Code: makepkg -g >> PKGBUILD

Result: f8bd9530b5ae503cb773dfa66a1d51d0

Now I can edit PKGBUILD :
# Contributor: Pablo

pkgname=openbox-madpablo-theme
pkgver=20100528
pkgrel=1
pkgdesc="MadPablo OpenBox Theme"
arch=('any')
url="http://archbang.47.forumer.com/viewtopic.php?f=28&t=278"
license=('GPL')
depends=('openbox')
source=(http://omploader.org/vNGZoOA.bz2)
md5sums=('f8bd9530b5ae503cb773dfa66a1d51d0')

build() {
install -d ${pkgdir}/usr/share/themes/
cp -r ${srcdir}/madpablo ${pkgdir}/usr/share/themes/ || return 1
}

The url is provided as link for more info about the theme:
http://archbang.47.forumer.com/viewtopic.php?f=28&t=278.
pkgver=20100528 just is the date of doing this.
Now I have to make a folder openbox-madpablo-theme
and put only the PKGBUILD in it and compress this to
openbox-madpablo-theme.tar.gz

Now I have to register at http://aur.archlinux.org/account.php
And upload the openbox-madpablo-theme.tar.gz file and give a comment if needed.



This is the result: http://aur.archlinux.org/packages.php?ID=37577


When a package is submitted by someone else and is not maintained you can submit a new
PKGBUILD in the form of a code pastebin: http://aur.pastebin.com/

Monday, May 17, 2010

Adapting an outdated PKGBUILD -Arch

When you download a PKGBUILd and do: makepkg -sci PKGBUILD
this will be normally enought but with an outdated PKGBUILD you will have to change
some variables
Lets take this packagebuild as example

# $Id: PKGBUILD,v 1.00 2009/05/31 01:00 darkbaboon Exp $
# Contributor: Ronan Rabouin

pkgname=adeskbar
pkgver=0.1.7.4
pkgrel=1
pkgdesc="A Quick Application Launcher"
arch=('i686' 'x86_64')
url="http://www.ad-comp.be/index.php?category/ADesk-Bar"
license=('GPL3')
depends=('python')
provides=($pkgname)
conflicts=($pkgname-bzr)
source=(http://www.ad-comp.be/public/projets/ADeskBar/$pkgname-$pkgver.tar.bz2)
md5sums=('9d07f253905fda8f986795415f684550')

build() {
cd $srcdir
install -d $pkgdir/usr/{bin,share/$pkgname,share/pixmaps,share/applications}
cp -a $srcdir/$pkgname-$pkgver/src/* $pkgdir/usr/share/$pkgname
install -m 644 $srcdir/$pkgname-$pkgver/$pkgname.png $pkgdir/usr/share/pixmaps/
install -m 644 $srcdir/$pkgname-$pkgver/$pkgname.desktop $pkgdir/usr/share/applications/

echo -e "#!/bin/bash\nif [ -f ~/.config/$pkgname/config ]; then\n/usr/share/$pkgname/$pkgname\nelse\n \
/usr/share/$pkgname/$pkgname-conf\n/usr/share/$pkgname/$pkgname\nfi" >$pkgdir/usr/bin/$pkgname
chmod 755 $pkgdir/usr/bin/$pkgname
}


What had to be changed??
pkgver=0.1.7.4 had to become pkgver=0.2

source=(http://www.ad-comp.be/public/projets/ADeskBar/$pkgname-$pkgver.tar.bz2) did not work because in the version 0.2 there was suddenly an underscore in the name
so had to be changed to>
source=(http://www.ad-comp.be/public/projets/ADeskBar/adeskbar_0.2.tar.bz2)

Third the validity check was negative because the file size has changed.
So determine md5sum of the now downloaded file:
Open in terminal the folder were it is and
md5sum adeskbar_0.2.tar.bz2
which gives e71f44e1a76054af9f2d2c939c1f6d3b
So change
md5sums=('9d07f253905fda8f986795415f684550')
to
md5sums=('e71f44e1a76054af9f2d2c939c1f6d3b')

Now we can do again:
makepkg -sci PKGBUILD

And all should go well.

This last md5sum problem can also be solved by
makepkg -g >> PKGBUILD

And then:
makepkg -sci PKGBUILD

Blog Archive