/[packages]/updates/1/drakx-net/current/SPECS/drakx-net.spec
ViewVC logotype

Contents of /updates/1/drakx-net/current/SPECS/drakx-net.spec

Parent Directory Parent Directory | Revision Log Revision Log


Revision 156397 - (show annotations) (download)
Tue Oct 18 19:12:18 2011 UTC (12 years, 5 months ago) by zezinho
File size: 5591 byte(s)
SILENT : tarball fixed
1 %define name drakx-net
2 %define version 0.97.1
3 %define release %mkrel 2
4 %define drakxtools_ver 12.36
5
6 %define libname lib%{name}
7
8 %define gtk_files (connection_manager|drakroam|ifw|monitor|netcenter|drakconnect/edit|drakconnect/global).pm
9
10 Summary: %_vendor network tools
11 Name: %{name}
12 Version: %{version}
13 Release: %{release}
14 Source0: %{name}-%{version}.tar.bz2
15 License: GPL
16 Group: System/Configuration/Networking
17 Url: http://www.mageia.org/
18 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-buildroot
19 BuildArch: noarch
20 BuildRequires: intltool
21 Requires: drakxtools >= %{drakxtools_ver}
22 Requires: %{name}-text = %{version}
23 Requires: %{libname} = %{version}
24 Requires: netprofile >= 0.20
25 Requires: perl-Gtk2 >= 1.154
26 Requires: usermode-consoleonly >= 1.92-4mdv2008.0
27 Conflicts: drakxtools <= 10.4.83
28 Suggests: net_monitor
29 Suggests: %{name}-applet
30
31 %description
32 This package contains the %_vendor network tools.
33
34 net_applet: applet to check network connection
35
36 %package text
37 Summary: %_vendor network text tools
38 Group: System/Configuration/Networking
39 Requires: drakxtools-curses >= %{drakxtools_ver}
40 Requires: %{libname} = %{version}
41 Conflicts: drakxtools-curses <= 10.4.83
42 Conflicts: mdkonline < 2.37
43
44 %description text
45 This package contains the %_vendor network tools that can be used in
46 text mode.
47
48 drakconnect: LAN/Internet connection configuration. It handles
49 ethernet, ISDN, DSL, cable, modem.
50
51 drakfirewall: simple firewall configurator
52
53 drakgw: internet connection sharing
54
55 drakproxy: proxies configuration
56
57 drakvpn: VPN configuration (openvpn, vpnc)
58
59 %package applet
60 Summary: %_vendor network applet
61 Group: System/Configuration/Networking
62 Requires: %{name} = %{version}-%{release}
63
64 %description applet
65 This package contains the %_vendor network applet.
66
67 %package -n %{libname}
68 Summary: %_vendor network tools library
69 Group: System/Configuration/Networking
70 Requires: drakxtools-backend >= %{drakxtools_ver}
71 # require perl-Net-Telnet for OpenVPN connections (#36126):
72 Requires: perl-Net-Telnet
73 # Require crda, iw and wireless-regdb for CRDA domain settings (#47324)
74 Requires: crda
75 Requires: iw
76 Requires: wireless-regdb
77 Conflicts: drakxtools-backend <= 10.4.83
78
79 %description -n %{libname}
80 This package contains the %_vendor network tools library.
81
82 %prep
83 %setup -q
84
85 %build
86 %make
87
88 %install
89 rm -rf %{buildroot}
90 %makeinstall_std
91
92 (cd %{buildroot}; find usr/lib/libDrakX/network/ -type f -name '*.pm') | perl -ne 'm!/%{gtk_files}$! ? print STDERR "/$_" : print "/$_"' > %{name}-nogtk.list 2> %{name}-gtk.list
93
94 %find_lang %{name}
95 cat %{name}-nogtk.list %{name}.lang > %{name}.list
96
97 # consolehelper config
98 # ask for user password
99 ln -s %{_bindir}/consolehelper %{buildroot}%{_bindir}/draknetcenter
100
101 mkdir -p %{buildroot}%{_sysconfdir}/pam.d/
102 mkdir -p %{buildroot}%{_sysconfdir}/security/console.apps/
103
104 ln -sf %{_sysconfdir}/pam.d/%_real_vendor-console-auth %{buildroot}%{_sysconfdir}/pam.d/draknetcenter
105
106 cat > %{buildroot}%{_sysconfdir}/security/console.apps/draknetcenter <<EOF
107 USER=<user>
108 PROGRAM=/usr/sbin/draknetcenter
109 FALLBACK=false
110 SESSION=true
111 EOF
112
113 # consolehelper config
114 # ask for root password
115 for pak in drakconnect drakgw drakroam draknetprofile drakproxy drakvpn drakhosts; do
116 ln -s %{_bindir}/consolehelper %{buildroot}%{_bindir}/$pak
117 ln -sf %{_sysconfdir}/pam.d/%_real_vendor-simple-auth %{buildroot}%{_sysconfdir}/pam.d/$pak
118 cat > %{buildroot}%{_sysconfdir}/security/console.apps/$pak <<EOF
119 USER=root
120 PROGRAM=/usr/sbin/$pak
121 FALLBACK=false
122 SESSION=true
123 EOF
124 done
125
126 %check
127 while read f; do
128 grep Gtk2 %{buildroot}$f && exit 1
129 done < %{name}-nogtk.list
130 exit 0
131
132 %clean
133 rm -rf %{buildroot}
134
135 %files -f %{name}-gtk.list
136 %defattr(-,root,root)
137 %doc NEWS
138 %{_bindir}/drakroam
139 %{_bindir}/draknetcenter
140 %{_bindir}/draknetprofile
141 %{_bindir}/drakhosts
142 %{_sbindir}/drakhosts
143 %{_sbindir}/drakids
144 %{_sbindir}/draknetcenter
145 %{_sbindir}/draknetprofile
146 %{_sbindir}/draknfs
147 %{_sbindir}/drakroam
148 %{_sbindir}/draksambashare
149 %config(noreplace) %{_sysconfdir}/pam.d/drakroam
150 %config(noreplace) %{_sysconfdir}/pam.d/draknetcenter
151 %config(noreplace) %{_sysconfdir}/pam.d/draknetprofile
152 %config(noreplace) %{_sysconfdir}/pam.d/drakhosts
153 %config(noreplace) %{_sysconfdir}/security/console.apps/drakroam
154 %config(noreplace) %{_sysconfdir}/security/console.apps/draknetprofile
155 %config(noreplace) %{_sysconfdir}/security/console.apps/draknetcenter
156 %config(noreplace) %{_sysconfdir}/security/console.apps/drakhosts
157 %{_datadir}/applications/draknetcenter.desktop
158 %{_prefix}/lib/libDrakX/icons/*.png
159 %{_datadir}/libDrakX/pixmaps/*.png
160
161 %files text
162 %config(noreplace) %{_sysconfdir}/pam.d/drakconnect
163 %config(noreplace) %{_sysconfdir}/pam.d/drakgw
164 %config(noreplace) %{_sysconfdir}/pam.d/drakproxy
165 %config(noreplace) %{_sysconfdir}/pam.d/drakvpn
166 %config(noreplace) %{_sysconfdir}/security/console.apps/drakconnect
167 %config(noreplace) %{_sysconfdir}/security/console.apps/drakgw
168 %config(noreplace) %{_sysconfdir}/security/console.apps/drakproxy
169 %config(noreplace) %{_sysconfdir}/security/console.apps/drakvpn
170 %{_bindir}/drakconnect
171 %{_bindir}/drakgw
172 %{_bindir}/drakvpn
173 %{_bindir}/drakproxy
174 %{_sbindir}/drakconnect
175 %{_sbindir}/drakfirewall
176 %{_sbindir}/drakgw
177 %{_sbindir}/drakinvictus
178 %{_sbindir}/drakproxy
179 %{_sbindir}/drakvpn
180
181 %files -n %{libname} -f %{name}.list
182 %defattr(-,root,root)
183 %dir %{_prefix}/lib/libDrakX/network/
184 %dir %{_prefix}/lib/libDrakX/network/connection
185 %dir %{_prefix}/lib/libDrakX/network/drakconnect/
186 %dir %{_prefix}/lib/libDrakX/network/vpn
187
188 %files applet
189 %{_bindir}/net_applet
190 %{_datadir}/applications/net_applet.desktop
191 %{_sysconfdir}/xdg/autostart/net_applet.desktop

  ViewVC Help
Powered by ViewVC 1.1.30