I am trying to make Sweave.sty and Rd.sty globally available on my system. After reading related posts on StackExchange, I changed texmf.cnf, so that
kpsewhich --expand-var='$TEXMF'
results in
{/home/philipp/texmf,!!/etc/texmf,!!/var/lib/texmf,!!/usr/lib/texmf,!!/usr/local/share/texmf,!!/usr/share/texmf,/usr/lib64/R/share/texmf/tex/latex}
The last directory is where R puts Sweave.sty and Rd.sty, and I also tried the variant with
!!
before this path. After
sudo texhash
and (just to be certain)
sudo mktexlsr
appropriate ls-R files are created. Nevertheless
kpsewhich Sweave.sty
still does not find the file, even with the
--must-exist
option. After trying all this I am stuck. I suspect there is some trouble because texlive and OpenSUSE are said not to mix well (especially when it comes to adding packages), but do not have the faintest clue.
~/texmf, then you do not need complicated configurations like you did – Yihui Xie May 18 '12 at 23:35kpsewhichfails. – Philipp May 19 '12 at 05:45Sweave.stytotexmf.cnf. You must only add the path up to thetexmffolder. So in my case it should have been:/usr/lib64/R/share/texmf/instead of/usr/lib64/R/share/texmf/tex/latex. – Philipp May 19 '12 at 07:13.../texmfrather than.../texmf/sincekpathseawill add/tex/latexwhich would result in a double slashtexmf//tex/latexand double slashes happen to have a special meaning (search recursively) forkpathsea. – mpg May 20 '12 at 20:21