Sophie

Sophie

distrib > Mageia > 8 > x86_64 > by-pkgid > cbefba908712f0048556306201354dbe > files > 3

discount-2.2.7-1.mga8.src.rpm

%define major   2
%define libname %mklibname markdown %{major}
%define devname %mklibname markdown -d

Name:           discount
Version:        2.2.7
Release:        %mkrel 1
Summary:        A command-line utility for converting Markdown files into HTML
Group:          Text tools
License:        BSD
URL:            http://www.pell.portland.or.us/~orc/Code/discount
Source0:        https://github.com/Orc/discount/archive/v%{version}/%{name}-%{version}.tar.gz
Patch0:         discount-2.2.4-ldconfig.patch

BuildRequires:  pkgconfig(libmarkdown)

%description
Discount is an implementation of John Gruber's Markdown language in C.
It includes all of the original Markdown features, along with a few
extensions, and passes the Markdown test suite.

%files
%{_bindir}/markdown
%{_bindir}/%{name}-makepage
%{_bindir}/%{name}-mkd2html
%{_bindir}/%{name}-theme
%{_mandir}/man1/markdown.1*
%{_mandir}/man7/markdown.7*
%{_mandir}/man1/%{name}-*.1*
%{_mandir}/man7/mkd-*.7*

#----------------------------------------------------------------------

%package -n     %{libname}
Summary:        A fast implementation of the Markdown language in C
Group:          System/Libraries

%description -n %{libname}
libmarkdown is the library portion of Discount, a fast Markdown language
implementation, written in C.

%files -n       %{libname}
%doc README COPYRIGHT CREDITS
%{_libdir}/libmarkdown.so.%{major}{,.*}

#----------------------------------------------------------------------

%package -n     %{devname}
Summary:        Development headers for the libmarkdown library
Group:          Development/C
Requires:       %{libname} = %{version}-%{release}
Provides:       markdown-devel = %{version}-%{release}
Provides:       libmarkdown-devel = %{version}-%{release}

%description -n %{devname}
This package contains development headers and developer-oriented man pages for
libmarkdown.

%files -n       %{devname}
%{_libdir}/libmarkdown.so
%{_libdir}/pkgconfig/libmarkdown.pc
%{_includedir}/mkdio.h
%{_mandir}/man3/markdown.3*
%{_mandir}/man3/mkd*.3*

#----------------------------------------------------------------------

%prep
%setup -q
%autopatch -p1

%build
%set_build_flags
# Not using %%configure since it is not an autotools script
./configure.sh \
    --shared \
    --pkg-config \
    --prefix=%{_prefix} \
    --execdir=%{_bindir} \
    --libdir=%{_libdir} \
    --mandir=%{_mandir} \
    --enable-all-features \
    --with-fenced-code
%make_build

%install
%make_install install.everything

install -D -m644 libmarkdown.pc %{buildroot}%{_libdir}/pkgconfig/libmarkdown.pc

# Rename sample programs (names are too generic) and matching man1 pages
mv %{buildroot}%{_bindir}/makepage %{buildroot}%{_bindir}/%{name}-makepage
mv %{buildroot}%{_bindir}/mkd2html %{buildroot}%{_bindir}/%{name}-mkd2html
mv %{buildroot}%{_bindir}/theme %{buildroot}%{_bindir}/%{name}-theme
mv %{buildroot}%{_mandir}/man1/makepage.1 \
   %{buildroot}%{_mandir}/man1/%{name}-makepage.1
mv %{buildroot}%{_mandir}/man1/mkd2html.1 \
   %{buildroot}%{_mandir}/man1/%{name}-mkd2html.1
mv %{buildroot}%{_mandir}/man1/theme.1 \
   %{buildroot}%{_mandir}/man1/%{name}-theme.1

%check
%make_build test


%changelog
* Tue Aug 25 2020 kekepower <kekepower> 2.2.7-1.mga8
+ Revision: 1618827
- Update to version 2.2.7

* Sat Feb 15 2020 umeabot <umeabot> 2.2.6-2.mga8
+ Revision: 1526269
- Mageia 8 Mass Rebuild
+ wally <wally>
- replace deprecated %%configure2_5x
- replace deprecated %%setup_compile_flags

* Fri May 10 2019 kekepower <kekepower> 2.2.6-1.mga7
+ Revision: 1397018
- Update to version 2.2.6

* Thu Jan 31 2019 kekepower <kekepower> 2.2.5-1.mga7
+ Revision: 1362067
- Update to version 2.2.5
- BR libmarkdown

* Sat Nov 03 2018 daviddavid <daviddavid> 2.2.4-1.mga7
+ Revision: 1328005
- new version: 2.2.4
- rediff ldconfig patch

* Sun Sep 23 2018 umeabot <umeabot> 2.2.2-2.mga7
+ Revision: 1297452
- Mageia 7 Mass Rebuild

* Sat Jan 21 2017 akien <akien> 2.2.2-1.mga6
+ Revision: 1082561
- Version 2.2.2

* Sat Oct 08 2016 akien <akien> 2.2.1-1.mga6
+ Revision: 1059615
- Version 2.2.1

* Thu Feb 11 2016 umeabot <umeabot> 2.1.8a-2.mga6
+ Revision: 953786
- Mageia 6 Mass Rebuild

* Tue Jun 23 2015 akien <akien> 2.1.8a-1.mga6
+ Revision: 840366
- Version 2.1.8a

* Wed Oct 15 2014 umeabot <umeabot> 2.1.7-4.mga5
+ Revision: 740810
- Second Mageia 5 Mass Rebuild

* Sat Sep 27 2014 tv <tv> 2.1.7-3.mga5
+ Revision: 726122
- rebuild for missing pythoneggs deps

* Tue Sep 16 2014 umeabot <umeabot> 2.1.7-2.mga5
+ Revision: 678754
- Mageia 5 Mass Rebuild

* Mon Sep 15 2014 akien <akien> 2.1.7-1.mga5
+ Revision: 676881
- Adapt spec file to Mageia
- import discount from Fedora