]>
Commit | Line | Data |
---|---|---|
742e5897 | 1 | # TODO: package the vim syntax file. |
86d6172c | 2 | Summary: A tool for converting text files to various formats |
465ba125 | 3 | Summary(pl.UTF-8): Narzędzie do konwersji plików tekstowych do różnych formatów |
86d6172c | 4 | Name: asciidoc |
0f7453d4 | 5 | Version: 9.1.0 |
73dee59c | 6 | Release: 1 |
5675ed0e | 7 | License: GPL v2+ |
86d6172c | 8 | Group: Applications/System |
04c9364e | 9 | #Source0Download: https://github.com/asciidoc/asciidoc/releases |
0f7453d4 JP |
10 | Source0: https://github.com/asciidoc-py/asciidoc-py/archive/%{version}/%{name}-%{version}.tar.gz |
11 | # Source0-md5: 52fc3849e1f48d8764337ce2b355b2ff | |
12 | URL: https://asciidoc.org/ | |
04c9364e | 13 | BuildRequires: autoconf >= 2.50 |
d62a141d | 14 | BuildRequires: rpm-pythonprov |
d0e0c459 | 15 | BuildRequires: sed >= 4.0 |
0f7453d4 JP |
16 | Requires: python3 >= 1:3.5 |
17 | Requires: python3-modules >= 1:3.5 | |
29d5dcd1 | 18 | Requires: xmlto |
86d6172c | 19 | BuildArch: noarch |
20 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
21 | ||
04c9364e | 22 | %define pkgconfdir %{_sysconfdir}/asciidoc |
86d6172c | 23 | |
24 | %description | |
fd5d72cd JB |
25 | AsciiDoc is a text document format for writing short documents, |
26 | articles, books and UNIX man pages. AsciiDoc files can be translated | |
27 | to HTML (with or without stylesheets), DocBook and LinuxDoc markup | |
28 | using the asciidoc(1) command. AsciiDoc is highly configurable: both | |
29 | the AsciiDoc source file syntax and the backend output markups (which | |
30 | can be almost any type of SGML/XML markup) can be customized and | |
31 | extended by the user. | |
86d6172c | 32 | |
3dc03438 JR |
33 | %description -l pl.UTF-8 |
34 | AsciiDoc jest formatem dokumentów tekstowych do pisania krótkich | |
35 | dokumentów, artykułów, książek i podręczników systemu UNIX. Pliki | |
36 | AsciiDoc mogą być tłumaczone do HTML-a (z lub bez CSS), DocBooka i | |
37 | LinuxDoca używając polecenia asciidoc(1). AsciiDoc jest wysoce | |
38 | konfigurowalny: zarówno składnia plików źródłowych, jak i znaczniki | |
39 | backendów (które mogą być dowolnego typu SGML/XML) mogą być | |
40 | dostosowywane i rozszerzane przez użytkownika. | |
86d6172c | 41 | |
42 | %prep | |
0f7453d4 | 43 | %setup -q -n %{name}-py-%{version} |
8eb1c8a9 | 44 | |
0f7453d4 | 45 | %{__sed} -i -e '1s|^#!/usr/bin/env python3\?|#!%{__python3}|' asciidoc.py a2x.py \ |
c496920f | 46 | filters/code/code-filter.py \ |
04c9364e | 47 | filters/latex/latex2img.py \ |
c496920f | 48 | filters/music/music2png.py \ |
0f7453d4 JP |
49 | filters/graphviz/graphviz2png.py \ |
50 | filters/unwraplatex.py | |
86d6172c | 51 | |
d0e0c459 | 52 | %build |
04c9364e | 53 | %{__autoconf} |
8eb1c8a9 JB |
54 | %configure |
55 | ||
56 | %{__make} | |
d0e0c459 | 57 | |
86d6172c | 58 | %install |
59 | rm -rf $RPM_BUILD_ROOT | |
86d6172c | 60 | |
04c9364e JB |
61 | %{__make} install \ |
62 | DESTDIR=$RPM_BUILD_ROOT | |
86d6172c | 63 | |
04c9364e JB |
64 | # install directly instead of symlinks to .py |
65 | %{__mv} $RPM_BUILD_ROOT%{_bindir}/a2x{.py,} | |
66 | %{__mv} $RPM_BUILD_ROOT%{_bindir}/asciidoc{.py,} | |
67 | # move constant data to /usr | |
68 | install -d $RPM_BUILD_ROOT%{_datadir}/%{name} | |
69 | %{__mv} $RPM_BUILD_ROOT%{pkgconfdir}/{images,javascripts} $RPM_BUILD_ROOT%{_datadir}/%{name} | |
70 | ln -sf %{_datadir}/%{name}/images $RPM_BUILD_ROOT%{pkgconfdir}/images | |
71 | ln -sf %{_datadir}/%{name}/javascripts $RPM_BUILD_ROOT%{pkgconfdir}/javascripts | |
742e5897 | 72 | |
0f7453d4 JP |
73 | %{__rm} $RPM_BUILD_ROOT%{_mandir}/man1/testasciidoc.1 |
74 | ||
742e5897 | 75 | # if [ -d $VIM_RPM_BUILD_ROOT%{sysconfdir} ]; then |
76 | # install -d $VIM_RPM_BUILD_ROOT%{sysconfdir}/syntax | |
77 | # install -m 644 vim/syntax/asciidoc.vim \ | |
78 | # $VIM_RPM_BUILD_ROOT%{sysconfdir}/syntax/asciidoc.vim | |
79 | # install -d $VIM_RPM_BUILD_ROOT%{sysconfdir}/ftdetect | |
80 | # install -m 644 vim/ftdetect/asciidoc_filetype.vim \ | |
81 | # $VIM_RPM_BUILD_ROOT%{sysconfdir}/ftdetect/asciidoc_filetype.vim | |
82 | # fi | |
ebdc84fb | 83 | |
86d6172c | 84 | %clean |
85 | rm -rf $RPM_BUILD_ROOT | |
86 | ||
87 | %files | |
88 | %defattr(644,root,root,755) | |
0f7453d4 | 89 | %doc BUGS.txt CHANGELOG.txt COPYRIGHT README.asciidoc doc/asciidoc.txt |
5675ed0e JB |
90 | %attr(755,root,root) %{_bindir}/a2x |
91 | %attr(755,root,root) %{_bindir}/asciidoc | |
04c9364e JB |
92 | %dir %{pkgconfdir} |
93 | %config(noreplace) %verify(not md5 mtime size) %{pkgconfdir}/*.conf | |
94 | %dir %{pkgconfdir}/dblatex | |
95 | %{pkgconfdir}/dblatex/*.sty | |
96 | %{pkgconfdir}/dblatex/*.xsl | |
97 | %dir %{pkgconfdir}/docbook-xsl | |
98 | %{pkgconfdir}/docbook-xsl/*.xsl | |
99 | %dir %{pkgconfdir}/filters | |
100 | %dir %{pkgconfdir}/filters/code | |
101 | %config(noreplace) %verify(not md5 mtime size) %{pkgconfdir}/filters/code/code-filter.conf | |
102 | %attr(755,root,root) %{pkgconfdir}/filters/code/code-filter.py | |
103 | %dir %{pkgconfdir}/filters/graphviz | |
104 | %config(noreplace) %verify(not md5 mtime size) %{pkgconfdir}/filters/graphviz/graphviz-filter.conf | |
105 | %attr(755,root,root) %{pkgconfdir}/filters/graphviz/graphviz2png.py | |
106 | %dir %{pkgconfdir}/filters/music | |
107 | %config(noreplace) %verify(not md5 mtime size) %{pkgconfdir}/filters/music/music-filter.conf | |
108 | %attr(755,root,root) %{pkgconfdir}/filters/music/music2png.py | |
109 | %dir %{pkgconfdir}/filters/source | |
110 | %config(noreplace) %verify(not md5 mtime size) %{pkgconfdir}/filters/source/source-highlight-filter.conf | |
111 | %dir %{pkgconfdir}/filters/latex | |
112 | %config(noreplace) %verify(not md5 mtime size) %{pkgconfdir}/filters/latex/latex-filter.conf | |
113 | %attr(755,root,root) %{pkgconfdir}/filters/latex/latex2img.py | |
0f7453d4 | 114 | %attr(755,root,root) %{pkgconfdir}/filters/unwraplatex.py |
04c9364e JB |
115 | %{pkgconfdir}/images |
116 | %{pkgconfdir}/javascripts | |
117 | %dir %{pkgconfdir}/stylesheets | |
118 | %{pkgconfdir}/stylesheets/*.css | |
119 | %{pkgconfdir}/themes | |
5675ed0e JB |
120 | %{_datadir}/%{name} |
121 | %{_mandir}/man1/a2x.1* | |
122 | %{_mandir}/man1/asciidoc.1* |