# This hack (taken from rpmdb-redhat) is needed for building alternative 
# platform databases on a single arch using rpm's --target flag
%define _arch %{_target_cpu}

Summary: Comps file and header lists for the Red Hat Linux distribution
Name: comps
Version: %{compsversion}
Release: 0.%(date +"%%Y%m%d")
License: GPL
Group: Development/System
BuildRoot: %{_tmppath}/%{name}-root


[ -d %{basedir} ] || {
   echo "This specfile needs access to %{basedir}"
   exit 1

[ -f %{basedir}/comps.xml ] && [ -f %{basedir}/hdlist ] && [ -f %{basedir}/hdlist2 ]  ||  {
   echo "This specfile needs access to the comps file and header lists"
   exit 1


mkdir -p $RPM_BUILD_ROOT/usr/share/comps/%{_arch}
install -m 644 %{basedir}/comps.xml $RPM_BUILD_ROOT/usr/share/comps/%{_arch}/
install -m 644 %{basedir}/hdlist $RPM_BUILD_ROOT/usr/share/comps/%{_arch}/
install -m 644 %{basedir}/hdlist2 $RPM_BUILD_ROOT/usr/share/comps/%{_arch}/

# this is kind of ugly...
install -m 644 %{basedir}/../../.discinfo $RPM_BUILD_ROOT/usr/share/comps/%{_arch}/



* Tue Jul 23 2002 Jeremy Katz <katzj@redhat.com>
- Initial build.