Skip to content

Latest commit

 

History

History
125 lines (94 loc) · 2.32 KB

ssu.spec

File metadata and controls

125 lines (94 loc) · 2.32 KB
 
3
4
5
Release: 1
Summary: SSU enabler for RND
Group: System/Base
7
8
9
10
11
12
Source0: %{name}-%{version}.tar.gz
URL: https://github.com/nemomobile/ssu
BuildRequires: pkgconfig(QtCore)
BuildRequires: pkgconfig(libzypp)
BuildRequires: pkgconfig(QtSystemInfo)
BuildRequires: pkgconfig(qt-boostable)
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
Requires(pre): shadow-utils
Requires(postun): shadow-utils
Requires: ssu-vendor-data
%description
%{summary}.
%files
%defattr(-,root,root,-)
%{_libdir}/zypp/plugins/urlresolver/*
%{_bindir}/rndssu
%{_libdir}/*.so.*
%dir %{_sysconfdir}/zypp/credentials.d
%package vendor-data-example
Summary: Sample vendor configuration data
Group: System/Base
%description vendor-data-example
%{summary}. A vendor (including Nemo) is supposed to put those configuration on device.
%files vendor-data-example
%defattr(-,root,root,-)
%attr(0664, root, ssu) %config(noreplace) %{_sysconfdir}/ssu/ssu.ini
%{_datadir}/ssu/*.ini
%package rnd-ui
Summary: Shiny user interface for %{name}
Group: System/Base
%description rnd-ui
%{summary}. With ponies!
%files rnd-ui
%defattr(-,root,root,-)
%{_bindir}/rndregisterui
%{_datadir}/applications/*.desktop
%package devel
Summary: Development files for %{name}
Group: Development/Libraries
Requires: %{name} = %{version}-%{release}
%description devel
%{summary}.
%files devel
%defattr(-,root,root,-)
%{_libdir}/*.so
%{_includedir}/ssu.h
%package tests
Summary: Unit tests for %{name}
Group: Development/Libraries
Requires: testrunner-lite
%description tests
%{summary}.
%files tests
%defattr(-,root,root,-)
/opt/tests/%{name}
%package tools
Summary: Tools for %{name}
Group: Development/Libraries
Requires: rpm
%description tools
%{summary}.
%files tools
%defattr(-,root,root,-)
%attr(0755, -, -) /usr/sbin/ssu-repos.sh
%prep
%setup -q
%build
qmake DEFINES+='TARGET_ARCH=\\\"\"%{_target_cpu}\"\\\"' -recursive
make %{?_smp_mflags}
%install
make INSTALL_ROOT=%{buildroot} install
mkdir -p %{buildroot}/%{_sysconfdir}/zypp/credentials.d
%pre
groupadd -rf ssu
USER=$(getent passwd 1000 | cut -d: -f1)
if [ -n "$USER" ]; then
usermod -a -G ssu $USER
fi
if [ -f /etc/ssu/ssu.ini ]; then
chgrp ssu /etc/ssu/ssu.ini
chmod 664 /etc/ssu/ssu.ini
fi
%postun
/sbin/ldconfig
if [ "$1" == 0 ]; then
getent group ssu >/dev/null && groupdel ssu
fi
%post -p /sbin/ldconfig