%define pkg_name pandoc %define pkg_version 1.17.1 %define pkg_release 1%{?_dist_release} %define ghc_version 7.10.3 Summary: general markup converter Summary(ja): 汎用マークアップ変換ツール Name: %{pkg_name} Version: %{pkg_version} Release: %{pkg_release} License: GPLv2+ Group: Applications/Text URL: http://hackage.haskell.org Source0: pandoc-%{pkg_version}/pandoc-%{pkg_version}.tar.gz BuildRoot: %{_tmppath}/%{pkg_name}-%{version}-root BuildRequires: ghc haskell-platform-base cabal-install BuildRequires: libffi-devel gmp-devel zlib-devel BuildRequires: libghc-data-default-class BuildRequires: libghc-dlist BuildRequires: libghc-data-default BuildRequires: libghc-aeson BuildRequires: libghc-http-client-tls BuildRequires: yaml BuildRequires: libghc-build-pandoc BuildRequires: docbook-utils docbook-utils-pdf docbook-style-xsl BuildRequires: hscolour Requires: libffi Vendor: Project Vine Distribution: Vine Linux Packager: ara_t %description Pandoc is a Haskell library for converting from one markup format to another, and a command-line tool that uses this library. It can read markdown and (subsets of) HTML, reStructuredText, LaTeX, DocBook, MediaWiki markup, Haddock markup, OPML, Emacs Org-mode, and Textile, and it can write markdown, reStructuredText, HTML, LaTeX (including rendering as plain PDF or beamer slide shows), ConTeXt, DocBook, OPML, OpenDocument, ODT, Word docx, RTF, MediaWiki, Textile, groff man pages, GNU Texinfo, plain text, Emacs Org-Mode, AsciiDoc, InDesign ICML, EPUB (v2 or v3), FictionBook2, and several kinds of HTML/javascript slide shows (S5, Slidy, Slideous, DZSlides, reveal.js). Pandoc extends standard markdown syntax with footnotes, embedded LaTeX, definition lists, tables, and other features. A compatibility mode is provided for those who need a drop-in replacement for Markdown.pl. In contrast to existing tools for converting markdown to HTML, which use regex substitutions, pandoc has a modular design: it consists of a set of readers, which parse text in a given format and produce a native representation of the document, and a set of writers, which convert this native representation into a target format. Thus, adding an input or output format requires only adding a reader or writer. %description -l ja Pandoc はあるマークアップ形式から別の形式に変換するHaskellライブラリで、 また、このライブラリを使ったコマンドラインツールです。 markdown、HTML (のサブセット)、reStructuredText、 LaTeX、DocBook、 MediaWikiマークアップ、Haddockマークアップ、OPML、Emacs Org-mode、 およびTextileを読み取り、 markdown、reStructuredText、HTML、LaTeX (プレインPDFまたはbeamerスライドショー での描画を含む)、ConTeXt、DocBook、OPML、OpenDocument、ODT、Word docx、RTF、 MediaWiki、Textile、groff manページ、GNU Texinfo、プレーンテキスト、 Emacs Org-Mode、AsciiDoc、InDesign ICML、EPUB (v2 または v3)、FictionBook2、 およびいくつかの種類のHTML/javascriptスライドショー (S5, Slidy, Slideous, DZSlides, reveal.js) に書き出せます。 Pandocは標準的なmarkdownの文法に脚注、組み込み LaTeX、定義リスト、表、 およびその他の機能を拡張しています。 Markdown.plの気軽な置き換えを希望する方向けに互換モードを提供しています。 markdownからHTMLに変換する既存のツールは正規表現で置換していますが、 これらとは異なり、pandoc はモジュール式の設計になっています: テキストを指定された形式でパースし、文書のネイティブ表現を生成するリーダ一式、 および、このネイティブ表現を対象とする形式に変換するライタ一式で構成されて います。したがって、入力または出力形式を追加するにはリーダやライタを追加する ことだけが必要です。 %package libs Summary: Library of pandoc Group: Development/Libraries %description libs Librariy of pandoc for building pandoc-citeproc and pandoc-crossref %prep %{__rm} -rf ${RPM_BUILD_ROOT} %setup -q %build # Initialise the package db ghc-pkg init %{_builddir}/package.conf PKG_CONF_DIR=${RPM_BUILD_ROOT}%{_libdir}/ghc-%{ghc_version}/package.conf.d %{__mkdir_p} ${PKG_CONF_DIR} cabal configure \ --prefix=%{_prefix} \ --libdir=%{_libdir}/%{name}-%{version} \ --libsubdir= \ --datadir=%{_datadir}/%{name}-%{version} \ --datasubdir= \ --docdir=%{_docdir}/%{name}-%{version} cabal build cabal haddock cabal copy --destdir=${RPM_BUILD_ROOT} cabal register --gen-pkg-config=${PKG_CONF_DIR}/%{name}.conf %install %{__mkdir_p} ${RPM_BUILD_ROOT}%{_docdir}/%{name}-%{version} %{__cp} BUGS changelog CONTRIBUTING.md COPYING COPYRIGHT README \ ${RPM_BUILD_ROOT}%{_docdir}/%{name}-%{version} %{__rm} ${RPM_BUILD_ROOT}%{_datadir}/%{name}-%{version}/{COPYRIGHT,README} %{__mv} ${RPM_BUILD_ROOT}%{_datadir}/%{name}-%{version}/man \ ${RPM_BUILD_ROOT}%{_datadir} %clean %{__rm} -rf ${RPM_BUILD_ROOT} %post libs ghc-pkg recache %postun libs ghc-pkg recache %files %defattr(-, root, root) %{_bindir}/pandoc %{_datadir}/%{name}-%{version}/ %{_docdir}/%{name}-%{version}/ %{_mandir}/man1/pandoc.1.gz %files libs %defattr(-, root, root) %{_libdir}/%{name}-%{version}/ %{_libdir}/ghc-%{ghc_version}/ %changelog * Sat Jun 18 2016 Toshiaki Ara 1.17.1-1 - update to 1.17.1 * Fri May 06 2016 Toshiaki Ara 1.17.0.3-5 - update to 1.17.0.3 - add BuildRequires: libghc-build-pandoc - provide pandoc-libs for building pandoc-citeproc and pacdoc-crossref - delete subpackages: pandoc-citeproc and pacdoc-crossref * Tue Apr 12 2016 Toshiaki Ara 1.16.0.2-5 - correct SPEC file * Mon Mar 07 2016 Toshiaki Ara 1.16.0.2-4 - correct pandoc-citeproc error * Tue Mar 01 2016 Toshiaki Ara 1.16.0.2-2 - rebuild under dependent rpm packages * Sun Feb 21 2016 Toshiaki Ara 1.16.0.2-2 - rebuild under ghc-7.10.3 and haskell-platform-2015.7.10.3 * Sun Feb 07 2016 Toshiaki Ara 1.16.0.2-1 - new package