up 2.4.10-dev, off all pathes, any flags on

This commit is contained in:
Sergey Zhemoitel 2021-09-12 04:07:04 +03:00
parent f7aa071c65
commit e8d2ca5369
2 changed files with 47 additions and 15 deletions

View file

@ -1,3 +1,4 @@
sources:
2.4.9.tar.gz: 4241f65a5f8e1efb3874b9c7887d38ae4d05d112
ppp-812e8e5c87da4fd84ae7bc5b6a18c85106188eb3.tar.gz: e02a8894045702adeecf995a0ee16d7f1e734261
ppp-watch.tar.xz: 74b6db205dc46fc179a2a3bc3d726ddfeb03c801

View file

@ -1,14 +1,16 @@
%define _disable_ld_no_undefined %nil
%define _rundir /var/run
%define commit 812e8e5c87da4fd84ae7bc5b6a18c85106188eb3
%define githash %(c=%{commit}; echo ${c:0:7})
Summary: The PPP daemon and documentation
Name: ppp
Version: 2.4.9
Release: 3
License: BSD-like
Version: 2.4.10
Release: 0.%{commit}
License: BSD
Group: System/Servers
Url: http://www.samba.org/ppp/
Source0: https://github.com/paulusmack/ppp/archive/%{version}.tar.gz
Url: http://www.samba.org/ppp
Source0: https://github.com/paulusmack/ppp/archive/%{commit}/%{name}-%{commit}.tar.gz
Source1000: %{name}.rpmlintrc
Source1: ppp-pam.conf
Source2: ppp-logrotate.conf
@ -70,7 +72,6 @@ the PPP protocol.
%{_sbindir}/chat
%{_sbindir}/pppd
%{_sbindir}/pppdump
#{_sbindir}/pppoe-discovery
%{_sbindir}/pppstats
%{_sbindir}/ppp-watch
%dir %{_sysconfdir}/ppp
@ -80,11 +81,10 @@ the PPP protocol.
%{_sysconfdir}/ppp/ip-down.ipv6to4
%{_sysconfdir}/ppp/ipv6-up
%{_sysconfdir}/ppp/ipv6-down
%{_sysconfdir}/ppp/openssl.cnf
%{_mandir}/man8/chat.8*
%{_mandir}/man8/pppd.8*
%{_mandir}/man8/pppdump.8*
#{_mandir}/man8/pppd-radattr.8*
#{_mandir}/man8/pppd-radius.8*
%{_mandir}/man8/pppstats.8*
%{_mandir}/man8/pppoe-discovery.8*
%{_mandir}/man8/ppp-watch.8*
@ -108,6 +108,7 @@ the PPP protocol.
%{_tmpfilesdir}/ppp.conf
%{_sysconfdir}/sysconfig/network-scripts/ifdown-ppp
%{_sysconfdir}/sysconfig/network-scripts/ifup-ppp
# scripts pon/poff/plog
%{_sbindir}/pon
%{_sbindir}/poff
@ -129,6 +130,7 @@ PPP over ATM plugin for %{name}.
%files devel
%doc README*
%{_includedir}/pppd/*
%{_libdir}/pkgconfig/pppd.pc
#----------------------------------------------------------------------------
@ -179,22 +181,42 @@ Radius plugin for %{name}.
#----------------------------------------------------------------------------
%prep
%setup -q
%setup -qn %{name}-%{commit}
#autopatch -p1
%apply_patches
#apply_patches
tar -xJf %{SOURCE12}
%build
%configure --cflags="$RPM_OPT_FLAGS -fPIC -Wall -fno-strict-aliasing"
%make_build LDFLAGS="%{ldflags} -pie"
./autogen.sh \
--prefix=%{_prefix} \
--exec-prefix=%{_prefix} \
--libdir=%{_libdir} \
--with-plugin-dir=\$\{prefix\}/%{_lib}/pppd/%{version} \
--enable-systemd \
--enable-cbcp \
--enable-ipxcp \
--enable-mslanman \
--enable-microsoft-extensions \
--enable-ipv6-support \
--enable-plugins \
--enable-eaptls \
--enable-openssl-engine \
OPENSSL_LDFLAGS="-L%{_libdir}"
#configure
#--cflags="$RPM_OPT_FLAGS -fPIC -Wall -fno-strict-aliasing"
#make_build LDFLAGS="%{ldflags} -pie"
%make
%make_build -C ppp-watch LDFLAGS="%{ldflags} -pie"
#make
%install
make INSTROOT=%{buildroot} install install-etcppp
%makeinstall
#make INSTROOT=%{buildroot} install install-etcppp
find scripts -type f | xargs chmod a-x
make ROOT=%{buildroot} -C ppp-watch install
%make ROOT=%{buildroot} -C ppp-watch install
# create log files dir
install -d %{buildroot}%{_localstatedir}/log/ppp
# install pam config
@ -224,3 +246,12 @@ mkdir -p %{buildroot}%{_rundir}/lock/ppp
install -Dm0755 scripts/pon %{buildroot}%{_sbindir}/pon
install -Dm0755 scripts/poff %{buildroot}%{_sbindir}/poff
install -Dm0755 scripts/plog %{buildroot}%{_sbindir}/plog
# clean *.a
find %{buildroot} -type f -name "*.a" -exec rm -rf {} \;
# create symlink rp-pppoe.so
pushd %{buildroot}%{_libdir}/pppd/%{version}
ln -s pppoe.so rp-pppoe.so
popd