LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Desktop
User Name
Password
Linux - Desktop This forum is for the discussion of all Linux Software used in a desktop context.

Notices


Reply
  Search this Thread
Old 03-29-2009, 04:10 AM   #1
themeone
Member
 
Registered: Mar 2008
Location: Croydon UK
Distribution: Debian
Posts: 33

Rep: Reputation: 15
Cannot run application via Alt+F2


The background to this question is that I compiled Audacity from source, and installed it to my home directory.

I like to start applications via Alt+F2 but I am unable to do this for Audacity. I can only start it by typing "audacity" on the command line.

I believe my PATH is set correctly. Part output from "env" is

PATH=/usr/local/bin:/usr/bin:/bin:/usr/games:/home/username/install/audacity/bin:/home/username

The Audacity executable resides in /home/username/install/audacity/bin

I changed the PATH by adding the following to ~/.bashrc

PATH=$PATH:"$HOME/install/audacity/bin:$HOME"

export PATH

My research suggests that the problem may stem from Alt+F2 not using a login shell, so therefore is not reading ~/.bashrc. Is this correct?

I am running Debian 5 with xfce 4.6 and gdm.
 
Old 03-30-2009, 12:23 PM   #2
tredegar
LQ 5k Club
 
Registered: May 2003
Location: London, UK
Distribution: Fedora38
Posts: 6,147

Rep: Reputation: 435Reputation: 435Reputation: 435Reputation: 435Reputation: 435
Quote:
My research suggests that the problem may stem from Alt+F2 not using a login shell,
so therefore is not reading ~/.bashrc. Is this correct
I don't know, but it sounds a perfectly reasonable explanation.
You could check this out by trying a simple command like this:

Code:
env > /home/yourusername/ALTF2-env
Execute it from your Alt+F2 thing.

Then see what the file /home/yourusername/ALTF2-env looks like
and compare it to the output of env in a normal terminal window (or whatever it is that you can start audacity from).

Please note that as a general security measure, I do not like to have anything under /home/ to be in my PATH

If you had done the make install step as root, audacity would probably now be in /usr/bin/ and you probably wouldn't have this problem. But it's in the nature of linux to encounter problems, and then maybe learn something by solving them.

Typing commands can become tedious. Why don't you just create an icon to launch audacity with a click?
 
Old 04-01-2009, 06:54 AM   #3
themeone
Member
 
Registered: Mar 2008
Location: Croydon UK
Distribution: Debian
Posts: 33

Original Poster
Rep: Reputation: 15
Thanks for that.

The output from env > ~/ALTF2.env, executed from Alt+F2 was different from the output of env from inside the terminal. However, I still haven't figured out where Alt+F2 is reading its environment variables from.

The good news though is I have fixed my problem.

Not only was Audacity installed in a directory not searched by the current PATH, but library files for wxWidgets (which Audacity needs in order to run) were also not installed in a directory where the default environment variables were looking. I had compiled wxWidgets manually and installed in a directory in my home area.

I changed the PATH in /etc/profile.

I then added the LD_LIBRARY_PATH variable to both ~/.bashrc and /etc/environment (this last file did not exist by default).

If LD_LIBRARY_PATH is only in ~/.bashrc, then I can only run Audacity from within a terminal. When it's in /etc/environment as well, I can run via Alt+F2. However, after setting all this up the output from env > ~/ALTF2.env never includes LD_LIBRARY_PATH, which I would have expected to see.

I think the main thing I've learned from this is never install anything in my home directory.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
how to run another GUI Window Alt+F7 RMLinux Linux - Newbie 5 12-05-2008 03:33 AM
alt+f2 run box stopped working in gnome fakie_flip Linux - Software 1 05-12-2008 01:55 AM
How do I get just installed openoffice to run on ALT??????? Lord Hakk Linux - Software 2 03-29-2006 05:05 PM
application to run ? johnyy Linux - Software 3 08-28-2003 10:21 AM
Slack 9, no Run Command upon pressing Alt+F2 VioLaToR Slackware 4 06-12-2003 01:08 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Desktop

All times are GMT -5. The time now is 12:15 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration