From 54e13765ccbb6a737fb5cbf2f36cd313a327806c Mon Sep 17 00:00:00 2001 From: Martin Mares Date: Tue, 23 Aug 2005 21:33:37 +0000 Subject: [PATCH] Released as 2.1.99-test9. git-archimport-id: mj@ucw.cz--public/pciutils--main--2.2--patch-78 --- ChangeLog | 10 ++++++++++ Makefile | 21 +++++++++++---------- README | 17 +---------------- TODO | 15 +++++---------- lib/configure | 4 ++-- lib/header.h | 2 +- lspci.man | 4 ++-- update-pciids.man | 2 +- 8 files changed, 33 insertions(+), 42 deletions(-) diff --git a/ChangeLog b/ChangeLog index 526da1e..970fc77 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,15 @@ 2005-08-23 Martin Mares + * Released as 2.1.99-test9. + + * Makefile (OPT): Removed -fomit-frame-pointer, it's default in recent + gcc versions when optimizing anyway. + + * Made the path to pci.ids customizable and independent on the SHAREDIR. + Just override IDSDIR in the top-level Makefile. + + * pci.ids: Synchronized with the current database snapshot. + * lspci.man, setpci.man: Improved the man pages. Documented all access methods and which operations are privileged. diff --git a/Makefile b/Makefile index ab044f0..fd5a443 100644 --- a/Makefile +++ b/Makefile @@ -1,15 +1,16 @@ # Makefile for The PCI Utilities -# (c) 1998--2004 Martin Mares +# (c) 1998--2005 Martin Mares -OPT=-O2 -fomit-frame-pointer +OPT=-O2 CFLAGS=$(OPT) -Wall -W -Wno-parentheses -Wstrict-prototypes -Wmissing-prototypes -Winline -VERSION=2.1.99-test8 -DATE=2004-08-13 +VERSION=2.1.99-test9 +DATE=2005-08-23 PREFIX=/usr/local SBINDIR=$(PREFIX)/sbin SHAREDIR=$(PREFIX)/share +IDSDIR=$(SHAREDIR) MANDIR:=$(shell if [ -d $(PREFIX)/share/man ] ; then echo $(PREFIX)/share/man ; else echo $(PREFIX)/man ; fi) INSTALL=install DIRINSTALL=install -d @@ -40,7 +41,7 @@ $(PCILIB): $(PCIINC) force force: lib/config.h: - cd lib && ./configure $(SHAREDIR) $(VERSION) $(HOST) $(RELEASE) + cd lib && ./configure $(IDSDIR) $(VERSION) $(HOST) $(RELEASE) lspci: lspci.o common.o $(PCILIB) setpci: setpci.o common.o $(PCILIB) @@ -50,10 +51,10 @@ setpci.o: setpci.c pciutils.h $(PCIINC) common.o: common.c pciutils.h $(PCIINC) update-pciids: update-pciids.sh - sed <$< >$@ "s@^DEST=.*@DEST=$(SHAREDIR)/pci.ids@" + sed <$< >$@ "s@^DEST=.*@DEST=$(IDSDIR)/pci.ids@" %.8: %.man - M=`echo $(DATE) | sed 's/-01-/-January-/;s/-02-/-February-/;s/-03-/-March-/;s/-04-/-April-/;s/-05-/-May-/;s/-06-/-June-/;s/-07-/-July-/;s/-08-/-August-/;s/-09-/-September-/;s/-10-/-October-/;s/-11-/-November-/;s/-12-/-December-/;s/\(.*\)-\(.*\)-\(.*\)/\3 \2 \1/'` ; sed <$< >$@ "s/@TODAY@/$$M/;s/@VERSION@/pciutils-$(VERSION)/;s#@SHAREDIR@#$(SHAREDIR)#" + M=`echo $(DATE) | sed 's/-01-/-January-/;s/-02-/-February-/;s/-03-/-March-/;s/-04-/-April-/;s/-05-/-May-/;s/-06-/-June-/;s/-07-/-July-/;s/-08-/-August-/;s/-09-/-September-/;s/-10-/-October-/;s/-11-/-November-/;s/-12-/-December-/;s/\(.*\)-\(.*\)-\(.*\)/\3 \2 \1/'` ; sed <$< >$@ "s/@TODAY@/$$M/;s/@VERSION@/pciutils-$(VERSION)/;s#@IDSDIR@#$(IDSDIR)#" clean: rm -f `find . -name "*~" -o -name "*.[oa]" -o -name "\#*\#" -o -name TAGS -o -name core` @@ -64,15 +65,15 @@ distclean: clean install: all # -c is ignored on Linux, but required on FreeBSD - $(DIRINSTALL) -m 755 $(SBINDIR) $(SHAREDIR) $(MANDIR)/man8 + $(DIRINSTALL) -m 755 $(SBINDIR) $(IDSDIR) $(MANDIR)/man8 $(INSTALL) -c -m 755 -s lspci setpci $(SBINDIR) $(INSTALL) -c -m 755 update-pciids $(SBINDIR) - $(INSTALL) -c -m 644 pci.ids $(SHAREDIR) + $(INSTALL) -c -m 644 pci.ids $(IDSDIR) $(INSTALL) -c -m 644 lspci.8 setpci.8 update-pciids.8 $(MANDIR)/man8 uninstall: all rm -f $(SBINDIR)/lspci $(SBINDIR)/setpci $(SBINDIR)/update-pciids - rm -f $(SHAREDIR)/pci.ids + rm -f $(IDSDIR)/pci.ids rm -f $(MANDIR)/man8/lspci.8 $(MANDIR)/man8/setpci.8 $(MANDIR)/man8/update-pciids.8 get-ids: diff --git a/README b/README index e47ddfc..9a8810a 100644 --- a/README +++ b/README @@ -1,27 +1,12 @@ This package contains the PCI Utilities, version @VERSION@. -Copyright (c) 1997--2004 Martin Mares +Copyright (c) 1997--2005 Martin Mares All files in this package can be freely distributed and used according to the terms of the GNU General Public License, either version 2 or (at your opinion) any newer version. See http://www.gnu.org/ for details. -############################################################################ - -Beware, this is a preliminary test version! Anything might not work! - -Some more things I intend to merge before the 2.2.0 release: - - o pcimodules and possibly other Linux module related stuff - o New ID's from the pciids project - o Avoid calling show_ext_caps() for non-ext devices. - o Kill memory leaks in lib/names.c - -############################################################################ - - - 1. What's that? ~~~~~~~~~~~~~~~ The PCI Utilities package contains a library for portable access to PCI bus diff --git a/TODO b/TODO index 326c566..9c2e89f 100644 --- a/TODO +++ b/TODO @@ -1,4 +1,5 @@ -- names.c: rewrite +- names.c: remove memory leaks +- names.c: reading of separate subsystem entries - update the web page @@ -6,16 +7,10 @@ - finish PCI-X 2.0 capabilities - finish PCI Express support - reading of VPD +- change machine-readable output? +- "Class %04x" -> "%04x" +- merge pcimodules? PCIIDS: - another mirror at Atrey? - delete old DB at SF - -MERGES: -- pcimodules??? -- Debian: a couple of bug fixes -- RedHat: bug fixes -- SuSE: synced -- MDK: synced -- Slack: obsolete -- make path to pci.ids customizable diff --git a/lib/configure b/lib/configure index 8521d20..73efcc8 100755 --- a/lib/configure +++ b/lib/configure @@ -10,7 +10,7 @@ echo_n() { } echo_n "Configuring libpci for your system..." -sharedir=${1:-/usr/share} +idsdir=${1:-/usr/share} version=${2:-0.0} sys=`uname -s` rel=`uname -r` @@ -103,6 +103,6 @@ echo " dump" if [ -z "$ok" ] ; then echo "WARNING: No real configuration access method is available." fi -echo >>$c "#define PCI_PATH_IDS \"$sharedir/pci.ids\"" +echo >>$c "#define PCI_PATH_IDS \"$idsdir/pci.ids\"" echo >>$c "#define PCILIB_VERSION \"$version\"" sed '/^#define [^ ]*$/!d;s/^#define \(.*\)/\1=1/' <$c >config.mk diff --git a/lib/header.h b/lib/header.h index 9071831..f064ab8 100644 --- a/lib/header.h +++ b/lib/header.h @@ -1,7 +1,7 @@ /* * The PCI Library -- PCI Header Structure (based on ) * - * Copyright (c) 1997--2004 Martin Mares + * Copyright (c) 1997--2005 Martin Mares * * Can be freely distributed and used under the terms of the GNU GPL. */ diff --git a/lspci.man b/lspci.man index 25da19b..a65c679 100644 --- a/lspci.man +++ b/lspci.man @@ -95,7 +95,7 @@ hexadecimal and may be omitted or given as "*", both meaning "any value". Use .B -as the PCI ID list instead of @SHAREDIR@/pci.ids. +as the PCI ID list instead of @IDSDIR@/pci.ids. .TP .B -m Dump PCI device data in machine readable form (both normal and verbose format supported) @@ -181,7 +181,7 @@ Increase debug level of the library. .SH FILES .TP -.B @SHAREDIR@/pci.ids +.B @IDSDIR@/pci.ids A list of all known PCI ID's (vendors, devices, classes and subclasses). Maintained at http://pciids.sourceforge.net/, use the .B update-pciids diff --git a/update-pciids.man b/update-pciids.man index f26a354..e28dcab 100644 --- a/update-pciids.man +++ b/update-pciids.man @@ -17,7 +17,7 @@ are available, it automatically downloads the compressed version of the list. .SH FILES .TP -.B @SHAREDIR@/pci.ids +.B @IDSDIR@/pci.ids Here we install the new list. .SH SEE ALSO -- 2.39.2