Blob Blame History Raw
Summary:	Graphical secure password generator
Name:		gnome-password-generator
Version:	1.5
Release:	2%{dist}
License:	GPLv2+
Group:		Applications/System
URL:		http://gnome-password.sourceforge.net/
Source0:	http://dl.sf.net/gnome-password/%{name}-%{version}.tar.gz

Patch0:		%{name}-%{version}-redhat-artwork.patch

BuildRoot:	%(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)

Requires:	gnome-python2
Requires:	hicolor-icon-theme
Requires:	pygtk2

BuildRequires:	desktop-file-utils

BuildArch:	noarch

%description
Gnome Password Generator is a GUI based secure password generator. It allows
the user to generate a specified number of random passwords of a specified
length.

%prep
%setup -q
%patch0 -p1

%build
make %{?_smp_mflags}

%install
rm -rf $RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/96x96/apps
mkdir -p $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/scalable/apps

make install DESTDIR=$RPM_BUILD_ROOT

# icon
install -m0644 %{name}.png \
  $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/96x96/apps
install -m0644 %{name}.svg \
  $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/scalable/apps

desktop-file-install --vendor gnome \
  --dir $RPM_BUILD_ROOT%{_datadir}/applications \
  $RPM_BUILD_ROOT%{_datadir}/applications/%{name}.desktop

%clean
rm -rf $RPM_BUILD_ROOT

%post
touch  --no-create %{_datadir}/icons/hicolor || :
if [ -x %{_bindir}/gtk-update-icon-cache ]; then
  %{_bindir}/gtk-update-icon-cache --quiet %{_datadir}/icons/hicolor || :
fi

%postun
touch --no-create %{_datadir}/icons/hicolor || :
if [ -x %{_bindir}/gtk-update-icon-cache ]; then
  %{_bindir}/gtk-update-icon-cache --quiet %{_datadir}/icons/hicolor || :
fi

%files
%defattr(-, root, root, -)
%doc AUTHORS ChangeLog COPYING NEWS README
%{_bindir}/%{name}
%{_datadir}/applications/%{name}.desktop
%{_datadir}/icons/hicolor/96x96/apps/%{name}.png
%{_datadir}/icons/hicolor/scalable/apps/%{name}.svg
%{_datadir}/pixmaps/%{name}.png

%changelog
* Sat Oct 06 2007 Debarshi Ray <rishi@fedoraproject.org> - 1.5-2
- Removed 'Requires: redhat-artwork' and fixed the sources. Closes Red Hat
  Bugzilla bug #313981.

* Wed Aug 22 2007 Debarshi Ray <rishi@fedoraproject.org> - 1.5-1
- Version bump to 1.5.
- Changed value of License according to Fedora licensing guidelines.
- Place icon in SVG format under /usr/share/icons/hicolor/scalable/apps.
- gnome-password-generator.desktop fixes added by upstream.

* Wed Aug 01 2007 Debarshi Ray <rishi@fedoraproject.org> - 1.4-5
- Removed Application from Categories.

* Tue Jul 31 2007 Debarshi Ray <rishi@fedoraproject.org> - 1.4-4
- Added 'Requires: redhat-artwork'.
- Trimmed the 'BuildRequires' list.
- Place icon under /usr/share/icons/hicolor/96x96/apps instead of
  /usr/share/icons/hicolor/48x48/apps.

* Sat Jul 28 2007 Debarshi Ray <rishi@fedoraproject.org> - 1.4-3
- Added 'Requires: hicolor-icon-theme'.
- Fixed 'gtk-update-icon-cache' in the post[un] scriptlets.
- Trimmed the 'make install ... DESTDIR=$RPM_BUILD_ROOT' command.
- Trimmed the 'BuildRequires' list.

* Tue Jun 30 2007 Debarshi Ray <rishi@fedoraproject.org> - 1.4-2
- Removed X-Fedora from Categories.
- Set vendor_id to "gnome".

* Tue Jun 26 2007 Debarshi Ray <rishi@fedoraproject.org> - 1.4-1
- Initial build. Imported SPECs from Dag Apt Repository and Fedora Extras 6.