You are not logged in.
Okay. This is my first try at a PKGBUILD.
pkgname=HTB-tools
pkgver=0.2.7a
pkgrel=1
pkgdesc="a tool to help simplify the difficult process of bandwidth allocation"
arch=(i686 x86_64)
url="http://htb-tools.arny.ro"
depends=()
makedepends=('flex')
conflicts=()
replaces=()
backup=()
install=
source=(http://htb-tools.arny.ro/$pkgname-current/archives/$pkgname-$pkgver.tar.gz http://unixlust.yeahost.com/others/bitops.h
md5sums=('4d827f15f79b8df645435b930e91dda0'\
'962daca65477787ec8fd8c805aca0c70')
build() {
cd $startdir/src/$pkgname-$pkgver
cp -v $startdir/src/bitops.h /usr/include/asm/bitops.h
make || return 1
make prefix=$startdir/pkg/ install
}
It errors out. What I need it to do is copy that bitops.h in /usr/include/asm before starting compilation, because it won't compile without it. Can someone please help me sort this thing out ?
PS: The bitops.h file is taken from a Debian install, because it is just missing in Arch (very strange). In my opinion the devs should include it in /usr/include/asm , because some progs just won't compile without it.
Last edited by unixlust (2007-02-04 14:44:32)
Offline
This is not a correct way to do things. You need to do another PKGBUILD with bitops.h and list this package in makedepends. In the build function, you should not install anything outside $startdir/pkg and $startdir/src.
However, the error you received is unrelated and depends from the fact that you are installing everything directly in /sbin, which is also mistaken and dangerous. The fact is that the Makefile for this app does not use the prefix variable, but OUT_DIR to define the directory where the executables are installed. Thus, you have to replace 'prefix=$startdir/pkg' with 'OUT_DIR=$startdir/pkg/sbin'.
Mortuus in anima, curam gero cutis
Offline
patroclo7, thank you very much for your suggestion. It works now Well it looks to me like a not-so-beautiful-method, that of making a separate PKGBUILD for a header file that should already exist in Arch. Anyway, I will remove the header file from the PKGBUILD once it will be present by default in Arch's kernel, as it is in all distros I tried. Thanks again !
Last edited by unixlust (2007-02-04 15:29:49)
Offline
I have no clear insight about that header, but if you think it should be included you are welcome to submit a bug for the kernel-headers package.
Mortuus in anima, curam gero cutis
Offline
Actually that file is already present in 3 locations (although not in /usr/include ) :
/usr/src/linux-26.19-ARCH/include/bitops.h
/usr/src/linux-26.19-ARCH/include/asm-generic/bitops.h
/usr/src/linux-26.19-ARCH/include/asm-i386/bitops.h
the make command probably looks in the wrong place .
Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.
clean chroot building not flexible enough ?
Try clean chroot manager by graysky
Offline
Actually that file is already present in 3 locations (although not in /usr/include ) :
/usr/src/linux-26.19-ARCH/include/bitops.h
/usr/src/linux-26.19-ARCH/include/asm-generic/bitops.h
/usr/src/linux-26.19-ARCH/include/asm-i386/bitops.hthe make command probably looks in the wrong place .
The kernel headers in /usr/src/ shouldn't be used to compile other apps than the kernel and its drivers. That's why there is a kernel-headers package to provide standardized versions of these headers. If it hasn't been done, follow patroclo7's advice to submit a bug report. Probably that include file has been created recently.
Offline