File dlib.spec of Package dlib
#
# spec file for package dlib
#
%define major 19
%define minor 24
%define patch 0
Name: dlib
Version: %{major}.%{minor}
Release: lp151.1.1
%define libname lib%{name}
%define soname %{major}_%{minor}_%{patch}
Summary: A toolkit for machine learning and data analysis in C++
Group: Development/Libraries/C and C++
License: BSL-1.0
URL: http://dlib.net/
Source0: dlib-%{version}.tar.bz2
BuildRoot: %{_tmppath}/%{name}-%{version}-build
Packager: Alessandro de Oliveira Faria (A.K.A CABELO) <cabelo@opensuse.org>
BuildRequires: -post-build-checks -rpmlint-Factory -rpmlint-mini -rpmlint
BuildRequires: cmake libjpeg-devel libpng-devel gcc-c++ gcc
BuildRequires: fdupes
%description
Dlib is a modern C++ toolkit containing machine learning algorithms and tools for creating complex software in C++ to solve real world problems. See http://dlib.net for the main project documentation and API reference.
#%package -n %{libname}%{soname}
%package -n %{libname}
Summary: The library itself required to run applications built against it
Group: Development/Libraries/C and C++
License: BSL-1.0
#%description -n %{libname}%{soname}
%description -n %{libname}
Dlib is a template-heavy, optimized library sporting sophisticated machine learning algorithm implementations.
%package devel
Summary: Development files for Dlib
Group: Development/Libraries/C and C++
Requires: %{libname}
%description devel
This package contains the Dlib library and header files along with a pkgconfig file. It enables you to build your own software leveraging Dlib.
%prep
%autosetup
%build
echo $FLAGS
#cmake .
#%cmake @FLAGS ../dlib
%make_build
%install
cd build
%make_install
%clean
rm -rf %{buildroot}
#%post -n %{libname}%{soname} -p /sbin/ldconfig
#%postun -n %{libname}%{soname} -p /sbin/ldconfig
%post -n %{libname} -p /sbin/ldconfig
%postun -n %{libname} -p /sbin/ldconfig
##%files -n %{libname}%{soname}
%files -n %{libname}
%defattr(-,root,root,-)
%{_libdir}/libdlib.so.%{major}.%{minor}.%{patch}
%files devel
%defattr(-,root,root,-)
%{_libdir}/libdlib.so
%dir %{_libdir}/cmake/dlib
%{_libdir}/cmake/dlib/*
%dir %{_libdir}/pkgconfig
%{_libdir}/pkgconfig/dlib-1.pc
%dir %{_includedir}/dlib
%{_includedir}/dlib/*
%changelog
* Sat Oct 19 2019 Chris H <raymanfx@gmail.com>
- Initial library spec