Sophie

Sophie

distrib > Fedora > 14 > x86_64 > by-pkgid > 2cc8bb0eace1818ca63b2cd51a5a3b1f > files > 3

gresistor-0.0.1-17.fc14.src.rpm

%{!?python_sitelib: %define python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}

Name:             gresistor
Version:          0.0.1
Release:          17%{?dist}
Summary:          Gnome resistor color code calculator

License:          GPL+
Group:            Applications/Engineering
URL:              http://minipop.org/index.php?file=%{name}

Source0:          http://www.minipop.org/progs/%{name}/%{name}-%{version}.tar.gz
Patch0:           gresistor-0.0.1-desktop.patch

BuildArch:        noarch
BuildRoot:        %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires:    python-devel desktop-file-utils

Requires:         pygtk2-libglade

%description
To allow for identification, resistors are usually marked with
colored bands. Often refereed to as color codes, these markings
are indicative of their resistance, tolerance and temperature
coefficient. gResistor is a great program that will help you
translate a resistor color codes into a readable value.

%prep
%setup -q

%patch0 -p0 -b %{name}.desktop

%build
%{__python} setup.py build

%install
%{__rm} -rf %{buildroot}
%{__python} setup.py install -O1 --skip-build --root %{buildroot}

desktop-file-install --vendor fedora            \
    --add-category Engineering                  \
    --delete-original                           \
    --dir %{buildroot}%{_datadir}/applications/ \
    %{buildroot}%{_datadir}/applications/%{name}.desktop

%{__mkdir} -p %{buildroot}%{_datadir}/icons/hicolor/48x48/apps
%{__mv} %{buildroot}%{_datadir}/%{name}/icon.png \
        %{buildroot}%{_datadir}/icons/hicolor/48x48/apps/%{name}.png

%clean
%{__rm} -rf %{buildroot}

%post
touch --no-create %{_datadir}/icons/hicolor || :
update-desktop-database &> /dev/null ||:
%{_bindir}/gtk-update-icon-cache --quiet %{_datadir}/icons/hicolor || :

%postun
touch --no-create %{_datadir}/icons/hicolor || :
update-desktop-database &> /dev/null ||:
%{_bindir}/gtk-update-icon-cache --quiet %{_datadir}/icons/hicolor || :

%files
%defattr(-,root,root,-)
%{_bindir}/%{name}
%{_datadir}/%{name}/
%{_datadir}/icons/hicolor/48x48/apps/%{name}.png
%{_datadir}/applications/fedora-%{name}.desktop
%{python_sitelib}/SimpleGladeApp.py*
%{python_sitelib}/%{name}-%{version}-py?.?.egg-info

%changelog
* Wed Jul 21 2010 David Malcolm <dmalcolm@redhat.com> - 0.0.1-17
- Rebuilt for https://fedoraproject.org/wiki/Features/Python_2.7/MassRebuild

* Fri Jul 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.0.1-16
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild

* Tue Feb 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.0.1-15
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild

* Sat Nov 29 2008 Ignacio Vazquez-Abrams <ivazqueznet+rpm@gmail.com> - 0.0.1-14
- Fix locations for Python 2.6

* Sat Nov 29 2008 Ignacio Vazquez-Abrams <ivazqueznet+rpm@gmail.com> - 0.0.1-13
- Rebuild for Python 2.6

* Mon Jun 16 2008 Chitlesh Goorah <chitlesh@fedoraproject.org> - 0.0.1-12
- Bugfix 440866 FTBFS gresistor-0.0.1-11.fc8

* Thu Aug 23 2007 Chitlesh Goorah <chitlesh@fedoraproject.org> - 0.0.1-11
- rebuild for fedora 8

* Sun Aug 12 2007 Chitlesh Goorah <chitlesh@fedoraproject.org> - 0.0.1-10
- fixed desktop file

* Thu Dec 14 2006 Jason L Tibbitts III <tibbs@math.uh.edu> - 0.0.1-9
- Rebuild for new python
- Add python-devel dependency

* Mon Sep 04 2006 Chitlesh Goorah <chitlesh@fedoraproject.org> - 0.0.1-8
- Fixed filename of icon

* Mon Sep 04 2006 Chitlesh Goorah <chitlesh@fedoraproject.org> - 0.0.1-7
- Fixed GTK+ icon cache for icon.png

* Mon Sep 04 2006 Chitlesh Goorah <chitlesh@fedoraproject.org> - 0.0.1-6
- Updated Spec file with respect to updated python packaging guidelines
- Added patch for gresistor.desktop

* Fri Aug 25 2006 Chitlesh Goorah <chitlesh@fedoraproject.org> - 0.0.1-5
- Previous ghost files included

* Mon Aug 21 2006 Chitlesh Goorah <chitlesh@fedoraproject.org> - 0.0.1-4
- corrected Licence

* Thu Jun 29 2006 Chitlesh Goorah <chitlesh@fedoraproject.org> - 0.0.1-3
- corrected typo gResistor in %%description

* Tue Jun 13 2006 Chitlesh Goorah <chitlesh@fedoraproject.org> - 0.0.1-2
- Requires corrected and dropped mkdir in %%install

* Tue Jun 13 2006 Chitlesh Goorah <chitlesh@fedoraproject.org> - 0.0.1-1
- Initial package.