R-pdftools/R-pdftools.spec

82 lines
1.9 KiB
RPMSpec
Raw Normal View History

2022-09-04 11:31:32 +00:00
%bcond_with bootstrap
2020-08-09 06:43:54 +00:00
%global packname pdftools
2023-02-08 20:32:45 +00:00
%global packver 3.3.3
2018-03-19 21:25:39 +00:00
%global rlibdir %{_libdir}/R/library
Name: R-%{packname}
Version: %{packver}
2022-02-22 21:03:45 +00:00
Release: %autorelease
2018-03-19 21:25:39 +00:00
Summary: Text Extraction, Rendering and Converting of PDF Documents
License: MIT
2019-01-23 00:55:24 +00:00
URL: https://CRAN.R-project.org/package=%{packname}
2020-08-09 06:43:54 +00:00
Source0: https://cran.r-project.org/src/contrib/%{packname}_%{packver}.tar.gz
2018-03-19 21:25:39 +00:00
# Here's the R view of the dependencies world:
# Depends:
2019-03-12 22:25:30 +00:00
# Imports: R-Rcpp >= 0.12.12, R-qpdf
2023-02-08 20:32:45 +00:00
# Suggests: R-png, R-webp, R-tesseract, R-testthat
2018-03-19 21:25:39 +00:00
# LinkingTo:
# Enhances:
2018-04-26 05:37:08 +00:00
BuildRequires: R-devel
BuildRequires: tex(latex)
2018-03-19 21:25:39 +00:00
BuildRequires: R-Rcpp-devel >= 0.12.12
2019-03-12 22:25:30 +00:00
BuildRequires: R-qpdf
%if %{without bootstrap}
2018-04-26 05:37:08 +00:00
BuildRequires: R-png
BuildRequires: R-webp
2020-06-06 13:04:51 +00:00
BuildRequires: R-tesseract
2020-08-09 06:43:54 +00:00
BuildRequires: R-testthat
%endif
2020-08-09 06:43:54 +00:00
BuildRequires: poppler-cpp-devel
BuildRequires: poppler-data
2018-03-19 21:25:39 +00:00
%description
2020-08-09 06:43:54 +00:00
Utilities based on 'libpoppler' for extracting text, fonts, attachments and
metadata from a PDF file. Also supports high quality rendering of PDF documents
into PNG, JPEG, TIFF format, or into raw bitmap vectors for further processing
in R.
2018-03-19 21:25:39 +00:00
%prep
%setup -q -c -n %{packname}
2022-02-22 23:35:01 +00:00
cd %{packname}
%autopatch -p1
2018-03-19 21:25:39 +00:00
%build
%install
mkdir -p %{buildroot}%{rlibdir}
%{_bindir}/R CMD INSTALL -l %{buildroot}%{rlibdir} %{packname}
test -d %{packname}/src && (cd %{packname}/src; rm -f *.o *.so)
rm -f %{buildroot}%{rlibdir}/R.css
%check
%if %{without bootstrap}
2018-03-19 21:25:39 +00:00
%{_bindir}/R CMD check %{packname}
%endif
2020-08-09 06:43:54 +00:00
2018-03-19 21:25:39 +00:00
%files
%dir %{rlibdir}/%{packname}
%doc %{rlibdir}/%{packname}/html
%{rlibdir}/%{packname}/DESCRIPTION
%license %{rlibdir}/%{packname}/LICENSE
%doc %{rlibdir}/%{packname}/NEWS
%{rlibdir}/%{packname}/INDEX
%{rlibdir}/%{packname}/NAMESPACE
%{rlibdir}/%{packname}/Meta
%{rlibdir}/%{packname}/R
%{rlibdir}/%{packname}/help
%dir %{rlibdir}/%{packname}/libs
%{rlibdir}/%{packname}/libs/%{packname}.so
%changelog
2022-02-22 21:03:45 +00:00
%autochangelog