Ville Skyttä 6cba39
%{!?python_sitelib: %global python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
Ville Skyttä 6cba39
jwboyer 7f91a8
Summary: Text based document generation
jwboyer 7f91a8
Name: asciidoc
Dave Airlie 0eeb1f
Version: 8.4.5
Dennis Gilmore def7d3
Release: 9%{?dist}
Tom Callaway 7a2ee0
# The python code does not specify a version.
Tom Callaway 7a2ee0
# The javascript example code is GPLv2+.
Tom Callaway 7a2ee0
License: GPL+ and GPLv2+
jwboyer 7f91a8
Group: Applications/System
jwboyer 7f91a8
URL: http://www.methods.co.nz/asciidoc/
jwboyer 7f91a8
Source0: http://www.methods.co.nz/asciidoc/%{name}-%{version}.tar.gz
Todd Zullinger 3492e3
# http://groups.google.com/group/asciidoc/browse_thread/thread/7f7a633c5b11ddc3
Todd Zullinger 3492e3
Patch0: asciidoc-8.4.5-datadir.patch
Todd Zullinger 3492e3
# https://bugzilla.redhat.com/506953
Todd Zullinger 3492e3
Patch1: asciidoc-8.4.5-use-unsafe-mode-by-default.patch
Ville Skyttä 6cba39
BuildRequires: python >= 2.4
Ville Skyttä 6cba39
Requires: python >= 2.4
Ville Skyttä 6cba39
Requires: docbook-style-xsl
Ville Skyttä 6cba39
Requires: libxslt
jwboyer 7f91a8
BuildArch: noarch
jwboyer 7f91a8
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
jwboyer 7f91a8
jwboyer 7f91a8
%description
jwboyer 7f91a8
AsciiDoc is a text document format for writing short documents,
jwboyer 7f91a8
articles, books and UNIX man pages. AsciiDoc files can be translated
jwboyer 7f91a8
to HTML and DocBook markups using the asciidoc(1) command.
jwboyer 7f91a8
jwboyer 7f91a8
%prep
jwboyer 7f91a8
%setup -q
Todd Zullinger 3492e3
%patch0 -p1 -b .datadir
Todd Zullinger 3492e3
%patch1 -p1 -b .use-unsafe-mode-by-default
Todd Zullinger 3492e3
Todd Zullinger 3492e3
# Fix line endings on COPYRIGHT file
Todd Zullinger 3492e3
sed -i "s/\r//g" COPYRIGHT
Todd Zullinger 3492e3
Todd Zullinger 3492e3
# Convert CHANGELOG and README to utf-8
Todd Zullinger 3492e3
for file in CHANGELOG README; do
Todd Zullinger 3492e3
    iconv -f ISO-8859-1 -t UTF-8 -o $file.new $file && \
Todd Zullinger 3492e3
    touch -r $file $file.new && \
Todd Zullinger 3492e3
    mv $file.new $file
Todd Zullinger 3492e3
done
jwboyer 7f91a8
jwboyer 7f91a8
%build
Ville Skyttä 6cba39
%configure
jwboyer 7f91a8
jwboyer 7f91a8
%install
Todd Zullinger 3492e3
rm -rf %{buildroot}
Ville Skyttä 6cba39
make install DESTDIR=%{buildroot}
Todd Zullinger 3492e3
Ville Skyttä 6cba39
# real conf data goes to sysconfdir, rest to datadir; symlinks so asciidoc works
Ville Skyttä 6cba39
for d in dblatex docbook-xsl images javascripts stylesheets ; do
Ville Skyttä 6cba39
    mv %{buildroot}%{_sysconfdir}/asciidoc/$d \
Ville Skyttä 6cba39
        %{buildroot}%{_datadir}/asciidoc
Ville Skyttä 6cba39
    ln -s %{_datadir}/asciidoc/$d %{buildroot}%{_sysconfdir}/asciidoc/
Todd Zullinger 3492e3
done
Chris Wright 5d7bd0
Ville Skyttä 6cba39
# Python API
Ville Skyttä 6cba39
install -Dpm 644 asciidocapi.py %{buildroot}%{python_sitelib}/asciidocapi.py
Chris Wright 5d7bd0
Ville Skyttä 6cba39
# Make it easier to %exclude these with both rpm < and >= 4.7
Ville Skyttä 6cba39
for file in %{buildroot}{%{_bindir},%{_datadir}/asciidoc/filters/*}/*.py ; do
Ville Skyttä 6cba39
    touch ${file}{c,o}
Ville Skyttä 6cba39
done
Chris Wright 5d7bd0
jwboyer 7f91a8
jwboyer 7f91a8
%clean
Todd Zullinger 3492e3
rm -rf %{buildroot}
jwboyer 7f91a8
jwboyer 7f91a8
%files
jwboyer 7f91a8
%defattr(-,root,root,0755)
jwboyer 7f91a8
%config(noreplace) %{_sysconfdir}/asciidoc
Ville Skyttä 6cba39
%exclude %{_bindir}/*.py[co]
Chris Wright 5d7bd0
%{_bindir}/*
jwboyer 7f91a8
%{_mandir}/man1/*
jwboyer 7f91a8
%{_datadir}/asciidoc/
Ville Skyttä 6cba39
%exclude %{_datadir}/asciidoc/filters/*/*.py[co]
Ville Skyttä 6cba39
%{python_sitelib}/asciidocapi.py*
Florian La Roche 7cfe58
%doc README BUGS CHANGELOG COPYRIGHT
jwboyer 7f91a8
jwboyer 7f91a8
%changelog
Dennis Gilmore def7d3
* Wed Feb 13 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 8.4.5-9
Dennis Gilmore def7d3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
Dennis Gilmore def7d3
Dennis Gilmore 1ec298
* Wed Jul 18 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 8.4.5-8
Dennis Gilmore 1ec298
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
Dennis Gilmore 1ec298
Dennis Gilmore 18c1ab
* Thu Jan 12 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 8.4.5-7
Dennis Gilmore 18c1ab
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
Dennis Gilmore 18c1ab
Dennis Gilmore 671013
* Wed Feb 09 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 8.4.5-6
Dennis Gilmore 671013
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
Dennis Gilmore 671013
dmalcolm d31ed5
* Wed Jul 21 2010 David Malcolm <dmalcolm@redhat.com> - 8.4.5-5
dmalcolm d31ed5
- Rebuilt for https://fedoraproject.org/wiki/Features/Python_2.7/MassRebuild
dmalcolm d31ed5
Ville Skyttä 6cba39
* Tue Sep  8 2009 Ville Skyttä <ville.skytta@iki.fi> - 8.4.5-4
Ville Skyttä 6cba39
- Remaining improvements from #480288:
Ville Skyttä 6cba39
- Add dependencies on libxslt and docbook-style-xsl.
Ville Skyttä 6cba39
- Install dblatex style sheets.
Ville Skyttä 6cba39
- Exclude unneeded *.py[co].
Ville Skyttä 6cba39
- Install python API.
Ville Skyttä 6cba39
- Specfile cleanups.
Ville Skyttä 6cba39
Todd Zullinger 3492e3
* Thu Aug 13 2009 Todd Zullinger <tmz@pobox.com> - 8.4.5-3
Todd Zullinger 3492e3
- Use 'unsafe' mode by default (bug 506953)
Todd Zullinger 3492e3
- Install filter scripts in %%{_datadir}/asciidoc
Todd Zullinger 3492e3
- Convert spec file, CHANGELOG, and README to utf-8
Todd Zullinger 3492e3
- Preserve timestamps on installed files, where feasible
Todd Zullinger 3492e3
- s/$RPM_BUILD_ROOT/%%{buildroot} and drop duplicated /'s
Todd Zullinger 3492e3
- Fix rpmlint mixed-use-of-spaces-and-tabs and end-of-line-encoding warnings
Todd Zullinger 3492e3
Jesse Keating e64f1c
* Fri Jul 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 8.4.5-2
Jesse Keating e64f1c
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
Jesse Keating e64f1c
Dave Airlie 0eeb1f
* Fri Jun 19 2009 Dave Airlie <airlied@redhat.com> 8.4.5-1
Dave Airlie 0eeb1f
- new upstream version 8.4.5 - required by X.org libXi to build
Dave Airlie 0eeb1f
Jesse Keating 03eda3
* Mon Feb 23 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 8.2.5-4
Jesse Keating 03eda3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
Jesse Keating 03eda3
Tom Callaway 7a2ee0
* Thu May 22 2008 Tom "spot" Callaway <tcallawa@redhat.com> - 8.2.5-3
Tom Callaway 7a2ee0
- fix license tag
Tom Callaway 7a2ee0
Florian La Roche 7cfe58
* Wed Dec 05 2007 Florian La Roche <laroche@redhat.com> - 8.2.5-2
Florian La Roche 7cfe58
- remove doc/examples from filelist due to dangling symlinks
Florian La Roche 7cfe58
Florian La Roche 7cfe58
* Tue Nov 20 2007 Florian La Roche <laroche@redhat.com> - 8.2.5-1
Florian La Roche 4c84e1
- new upstream version 8.2.5
Florian La Roche 4c84e1
Florian La Roche cbe834
* Mon Oct 22 2007 Florian La Roche <laroche@redhat.com> - 8.2.3-1
Florian La Roche cbe834
- new upstream version 8.2.3
Florian La Roche cbe834
Florian La Roche 9d820e
* Sat Sep 01 2007 Florian La Roche <laroche@redhat.com> - 8.2.2-1
Florian La Roche 9d820e
- new upstream version 8.2.2
Florian La Roche 9d820e
Chris Wright 5d7bd0
* Mon Mar 19 2007 Chris Wright <chrisw@redhat.com> - 8.1.0-1
Chris Wright 5d7bd0
- update to asciidoc 8.1.0
Chris Wright 5d7bd0
Chris Wright 32972d
* Thu Sep 14 2006 Chris Wright <chrisw@redhat.com> - 7.0.2-3
Chris Wright 32972d
- rebuild for Fedora Extras 6
Chris Wright 32972d
Chris Wright 2ad0a6
* Tue Feb 28 2006 Chris Wright <chrisw@redhat.com> - 7.0.2-2
Chris Wright 2ad0a6
- rebuild for Fedora Extras 5
Chris Wright 2ad0a6
jwboyer 8ec3f6
* Mon Aug 29 2005 Chris Wright <chrisw@osdl.org> - 7.0.2-1
jwboyer 8ec3f6
- convert spec file to UTF-8
jwboyer 8ec3f6
- Source should be URL
jwboyer 8ec3f6
- update to 7.0.2
jwboyer 7f91a8
jwboyer 7f91a8
* Fri Aug 19 2005 Chris Wright <chrisw@osdl.org> - 7.0.1-3
jwboyer 7f91a8
- consistent use of RPM_BUILD_ROOT
jwboyer 7f91a8
jwboyer 7f91a8
* Thu Aug 18 2005 Chris Wright <chrisw@osdl.org> - 7.0.1-2
jwboyer 7f91a8
- Update BuildRoot
jwboyer 7f91a8
- use _datadir
jwboyer 7f91a8
- use config and _sysconfdir
jwboyer 7f91a8
Todd Zullinger 3492e3
* Wed Jun 29 2005 Terje Røsten <terje.rosten@ntnu.no> - 7.0.1-1
jwboyer 7f91a8
- 7.0.1
jwboyer 7f91a8
- Drop patch now upstream
Todd Zullinger 3492e3
- Build as noarch (Petr Klíma)
jwboyer 7f91a8
Todd Zullinger 3492e3
* Sat Jun 11 2005 Terje Røsten <terje.rosten@ntnu.no> - 7.0.0-0.3
jwboyer 7f91a8
- Add include patch 
jwboyer 7f91a8
Todd Zullinger 3492e3
* Fri Jun 10 2005 Terje Røsten <terje.rosten@ntnu.no> - 7.0.0-0.2
jwboyer 7f91a8
- Fix stylesheets according to Stuart
jwboyer 7f91a8
Todd Zullinger 3492e3
* Fri Jun 10 2005 Terje Røsten <terje.rosten@ntnu.no> - 7.0.0-0.1
jwboyer 7f91a8
- Initial package
jwboyer 7f91a8
- Based on Debian package, thx!