]> git.pld-linux.org Git - packages/redshift.git/blob - redshift.spec
set py interpreter directly for rpm autodeps
[packages/redshift.git] / redshift.spec
1 Summary:        Adjusts the color temperature of your screen according to time of day
2 Name:           redshift
3 Version:        1.7
4 Release:        1
5 License:        GPL v3+
6 Group:          Applications/System
7 Source0:        http://launchpad.net/redshift/trunk/%{version}/+download/%{name}-%{version}.tar.bz2
8 # Source0-md5:  c56512afa292b5a94b715ed4a1841d4c
9 # Remove Ubuntu specific geoclue provider
10 Patch0:         %{name}-geoclue-provider.patch
11 # https://bugs.launchpad.net/redshift/+bug/888661
12 # http://bazaar.launchpad.net/~jonls/redshift/trunk/revision/165
13 Patch1:         %{name}-geoclue-client-check.patch
14 URL:            http://jonls.dk/redshift/
15 BuildRequires:  GConf2-devel
16 BuildRequires:  desktop-file-utils
17 BuildRequires:  geoclue-devel
18 BuildRequires:  gettext-devel
19 BuildRequires:  sed >= 4.0
20 BuildRequires:  python
21 BuildRequires:  rpm-pythonprov
22 BuildRequires:  rpmbuild(macros) >= 1.219
23 BuildRequires:  xorg-lib-libXrandr-devel
24 BuildRequires:  xorg-lib-libXxf86vm-devel
25 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
26
27 %description
28 Redshift adjusts the color temperature of your screen according to
29 your surroundings. This may help your eyes hurt less if you are
30 working in front of the screen at night.
31
32 The color temperature is set according to the position of the sun. A
33 different color temperature is set during night and daytime. During
34 twilight and early morning, the color temperature transitions smoothly
35 from night to daytime temperature to allow your eyes to slowly adapt.
36
37 This package provides the base program.
38
39 %package -n gtk-%{name}
40 Summary:        GTK integration for Redshift
41 Group:          Applications/System
42 Requires:       %{name} = %{version}-%{release}
43 Requires:       python-pygtk-gtk
44 Requires:       python-pyxdg
45
46 %description -n gtk-%{name}
47 This package provides GTK integration for Redshift, a screen color
48 temperature adjustment program.
49
50 %prep
51 %setup -q
52 %patch0 -p1
53 %patch1 -p0
54
55 %{__sed} -i -e '1s,^#!.*python,#!%{__python},' src/gtk-redshift/gtk-redshift
56
57 %build
58 %configure \
59         --disable-silent-rules
60 %{__make}
61
62 %install
63 rm -rf $RPM_BUILD_ROOT
64 %{__make} install \
65         INSTALL="install -p" \
66         DESTDIR=$RPM_BUILD_ROOT
67
68 %py_postclean
69
70 %find_lang %{name}
71 desktop-file-validate $RPM_BUILD_ROOT%{_desktopdir}/gtk-redshift.desktop
72
73 %clean
74 rm -rf $RPM_BUILD_ROOT
75
76 %post -n gtk-%{name}
77 %update_icon_cache hicolor
78
79 %postun -n gtk-%{name}
80 %update_icon_cache hicolor
81
82 %files -f %{name}.lang
83 %defattr(644,root,root,755)
84 %doc AUTHORS ChangeLog NEWS README
85 %attr(755,root,root) %{_bindir}/redshift
86 %{_mandir}/man1/redshift.1*
87
88 %files -n gtk-%{name}
89 %defattr(644,root,root,755)
90 %attr(755,root,root) %{_bindir}/gtk-redshift
91 %{py_sitescriptdir}/gtk_redshift
92 %{_iconsdir}/hicolor/scalable/apps/redshift*.svg
93 %{_desktopdir}/gtk-redshift.desktop
This page took 0.042275 seconds and 4 git commands to generate.