Boot into an empty X and start one single Program


Forum: Other Help Topics
Topic: Boot into an empty X and start one single Program
started by: eeffoC

Posted by eeffoC on Jan. 04 2007,17:13
Hello!

I tried to compile a Qt Program on my DSL HDD Installation including the GCC-inkl.Libs MyDSL extension. Luckily it worked and it even uses the Fluxbox Styles/Themes!!
Amazing how powerful and complete this small DSL is!

Now id like this Program to run upon start of another machine (frugal install) in an empty Fluxbox/X.

What would be the best way to achieve this?

I guess something like:

Boot into text mode
Load Gcc+Liby extension
Start empty X
Start Program

Are those steps correct? Wich files would I have to modify? Any other soggestions?

Thanks in advance, Jan

Posted by ^thehatsrule^ on Jan. 04 2007,21:26
What do you mean by "empty" fluxbox or X?
Either way, for a permanent and automatic solution, you can edit ~/.xinitrc and modify it to your liking.

If you are using DSL v3.x+ you may wish to create a custom item in the case statement and edit ~/.desktop to that custom item.


If you prefer to manually execute all those steps only from cmdline, you can use "startx -- /my/script/or/program"

Posted by eeffoC on Jan. 05 2007,21:19
Thanks for your suggestions!!

Maybe you can help me still a bit further:

What exactly would I have to type into .xinitrc to start my program wich is in $HOME/dir/dat and needs root privileges (it uses the ioperm function to write to some ports)?

I tried a lot of things but I dont seem to be able to figure it out  :(

Thanks in advance,
Jan

Posted by ^thehatsrule^ on Jan. 05 2007,22:02
The program requires root priviliges?  You can prepend sudo to the command you need to use.
Posted by eeffoC on Jan. 07 2007,13:06
Thanks again for your reply!

The problem is that I am quite a beginner to Linux and that I just seem to stupid to figure out what to type into .xinitrc

I tried a lot of different things like

"/ramdisk/home/dsl/program/start &"
"exec /ramdisk/dsl/program/start &"
"exec $HOME/program/start &"
"exec $HOME/program/start &> dev/null &"
......

but nothing seemed to work. Nothing happens after restarting the window manager.

I hope someone will take pity on me and give me a working example!

Thanks very much!!!

Posted by ^thehatsrule^ on Jan. 07 2007,20:32
Your first line should be fine

Also, how did you "restart" the window manager?  Afaik, if you use the wm's restart, only itself will be restarted.
Since .xinitrc is not part of the wm, you should kill x, then run startx again.

Posted by eeffoC on Jan. 08 2007,16:00
Oops I kept using the window managers restart function...

Without that it works fine!! Thanks a lot for your help and your patience :-)

Powered by Ikonboard 3.1.2a
Ikonboard © 2001 Jarvis Entertainment Group, Inc.