Blob Blame History Raw
%global		_hardened_build 1

Name:		libdkimpp
Version:	1.0.10
Release:	5%{?dist}
Summary:	Lightweight and portable DKIM (RFC4871) library

Group:		System Environment/Libraries
License:	LGPLv3+
URL:		https://github.com/halonsecurity/libdkimpp
Source0:	https://github.com/halonsecurity/libdkimpp/archive/v%{version}.tar.gz

BuildRequires:	cmake
BuildRequires:	coreutils
BuildRequires:	gcc-c++
BuildRequires:	make
BuildRequires:	pkgconfig

BuildRequires:	pkgconfig(cppunit)
BuildRequires:	openssl-devel

Patch0:		0001-use-pkg-config-to-find-cppunit.patch

%description
libdkim++ is a lightweight and portable DKIM (RFC4871) library for *NIX,
supporting both signing and DMARC/SDID/ADSP verification, sponsored and
used by Halon Security. libdkim++ has extensive unit test coverage and
aims to fully comply with the current RFC.

%package devel
Summary:	Development files for %{name}
Group:		Development/Libraries
Requires:	%{name}%{?_isa} = %{version}-%{release}

%description devel
This package contains the header files and libraries for developing
with %{name}.

%prep
%setup -q
%patch0 -p1 -b .cppunit

%build
mkdir -p build
cd build

%cmake .. -DPKG_CONFIG_DIR:PATH=%{_lib}/pkgconfig

make %{?_smp_mflags}

%check
cd build
make test

%install
cd build
make install DESTDIR=$RPM_BUILD_ROOT

chmod +x $RPM_BUILD_ROOT/%{_libdir}/*.so*

%post -p /sbin/ldconfig

%postun -p /sbin/ldconfig

%files
%license LICENSE
%doc README.md
%{_libdir}/libdkim++.so.*

%files devel
%{_includedir}/libdkim++
%{_libdir}/libdkim++.so
%{_libdir}/pkgconfig/libdkim++.pc


%changelog
* Fri Jul 13 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.10-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild

* Wed Feb 07 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.10-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild

* Thu Aug 03 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.10-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild

* Wed Jul 26 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.10-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild

* Tue Mar 21 2017 Denis Fateyev <denis@fateyev.com> - 1.0.10-1
- Update to 1.0.10 release

* Fri Feb 10 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.9-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild

* Wed May 25 2016 Denis Fateyev <denis@fateyev.com> - 1.0.9-1
- Update to 1.0.9 release

* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.8-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild

* Thu Dec 10 2015 Denis Fateyev <denis@fateyev.com> - 1.0.8-1
- Initial release