%global commit 47f8ccf50c0933742847e657c4be9f5ba796c1a4 %global shortcommit %(c=%{commit}; echo ${c:0:7}) Name: openvpn-otp Version: 1.0^20230731git%{shortcommit} Release: 1%{?dist} Summary: OpenVPN OTP authentication support License: GPL-1.0-or-later AND Apache-2.0 AND Apache-1.0 AND APSL-2.0 URL: https://github.com/evgeny-gridasov/%{name} Source: https://github.com/evgeny-gridasov/%{name}/archive/%{commit}/%{name}-%{shortcommit}.tar.gz Source: Apache-1.0.txt Source: Apache-2.0.txt Source: APSL-2.0.txt BuildRequires: autoconf BuildRequires: automake BuildRequires: bash BuildRequires: coreutils BuildRequires: gcc BuildRequires: libtool BuildRequires: make BuildRequires: openssl-devel >= 1.1.0 BuildRequires: openvpn-devel # This is a plugin not linked against a lib, so hardcode the requirement # since we require the parent configuration and plugin directories Requires: openvpn >= 2.0 %description This plug-in adds support for time based OTP (totp) and HMAC based OTP (hotp) tokens for OpenVPN. Compatible with Google Authenticator software token, other software and hardware based OTP tokens. %prep %autosetup -n %{name}-%{commit} for license in Apache-1.0.txt Apache-2.0.txt APSL-2.0.txt do cp %{_sourcedir}/$license . done %build ./autogen.sh %configure --with-openvpn-plugin-dir=%{_libdir}/openvpn/plugins/ %make_build %install %make_install rm -f %{buildroot}/%{_libdir}/openvpn/plugins/*.la %files %license LICENSE Apache-1.0.txt Apache-2.0.txt APSL-2.0.txt %doc README.md %{_libdir}/openvpn/plugins/openvpn-otp.so %changelog * Fri Aug 11 2023 Christian Schuermann 1.0^20230731git47f8ccf-1 - Initial package