LogoopenSUSE Build Service > Projects
Sign Up | Log In

View File R-formatR.spec of Package R-formatR (Project home:phyxkal)

%global packname  formatR
%global rlibdir   %{_libdir}/R/library

Name:           R-%{packname}
Version:        1.0
Release:        0
Summary:        Format R Code Automatically

Group:          Development/Libraries/Other
License:        GPL
URL:            http://cran.r-project.org/web/packages/%{packname}
Source0:        formatR_%{version}.tar.gz
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
Requires:       R-base

# Package suggestions
#Requires:         R-codetools R-gWidgetsRGtk2 R-testit R-knitr 
BuildRequires:  texlive
BuildRequires:  texinfo
BuildRequires:  fdupes
#
%if 0%{?suse_version} <= 1220 && 0%{?suse_version} != 1110
BuildRequires:  texlive-fonts-extra
%endif

BuildRequires:    R-base-devel 
# Package suggestions, not required to build
#BuildRequires: R-codetools R-gWidgetsRGtk2 R-testit R-knitr

%description
This package provides a function tidy.source() and optionally a GUI (by
gWidgets and preferably gWidgetsRGtk2) to format R source code. Spaces and
indent will be added to the code automatically, and comments will be
preserved under certain conditions, so that R code will be more
human-readable and tidy.

%prep
%setup -q -c -n %{packname}

%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

%files
%defattr(-, root, root, -)
%dir %{rlibdir}/%{packname}
%doc %{rlibdir}/%{packname}/doc
%doc %{rlibdir}/%{packname}/html
%doc %{rlibdir}/%{packname}/shiny/DESCRIPTION
%doc %{rlibdir}/%{packname}/shiny/Readme.md
%doc %{rlibdir}/%{packname}/DESCRIPTION
%doc %{rlibdir}/%{packname}/NEWS
%{rlibdir}/%{packname}/INDEX
%{rlibdir}/%{packname}/NAMESPACE
%{rlibdir}/%{packname}/Meta
%{rlibdir}/%{packname}/R
%{rlibdir}/%{packname}/help
%{rlibdir}/%{packname}/format
%{rlibdir}/%{packname}/shiny


%changelog