-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathmobile-manager.spec
138 lines (105 loc) · 2.88 KB
/
mobile-manager.spec
1
2
3
4
5
6
7
8
9
10
11
12
13
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
126
127
128
129
130
131
132
133
134
135
136
137
138
%define is_mandrake %(test -e /etc/mandrake-release && echo 1 || echo 0)
%define is_suse %(test -e /etc/SuSE-release && echo 1 || echo 0)
%define is_fedora %(test -e /etc/fedora-release && echo 1 || echo 0)
Name: mobile-manager
Summary: Mobile Manager daemon (GPRS/3g support)
Version: 0.8
Release: 1
License: GPLv2+
Group: Applications/Internet
Source: mobile-manager-%{version}.tar.gz
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
Requires: gtk2 >= 2.4.0
Requires: python
Requires: libusb
Requires: usb_modeswitch
Requires: wvdial
%if %is_suse
Requires: python-gtk
Requires: dbus-1
Requires: dbus-1-python
%endif
%if %is_fedora
Requires: pygtk2
Requires: dbus
Requires: dbus-python
%endif
%if %is_suse
BuildRequires: python-gtk-devel
BuildRequires: dbus-1-python-devel
BuildRequires: dbus-1-glib-devel
BuildRequires: dbus-1-devel
%endif
%if %is_fedora
BuildRequires: pygtk2-devel
BuildRequires: dbus-devel >= 0.90
BuildRequires: dbus-python-devel
%endif
BuildRequires: automake
BuildRequires: autoconf
BuildRequires: python-devel
BuildRequires: gettext
BuildRequires: gcc
%if %is_suse
BuildRequires: gnome-doc-utils-devel
%endif
%if %is_fedora
BuildRequires: gnome-doc-utils
%endif
BuildRequires: intltool
BuildRequires: libtool
BuildRequires: libusb-devel
%description
Mobile Manager is a GPRS/3G daemon developed by Telefonica.
This daemon cover the GPRS/3G funtions for develop and work
over GPRS/3G
%prep
%setup -q
%build
%if 0%{?suse_version} > 1020
%configure --prefix=/usr --sysconfdir=/etc --with-init-scripts=suse
make %{?_smp_mflags}
%else
%configure --prefix=/usr --sysconfdir=/etc --with-init-scripts=redhat
make %{?_smp_mflags}
%endif
%install
rm -rf $RPM_BUILD_ROOT
make install DESTDIR=$RPM_BUILD_ROOT
%files
%{_bindir}/*
%{_sbindir}/*
%{_sysconfdir}/*
%{_libdir}/*
%{_datadir}/*
%clean
rm -rf $RPM_BUILD_ROOT
%post
/sbin/ldconfig
/sbin/chkconfig --add mobile-manager
dbus-send --print-reply --system --type=method_call \
--dest=org.freedesktop.DBus \
/ org.freedesktop.DBus.ReloadConfig > /dev/null
if [ -f /etc/init.d/boot.udev ] && [ -x /etc/init.d/boot.udev ] ; then
/etc/init.d/boot.udev reload
fi
if [ -f /etc/init.d/udev ] && [ -x /etc/init.d/udev ] ; then
/etc/init.d/udev reload
fi
if [ -f /etc/init.d/mobile-manager ] && [ -x /etc/init.d/mobile-manager ] ; then
/etc/init.d/mobile-manager start
fi
%preun
if [ $1 = 0 ]; then
service mobile-manager stop > /dev/null 2>&1
/sbin/chkconfig --del mobile-manager
fi
%changelog
* Mon Dec 29 2008 Roberto Majadas <roberto.majadas@openshine.com> - 0.8-1
- New upstream version
* Wed Jun 25 2008 Roberto Majadas <roberto.majadas@openshine.com> - 0.7-1
- New upstream version
* Fri Jun 20 2008 Roberto Majadas <roberto.majadas@openshine.com> - 0.6-2
- Fedora and opensuse support
* Thu Jun 19 2008 Roberto Majadas <roberto.majadas@openshine.com> - 0.6-1
- Initial