# help2man is executed from ./src/Makefile if main.c or configure.ac is newer
# than recode.1.
BuildRequires: make
BuildRequires: libtool
BuildRequires: libtool
BuildRequires: texinfo
BuildRequires: texinfo
# Tests:
BuildRequires: python3-Cython
BuildRequires: python3-devel >= 3.7.5
BuildRequires: python3-setuptools
%description
%description
The recode tool and library convert files between character sets and surfaces.
The `recode' converts files between character sets and usages.
It recognizes or produces over 200 different character sets (or about 300 if
It recognizes or produces nearly 150 different character sets
combined with an iconv library) and transliterates files between almost any
and is able to transliterate files between almost any pair. When exact
pair. When exact transliteration is not possible, it gets rid of the offending
transliteration are not possible, it may get rid of the offending
character or falls back on an approximations.
characters or fall back on approximations. Most RFC 1345 character sets
are supported.
%package devel
%package devel
Summary: Header files for development using recode library
Summary: Header files for development using recode
# Header files are LGPLv3+
Group: Development/Libraries
License: LGPL-3.0-or-later
Requires: %{name}%{?_isa} = %{version}-%{release}
Requires: %{name}%{?_isa} = %{version}-%{release}
%description devel
%description devel
This package provides the header files for a recode library.
The `recode' library converts files between character sets and usages.
The library recognizes or produces nearly 150 different character sets
and is able to transliterate files between almost any pair. When exact
transliteration are not possible, it may get rid of the offending
characters or fall back on approximations. Most RFC 1345 character sets
are supported.
%prep
%prep
%autosetup -p1 -n %{name}-%{version}
%setup -q
autoreconf -fi
%patch0 -p1
%patch1 -p1 -b .getcwd
%patch2 -p0
%patch3 -p1
%patch4 -p1
%patch5 -p1
%patch6 -p1
rm m4/libtool.m4
rm acinclude.m4
%build
%build
export PYTHON=%{__python3}
autoreconf -fiv
%configure \
%configure --disable-static
--without-dmalloc \
make %{?_smp_mflags}
--disable-gcc-warnings \
--enable-largefile \
--enable-nls \
--disable-rpath \
--enable-shared \
--disable-static
%{make_build}
%check
%check
make check
make check
%install
%install
%{make_install}
%makeinstall
%find_lang %{name}
%find_lang %{name}
# remove unpackaged file from the buildroot
# remove unpackaged file from the buildroot
rm -r $RPM_BUILD_ROOT%{_infodir}/dir
rm -f $RPM_BUILD_ROOT%{_infodir}/dir
# remove libtool archives
# remove libtool archives
rm $RPM_BUILD_ROOT%{_libdir}/*.la
rm -f $RPM_BUILD_ROOT%{_libdir}/*.la
%post
/sbin/ldconfig
/sbin/install-info %{_infodir}/recode.info.gz %{_infodir}/dir --entry="* recode: (recode). Conversion between character sets and surfaces." || :
%preun
if [ $1 = 0 ]; then
/sbin/install-info --delete %{_infodir}/recode.info.gz %{_infodir}/dir --entry="* recode: (recode). Conversion between character sets and surfaces." || :
fi
%postun -p /sbin/ldconfig
%files -f %{name}.lang
%files -f %{name}.lang
%license COPYING COPYING-LIB
%doc AUTHORS COPYING* ChangeLog NEWS README THANKS TODO
# Changelog is not helpful
%doc AUTHORS NEWS README THANKS TODO
%{_mandir}/*/*
%{_mandir}/*/*
%{_infodir}/recode.info*
%{_infodir}/recode.info*
%{_bindir}/*
%{_bindir}/*
%{_libdir}/librecode.so.3
%{_libdir}/*.so.0*
%{_libdir}/librecode.so.3.*
%files devel
%files devel
%{_libdir}/*.so
%{_libdir}/*.so
%{_includedir}/*
%{_includedir}/*
%changelog
%changelog
* Thu Dec 26 2024 Dmitriy Samoylik <samoylikdv@msvsphere-os.ru> - 3.7.14-6