You are not logged in.
I'm trying to make an Arch pkg for Kerio Mailserver Console. Because they only provide rpm based package. This my trial PKGBUILD:
pkgname=kerio-mailserver-admin
pkgver=6.1.3build838
pkgrel=1
pkgdesc="Administration Console for Kerio Mailserver"
url="http://www.kerio.com"
license=""
depends=()
makedepends=(rpmextract)
conflicts=()
replaces=()
backup=()
install=
source=(http://download.kerio.com/dwn/kms/$pkgname-$pkgver-linux.i386.rpm)
md5sums=(2ff6779181f29e9429968e76c4a53af8)
build() {
cd $startdir/src
rpmextract.sh $pkgname-$pkgver-linux.i386.rpm
chmod 755 opt usr
chmod 755 opt/kerio opt/kerio/admin
chmod 755 opt/kerio/admin/icons opt/kerio/admin/translations
chmod 755 usr/bin usr/share
chmod 755 usr/share/applications
mv opt ../pkg/
mv usr ../pkg/
}
Everything goes right, but i must use many "chmod 755" because every directory that extracted by 'rpmextract.sh' from the rpm package was created by 700 permission. Do you have any suggestion to get rid that many "chmod 755" command ?
Offline
chmod -R 755 opt usr
That should do it.
Offline
Yeah, well except it's probably not so wise to make all files executable. I would rather do something like this:
find -type d -exec chmod 755 {} ;
chmod 755 usr/bin/*
mv usr opt $startdir/pkg
All of your mips are belong to us!!
Offline
Thank you, bogomipz
That's what i really want..!
Offline
no problem, if the files already have correct permissions you don't need the usr/bin/* line. On the other hand, if all the files have some strange rights you might want to throw in this line before making the binaries executable:
find -type f -exec chmod 644 {} ;
All of your mips are belong to us!!
Offline