changeset 2325:63c9a2724e73 trunk

[svn] - revert r3646 because it is not a user-friendly method of transitioning. pre-r3646 produces the proper behaviour defined by XDG for migration.
author nenolod
date Sat, 13 Jan 2007 15:04:38 -0800
parents 2ab9ef1e9544
children 094cac62c904
files ChangeLog configure.ac src/libaudacious/configdb_rcfile.c
diffstat 3 files changed, 27 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog	Sat Jan 13 14:49:55 2007 -0800
+++ b/ChangeLog	Sat Jan 13 15:04:38 2007 -0800
@@ -1,3 +1,14 @@
+2007-01-13 22:49:55 +0000  William Pitcock <nenolod@sacredspiral.co.uk>
+  revision [3658]
+  - remove leftover remnants of automake from buildsystem
+  
+  trunk/configure.ac  |    7 
+  trunk/libtool.m4    | 6248 ----------------------------------------------------
+  trunk/missing       |  360 --
+  trunk/mkinstalldirs |  111 
+  4 files changed, 6 insertions(+), 6720 deletions(-)
+
+
 2007-01-13 22:40:03 +0000  William Pitcock <nenolod@sacredspiral.co.uk>
   revision [3656]
   - move manpages to subdir man/
--- a/configure.ac	Sat Jan 13 14:49:55 2007 -0800
+++ b/configure.ac	Sat Jan 13 15:04:38 2007 -0800
@@ -72,6 +72,7 @@
 AC_DEFINE_UNQUOTED(BMP_RCPATH, "$rc_path",
     [Resource and configuration path for audacious relative to $HOME.]
 )
+AC_DEFINE(DOTAUDACIOUS_COMPAT, 1, [Enable compatibility for $HOME/.audacious])
 AC_SUBST(BMP_RCPATH)
 
 AC_ARG_ENABLE(one-plugin-dir,
--- a/src/libaudacious/configdb_rcfile.c	Sat Jan 13 14:49:55 2007 -0800
+++ b/src/libaudacious/configdb_rcfile.c	Sat Jan 13 15:04:38 2007 -0800
@@ -51,8 +51,22 @@
 
     db->file = bmp_rcfile_open(db->filename);
 
-    if (!db->file)
+#ifdef DOTAUDACIOUS_COMPAT
+    if (!db->file) {
+        tmp = g_build_filename(g_get_home_dir(), BMP_RCPATH, "config", NULL);
+        if (db->file = bmp_rcfile_open(tmp)) {
+            g_free(db->filename);
+            db->filename = tmp;
+        }
+    }
+#endif
+
+    if (!db->file) {
+#ifdef DOTAUDACIOUS_COMPAT
+        g_free(tmp);
+#endif
         db->file = bmp_rcfile_new();
+    }
 
     db->dirty = FALSE;