%define libnfnetlink 1.0.1

Name:           libnetfilter_log
Version:        1.0.2
Release:        1%{?_dist_release}
Summary:        Netfilter logging userspace library
Group:          system
Vendor:         Project Vine
Distribution:   Vine Linux

License:        GPLv2
URL:            https://netfilter.org
Source0:        https://netfilter.org/projects/%{name}/files/%{name}-%{version}.tar.bz2
BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)

BuildRequires:  libmnl-devel
BuildRequires:  libnfnetlink-devel >= %{libnfnetlink}
BuildRequires:  pkgconfig
BuildRequires:  kernel-headers

%description
libnetfilter_log is a userspace library providing interface to packets that
have been logged by the kernel packet filter. It is is part of a system that
deprecates the old syslog/dmesg based packet logging.

libnetfilter_log has been previously known as libnfnetlink_log.

libnetfilter_log is used by ulogd2. 


%package        devel
Summary:        Netfilter logging userspace library
Group:          programming
Requires:       %{name} = %{version}-%{release}, pkgconfig, kernel-headers

%description    devel
libnetfilter_log is a userspace library providing interface to packets that
have been logged by the kernel packet filter. It is is part of a system that
deprecates the old syslog/dmesg based packet logging.

libnetfilter_log has been previously known as libnfnetlink_log.

libnetfilter_log is used by ulogd2.


%debug_package


%prep
%setup -q


%build
%configure --disable-static --disable-rpath
sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool
sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool

make %{?_smp_mflags}


%install
rm -rf $RPM_BUILD_ROOT
make install DESTDIR=$RPM_BUILD_ROOT
find $RPM_BUILD_ROOT -type f -name "*.la" -exec rm -f {} ';'


%files
%defattr(-,root,root,-)
%license COPYING
%{_libdir}/*.so.*

%files devel
%defattr(-,root,root,-)
%{_libdir}/*.so
%dir %{_includedir}/%{name}
%{_includedir}/%{name}/*.h
%{_libdir}/pkgconfig/*.pc


%changelog
* Fri Oct 20 2023 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 1.0.2-1
- new upstream release.
- dropped ldconfig scriptlets.

* Sun Aug 25 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 1.0.1-7
- rebuilt with current environment.

* Sun Jun 29 2014 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 1.0.1-6
- initial build for Vine Linux.

* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.1-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild

* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.1-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild

* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.1-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild

* Thu Jul 19 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.1-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild

* Sat Mar 17 2012 Paul P. Komkoff Jr <i@stingr.net> - 1.0.1-1
- upstream release

* Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.0-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild

* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.0-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild

* Wed Nov  3 2010 Paul P. Komkoff Jr <i@stingr.net> - 1.0.0-1
- upstream release

* Fri Jul 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.0.16-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild

* Fri Mar  6 2009 Paul P. Komkoff Jr <i@stingr.net> - 0.0.16-1
- upstream release

* Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.0.15-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild

* Sun Oct 26 2008 Paul P. Komkoff Jr <i@stingr.net> - 0.0.15-1
- new upstream version
- hard dependency on libnfnetlink version

* Fri Aug 29 2008 Michael Schwendt <mschwendt@fedoraproject.org> - 0.0.14-3
- include /usr/include/libnetfilter_log directory

* Thu Aug  7 2008 Tom "spot" Callaway <tcallawa@redhat.com> - 0.0.14-2
- fix license tag

* Wed Jul 16 2008 Paul P. Komkoff Jr <i@stingr.net> - 0.0.14-1
- grab latest upstream version

* Sat Apr  5 2008 Paul P Komkoff Jr <i@stingr.net> - 0.0.13-6
- update to latest svn and to use system netfilter header (fixes the build)

* Tue Feb 19 2008 Fedora Release Engineering <rel-eng@fedoraproject.org> - 0.0.13-5
- Autorebuild for GCC 4.3

* Sun May 27 2007 Paul P Komkoff Jr <i@stingr.net> - 0.0.13-4
- try to rebuild.

* Sun May 27 2007 Paul P Komkoff Jr <i@stingr.net> - 0.0.13-3
- stupid CVS import script keeps tagging all imported rpms with incorrect tags.

* Mon Mar 19 2007 Paul P Komkoff Jr <i@stingr.net> - 0.0.13-2
- fix source url
- add pkgconfig to -devel Requires

* Sat Mar 17 2007 Paul P Komkoff Jr <i@stingr.net> - 0.0.13-1
- Preparing for submission to fedora extras
