File pciutils-ids.spec of Package pciutils-ids

# spec file for package pciutils-ids
# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via

Name:           pciutils-ids
Version:        20171206
Release:        0
Summary:        PCI utilities's pci.ids database
License:        GPL-2.0+
Group:          Hardware/Other
Source:         %{name}-%{version}.tar.xz
BuildRequires:  perl-macros
Requires(post): %{_bindir}/perl
Requires(post): coreutils
BuildArch:      noarch

The database of PCI IDs for pciutils.

merge-pciids: This program merges several pci.ids files.

%setup -q


install -D -p -m 0644 pci.ids \
install -d -m755 %{buildroot}%{_bindir}
install -p -m755 %{SOURCE4} %{buildroot}%{_bindir}/merge-pciids
install -m644 /dev/null %{buildroot}%{_datadir}/pci.ids

%dir %{_datadir}/pci.ids.d
%ghost %{_datadir}/pci.ids

if [ -x %{_bindir}/merge-pciids -a -x %{_bindir}/perl ]; then
  # This should only happen in autobuild
  echo "WARNING: merge-pciids or perl not found"
  cp -p %{_datadir}/pci.ids.d/pci.ids.dist %{_datadir}/pci.ids

openSUSE Build Service is sponsored by