On Tue, 2014-07-22 at 12:23 +0200, Dirk Jung wrote:
>       • If I use xcsoar -fly in /etc/rc.local XCSoar starts perfekt, but I 
> can't control using the keyboard. I have to quit and restart XCSoar at a 
> terminal using xcsoar -fly, then the keyboard works perfekt
> 
Thats's not surprising. rc.local is run as a root process at boot time,
so any programs started by it will also run as root, which you almost
certainly did not intend or want. Its usual purpose is to modify global
settings, e.g. changing access permissions for /dev/ttyS* and/or to
start site-specific servers or utilities that, for some reason, can't be
run as normal system services. It is *NOT* intended to start user
programs because these should never be run as root and anyway, as you
found out, a normal user will not be able to use their i/o channels.

If you want to start a program when you login to a particular user you
should either use services provided by the desktop manager (Gnome, XFCE,
Cinnamon, etc) or, if you don't need to start a desktop manager, you can
start it from the .bash_profile in the user's home directory.

The fact that XCSoar crashes when you try to make the desktop manager
start it suggests that that environment is not providing something it
needs. For instance, is XCSoar really crashing or is it just the manager
not being able to find XCSoar? Things to check and do:

- Is the directory containing XCSoar in $PATH? If not, you need 
  to change .bash_profile so it adds that directory to $PATH

- Does it work if you use an absolute pathname for XCSoar? That type of
  program launcher often ignores $PATH and so an absolute path name is
  required.

- write a bash script to start XCSoar and also load add diagnostic
  statements into it such as:

  pwd
  which XCSoar
  echo $USER
  echo $PATH

  and run it from the command line. When its working properly, tell the
  desktop manager to run the script at login time. If the diagnostic
  displays differ, add statements to the script to fix the differences
  until XCSoar does run.

 
Martin





------------------------------------------------------------------------------
Want fast and easy access to all the code in your enterprise? Index and
search up to 200,000 lines of code with a free copy of Black Duck
Code Sight - the same software that powers the world's largest code
search on Ohloh, the Black Duck Open Hub! Try it now.
http://p.sf.net/sfu/bds
_______________________________________________
Xcsoar-user mailing list
Xcsoar-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/xcsoar-user

Reply via email to