Base directory specification

Sanel Zukan sanelz at
Tue Mar 27 06:44:47 PDT 2007

> For an app-level implementation, never assume that the desktop
> environment (if any!) has set the XDG_* env vars.  Just hard-code the
> defaults and use those for variables that are unset.  You can choose to
> have EDE set them or not on desktop startup, but the applications should
> to be able to handle the case where they're not set.

Brian, thanks for the tips :)

> Also, if you use glib, you can use g_get_user_data_dir() and
> g_get_user_config_dir(): those functions use the default values if the

We was using efltk, a modified fltk library. There was an function
fl_find_config_file() that used ~/.ede as default path, but that library
was written before any publicly available standard.

It is nice that glib have XDG specific functions, and since I am
preparing an new library it is a perfect time to introduce a similar 
functions in it.

My concern about variables was mostly about other programs and I was not
sure how they should handle cases when variables are not set. But after 
given notes about app behaviour and existing glib functions, situation
is much clearer now.

Thanks guys!


More information about the xdg mailing list