summaryrefslogtreecommitdiff
path: root/libs/pbd
diff options
context:
space:
mode:
authorPaul Davis <paul@linuxaudiosystems.com>2013-03-20 07:43:19 -0400
committerPaul Davis <paul@linuxaudiosystems.com>2013-03-20 07:43:19 -0400
commita2d657721094e31f1f17ae0bd406bbe36bbc9e98 (patch)
tree735c5d7312a737d6c11672ef88d0029b89c145c4 /libs/pbd
parentb2a667266bb285f73e4701be55c10633846ace56 (diff)
move path_expand() and search_path_expand() into libpbd, and use them to expand search paths given to pathscanner objects (always)
Diffstat (limited to 'libs/pbd')
-rw-r--r--libs/pbd/pathscanner.cc3
-rw-r--r--libs/pbd/pbd/basename.h13
-rw-r--r--libs/pbd/wscript1
3 files changed, 8 insertions, 9 deletions
diff --git a/libs/pbd/pathscanner.cc b/libs/pbd/pathscanner.cc
index 8f57726c7f..fac2dcfd96 100644
--- a/libs/pbd/pathscanner.cc
+++ b/libs/pbd/pathscanner.cc
@@ -29,6 +29,7 @@
#include <glibmm/miscutils.h>
#include "pbd/error.h"
+#include "pbd/pathexpand.h"
#include "pbd/pathscanner.h"
#include "pbd/stl_delete.h"
@@ -90,7 +91,7 @@ PathScanner::run_scan_internal (vector<string *> *result,
{
DIR *dir;
struct dirent *finfo;
- char *pathcopy = strdup (dirpath.c_str());
+ char *pathcopy = strdup (search_path_expand (dirpath).c_str());
char *thisdir;
string fullpath;
string search_str;
diff --git a/libs/pbd/pbd/basename.h b/libs/pbd/pbd/basename.h
index f13c3840dc..290af2e4bf 100644
--- a/libs/pbd/pbd/basename.h
+++ b/libs/pbd/pbd/basename.h
@@ -17,16 +17,13 @@
*/
-#ifndef __stupid_basename_h__
-#define __stupid_basename_h__
+#ifndef __libpbd_basename_h__
+#define __libdpbd_basename_h__
#include <glibmm/ustring.h>
-namespace PBD
-{
-
-Glib::ustring basename_nosuffix (Glib::ustring);
-
+namespace PBD {
+ Glib::ustring basename_nosuffix (Glib::ustring);
}
-#endif // __stupid_basename_h__
+#endif /* __libdpbd_basename_h__ */
diff --git a/libs/pbd/wscript b/libs/pbd/wscript
index eb88809f53..0ec2747cb3 100644
--- a/libs/pbd/wscript
+++ b/libs/pbd/wscript
@@ -86,6 +86,7 @@ def build(bld):
malign.cc
mountpoint.cc
openuri.cc
+ pathexpand.cc
pathscanner.cc
pool.cc
property_list.cc