Consolidate search/file-system paths (fixes vst builds)
Keep file-system paths and PBD::Searchpath mostly separate. This amends58c2b0a848
libs/fst directly includes relevant ardour C++ code, so lib/fst must not link against libardour. The problem was that58c2b0a848
introduced additional dependencies on other libardour functions.
This commit is contained in:
parent
d521c2ede6
commit
a6f8f2dd9e
|
@ -89,9 +89,6 @@ namespace ARDOUR {
|
|||
LIBARDOUR_API std::string windows_package_directory_path ();
|
||||
#endif
|
||||
|
||||
LIBARDOUR_API PBD::Searchpath system_midi_map_search_path ();
|
||||
LIBARDOUR_API std::string user_midi_map_directory ();
|
||||
|
||||
namespace ArdourVideoToolPaths {
|
||||
|
||||
LIBARDOUR_API bool harvid_exe (std::string &harvid_exe);
|
||||
|
|
|
@ -130,6 +130,11 @@ namespace ARDOUR {
|
|||
*/
|
||||
LIBARDOUR_API PBD::Searchpath lua_search_path ();
|
||||
|
||||
/** retun a Searchpath for midi *.map files used by the
|
||||
* generic ctrl surface
|
||||
*/
|
||||
LIBARDOUR_API PBD::Searchpath system_midi_map_search_path ();
|
||||
LIBARDOUR_API std::string user_midi_map_directory ();
|
||||
|
||||
} // namespace ARDOUR
|
||||
|
||||
|
|
|
@ -313,27 +313,4 @@ been_here_before_path (int version)
|
|||
return Glib::build_filename (user_config_directory (version), string (".a") + to_string (version));
|
||||
}
|
||||
|
||||
static const char * const midimap_env_variable_name = "ARDOUR_MIDIMAPS_PATH";
|
||||
|
||||
Searchpath
|
||||
system_midi_map_search_path ()
|
||||
{
|
||||
bool midimap_path_defined = false;
|
||||
std::string spath_env (Glib::getenv (midimap_env_variable_name, midimap_path_defined));
|
||||
|
||||
if (midimap_path_defined) {
|
||||
return spath_env;
|
||||
}
|
||||
|
||||
Searchpath spath (ardour_data_search_path());
|
||||
spath.add_subdirectory_to_paths (midi_map_dir_name);
|
||||
return spath;
|
||||
}
|
||||
|
||||
std::string
|
||||
user_midi_map_directory ()
|
||||
{
|
||||
return Glib::build_filename (user_config_directory(), midi_map_dir_name);
|
||||
}
|
||||
|
||||
} // namespace ARDOUR
|
||||
|
|
|
@ -192,6 +192,29 @@ lua_search_path ()
|
|||
return spath;
|
||||
}
|
||||
|
||||
static const char * const midimap_env_variable_name = "ARDOUR_MIDIMAPS_PATH";
|
||||
|
||||
Searchpath
|
||||
system_midi_map_search_path ()
|
||||
{
|
||||
bool midimap_path_defined = false;
|
||||
std::string spath_env (Glib::getenv (midimap_env_variable_name, midimap_path_defined));
|
||||
|
||||
if (midimap_path_defined) {
|
||||
return spath_env;
|
||||
}
|
||||
|
||||
Searchpath spath (ardour_data_search_path());
|
||||
spath.add_subdirectory_to_paths (midi_map_dir_name);
|
||||
return spath;
|
||||
}
|
||||
|
||||
std::string
|
||||
user_midi_map_directory ()
|
||||
{
|
||||
return Glib::build_filename (user_config_directory(), midi_map_dir_name);
|
||||
}
|
||||
|
||||
#ifdef PLATFORM_WINDOWS
|
||||
|
||||
const char*
|
||||
|
|
|
@ -40,7 +40,7 @@ def build(bld):
|
|||
'LIBARDOUR="' + bld.env['lwrcase_dirname'] + '"',
|
||||
'LOCALEDIR="' + os.path.join(os.path.normpath(bld.env['DATADIR']), 'locale') + '"',
|
||||
]
|
||||
obj.use = [ 'libpbd', 'libardour' ]
|
||||
obj.use = [ 'libpbd' ]
|
||||
obj.uselib = 'GIOMM DL UUID ARCHIVE CURL XML'
|
||||
|
||||
if sys.platform == 'darwin':
|
||||
|
@ -63,10 +63,10 @@ def build(bld):
|
|||
bld (features = 'c', name='vstwin', source='vstwin.c', uselib = 'GIOMM', includes = [ '../pbd/', '../ardour/', '.' ])
|
||||
obj.uselib = ['GIOMM', 'DL', 'GDI32', 'ARCHIVE', 'CURL', 'XML']
|
||||
obj.linkflags = ['-mwindows']
|
||||
obj.use = [ 'libpbd', 'libtemporal', 'libevoral', 'libardour', 'vstwin' ]
|
||||
obj.use = [ 'libpbd', 'libtemporal', 'libevoral', 'vstwin' ]
|
||||
else:
|
||||
obj.uselib = ['GIOMM', 'DL', 'OSX', 'ARCHIVE', 'CURL', 'XML' ]
|
||||
obj.use = [ 'libpbd', 'libtemporal', 'libevoral', 'libardour' ]
|
||||
obj.use = [ 'libpbd', 'libtemporal', 'libevoral' ]
|
||||
|
||||
obj.includes = [ '../pbd/', '../ardour/', '.' ]
|
||||
obj.defines = [
|
||||
|
|
|
@ -52,7 +52,7 @@
|
|||
#include "ardour/auditioner.h"
|
||||
#include "ardour/directory_names.h"
|
||||
#include "ardour/filename_extensions.h"
|
||||
#include "ardour/filesystem_paths.h"
|
||||
#include "ardour/search_paths.h"
|
||||
#include "ardour/session.h"
|
||||
#include "ardour/midi_ui.h"
|
||||
#include "ardour/plugin_insert.h"
|
||||
|
|
Loading…
Reference in New Issue
Block a user