3 # - check if %{_libdir}/pppd/%{version} path is needed, if not drop the symlink
6 %bcond_without mppc # MPPC support
7 %bcond_without pppoatm # PPPoATM plugin (requires kernel 2.4+ and atm-devel)
8 %bcond_with srp # SRP support
10 Summary: ppp daemon package for Linux
11 Summary(de.UTF-8): ppp-Dämonpaket für Linux
12 Summary(es.UTF-8): Servidor ppp para Linux
13 Summary(fr.UTF-8): Paquetage du démon ppp pour Linux
14 Summary(pl.UTF-8): Demon PPP dla Linuksa
15 Summary(pt_BR.UTF-8): Servidor ppp para Linux
16 Summary(ru.UTF-8): Демон ppp
17 Summary(tr.UTF-8): PPP sunucu süreci
18 Summary(zh_CN.UTF-8): PPP 配置和管理软件包
23 License: distributable
24 Group: Networking/Daemons
25 Source0: https://download.samba.org/pub/ppp/%{name}-%{version}.tar.gz
26 # Source0-md5: c88153ae3d16ae114152cd3c15c7301d
30 Source4: http://www.mif.pg.gda.pl/homepages/ankry/man-PLD/%{name}-non-english-man-pages.tar.bz2
31 # Source4-md5: 3801b59005bef8f52856300fe3167a64
32 Source5: %{name}.logrotate
33 Patch0: %{name}-make.patch
34 Patch2: %{name}-debian_scripts.patch
35 Patch4: %{name}-pidfile-owner.patch
36 #Patch7: http://public.planetmirror.com/pub/mppe/pppd-2.4.2-chapms-strip-domain.patch.gz
37 Patch7: pppd-2.4.2-chapms-strip-domain.patch
38 Patch8: %{name}-openssl.patch
39 Patch9: %{name}-lib64.patch
40 #Patch10: http://mppe-mppc.alphacron.de/%{name}-2.4.3-mppe-mppc-1.1.patch.gz
41 Patch10: %{name}-2.4.3-mppe-mppc-1.1.patch
42 Patch11: %{name}-ifpppstatsreq.patch
43 Patch12: %{name}-libx32.patch
44 URL: https://ppp.samba.org/
45 BuildRequires: libpcap-devel >= 2:0.8.1
46 %{?with_pppoatm:BuildRequires: linux-atm-devel}
47 # <linux/if_pppol2tp.h>
48 BuildRequires: linux-libc-headers >= 7:2.6.23
49 BuildRequires: openssl-devel
50 BuildRequires: pam-devel
51 %{?with_srp:BuildRequires: srp-devel}
52 Requires: pam >= 0.77.3
53 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
56 This is the daemon and documentation for PPP support. It requires a
57 kernel greater than 2.2.11 which is built with PPP support. The
58 default kernels include PPP support as a module. This version supports
61 %description -l de.UTF-8
62 Dies ist der Dämon und die Dokumentation für PPP-Support. Erfordert
63 einen Kernel höher als 2.2.11, der mit PPP-Support gebaut ist. Die
64 Standard-Kernel schließen PPP-Support als Modul ein. (IPv6)
66 %description -l es.UTF-8
67 Este es el servidor y la documentación para soporte PPP. Requiere un
68 kernel superior al 2.0.
70 %description -l fr.UTF-8
71 Ceci est le démon et la documentation pour le support PPP. Cela
72 réclame un noyau supérieur au 2.2.11 et construit avec le support PPP.
74 %description -l pl.UTF-8
75 Pakiet zawiera demona i dokumentację umożliwiającą korzystanie z
76 protokołu PPP. Wymaga jądra 2.2.11 - lub późniejszego - z wkompilowaną
77 obsługą protokołu PPP. Standardowe jądro z dystrybucji zawiera
78 wsparcie dla PPP skompilowane jako moduł. (IPv6)
80 %description -l pt_BR.UTF-8
81 Este é o servidor e a documentação para suporte PPP. Ele requer um
82 kernel superior ao 2.0.
84 %description -l ru.UTF-8
85 Демон, конфигурационные файлы и документация для поддержки PPP.
87 %description -l tr.UTF-8
88 Bu paket PPP desteği için belgeler ve sunucu sürecini içerir. Çekirdek
89 sürümünun 2.2.11'dan daha yüksek olmasını gerektirir.
92 Summary: Stuff needed to build plugins for pppd
93 Summary(pl.UTF-8): Rzeczy potrzebne do budowania wtyczek dla pppd
94 Group: Development/Libraries
95 # doesn't require base but enforce new version
96 Conflicts: %{name} < %{epoch}:%{version}-%{release}
98 %description plugin-devel
99 Development files needed to build plugins for pppd.
101 %description plugin-devel -l pl.UTF-8
102 Pliki nagłówkowe potrzebne do budowania wtyczek dla pppd.
104 %package plugin-pppoatm
105 Summary: PPPoATM plugin for pppd
106 Summary(pl.UTF-8): Wtyczka PPPoATM dla pppd
108 Requires: %{name} = %{epoch}:%{version}-%{release}
110 %description plugin-pppoatm
111 PPPoATM plugin for pppd.
113 %description plugin-pppoatm -l pl.UTF-8
114 Wtyczka PPPoATM dla pppd.
123 %if "%{_lib}" == "lib64"
130 %if "%{_lib}" == "libx32"
134 # use headers from llh instead of older supplied by ppp, incompatible with current llh
135 %{__rm} include/linux/*.h
138 # note: not autoconf configure
141 --cflags="%{rpmcflags} %{rpmcppflags}"
144 %{?with_pppoatm:HAVE_LIBATM=y} \
146 %{?with_srp:USE_SRP=y} \
147 LDFLAGS="%{rpmldflags}"
150 rm -rf $RPM_BUILD_ROOT
151 install -d $RPM_BUILD_ROOT{%{_bindir},%{_sysconfdir}/ppp/peers,/var/log} \
152 $RPM_BUILD_ROOT/etc/{pam.d,logrotate.d}
155 %{?with_pppoatm:HAVE_LIBATM=y} \
156 %{?with_srp:USE_SRP=y} \
157 DESTDIR=$RPM_BUILD_ROOT%{_prefix}
159 install -p %{SOURCE2} $RPM_BUILD_ROOT%{_bindir}/pon
160 install -p %{SOURCE3} $RPM_BUILD_ROOT%{_bindir}/poff
161 install -p debian/plog $RPM_BUILD_ROOT%{_bindir}
163 cp -p etc.ppp/chap-secrets $RPM_BUILD_ROOT%{_sysconfdir}/ppp
164 cp -p debian/pap-secrets $RPM_BUILD_ROOT%{_sysconfdir}/ppp
165 cp -p debian/options $RPM_BUILD_ROOT%{_sysconfdir}/ppp
166 cp -p debian/options.ttyXX $RPM_BUILD_ROOT%{_sysconfdir}/ppp
168 bzip2 -dc %{SOURCE4} | tar xf - -C $RPM_BUILD_ROOT%{_mandir}
169 %{__rm} $RPM_BUILD_ROOT%{_mandir}/README.ppp-non-english-man-pages
171 cp -p %{SOURCE5} $RPM_BUILD_ROOT/etc/logrotate.d/ppp
172 > $RPM_BUILD_ROOT/var/log/ppp.log
174 %{__rm} scripts/README
176 cp -p %{SOURCE1} $RPM_BUILD_ROOT/etc/pam.d/ppp
178 cd $RPM_BUILD_ROOT%{_libdir}/pppd
179 v=$(echo %{version}*)
181 # not sure which path used, keep the old path for compat
185 rm -rf $RPM_BUILD_ROOT
188 # %{version} used to be directory
189 if [ -d %{_libdir}/pppd/%{version} -a ! -L %{_libdir}/pppd/%{version} ]; then
191 rm -f %{_libdir}/pppd/plugins
192 mv -f %{_libdir}/pppd/{%{version},plugins}
193 ln -snf plugins %{_libdir}/pppd/%{version}
197 %defattr(644,root,root,755)
198 %doc README.linux debian/README.debian scripts
199 %doc debian/win95.ppp README.MSCHAP8* FAQ debian/ppp-2.3.0.STATIC.README
200 %doc README.MPPE README.pppoe README.cbcp README.pwfd
201 %attr(755,root,root) %{_bindir}/plog
202 %attr(755,root,root) %{_bindir}/poff
203 %attr(755,root,root) %{_bindir}/pon
204 %attr(755,root,root) %{_sbindir}/chat
205 %attr(755,root,root) %{_sbindir}/pppd
206 %attr(755,root,root) %{_sbindir}/pppdump
207 %attr(755,root,root) %{_sbindir}/pppoe-discovery
208 %attr(755,root,root) %{_sbindir}/pppstats
209 %{?with_srp:%attr(755,root,root) %{_sbindir}/srp-entry}
211 %dir %{_libdir}/pppd/plugins
212 %attr(755,root,root) %{_libdir}/pppd/plugins/minconn.so
213 %attr(755,root,root) %{_libdir}/pppd/plugins/openl2tp.so
214 %attr(755,root,root) %{_libdir}/pppd/plugins/passprompt.so
215 %attr(755,root,root) %{_libdir}/pppd/plugins/passwordfd.so
216 %attr(755,root,root) %{_libdir}/pppd/plugins/pppoe.so
217 %attr(755,root,root) %{_libdir}/pppd/plugins/pppol2tp.so
218 %attr(755,root,root) %{_libdir}/pppd/plugins/radattr.so
219 %attr(755,root,root) %{_libdir}/pppd/plugins/radius.so
220 %attr(755,root,root) %{_libdir}/pppd/plugins/radrealms.so
221 %attr(755,root,root) %{_libdir}/pppd/plugins/rp-pppoe.so
222 %attr(755,root,root) %{_libdir}/pppd/plugins/winbind.so
224 # TODO: legacy, try to drop
225 %{_libdir}/pppd/%{version}
227 %{_mandir}/man8/chat.8*
228 %{_mandir}/man8/pppd.8*
229 %{_mandir}/man8/pppd-radattr.8*
230 %{_mandir}/man8/pppd-radius.8*
231 %{_mandir}/man8/pppdump.8*
232 %{_mandir}/man8/pppstats.8*
233 %lang(fr) %{_mandir}/fr/man8/*
234 %lang(ja) %{_mandir}/ja/man8/*
235 %lang(ko) %{_mandir}/ko/man8/*
236 %lang(pl) %{_mandir}/pl/man8/*
238 %attr(600,root,root) %config(missingok,noreplace) %verify(not md5 mtime size) %{_sysconfdir}/ppp/chap-secrets
239 %attr(600,root,root) %config(missingok,noreplace) %verify(not md5 mtime size) %{_sysconfdir}/ppp/pap-secrets
240 %config(missingok,noreplace) %verify(not md5 mtime size) %{_sysconfdir}/ppp/options
241 %config(missingok,noreplace) %verify(not md5 mtime size) %{_sysconfdir}/ppp/options.ttyXX
242 %dir %{_sysconfdir}/ppp/peers
243 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/pam.d/ppp
244 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/logrotate.d/ppp
245 %attr(640,root,root) %ghost /var/log/ppp.log
248 %defattr(644,root,root,755)
252 %files plugin-pppoatm
253 %defattr(644,root,root,755)
254 %attr(755,root,root) %{_libdir}/pppd/plugins/pppoatm.so