uchardet/uchardet.spec
2020-03-03 21:27:45 +08:00

70 lines
1.5 KiB
RPMSpec

Name: uchardet
Version: 0.0.6
Release: 1
Summary: An encoding detector library ported from Mozilla
License: MPLv1.1
URL: https://www.freedesktop.org/wiki/Software/%{name}
Source0: https://www.freedesktop.org/software/%{name}/releases/%{name}-%{version}.tar.xz
BuildRequires: gcc gcc-c++ cmake
%description
Uchardet is a C language binding of the original C++ implementation of the
universal charset detection library by Mozilla. Uchardet is an encoding
detector library, which takes a sequence of bytes in an unknown character
encoding without any additional information, and attempts to determine the
encoding of the text.
%package devel
Summary: Development files for %{name}
Requires: %{name} = %{version}-%{release}
%description devel
The %{name}-devel package contains headers and shared libraries
for developing tools for uchardet.
%prep
%autosetup
mkdir build
%build
pushd build
%cmake .. \
-DCMAKE_INSTALL_LIBDIR=%{_libdir} \
-DBUILD_STATIC=OFF
%make_build
popd
%install
pushd build
%make_install
popd
%ldconfig_scriptlets
%check
pushd build
ctest -VV \
%ifarch %{ix86}
|| :
%else
;
%endif
popd
%files
%doc AUTHORS
%license COPYING
%{_bindir}/%{name}
%{_libdir}/lib%{name}.so.*
%{_mandir}/man1/%{name}.1.*
%files devel
%{_includedir}/%{name}/
%{_libdir}/lib%{name}.so
%{_libdir}/pkgconfig/%{name}.pc
%changelog
* Mon Mar 2 2020 openEuler Buildteam <buildteam@openeuler.org> - 0.0.6-1
- Package init