diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..6611bfb --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +/libnumbertext-1.0.2.tar.xz diff --git a/README.md b/README.md deleted file mode 100644 index 57442c5..0000000 --- a/README.md +++ /dev/null @@ -1,3 +0,0 @@ -# libnumbertext - -The libnumbertext package \ No newline at end of file diff --git a/libnumbertext-cxxflags.patch b/libnumbertext-cxxflags.patch new file mode 100644 index 0000000..f308d4c --- /dev/null +++ b/libnumbertext-cxxflags.patch @@ -0,0 +1,11 @@ +--- libnumbertext-1.0.2/configure.ac ++++ libnumbertext-1.0.2/configure.ac +@@ -22,7 +22,7 @@ + + dnl Checks for typedefs, structures, and compiler characteristics. + AC_LANG([C++]) +-CXXFLAGS='-Wall -std=c++11' ++CXXFLAGS="$CXXFLAGS -Wall -std=c++11" + + AC_CHECK_HEADERS([codecvt regex]) + diff --git a/libnumbertext-updateautotools.patch b/libnumbertext-updateautotools.patch new file mode 100644 index 0000000..4383e9a --- /dev/null +++ b/libnumbertext-updateautotools.patch @@ -0,0 +1,20 @@ +--- libnumbertext-1.0.2/configure.ac 2018-06-12 14:48:53.518952998 +0100 ++++ libnumbertext-1.0.2/configure.ac 2018-06-12 14:50:48.000000000 +0100 +@@ -3,7 +3,7 @@ + m4_define([numbertext_version_micro],[2]) + m4_define([numbertext_version],[numbertext_version_major.numbertext_version_minor.numbertext_version_micro]) + +-AC_PREREQ([2.68]) ++AC_PREREQ([2.69]) + + AC_INIT([libnumbertext],[numbertext_version]) + AC_CONFIG_MACRO_DIR([m4]) +@@ -18,7 +18,7 @@ + AC_PROG_CPP + AC_PROG_INSTALL + AC_PROG_LN_S +-AC_PROG_LIBTOOL ++LT_INIT + + dnl Checks for typedefs, structures, and compiler characteristics. + AC_LANG([C++]) diff --git a/libnumbertext.spec b/libnumbertext.spec new file mode 100644 index 0000000..6c8b9f2 --- /dev/null +++ b/libnumbertext.spec @@ -0,0 +1,73 @@ +Name: libnumbertext +Version: 1.0.2 +Release: 3%{?dist} +Summary: Number to number name and money text conversion library + +#The entire source code is dual license LGPLv3+ or BSD, except for +#the data files hr.sor, sr.sor and sh.sor which are tri license +#CC-BY-SA or LGPLv3+ or BSD +License: (LGPLv3+ or BSD) and (LGPLv3+ or BSD or CC-BY-SA) +URL: https://github.com/Numbertext/libnumbertext +Source: https://github.com/Numbertext/libnumbertext/releases/download/1.0.beta3/libnumbertext-1.0.2.tar.xz +Patch0: libnumbertext-cxxflags.patch +Patch1: libnumbertext-updateautotools.patch + +BuildRequires: autoconf, automake, libtool + +%description +Language-neutral NUMBERTEXT and MONEYTEXT functions for LibreOffice Calc + +%package devel +Requires: libnumbertext = %{version}-%{release} +Summary: Files for developing with libnumbertext +Group: Development/Libraries + +%description devel +Includes and definitions for developing with libnumbertext + +%prep +%autosetup -p1 + +%build +autoreconf -v --install --force +%configure --disable-silent-rules --disable-static --disable-werror --with-pic +make %{?_smp_mflags} + +%check +make check + +%install +rm -rf $RPM_BUILD_ROOT +make DESTDIR=$RPM_BUILD_ROOT install +rm -f $RPM_BUILD_ROOT/%{_libdir}/*.la + +%post -p /sbin/ldconfig + +%postun -p /sbin/ldconfig + +%files +%defattr(-,root,root,-) +%doc AUTHORS ChangeLog README NEWS THANKS +%license COPYING +%{_bindir}/spellout +%{_libdir}/*.so.* +%{_datadir}/libnumbertext + +%files devel +%defattr(-,root,root,-) +%{_includedir}/libnumbertext +%{_libdir}/pkgconfig/libnumbertext.pc +%{_libdir}/*.so + +%changelog +* Tue Jun 12 2018 Caolán McNamara - 1.0.2-3 +- fix changelog order +- remove clean section +- set COPYING as license +- use LT_INIT + +* Mon Jun 11 2018 Caolán McNamara - 1.0.2-2 +- clarify extra license option of the sh/sr/hr data files + +* Mon Jun 11 2018 Caolán McNamara - 1.0.2-1 +- initial version diff --git a/sources b/sources new file mode 100644 index 0000000..01258e9 --- /dev/null +++ b/sources @@ -0,0 +1 @@ +SHA512 (libnumbertext-1.0.2.tar.xz) = e49ff7447aa15b3985486d492c44f0d57ef5b3f342f11291c2cf687d8f37e4a0b16bce933ff7acb82183cadea2d1ac7acd3f0074ad98645f5b49dc5208d4eabc