3 %bcond_with apidocs # don't generate apidocs subpackage
4 %bcond_without gui # don't build Qt GUI tool
6 Summary: A source code converter to HTML, XHTML, RTF, TeX, LaTeX, XSL-FO, and XML
7 Summary(pl.UTF-8): Konwerter kodu źródłowego do formatów HTML, XHTML, RTF, TeX, LaTeX, XSL-FO oraz XML
12 Group: Applications/Publishing
13 Source0: http://www.andre-simon.de/zip/%{name}-%{version}.tar.bz2
14 # Source0-md5: e61056f9cfe5f865ea7f87c74f05d22f
15 Patch0: %{name}-Makefile.patch
16 URL: http://www.andre-simon.de/
17 BuildRequires: boost-devel
18 %{?with_apidocs:BuildRequires: doxygen}
19 BuildRequires: libstdc++-devel
20 BuildRequires: lua-devel >= 5.3
21 BuildRequires: pkgconfig
22 BuildRequires: rpm-build >= 4.6
23 BuildRequires: rpmbuild(macros) >= 1.752
25 BuildRequires: Qt5Core-devel
26 BuildRequires: Qt5Gui-devel
27 BuildRequires: Qt5Widgets-devel
28 BuildRequires: qt5-build
29 BuildRequires: qt5-qmake
31 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
33 %define _sysconfdir /etc/highlight
36 Highlight is a universal converter from source code to HTML, XHTML,
37 RTF, TeX, LaTeX, XSL-FO, and XML. (X)HTML output is formatted by
38 Cascading Style Sheets. It supports 100 programming languages and
39 includes 50 highlighting color themes. It's possible to easily enhance
40 the parsing database. The converter includes some features to provide
41 a consistent layout of the input code.
43 %description -l pl.UTF-8
44 Highlight jest uniwersalnym konwerterem kodu źródłowego do formatów
45 HTML, XHTML, RTF, TeX, LaTeX, XSL-FO, and XML. Wyjście (X)HTML jest
46 formatowane przez kaskadowe arkusze stylów (CSS). Highlight wspiera
47 100 języków programowania i zawiera 50 kolorystycznych motywów
48 podświetlania składni. Umożliwia łatwe ulepszanie bazy parsowania.
49 Konwerter zawiera pewne cechy zapewniające spójny układ graficzny kodu
53 Summary: API documentation for highlight - a source code converter to HTML, XHTML, RTF, TeX, LaTeX, XSL-FO, and XML
54 Summary(pl.UTF-8): Dokumentacja API highlight - konwertera kodu źródłowego do HTML, XHTML, RTF, TeX, LaTeX, XSL-FO oraz XML
59 API documentation for highlight - a source code converter to HTML,
60 XHTML, RTF, TeX, LaTeX, XSL-FO, and XML.
62 %description apidocs -l pl.UTF-8
63 Dokumentacja API highlight - konwertera kodu źródłowego do formatu
64 HTML, XHTML, RTF, TeX, LaTeX, XSL-FO oraz XML.
67 Summary: GUI for highlight - a source code converter to HTML, XHTML, RTF, TeX, LaTeX, XSL-FO, and XML
68 Summary(pl.UTF-8): GUI do highlight - konwertera kodu źródłowego do HTML, XHTML, RTF, TeX, LaTeX, XSL-FO oraz XML
69 Group: Development/Tools
71 Requires(post,postun): gtk-update-icon-cache
72 Requires: hicolor-icon-theme
75 Qt4 GUI for for highlight - a source code converter to HTML, XHTML,
76 RTF, TeX, LaTeX, XSL-FO, and XML.
78 %package -n bash-completion-highlight
79 Summary: Bash completion for highlight
80 Group: Applications/Shells
81 Requires: %{name} = %{version}-%{release}
82 Requires: bash-completion >= 1:2.0
85 %description -n bash-completion-highlight
86 Bash completion for highlight.
88 %package -n fish-completion-highlight
89 Summary: fish-completion for highlight
90 Group: Applications/Shells
91 Requires: %{name} = %{version}-%{release}
95 %description -n fish-completion-highlight
96 fish-completion for highlight.
98 %package -n zsh-completion-highlight
99 Summary: ZSH completion for highlight
100 Group: Applications/Shells
101 Requires: %{name} = %{version}-%{release}
105 %description -n zsh-completion-highlight
106 ZSH completion for highlight.
115 CXXFLAGS="%{rpmcxxflags} -std=c++11" \
123 %{?with_apidocs:%{__make} apidocs}
126 rm -rf $RPM_BUILD_ROOT
129 DESTDIR=$RPM_BUILD_ROOT
132 %{__make} install-gui \
133 DESTDIR=$RPM_BUILD_ROOT
136 # to avoid false `warning: Installed (but unpackaged) file(s) found:' - these files are packaged through %doc
137 rm -fr $RPM_BUILD_ROOT%{_docdir}/highlight
140 rm -rf $RPM_BUILD_ROOT
143 %update_icon_cache hicolor
146 %update_icon_cache hicolor
149 %defattr(644,root,root,755)
150 %doc AUTHORS ChangeLog.adoc README.adoc README_LANGLIST.adoc README_PLUGINS.adoc README_REGEX.adoc extras
151 %lang(de) %doc README_DE.adoc
152 %attr(755,root,root) %{_bindir}/%{name}
153 %dir %{_datadir}/%{name}
154 %{_datadir}/%{name}/langDefs
155 %dir %{_datadir}/%{name}/plugins
156 %{_datadir}/%{name}/plugins/*.lua
157 %{_datadir}/%{name}/themes
158 %{_mandir}/man1/highlight.1*
159 %{_mandir}/man5/filetypes.conf.5*
161 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/*
165 %defattr(644,root,root,755)
171 %defattr(644,root,root,755)
172 %attr(755,root,root) %{_bindir}/%{name}-gui
173 %dir %{_datadir}/%{name}/gui_files
174 %dir %{_datadir}/%{name}/gui_files/l10n
175 %lang(bg) %{_datadir}/%{name}/gui_files/l10n/highlight_bg_BG.qm
176 %lang(cs) %{_datadir}/%{name}/gui_files/l10n/highlight_cs_CZ.qm
177 %lang(de) %{_datadir}/%{name}/gui_files/l10n/highlight_de_DE.qm
178 %lang(es) %{_datadir}/%{name}/gui_files/l10n/highlight_es_ES.qm
179 %lang(fr) %{_datadir}/%{name}/gui_files/l10n/highlight_fr_FR.qm
180 %lang(it) %{_datadir}/%{name}/gui_files/l10n/highlight_it_IT.qm
181 %lang(ja) %{_datadir}/%{name}/gui_files/l10n/highlight_ja_JP.qm
182 %lang(zh) %{_datadir}/%{name}/gui_files/l10n/highlight_zh_CN.qm
183 %{_datadir}/%{name}/gui_files/ext
184 %{_desktopdir}/*.desktop
185 %{_iconsdir}/hicolor/*x*/apps/highlight.png
188 %files -n bash-completion-highlight
189 %defattr(644,root,root,755)
190 %{bash_compdir}/highlight
192 %files -n fish-completion-highlight
193 %defattr(644,root,root,755)
194 %{fish_compdir}/highlight.fish
196 %files -n zsh-completion-highlight
197 %defattr(644,root,root,755)
198 %{zsh_compdir}/_highlight