diff --git a/.cvsignore b/.cvsignore deleted file mode 100644 index e69de29..0000000 diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..4e73b37 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +usbview-1.1.tar.gz diff --git a/Makefile b/Makefile deleted file mode 100644 index b1bfe7a..0000000 --- a/Makefile +++ /dev/null @@ -1,21 +0,0 @@ -# Makefile for source rpm: usbview -# $Id$ -NAME := usbview -SPECFILE = $(firstword $(wildcard *.spec)) - -define find-makefile-common -for d in common ../common ../../common ; do if [ -f $$d/Makefile.common ] ; then if [ -f $$d/CVS/Root -a -w $$d/Makefile.common ] ; then cd $$d ; cvs -Q update ; fi ; echo "$$d/Makefile.common" ; break ; fi ; done -endef - -MAKEFILE_COMMON := $(shell $(find-makefile-common)) - -ifeq ($(MAKEFILE_COMMON),) -# attept a checkout -define checkout-makefile-common -test -f CVS/Root && { cvs -Q -d $$(cat CVS/Root) checkout common && echo "common/Makefile.common" ; } || { echo "ERROR: I can't figure out how to checkout the 'common' module." ; exit -1 ; } >&2 -endef - -MAKEFILE_COMMON := $(shell $(checkout-makefile-common)) -endif - -include $(MAKEFILE_COMMON) diff --git a/sources b/sources index e69de29..96f571e 100644 --- a/sources +++ b/sources @@ -0,0 +1 @@ +8bf5e66351156356f3ad07454123affa usbview-1.1.tar.gz diff --git a/usbview.desktop b/usbview.desktop new file mode 100644 index 0000000..6f455e2 --- /dev/null +++ b/usbview.desktop @@ -0,0 +1,9 @@ +[Desktop Entry] +Name=USB Viewer +GenericName=USB Viewer +Comment=USB topology and device viewer +Exec=usbview +Icon=usbview_icon +Terminal=false +Type=Application +Categories=System; diff --git a/usbview.spec b/usbview.spec new file mode 100644 index 0000000..1107c0b --- /dev/null +++ b/usbview.spec @@ -0,0 +1,78 @@ +Name: usbview +Version: 1.1 +Release: 4%{?dist} +Summary: USB topology and device viewer + +Group: Applications/System +License: GPLv2 +URL: http://www.kroah.com/linux-usb/ +Source0: http://www.kroah.com/linux-usb/%{name}-%{version}.tar.gz +BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) + +BuildRequires: gtk2-devel + +Source1: %{name}_icon.png +Source2: %{name}.desktop + + +BuildRequires: desktop-file-utils + + +%description +Display information about the topology of the devices connected to the USB bus +on a Linux machine. It also displays detailed information on the individual +devices. + +%prep +%setup -q +# Convert to utf-8 +for file in ChangeLog; do + iconv -f ISO-8859-1 -t UTF-8 -o $file.new $file && \ + touch -r $file $file.new && \ + mv $file.new $file +done + +%build +%configure +make %{?_smp_mflags} + + +%install +rm -rf $RPM_BUILD_ROOT +make install DESTDIR=$RPM_BUILD_ROOT + +#install desktop icon +install -Dp -m 0644 %{SOURCE1} $RPM_BUILD_ROOT%{_datadir}/pixmaps/%{name}_icon.png + +#install desktop file +desktop-file-install \ +--vendor fedora \ +--add-category="System" \ +--dir=$RPM_BUILD_ROOT%{_datadir}/applications \ +%{SOURCE2} + +%clean +rm -rf $RPM_BUILD_ROOT + + +%files +%defattr(-,root,root,-) +%doc ChangeLog COPYING* README TODO +%{_bindir}/usbview +%{_mandir}/man8/usbview* +%{_datadir}/pixmaps/%{name}_icon.png +%{_datadir}/applications/fedora-%{name}.desktop + +%changelog +* Tue Dec 15 2009 Itamar Reis Peixoto - 1.1-4 +- include --vendor fedora in desktop-file-install (required for EL-5) + +* Fri Dec 11 2009 Itamar Reis Peixoto - 1.1-3 +- increasy usage of macros, fix icon permission + +* Fri Dec 11 2009 Itamar Reis Peixoto - 1.1-2 +- install desktop icon + +* Sun Nov 29 2009 Itamar Reis Peixoto - 1.1-1 +- Initial RPM for fedora + diff --git a/usbview_icon.png b/usbview_icon.png new file mode 100644 index 0000000..85d1b81 Binary files /dev/null and b/usbview_icon.png differ