build: prepend ${PREFIX} to SYSCONFDIR if not set (FS#468)

Also fixes what seemed like a typo in the env checking for
XDG_CONFIG_DIR.

Signed-off-by: Julien Danjou <julien@danjou.info>
This commit is contained in:
Nikos Ntarmos 2009-04-01 17:56:02 +02:00 committed by Julien Danjou
parent db68ae2ebe
commit f24f652962
1 changed files with 2 additions and 2 deletions

View File

@ -220,13 +220,13 @@ endif()
if(DEFINED SYSCONFDIR)
set(SYSCONFDIR ${SYSCONFDIR} CACHE PATH "config directory")
else()
set(SYSCONFDIR /etc CACHE PATH "config directory")
set(SYSCONFDIR ${PREFIX}/etc CACHE PATH "config directory")
endif()
#If an XDG Config Dir is specificed, use it instead
#of the default XDG configuration dir.
if(DEFINED XDG_CONFIG_DIR)
set(XDG_CONFIG_DIR ${XDG_CONFIG_SYS} CACHE PATH "xdg config directory")
set(XDG_CONFIG_DIR ${XDG_CONFIG_DIR} CACHE PATH "xdg config directory")
else()
set(XDG_CONFIG_DIR ${SYSCONFDIR}/xdg CACHE PATH "xdg config directory")
endif()