You are not logged in.

#1 2011-01-30 20:46:00

graysky
Wiki Maintainer
From: :wq
Registered: 2008-12-01
Posts: 10,729
Website

makepkg refuses to build due to depends array [solved]

Makepkg refuses to build a package based on the contents of the depends array.  My understanding is that the contents of the makedepends array are needed to build, but the contents of the depends array are needed to run the software.

Example, I want to build nvidia drivers for a kernel which I do not have installed.  I do have that specific kernel headers extracted (via a wrapper script) to $startdir/tar/lib/modules/${_kernver}/build

I get the following error when I try to build:

$ makepkg -s
==> Making package: nvidia-lts-ck 260.19.36-2 (Sun Jan 30 15:41:20 EST 2011)
==> Checking Runtime Dependencies...
==> Installing missing dependencies...
error: 'kernel26-lts-ck>=2.6.32': could not find or read package
==> ERROR: 'pacman' failed to install missing dependencies.

But if I comment out the depends array, it builds just fine.  What am I missed?

PKGBUILD:

# Maintainer: graysky <graysky AT archlinux DOT us>
# Contributer: Eric Belanger <eric@archlinux.org>

pkgname=nvidia-lts-ck
pkgver=260.19.36
_kernver='2.6.32-lts-ck'
pkgrel=2
pkgdesc="NVIDIA drivers for kernel26-lts-ck"
arch=('i686' 'x86_64')
url="http://www.nvidia.com/"
makedepends=('kernel26-lts-ck-headers>=2.6.32' 'kernel26-lts-ck-headers<2.6.33')
depends=('kernel26-lts-ck>=2.6.32' 'kernel26-lts-ck<2.6.33' "nvidia-utils=$pkgver")
provides=('nvidia')
license=('custom')
install=nvidia-lts-ck.install
if [ "$CARCH" = "i686" ]; then
  _arch='x86'
  _pkg="NVIDIA-Linux-${_arch}-${pkgver}"
  source=("ftp://download.nvidia.com/XFree86/Linux-${_arch}/${pkgver}/${_pkg}.run")
  md5sums=('2826484d87827351774449382e45c4a9')
elif [ "$CARCH" = "x86_64" ]; then
  _arch='x86_64'
  _pkg="NVIDIA-Linux-${_arch}-${pkgver}-no-compat32"
  source=("ftp://download.nvidia.com/XFree86/Linux-${_arch}/${pkgver}/${_pkg}.run")
  md5sums=('6ebc5db9066e920b0b0e48377ce5eeb5')
fi

build() {
  cd "${srcdir}"
  sh ${_pkg}.run --extract-only
  cd ${_pkg}/kernel
  make SYSSRC=$startdir/tar/lib/modules/${_kernver}/build module
}

package() {
  install -D -m644 "${srcdir}/${_pkg}/kernel/nvidia.ko" \
    "${pkgdir}/lib/modules/${_kernver}/kernel/drivers/video/nvidia.ko"
  install -d -m755 "${pkgdir}/etc/modprobe.d"
  echo "blacklist nouveau" >> "${pkgdir}/etc/modprobe.d/nouveau_blacklist-lts_ck.conf"
  install -D -m644 "${srcdir}/${_pkg}/LICENSE" "${pkgdir}/usr/share/licenses/nvidia-lts-ck/LICENSE"

EDIT:  My bad... so accustomed to using the -s switch!  I now realize I need to makepkg -d to get this to work properly.

Last edited by graysky (2011-01-30 20:59:19)

Offline

Board footer

Powered by FluxBB