[R/el5] Symlink LaTeX files, and rehash on package change when possible (# 630835)
Michel Alexandre Salim
salimma at fedoraproject.org
Tue Aug 9 14:42:07 UTC 2011
commit 2eee2b7b5a07efb4cf42b005d620dd33f92a1b17
Author: Michel Alexandre Salim <salimma at fedoraproject.org>
Date: Tue Aug 9 16:14:12 2011 +0200
Symlink LaTeX files, and rehash on package change when possible (# 630835)
R.spec | 22 ++++++++++++++++++++--
1 files changed, 20 insertions(+), 2 deletions(-)
---
diff --git a/R.spec b/R.spec
index 389e535..5808184 100644
--- a/R.spec
+++ b/R.spec
@@ -6,7 +6,7 @@
Name: R
Version: 2.13.1
-Release: 2%{?dist}
+Release: 3%{?dist}
Summary: A language for data analysis and graphics
URL: http://www.r-project.org
Source0: ftp://cran.r-project.org/pub/R/src/base/R-2/R-%{version}.tar.gz
@@ -260,10 +260,24 @@ chmod +x $RPM_BUILD_ROOT%{_datadir}/R/sh/echo.sh
chmod -x $RPM_BUILD_ROOT%{_libdir}/R/library/mgcv/CITATION ${RPM_BUILD_ROOT}%{_docdir}/R-%{version}/CAPABILITIES
# Symbolic link for convenience
-pushd %{buildroot}%{_libdir}/R
+pushd $RPM_BUILD_ROOT%{_libdir}/R
ln -s ../../include/R include
popd
+# Symbolic link for LaTeX
+mkdir -p $RPM_BUILD_ROOT%{_datadir}/texmf/tex/latex
+pushd $RPM_BUILD_ROOT%{_datadir}/texmf/tex/latex
+ln -s ../../../R/texmf/tex/latex R
+popd
+
+%postun
+if [ $1 -eq 0 ] ; then
+ /usr/bin/mktexlsr %{_datadir}/texmf &>/dev/null || :
+fi
+
+%posttrans
+/usr/bin/mktexlsr %{_datadir}/texmf &>/dev/null || :
+
%files
# Metapackage
@@ -293,6 +307,7 @@ popd
%{_datadir}/R/R/
%{_datadir}/R/sh/
%{_datadir}/R/texmf/
+%{_datadir}/texmf/
%dir %{_libdir}/R
%{_libdir}/R/bin
%{_libdir}/R/etc
@@ -885,6 +900,9 @@ fi
%postun -n libRmath -p /sbin/ldconfig
%changelog
+* Tue Aug 9 2011 Michel Salim <salimma at fedoraproject.org> - 2.13.1-3
+- Symlink LaTeX files, and rehash on package change when possible (# 630835)
+
* Mon Aug 8 2011 Tom Callaway <spot at fedoraproject.org> - 2.13.1-2
- add BuildRequires: less
More information about the scm-commits
mailing list