%define ghc_ver %(ghc --numeric-version) %define pkgname texmath Name: ghc-texmath Version: 0.8.1 Release: 1mamba Summary: GHC library: Conversion between formats used to represent mathematics Group: System/Libraries Vendor: openmamba Distribution: openmamba Packager: Silvan Calarco URL: http://hackage.haskell.org/package/%{pkgname} Source: http://hackage.haskell.org/packages/archive/texmath/%{version}/texmath-%{version}.tar.gz License: BSD ## AUTOBUILDREQ-BEGIN ## AUTOBUILDREQ-END BuildRequires: ghc BuildRequires: ghc-xml BuildRequires: ghc-pandoc-types Requires: ghc = %{ghc_ver} Requires: ghc-xml Requires: ghc-pandoc-types BuildRoot: %{_tmppath}/%{name}-%{version}-root %description The texmath library provides functions to read and write TeX math, presentation MathML, and OMML (Office Math Markup Language, used in Microsoft Office). Support is also included for converting math formats to pandoc's native format (allowing conversion, via pandoc, to a variety of different markup formats). The TeX reader supports basic LaTeX and AMS extensions, and it can parse and apply LaTeX macros. %prep %setup -q -n texmath-%{version} %build runghc Setup.lhs configure -v2 \ --prefix=%{_prefix} \ --libdir=%{_libdir} \ --libexecdir=%{_libexecdir} \ --docdir=%{_docdir}/%{name}-%{version} runghc Setup.lhs build runghc Setup.lhs haddock --executable --html-location=URL --hyperlink-source %install [ "%{buildroot}" != / ] && rm -rf "%{buildroot}" runghc Setup.lhs copy --destdir=%{buildroot} runghc Setup.lhs register \ --gen-pkg-config="%{buildroot}%{_libdir}/ghc-%{ghc_ver}/%{pkgname}-%{version}/%{pkgname}-%{version}.conf" %clean [ "%{buildroot}" != / ] && rm -rf "%{buildroot}" %post ghc-pkg register %{_libdir}/ghc-%{ghc_ver}/%{pkgname}-%{version}/%{pkgname}-%{version}.conf &>/dev/null || : %preun ghc-pkg unregister %{pkgname}-%{version} &>/dev/null || : %files %defattr(-,root,root) %{_libdir}/ghc-%{ghc_ver}/%{pkgname}-%{version} %{_docdir}/%{name}-%{version}/LICENSE %{_docdir}/%{name}-%{version}/html %changelog * Mon Apr 13 2015 Davide Madrisan 0.8.1-1mamba - update to 0.8.1 * Sun Sep 08 2013 Silvan Calarco 0.6.4-1mamba - package created by silvan using the webbuild interface