[gnome-chess] Move engines.conf from datadir to sysconfdir
- From: Michael Catanzaro <mcatanzaro src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-chess] Move engines.conf from datadir to sysconfdir
- Date: Wed, 14 Aug 2013 02:32:24 +0000 (UTC)
commit 765c29f1af96f2194a441c406c43da3ff7765b2d
Author: Michael Catanzaro <mcatanzaro gnome org>
Date: Tue Aug 13 20:50:38 2013 -0500
Move engines.conf from datadir to sysconfdir
engines.conf is a human-editable configuration file. It belongs in
/etc, not /usr/share
data/Makefile.am | 3 +--
src/Makefile.am | 1 +
src/config.vapi | 1 +
src/gnome-chess.vala | 2 +-
4 files changed, 4 insertions(+), 3 deletions(-)
---
diff --git a/data/Makefile.am b/data/Makefile.am
index 87d275c..9067ef1 100644
--- a/data/Makefile.am
+++ b/data/Makefile.am
@@ -16,8 +16,7 @@ gsettings_SCHEMAS = org.gnome.gnome-chess.gschema.xml
@INTLTOOL_XML_NOMERGE_RULE@
@GSETTINGS_RULES@
-aidir = $(datadir)/gnome-chess/
-ai_DATA = engines.conf
+sysconf_DATA = engines.conf
man_MANS = gnome-chess.6
diff --git a/src/Makefile.am b/src/Makefile.am
index 7b3b486..d854c09 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -53,6 +53,7 @@ gnome_chess_CFLAGS = \
-DGETTEXT_PACKAGE=\"$(GETTEXT_PACKAGE)\" \
-DPKGDATADIR=\"@datadir@/gnome-chess\" \
-DLOCALEDIR=\"@localedir \" \
+ -DSYSCONFDIR=\"@sysconfdir \" \
$(GNOME_CHESS_CFLAGS)
gnome_chess_LDADD = \
diff --git a/src/config.vapi b/src/config.vapi
index a1787ca..ee6dfda 100644
--- a/src/config.vapi
+++ b/src/config.vapi
@@ -1,4 +1,5 @@
public const string PKGDATADIR;
+public const string SYSCONFDIR;
public const string LOCALEDIR;
public const string GETTEXT_PACKAGE;
public const string VERSION;
diff --git a/src/gnome-chess.vala b/src/gnome-chess.vala
index 8d0c64e..433af5c 100644
--- a/src/gnome-chess.vala
+++ b/src/gnome-chess.vala
@@ -196,7 +196,7 @@ public class Application : Gtk.Application
settings.changed.connect (settings_changed_cb);
settings_changed_cb (settings, "show-3d");
- ai_profiles = AIProfile.load_ai_profiles (Path.build_filename (PKGDATADIR, "engines.conf", null));
+ ai_profiles = AIProfile.load_ai_profiles (Path.build_filename (SYSCONFDIR, "engines.conf", null));
foreach (var profile in ai_profiles)
message ("Detected AI profile %s in %s", profile.name, profile.path);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]