package init
This commit is contained in:
parent
da0609175a
commit
ae20d21d8c
BIN
kronosnet-1.13.tar.xz
Normal file
BIN
kronosnet-1.13.tar.xz
Normal file
Binary file not shown.
438
kronosnet.spec
Normal file
438
kronosnet.spec
Normal file
@ -0,0 +1,438 @@
|
||||
%bcond_without sctp
|
||||
%bcond_without nss
|
||||
%bcond_without openssl
|
||||
%bcond_without zlib
|
||||
%bcond_without lz4
|
||||
%bcond_without lzo2
|
||||
%bcond_without lzma
|
||||
%bcond_without bzip2
|
||||
%bcond_without zstd
|
||||
%bcond_with kronosnetd
|
||||
%bcond_without libnozzle
|
||||
%bcond_with runautogen
|
||||
%bcond_with rpmdebuginfo
|
||||
%bcond_with overriderpmdebuginfo
|
||||
%bcond_without buildman
|
||||
%bcond_with installtests
|
||||
%if %{with overriderpmdebuginfo}
|
||||
%undefine _enable_debug_packages
|
||||
%endif
|
||||
Name: kronosnet
|
||||
Summary: Multipoint-to-Multipoint VPN daemon
|
||||
Version: 1.13
|
||||
Release: 2
|
||||
License: GPLv2+ and LGPLv2+
|
||||
URL: https://kronosnet.org
|
||||
Source0: https://kronosnet.org/releases/%{name}-%{version}.tar.xz
|
||||
BuildRequires: gcc
|
||||
%if %{with buildman}
|
||||
BuildRequires: libqb-devel libxml2-devel doxygen
|
||||
%endif
|
||||
%if %{with sctp}
|
||||
BuildRequires: lksctp-tools-devel
|
||||
%endif
|
||||
%if %{with nss}
|
||||
BuildRequires: nss-devel
|
||||
%endif
|
||||
%if %{with openssl}
|
||||
BuildRequires: openssl-devel
|
||||
%endif
|
||||
%if %{with zlib}
|
||||
BuildRequires: zlib-devel
|
||||
%endif
|
||||
%if %{with lz4}
|
||||
BuildRequires: lz4-devel
|
||||
%endif
|
||||
%if %{with lzo2}
|
||||
BuildRequires: lzo-devel
|
||||
%endif
|
||||
%if %{with lzma}
|
||||
BuildRequires: xz-devel
|
||||
%endif
|
||||
%if %{with bzip2}
|
||||
BuildRequires: bzip2-devel
|
||||
%endif
|
||||
%if %{with zstd}
|
||||
BuildRequires: libzstd-devel
|
||||
%endif
|
||||
%if %{with kronosnetd}
|
||||
BuildRequires: pam-devel
|
||||
%endif
|
||||
%if %{with libnozzle}
|
||||
BuildRequires: libnl3-devel
|
||||
%endif
|
||||
%if %{with runautogen}
|
||||
BuildRequires: autoconf automake libtool
|
||||
%endif
|
||||
|
||||
%prep
|
||||
%setup -q -n %{name}-%{version}
|
||||
|
||||
%build
|
||||
%if %{with runautogen}
|
||||
./autogen.sh
|
||||
%endif
|
||||
%{configure} \
|
||||
%if %{with installtests}
|
||||
--enable-install-tests \
|
||||
%else
|
||||
--disable-install-tests \
|
||||
%endif
|
||||
%if %{with buildman}
|
||||
--enable-man \
|
||||
%else
|
||||
--disable-man \
|
||||
%endif
|
||||
%if %{with sctp}
|
||||
--enable-libknet-sctp \
|
||||
%else
|
||||
--disable-libknet-sctp \
|
||||
%endif
|
||||
%if %{with nss}
|
||||
--enable-crypto-nss \
|
||||
%else
|
||||
--disable-crypto-nss \
|
||||
%endif
|
||||
%if %{with openssl}
|
||||
--enable-crypto-openssl \
|
||||
%else
|
||||
--disable-crypto-openssl \
|
||||
%endif
|
||||
%if %{with zlib}
|
||||
--enable-compress-zlib \
|
||||
%else
|
||||
--disable-compress-zlib \
|
||||
%endif
|
||||
%if %{with lz4}
|
||||
--enable-compress-lz4 \
|
||||
%else
|
||||
--disable-compress-lz4 \
|
||||
%endif
|
||||
%if %{with lzo2}
|
||||
--enable-compress-lzo2 \
|
||||
%else
|
||||
--disable-compress-lzo2 \
|
||||
%endif
|
||||
%if %{with lzma}
|
||||
--enable-compress-lzma \
|
||||
%else
|
||||
--disable-compress-lzma \
|
||||
%endif
|
||||
%if %{with bzip2}
|
||||
--enable-compress-bzip2 \
|
||||
%else
|
||||
--disable-compress-bzip2 \
|
||||
%endif
|
||||
%if %{with zstd}
|
||||
--enable-compress-zstd \
|
||||
%else
|
||||
--disable-compress-zstd \
|
||||
%endif
|
||||
%if %{with kronosnetd}
|
||||
--enable-kronosnetd \
|
||||
%else
|
||||
--disable-kronosnetd \
|
||||
%endif
|
||||
%if %{with libnozzle}
|
||||
--enable-libnozzle \
|
||||
%else
|
||||
--disable-libnozzle \
|
||||
%endif
|
||||
--with-initdefaultdir=%{_sysconfdir}/sysconfig/ \
|
||||
--with-systemddir=%{_unitdir}
|
||||
make %{_smp_mflags}
|
||||
|
||||
%install
|
||||
rm -rf %{buildroot}
|
||||
make install DESTDIR=%{buildroot}
|
||||
find %{buildroot} -name "*.a" -exec rm {} \;
|
||||
find %{buildroot} -name "*.la" -exec rm {} \;
|
||||
rm -rf %{buildroot}/etc/init.d
|
||||
rm -rf %{buildroot}/usr/share/doc/kronosnet
|
||||
%description
|
||||
The kronosnet source
|
||||
%if %{with kronosnetd}
|
||||
|
||||
%package -n kronosnetd
|
||||
Summary: Multipoint-to-Multipoint VPN daemon
|
||||
License: GPLv2+
|
||||
Requires(post): systemd-sysv
|
||||
Requires(post): systemd-units
|
||||
Requires(preun): systemd-units
|
||||
Requires(postun): systemd-units
|
||||
Requires(post): shadow-utils
|
||||
Requires(preun): shadow-utils
|
||||
Requires: pam, /etc/pam.d/passwd
|
||||
%description -n kronosnetd
|
||||
The kronosnet daemon is a bridge between kronosnet switching engine
|
||||
and kernel network tap devices, to create and administer a
|
||||
distributed LAN over multipoint-to-multipoint VPNs.
|
||||
The daemon does a poor attempt to provide a configure UI similar
|
||||
to other known network devices/tools (Cisco, quagga).
|
||||
Beside looking horrific, it allows runtime changes and
|
||||
reconfiguration of the kronosnet(s) without daemon reload
|
||||
or service disruption.
|
||||
|
||||
%post -n kronosnetd
|
||||
%systemd_post kronosnetd.service
|
||||
getent group kronosnetadm >/dev/null || groupadd --force --system kronosnetadm
|
||||
|
||||
%preun -n kronosnetd
|
||||
%systemd_preun kronosnetd.service
|
||||
|
||||
%files -n kronosnetd
|
||||
%license COPYING.* COPYRIGHT
|
||||
%dir %{_sysconfdir}/kronosnet
|
||||
%dir %{_sysconfdir}/kronosnet/*
|
||||
%config(noreplace) %{_sysconfdir}/sysconfig/kronosnetd
|
||||
%config(noreplace) %{_sysconfdir}/pam.d/kronosnetd
|
||||
%config(noreplace) %{_sysconfdir}/logrotate.d/kronosnetd
|
||||
%{_unitdir}/kronosnetd.service
|
||||
%{_sbindir}/*
|
||||
%{_mandir}/man8/*
|
||||
%endif
|
||||
%if %{with libnozzle}
|
||||
|
||||
%package -n libnozzle1
|
||||
Summary: Simple userland wrapper around kernel tap devices
|
||||
License: LGPLv2+
|
||||
%description -n libnozzle1
|
||||
This is an over-engineered commodity library to manage a pool
|
||||
of tap devices and provides the basic
|
||||
pre-up.d/up.d/down.d/post-down.d infrastructure.
|
||||
|
||||
%files -n libnozzle1
|
||||
%license COPYING.* COPYRIGHT
|
||||
%{_libdir}/libnozzle.so.*
|
||||
%if 0%{?ldconfig_scriptlets}
|
||||
%ldconfig_scriptlets -n libnozzle1
|
||||
%else
|
||||
|
||||
%post -n libnozzle1 -p /sbin/ldconfig
|
||||
|
||||
%postun -n libnozzle1 -p /sbin/ldconfig
|
||||
%endif
|
||||
|
||||
%package -n libnozzle1-devel
|
||||
Summary: Simple userland wrapper around kernel tap devices (developer files)
|
||||
License: LGPLv2+
|
||||
Requires: libnozzle1%{_isa} = %{version}-%{release} pkgconfig
|
||||
%description -n libnozzle1-devel
|
||||
This is an over-engineered commodity library to manage a pool
|
||||
of tap devices and provides the basic
|
||||
pre-up.d/up.d/down.d/post-down.d infrastructure.
|
||||
|
||||
%files -n libnozzle1-devel
|
||||
%license COPYING.* COPYRIGHT
|
||||
%{_libdir}/libnozzle.so
|
||||
%{_includedir}/libnozzle.h
|
||||
%{_libdir}/pkgconfig/libnozzle.pc
|
||||
%if %{with buildman}
|
||||
%{_mandir}/man3/nozzle*.3.gz
|
||||
%endif
|
||||
%endif
|
||||
|
||||
%package -n libknet1
|
||||
Summary: Kronosnet core switching implementation
|
||||
License: LGPLv2+
|
||||
%description -n libknet1
|
||||
The whole kronosnet core is implemented in this library.
|
||||
Please refer to the not-yet-existing documentation for further
|
||||
information.
|
||||
|
||||
%files -n libknet1
|
||||
%license COPYING.* COPYRIGHT
|
||||
%{_libdir}/libknet.so.*
|
||||
%dir %{_libdir}/kronosnet
|
||||
%if 0%{?ldconfig_scriptlets}
|
||||
%ldconfig_scriptlets -n libknet1
|
||||
%else
|
||||
|
||||
%post -n libknet1 -p /sbin/ldconfig
|
||||
|
||||
%postun -n libknet1 -p /sbin/ldconfig
|
||||
%endif
|
||||
|
||||
%package -n libknet1-devel
|
||||
Summary: Kronosnet core switching implementation (developer files)
|
||||
License: LGPLv2+
|
||||
Requires: libknet1%{_isa} = %{version}-%{release} pkgconfig
|
||||
%description -n libknet1-devel
|
||||
The whole kronosnet core is implemented in this library.
|
||||
Please refer to the not-yet-existing documentation for further
|
||||
information.
|
||||
|
||||
%files -n libknet1-devel
|
||||
%license COPYING.* COPYRIGHT
|
||||
%{_libdir}/libknet.so
|
||||
%{_includedir}/libknet.h
|
||||
%{_libdir}/pkgconfig/libknet.pc
|
||||
%if %{with buildman}
|
||||
%{_mandir}/man3/knet*.3.gz
|
||||
%endif
|
||||
%if %{with nss}
|
||||
|
||||
%package -n libknet1-crypto-nss-plugin
|
||||
Summary: Provides libknet1 nss support
|
||||
License: LGPLv2+
|
||||
Requires: libknet1%{_isa} = %{version}-%{release}
|
||||
%description -n libknet1-crypto-nss-plugin
|
||||
Provides NSS crypto support for libknet1.
|
||||
|
||||
%files -n libknet1-crypto-nss-plugin
|
||||
%{_libdir}/kronosnet/crypto_nss.so
|
||||
%endif
|
||||
%if %{with openssl}
|
||||
|
||||
%package -n libknet1-crypto-openssl-plugin
|
||||
Summary: Provides libknet1 openssl support
|
||||
License: LGPLv2+
|
||||
Requires: libknet1%{_isa} = %{version}-%{release}
|
||||
%description -n libknet1-crypto-openssl-plugin
|
||||
Provides OpenSSL crypto support for libknet1.
|
||||
|
||||
%files -n libknet1-crypto-openssl-plugin
|
||||
%{_libdir}/kronosnet/crypto_openssl.so
|
||||
%endif
|
||||
%if %{with zlib}
|
||||
|
||||
%package -n libknet1-compress-zlib-plugin
|
||||
Summary: Provides libknet1 zlib support
|
||||
License: LGPLv2+
|
||||
Requires: libknet1%{_isa} = %{version}-%{release}
|
||||
%description -n libknet1-compress-zlib-plugin
|
||||
Provides zlib compression support for libknet1.
|
||||
|
||||
%files -n libknet1-compress-zlib-plugin
|
||||
%{_libdir}/kronosnet/compress_zlib.so
|
||||
%endif
|
||||
%if %{with lz4}
|
||||
|
||||
%package -n libknet1-compress-lz4-plugin
|
||||
Summary: Provides libknet1 lz4 and lz4hc support
|
||||
License: LGPLv2+
|
||||
Requires: libknet1%{_isa} = %{version}-%{release}
|
||||
%description -n libknet1-compress-lz4-plugin
|
||||
Provides lz4 and lz4hc compression support for libknet1.
|
||||
|
||||
%files -n libknet1-compress-lz4-plugin
|
||||
%{_libdir}/kronosnet/compress_lz4.so
|
||||
%{_libdir}/kronosnet/compress_lz4hc.so
|
||||
%endif
|
||||
%if %{with lzo2}
|
||||
|
||||
%package -n libknet1-compress-lzo2-plugin
|
||||
Summary: Provides libknet1 lzo2 support
|
||||
License: LGPLv2+
|
||||
Requires: libknet1%{_isa} = %{version}-%{release}
|
||||
%description -n libknet1-compress-lzo2-plugin
|
||||
Provides lzo2 compression support for libknet1.
|
||||
|
||||
%files -n libknet1-compress-lzo2-plugin
|
||||
%{_libdir}/kronosnet/compress_lzo2.so
|
||||
%endif
|
||||
%if %{with lzma}
|
||||
|
||||
%package -n libknet1-compress-lzma-plugin
|
||||
Summary: Provides libknet1 lzma support
|
||||
License: LGPLv2+
|
||||
Requires: libknet1%{_isa} = %{version}-%{release}
|
||||
%description -n libknet1-compress-lzma-plugin
|
||||
Provides lzma compression support for libknet1.
|
||||
|
||||
%files -n libknet1-compress-lzma-plugin
|
||||
%{_libdir}/kronosnet/compress_lzma.so
|
||||
%endif
|
||||
%if %{with bzip2}
|
||||
|
||||
%package -n libknet1-compress-bzip2-plugin
|
||||
Summary: Provides libknet1 bzip2 support
|
||||
License: LGPLv2+
|
||||
Requires: libknet1%{_isa} = %{version}-%{release}
|
||||
%description -n libknet1-compress-bzip2-plugin
|
||||
Provides bzip2 compression support for libknet1.
|
||||
|
||||
%files -n libknet1-compress-bzip2-plugin
|
||||
%{_libdir}/kronosnet/compress_bzip2.so
|
||||
%endif
|
||||
%if %{with zstd}
|
||||
|
||||
%package -n libknet1-compress-zstd-plugin
|
||||
Summary: Provides libknet1 zstd support
|
||||
License: LGPLv2+
|
||||
Requires: libknet1%{_isa} = %{version}-%{release}
|
||||
%description -n libknet1-compress-zstd-plugin
|
||||
Provides zstd compression support for libknet1.
|
||||
|
||||
%files -n libknet1-compress-zstd-plugin
|
||||
%{_libdir}/kronosnet/compress_zstd.so
|
||||
%endif
|
||||
|
||||
%package -n libknet1-crypto-plugins-all
|
||||
Summary: Provides libknet1 crypto plugins meta package
|
||||
License: LGPLv2+
|
||||
%if %{with nss}
|
||||
Requires: libknet1-crypto-nss-plugin%{_isa} = %{version}-%{release}
|
||||
%endif
|
||||
%if %{with openssl}
|
||||
Requires: libknet1-crypto-openssl-plugin%{_isa} = %{version}-%{release}
|
||||
%endif
|
||||
%description -n libknet1-crypto-plugins-all
|
||||
Provides meta package to install all of libknet1 crypto plugins
|
||||
|
||||
%files -n libknet1-crypto-plugins-all
|
||||
|
||||
%package -n libknet1-compress-plugins-all
|
||||
Summary: Provides libknet1 compress plugins meta package
|
||||
License: LGPLv2+
|
||||
%if %{with zlib}
|
||||
Requires: libknet1-compress-zlib-plugin%{_isa} = %{version}-%{release}
|
||||
%endif
|
||||
%if %{with lz4}
|
||||
Requires: libknet1-compress-lz4-plugin%{_isa} = %{version}-%{release}
|
||||
%endif
|
||||
%if %{with lzo2}
|
||||
Requires: libknet1-compress-lzo2-plugin%{_isa} = %{version}-%{release}
|
||||
%endif
|
||||
%if %{with lzma}
|
||||
Requires: libknet1-compress-lzma-plugin%{_isa} = %{version}-%{release}
|
||||
%endif
|
||||
%if %{with bzip2}
|
||||
Requires: libknet1-compress-bzip2-plugin%{_isa} = %{version}-%{release}
|
||||
%endif
|
||||
%if %{with zstd}
|
||||
Requires: libknet1-compress-zstd-plugin%{_isa} = %{version}-%{release}
|
||||
%endif
|
||||
%description -n libknet1-compress-plugins-all
|
||||
Meta package to install all of libknet1 compress plugins
|
||||
|
||||
%files -n libknet1-compress-plugins-all
|
||||
|
||||
%package -n libknet1-plugins-all
|
||||
Summary: Provides libknet1 plugins meta package
|
||||
License: LGPLv2+
|
||||
Requires: libknet1-compress-plugins-all%{_isa} = %{version}-%{release}
|
||||
Requires: libknet1-crypto-plugins-all%{_isa} = %{version}-%{release}
|
||||
%description -n libknet1-plugins-all
|
||||
Meta package to install all of libknet1 plugins
|
||||
|
||||
%files -n libknet1-plugins-all
|
||||
%if %{with installtests}
|
||||
|
||||
%package -n kronosnet-tests
|
||||
Summary: Provides kronosnet test suite
|
||||
License: GPLv2+
|
||||
Requires: libknet1%{_isa} = %{version}-%{release}
|
||||
%description -n kronosnet-tests
|
||||
This package contains all the libknet and libnozzle test suite.
|
||||
|
||||
%files -n kronosnet-tests
|
||||
%{_libdir}/kronosnet/tests/*
|
||||
%endif
|
||||
%if %{with rpmdebuginfo}
|
||||
%debug_package
|
||||
%endif
|
||||
|
||||
%changelog
|
||||
* Sat Jul 18 2020 yanan li <liyanan032@huawei.com> - 1.13-2
|
||||
- Package init
|
||||
5
kronosnet.yaml
Normal file
5
kronosnet.yaml
Normal file
@ -0,0 +1,5 @@
|
||||
git_url: https://github.com/kronosnet/kronosnet.git
|
||||
version_control: github
|
||||
src_repo: kronosnet
|
||||
tag_prefix: "^v"
|
||||
seperator: "."
|
||||
Loading…
x
Reference in New Issue
Block a user