Skip silent sources on session-archive -- fixes #7699
[ardour.git] / gtk2_ardour / bundle_env_msvc.cc
index 1be6434fb6037d0c389ad338f70ec0d4102f659f..a188e705aa0d45a48e876562a26bdc6cf584ba63 100644 (file)
@@ -18,7 +18,7 @@
 */
 
 #include "bundle_env.h"
-#include "i18n.h"
+#include "pbd/i18n.h"
 
 #include <shlobj.h>
 #include <stdlib.h>
@@ -29,7 +29,7 @@
 #include <fstream>
 
 #include <glibmm.h>
-#include <pbd/gstdio_compat.h>
+#include "pbd/gstdio_compat.h"
 
 #include <fontconfig/fontconfig.h>
 
@@ -86,7 +86,7 @@ std::string ret;
        if (0 == pExeRoot) {
                pExeRoot = g_build_filename("C:\\", "Program Files", PROGRAM_NAME, 0);
        }
-       
+
        if (pExeRoot) {
                gchar  tmp[PATH_MAX+1];
                gchar* p;
@@ -232,10 +232,11 @@ string fonts_conf_file;
 
 #ifdef DEBUG
        fonts_conf_file = get_module_folder();
-       
+
        if (!fonts_conf_file.empty()) {
                fonts_conf_file += "\\";
                fonts_conf_file += PROGRAM_NAME;
+               fonts_conf_file += PROGRAM_VERSION;
                fonts_conf_file += FONTS_CONF_LOCATION;
 #else
        if (PBD::find_file (ARDOUR::ardour_config_search_path(), "fonts.conf", fonts_conf_file)) {
@@ -257,10 +258,11 @@ string pango_modules_file;
 #if defined(DEBUG) || defined(RDC_BUILD)
        // Make sure we pick up the debuggable DLLs !!!
        pango_modules_file = get_module_folder();
-       
+
        if (!pango_modules_file.empty()) {
                pango_modules_file += "\\";
                pango_modules_file += PROGRAM_NAME;
+               pango_modules_file += PROGRAM_VERSION;
                pango_modules_file += PANGO_CONF_LOCATION;
 #if 0
 // JE - handy for non-English locale testing (Greek, in this case)
@@ -295,10 +297,11 @@ string gdk_pixbuf_loaders_file;
 #if defined(DEBUG) || defined(RDC_BUILD)
        // Make sure we pick up the debuggable DLLs !!!
        gdk_pixbuf_loaders_file = get_module_folder();
-       
+
        if (!gdk_pixbuf_loaders_file.empty()) {
                gdk_pixbuf_loaders_file += "\\";
                gdk_pixbuf_loaders_file += PROGRAM_NAME;
+               gdk_pixbuf_loaders_file += PROGRAM_VERSION;
                gdk_pixbuf_loaders_file += PIXBUFLOADERS_CONF_LOCATION;
 #else
        if (PBD::find_file (ARDOUR::ardour_config_search_path(), "gdk-pixbuf.loaders", gdk_pixbuf_loaders_file)) {
@@ -321,10 +324,11 @@ string clearlooks_la_file;
 #if defined(DEBUG) || defined(RDC_BUILD)
        // Make sure we pick up the debuggable DLLs !!!
        clearlooks_la_file = get_module_folder();
-       
+
        if (!clearlooks_la_file.empty()) {
                clearlooks_la_file += "\\";
                clearlooks_la_file += PROGRAM_NAME;
+               clearlooks_la_file += PROGRAM_VERSION;
                clearlooks_la_file += CLEARLOOKS_CONF_LOCATION;
 #else
        if (PBD::find_file (ARDOUR::ardour_config_search_path(), "libclearlooks.la", clearlooks_la_file)) {
@@ -373,6 +377,7 @@ fixup_bundle_environment (int argc, char* argv[], string & localedir)
        // Next, set up 'ARDOUR_DATA_PATH'
        path  = get_module_folder() + "\\";
        path += PROGRAM_NAME;
+       path += PROGRAM_VERSION;
        path += "\\share";
        Glib::setenv ("ARDOUR_DATA_PATH", path, true);
 
@@ -386,21 +391,6 @@ fixup_bundle_environment (int argc, char* argv[], string & localedir)
        Glib::setenv ("ARDOUR_CONFIG_PATH", path, true);
 
 
-       // Next, set up 'ARDOUR_PATH'
-       path  = user_config_directory();
-       path  = Glib::path_get_dirname (path);
-       path += G_SEARCHPATH_SEPARATOR;
-       path += windows_search_path().to_string();
-       path += "\\icons;";
-       path += windows_search_path().to_string();
-       path += "\\pixmaps;";
-       path += ardour_data_search_path().to_string();  // In fact, adds both the 'data' search
-       path += G_SEARCHPATH_SEPARATOR;                 // path and our 'config' search path
-       path += dir_path;
-       path += "\\etc";
-       Glib::setenv ("ARDOUR_PATH", path, true);
-
-
        // Next, set up 'ARDOUR_INSTANT_XML_PATH'
        path = user_config_directory();
        Glib::setenv ("ARDOUR_INSTANT_XML_PATH", path, true);
@@ -425,6 +415,7 @@ fixup_bundle_environment (int argc, char* argv[], string & localedir)
        }
        path += get_module_folder() + "\\";
        path += PROGRAM_NAME;
+       path += PROGRAM_VERSION;
        path += "\\bin\\vamp";
        path += G_SEARCHPATH_SEPARATOR;
        path += "%ProgramFiles%\\Vamp Plugins";
@@ -467,8 +458,8 @@ fixup_bundle_environment (int argc, char* argv[], string & localedir)
        Glib::setenv ("GTK_PATH", path, true);
 
 
-       // Unset GTK_RC_FILES so that we only load the RC files that we define
-       Glib::unsetenv ("GTK_RC_FILES");
+       // Unset GTK2_RC_FILES so that we only load the RC files that we define
+       Glib::unsetenv ("GTK2_RC_FILES");
 
 
        // and set a '$HOME' environment variable. This variable changes the value returned
@@ -490,7 +481,7 @@ fixup_bundle_environment (int argc, char* argv[], string & localedir)
 }
 
 
-void load_custom_fonts() 
+void load_custom_fonts()
 {
        std::string ardour_mono_file;