Window Mangers :: How best to deal with conf and log files in a uci
This my first attempt at a uci - for xorg-7.2 in this case.
After building the uci, the first thing I discovered is that xorg will not run because it needs to write a log file to /opt/xorg72/var/log and read a configuration file from /opt/xorg72/etc/X11 and the uci is read-only.
I was thinking that I could perhaps use symlinks as follows:
/opt/xorg72/var/log/Xorg.0.log --> /var/log/Xorg.0.log
/opt/xorg72/var/log/Xorg.0.log.old --> /var/log/Xorg.0.log.old
/opt/xorg72/etc/X11/xorg.conf --> /etc/X11/xorg.conf
Is this an "approved" way to work with uci extensions in DSL?
For the xlogs, you probably could leave the symlinks if they work. It seems the -log option only works for real-uid root. The other alternative would be to recompile using a different default path just for the xlogs.
/opt/xorg72/etc/X11 is fine because it will be read-only. Maybe leaving a default "vesa" config there would be good for default behaviour (which I personally do). Why is it fine still if you want to change your xconfig? Because it looks like the search path uses /etc/X11 first... (i.e. see `man xorg.conf` )
p.s. X isn't a wm.. maybe system would be better?
In most cases, the symlink should work fine. In the case of Xorg, though, you *might* run into some trouble as it attempts to shuffle logs. Once the log gets to a certain size, a new one is created, so it might choke trying to create a new file on a read-only filesystem. I might be wrong about this, of course. I know that XFree86 creates multiple log files, but I don't know if Xorg might just stick with those two.
Personally i'd still look into the suggestion of using a different default path.
Good point mikshaw. If you run the defaults it will only use Xorg.0.log and Xorg.0.log.old - but afaik the # corresponds to the xserver # currently running ( $DISPLAY by default is :0.0 )
Perhaps using /opt/xorg72/var/log/ --> /var/log/ will be easier?
That's an even better idea.