[Geany-Users] Environment variables

Colomban Wendling lists.ban at xxxxx
Fri Jan 31 20:39:31 UTC 2014


Hi,

Le 31/01/2014 20:55, Egbert a écrit :
> I'm trying to use Geany 1.23 for cross compiling for ARM (Gnublin board)
> on a Kubuntu 13.10 laptop. I've installed the crosscompiler toolchain
> but the compiler (arm-linux-gnueabi-gcc) lives in a very odd place with
> a very long pathname. I've added this path to the PATH variable in
> .bashrc. When executed In a terminal window the cross compiler works
> fine. When entering the name of the compiler in the Geany build
> settings, it does not work. Path unknown error.
> 
> After searching internet, the only working solution I found seems to be
> to add the PATH extension in /etc/profile and indeed this works. Must I
> put it In the system wide config? Is that really the one and only
> option? Why is .profile of .bashrc in the home directory not evaluated?

You should put it in your .profile, not in the system one; and then
close and reopen your session.

> I think it's kind of weird. Or am I wrong?

No it's not weird actually.  If you launch an application from your
menus, it inherits your session's environment (unless explicitly
overwritten, but that's another story).  .bashrc is only read by bash,
where .profile is supposed to be read by any login mean -- including
your session.

So, what you put in .bashrc will only affect interactive bash shells
(e.g. the one run when you open a terminal window), whereas what you put
in .profile will affect any login mean (including the session).

In any case however, you need to re log-in, so for a graphical session
like KDE you need to close the session and reopen it.

But if .profile don't affect KDE session, I can't really help, it would
mean KDE behaves strangely -- moreover if it properly read /etc/profile.

BTW, if you run Geany from your terminal window, it will inherit your
modified PATH as seen by bash, so like you wanted it.


Regards,
Colomban


More information about the Users mailing list