[tex-live] Rubber and Tex Live Native

Zdenek Wagner zdenek.wagner at gmail.com
Mon Aug 15 15:19:35 CEST 2011


2011/8/15 raphael.lallement <raphael.lallement at laposte.net>:
> Hi,
>
> sorry for the delay in my answer but I was away.
>
> So I tried to create the .bash_profile in my home folder (I also tried with a .bash_login) but it actually doesn't work. It works only in the case when I connect to my computer using bash (i.e. in Ubuntu Ctrl+Alt+F1 for instance). When I login in graphic mode it doesn't work.
>
> I found another way, using /etc/environment but it's not really the proper way to do it. If you know another way to do it please tell me. I'm sorry to bother you with Linux related questions.
> Anyway, using /etc/environment works fine with rubber. And if you're interested, the Latex plugin for gedit works really well with it.
>
It depends on what you want to achieve. There are different ways and
it is difficult to say that one method is better than another. I can
only describe how it is done in my computers. My requirements are:

1. I have both i386 and x86_64 computers, I want to copy the
configuratin from one computer to another without the need of much
thinking

2. My TL is customized, I use commercial fonts, customized formats (encTeX)

3. I have several versions of TL, one of them is default

4. I set the new TL version as default after a delay when I am sure
that all customization works as the previous one

5. I run TeX from a command line, from applications started by an icon
on a gnome panel, from PHP scripts invoked via a web page

6. I do not want to set too many things and do not want to do a lot of
actions when changing the default TL version. Moreover, I run TeX from
PHP scripts even on a server where I do not have root access, thus I
am not allowed to change "SetEnv PATH" in Apache config.

My solution:
1. TL is installed in /usr/local/texlive, I install it as a normal
user, the server admin changed ownership of /usr/local/texlive to me
so that I can install and update TL there.

2. /usr/local/texlive/current is a symlink to the default TL version.
When I decide to switch to the new version as default, I just symlink
/usr/local/texlive/current to it

3. My .bashrc contains:
addtopath () {
        if ! echo $PATH | /bin/egrep -q "(^|:)$1($|:)" ; then
           if [ "$2" = "after" ] ; then
              PATH=$PATH:$1
           else
              PATH=$1:$PATH
           fi
        fi
}
export MACHINE=`uname -i`
addtopath /usr/local/texlive/current/bin/$MACHINE-linux

4. My .bash_profile contains:
if [ -f ~/.bashrc ]; then
        . ~/.bashrc
fi

5. PATH is not set in httpd.conf but in a bash script started from the
PHP script.

6. If TeX is called in PHP or from an icon in an editor, there is a
danger that it will lock if it waits for a user interaction from a
console. In such cases no console is available and it is necesary to
kill the parent process. Therefore I run it via my own Expect script
that will kill TeX after some time of inactivity


But as I wrote at the very beginning, there are certainly other ways...

> Thank you again for your time.
> Raphael
>
>
>
>> Message du 07/08/11 19:18
>> De : "Manuel Pégourié-Gonnard"
>> A : "raphael.lallement"
>> Copie à : "Zdenek Wagner" , "George N. White III" , texlive at tug.org
>> Objet : Re: [tex-live] Rubber and Tex Live Native
>>
>> Le 07/08/2011 16:23, raphael.lallement a écrit :
>> > thank you all for your answers. So indeed rubber doesn't use the good path
>> > because I set it only in .bashrc. By the way, to launch gedit from a terminal
>> > is still not enough, the path is not evaluated or not given to gedit
>> > (strange, isn't it ?). So I would like to try the solution involving
>> > .bash_profile but I can find it (I tried with the find command). I'm using
>> > ubuntu I could make a difference. Do you have any idea of where exacly
>> > is/should be the file. Or the Ubuntu equivalent. Thank you.
>> >
>> Juste create the file in your home.
>>
>> Manuel.
>>
>
> Une messagerie gratuite, garantie à vie et des services en plus, ça vous tente ?
> Je crée ma boîte mail www.laposte.net
>



-- 
Zdeněk Wagner
http://hroch486.icpf.cas.cz/wagner/
http://icebearsoft.euweb.cz



More information about the tex-live mailing list