diff options
author | sunpoet <sunpoet@FreeBSD.org> | 2013-08-19 23:31:30 +0800 |
---|---|---|
committer | sunpoet <sunpoet@FreeBSD.org> | 2013-08-19 23:31:30 +0800 |
commit | 79c806de55332fa214021d5ce58b555a9e70baf1 (patch) | |
tree | a3c9a423d1a3be34ad6619fc28d03fe2d4492c6b /sysutils | |
parent | 14871e8366c3ac13eb95b9e6985e8c35cb4022fc (diff) | |
download | freebsd-ports-gnome-79c806de55332fa214021d5ce58b555a9e70baf1.tar.gz freebsd-ports-gnome-79c806de55332fa214021d5ce58b555a9e70baf1.tar.zst freebsd-ports-gnome-79c806de55332fa214021d5ce58b555a9e70baf1.zip |
- Use devel/libpci as library dependency
- Use misc/pciids as runtime dependency
- Use REINPLACE_CMD instead of patch file
- Remove unnecessary sbin/update-pciids and update-pciids.8
- Remove unnecessary pci.ids check
- Add LICENSE
- Use USES=gmake
- Use PLIST_FILES instead of PLIST
- Bump PORTREVISION for dependency/package change
- Take maintainership
Diffstat (limited to 'sysutils')
-rw-r--r-- | sysutils/pciutils/Makefile | 42 | ||||
-rw-r--r-- | sysutils/pciutils/files/patch-Makefile | 33 | ||||
-rw-r--r-- | sysutils/pciutils/pkg-plist | 8 |
3 files changed, 23 insertions, 60 deletions
diff --git a/sysutils/pciutils/Makefile b/sysutils/pciutils/Makefile index 658f2a57282a..795e0ebde158 100644 --- a/sysutils/pciutils/Makefile +++ b/sysutils/pciutils/Makefile @@ -3,32 +3,36 @@ PORTNAME= pciutils PORTVERSION= 3.2.0 +PORTREVISION= 1 CATEGORIES= sysutils MASTER_SITES= ftp://atrey.karlin.mff.cuni.cz/pub/linux/pci/ \ - ${MASTER_SITE_KERNEL_ORG} \ - ftp://metalab.unc.edu/pub/Linux/hardware/ -MASTER_SITE_SUBDIR= software/utils/pciutils + KERNEL/software/utils/pciutils \ + LOCAL/sunpoet -MAINTAINER= ports@FreeBSD.org +MAINTAINER= sunpoet@FreeBSD.org COMMENT= PCI configuration utilities -USE_GMAKE= yes +LICENSE= GPLv2 -MAN8= lspci.8 setpci.8 update-pciids.8 +LIB_DEPENDS= pci:${PORTSDIR}/devel/libpci +RUN_DEPENDS= ${LOCALBASE}/share/pciids/pci.ids:${PORTSDIR}/misc/pciids + +ALL_TARGET= ${BINS} ${MAN8} +CPPFLAGS+= -fPIC +LDFLAGS+= -L${LOCALBASE}/lib -lpci +MAKE_ENV= LANG=C +USES= gmake + +BINS= lspci setpci +MAN8= lspci.8 setpci.8 +PLIST_FILES= ${BINS:S/^/bin\//} + +post-patch: + @${REINPLACE_CMD} -e '/^CC=/d; /^CFLAGS=/ s|=|+=|; /^IDSDIR=/ s|$$|/pciids|; /^OPT=/d; /^PREFIX=/d; s| lib/$$(PCILIB)||' ${WRKSRC}/Makefile do-install: - ${INSTALL_MAN} ${WRKSRC}/lspci.8 ${PREFIX}/man/man8 - ${INSTALL_MAN} ${WRKSRC}/setpci.8 ${PREFIX}/man/man8 - ${INSTALL_MAN} ${WRKSRC}/update-pciids.8 ${PREFIX}/man/man8 - ${INSTALL_PROGRAM} ${WRKSRC}/lspci ${PREFIX}/bin - ${INSTALL_PROGRAM} ${WRKSRC}/setpci ${PREFIX}/bin - ${INSTALL_SCRIPT} ${WRKSRC}/update-pciids ${PREFIX}/sbin - @${MKDIR} ${DATADIR} - ${INSTALL_DATA} ${WRKSRC}/pci.ids ${DATADIR}/pci.ids.sample - -post-install: - @if [ ! -f ${DATADIR}/pci.ids ]; then \ - ${CP} -p ${DATADIR}/pci.ids.sample ${DATADIR}/pci.ids ; \ - fi + cd ${WRKSRC}/ && \ + ${INSTALL_PROGRAM} ${BINS} ${PREFIX}/bin/ && \ + ${INSTALL_MAN} ${MAN8} ${PREFIX}/man/man8/ .include <bsd.port.mk> diff --git a/sysutils/pciutils/files/patch-Makefile b/sysutils/pciutils/files/patch-Makefile deleted file mode 100644 index 60457eecd281..000000000000 --- a/sysutils/pciutils/files/patch-Makefile +++ /dev/null @@ -1,33 +0,0 @@ ---- Makefile.orig 2008-11-09 21:28:18.000000000 +0100 -+++ Makefile 2008-12-19 14:23:43.000000000 +0100 -@@ -1,8 +1,7 @@ - # Makefile for The PCI Utilities - # (c) 1998--2008 Martin Mares <mj@ucw.cz> - --OPT=-O2 --CFLAGS=$(OPT) -Wall -W -Wno-parentheses -Wstrict-prototypes -Wmissing-prototypes -+CFLAGS+=-Wall -W -Wno-parentheses -Wstrict-prototypes -Wmissing-prototypes - - VERSION=3.0.3 - DATE=2008-11-09 -@@ -25,10 +24,9 @@ - ABI_VERSION=.3 - - # Installation directories --PREFIX=/usr/local - SBINDIR=$(PREFIX)/sbin - SHAREDIR=$(PREFIX)/share --IDSDIR=$(SHAREDIR) -+IDSDIR=$(SHAREDIR)/pciutils - MANDIR:=$(shell if [ -d $(PREFIX)/share/man ] ; then echo $(PREFIX)/share/man ; else echo $(PREFIX)/man ; fi) - INCDIR=$(PREFIX)/include - LIBDIR=$(PREFIX)/lib -@@ -38,7 +36,7 @@ - INSTALL=install - DIRINSTALL=install -d - STRIP=-s --CC=$(CROSS_COMPILE)gcc -+CC?=$(CROSS_COMPILE)gcc - AR=$(CROSS_COMPILE)ar - RANLIB=$(CROSS_COMPILE)ranlib - diff --git a/sysutils/pciutils/pkg-plist b/sysutils/pciutils/pkg-plist deleted file mode 100644 index 9ee2568bf158..000000000000 --- a/sysutils/pciutils/pkg-plist +++ /dev/null @@ -1,8 +0,0 @@ -bin/lspci -bin/setpci -sbin/update-pciids -@unexec if cmp -s %D/share/pciutils/pci.ids.sample %D/share/pciutils/pci.ids; then rm -f %D/share/pciutils/pci.ids; fi -%%DATADIR%%/pci.ids.sample -@exec [ -f %B/pci.ids ] || cp -p %B/%f %B/pci.ids -@unexec rm -f %D/share/pciutils/pci.ids.old 2> /dev/null || true -@dirrmtry %%DATADIR%% |