File sslscan.spec of Package sslscan
%define realname sslscan
%define realver 2.1.4
%define srcext tar.gz
# Common info
Name: %{realname}
Version: %{realver}
Release: wiz%{?extraver:0.}1%{?dist}
License: GPL-3.0
Group: System/Monitoring
URL: https://github.com/rbsec/sslscan
Summary: Test SSL/TLS enabled services to discover supported cipher suites
# Build-time parameters
BuildRequires: openssl-devel
BuildRequires: zlib-devel
Source0: https://codeload.github.com/rbsec/sslscan/%{srcext}/refs/tags/%{realver}#/%{realname}-%{realver}%{?extraver}.%{srcext}
%description
sslscan tests SSL/TLS enabled services to discover supported cipher suites
# Preparation step (unpackung and patching if necessary)
%prep
%setup -q -n %{realname}-%{realver}%{?extraver}
# Build step (compile/build binaries, documentation, etc)
%build
_CFLAGS='%{optflags} %{?gcc_lto}'
_LDFLAGS='-Wl,--as-needed -Wl,--strip-all -Wl,--no-undefined -Wl,-z,noexecstack -Wl,-z,now -Wl,-z,relro %{?gcc_lto}'
%{__make} %{?_smp_mflags} \
GIT_VERSION=%{version} \
CFLAGS="$_CFLAGS" \
LDFLAGS="$_LDFLAGS"
# Install built stuff
%install
%{__make} install \
DESTDIR=%{buildroot} \
BINDIR=%{_bindir} \
MANDIR=%{_mandir}
# Files list
%files
%defattr(-,root,root)
%license LICENSE
%doc Changelog README.md
%{_bindir}/sslscan
%doc %{_mandir}/man1/sslscan.1*
%changelog