parameterize the version number used to define the config directory name
authorPaul Davis <paul@linuxaudiosystems.com>
Wed, 16 Jul 2014 12:15:18 +0000 (08:15 -0400)
committerPaul Davis <paul@linuxaudiosystems.com>
Wed, 16 Jul 2014 12:15:18 +0000 (08:15 -0400)
libs/ardour/directory_names.cc
wscript

index c368f8eaaf0e9a057d4ccef5a156149526fb1e47..43238ba45afa687d3a90862883aefbffabbc66a5 100644 (file)
@@ -40,7 +40,7 @@ const char* const ladspa_dir_name = X_("ladspa");
 const char* const panner_dir_name = X_("panners");
 const char* const backend_dir_name = X_("backends");
 
-char config_dir_name[] = X_(PROGRAM_NAME "3");
+char config_dir_name[] = X_(PROGRAM_NAME PROGRAM_VERSION);
 #if defined (__APPLE__) || defined (PLATFORM_WINDOWS)
 const char* const user_config_dir_name = config_dir_name;
 #else
diff --git a/wscript b/wscript
index f217c6408545ae81ed3042251a95ee78e9c8c9cb..68054f54d3699264528ac16b7c7c097b1b534d52 100644 (file)
--- a/wscript
+++ b/wscript
@@ -48,7 +48,7 @@ V = MAJOR + '.' + MINOR + '.' + MICRO
 # because if it is, it breaks waf somehow.
 #
 VERSION = V.encode ('ascii', 'ignore')
-APPNAME = 'Ardour' + MAJOR
+PROGRAM_VERSION = MAJOR.encode ('ascii', 'ignore')
 
 # Mandatory variables
 top = '.'
@@ -380,6 +380,7 @@ def set_compiler_flags (conf,opt):
         compiler_flags.append('-DENABLE_NLS')
 
     compiler_flags.append ('-DPROGRAM_NAME="' + Options.options.program_name + '"')
+    compiler_flags.append ('-DPROGRAM_VERSION="' + PROGRAM_VERSION + '"')
 
     if opt.debug:
         conf.env.append_value('CFLAGS', debug_flags)