Contents of /branches/magellan-next/core/pciutils/pciutils-3.1.8-r1.smage2
Parent Directory | Revision Log
Revision 9042 -
(show annotations)
(download)
Mon Oct 3 13:18:23 2011 UTC (12 years, 7 months ago) by niro
File size: 1752 byte(s)
Mon Oct 3 13:18:23 2011 UTC (12 years, 7 months ago) by niro
File size: 1752 byte(s)
auto added: ver bump to 3.1.8-r1
1 | # $Id$ |
2 | |
3 | PNAME="pciutils" |
4 | PVER="3.1.8" |
5 | PBUILD="r1" |
6 | |
7 | PCATEGORIE="sys-apps" |
8 | |
9 | DESCRIPTION="Various utilities dealing with the PCI bus." |
10 | HOMEPAGE="http://atrey.karlin.mff.cuni.cz/~mj/pciutils.html" |
11 | |
12 | DEPEND=">= net-misc/wget-1.12 |
13 | >= sys-apps/which-2.20 |
14 | >= virtual/glibc" |
15 | |
16 | SDEPEND=">= sys-apps/sed-4" |
17 | |
18 | SRCFILE="${PNAME}-${PVER}.tar.gz" |
19 | SRCDIR="${BUILDDIR}/${PNAME}-${PVER}" |
20 | |
21 | sminclude mtools |
22 | |
23 | SRC_URI=( |
24 | ftp://atrey.karlin.mff.cuni.cz/pub/linux/pci/${SRCFILE} |
25 | mirror://${PNAME}/${SRCFILE} |
26 | mirror://${PNAME}/${PNAME}-2.2.0-scan.patch |
27 | mirror://${PNAME}/${PNAME}-2.2.0-havepread.patch |
28 | mirror://${PNAME}/${PNAME}-2.2.4-buf.patch |
29 | ) |
30 | |
31 | UP2DATE="updatecmd ftp://atrey.karlin.mff.cuni.cz/pub/linux/pci | lasttarball gz" |
32 | |
33 | src_prepare() |
34 | { |
35 | munpack ${SRCFILE} || die |
36 | cd ${SRCDIR} |
37 | |
38 | # fix segfaults |
39 | mpatch ${PNAME}-2.2.0-scan.patch || die |
40 | |
41 | # always assume that pread exist; all newer glibc support this |
42 | mpatch ${PNAME}-2.2.0-havepread.patch || die |
43 | |
44 | # truncate long device names |
45 | mpatch ${PNAME}-2.2.4-buf.patch || die |
46 | |
47 | # fix pathes |
48 | sed -i -e '/^PREFIX=/s:=.*:=/usr:' \ |
49 | -e '/^IDSDIR=/s:=.*:=$(PREFIX)/share/misc:' \ |
50 | -e "/^LIBDIR=/s:/lib:/$(mlibdir):" \ |
51 | Makefile || die |
52 | |
53 | # update pci-ids via internet (needs wget) |
54 | ./update-pciids.sh || die |
55 | } |
56 | |
57 | src_compile() |
58 | { |
59 | cd ${SRCDIR} |
60 | # disable zlib support, or it breaks hal-0.5.10 pci support |
61 | mmake ZLIB=no DNS=yes OPT="${CFLAGS} -fPIC" || die |
62 | } |
63 | |
64 | src_install() |
65 | { |
66 | cd ${SRCDIR} |
67 | |
68 | # needed directories |
69 | minstalldir /usr/$(mlibdir) || die |
70 | minstalldir /usr/{include/pci,share/man} || die |
71 | |
72 | mmake PREFIX=${BINDIR}/usr install || die |
73 | |
74 | # our lib |
75 | minstallfile lib/libpci.\* /usr/$(mlibdir) || die |
76 | |
77 | # missing header |
78 | minstallfile lib/\*.h /usr/include/pci || die |
79 | |
80 | # docs |
81 | minstalldocs ChangeLog README TODO || die |
82 | } |