summaryrefslogtreecommitdiff
path: root/src/lib
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/film.cc11
-rw-r--r--src/lib/wscript2
2 files changed, 8 insertions, 5 deletions
diff --git a/src/lib/film.cc b/src/lib/film.cc
index 041bbc225..cb66e2783 100644
--- a/src/lib/film.cc
+++ b/src/lib/film.cc
@@ -25,6 +25,10 @@
#include <sstream>
#include <iomanip>
#include <unistd.h>
+#ifdef DVDOMATIC_WINDOWS
+#undef DATADIR
+#include <shlwapi.h>
+#endif
#include <boost/filesystem.hpp>
#include <boost/algorithm/string.hpp>
#include <boost/lexical_cast.hpp>
@@ -1002,10 +1006,9 @@ Film::set_content (string c)
#ifdef DVDOMATIC_WINDOWS
wchar_t dir[512];
GetModuleFileName (GetModuleHandle (0), dir, sizeof (dir));
- boost::filesystem::path path_dir (dir);
- path_dir = path_dir.parent_path ();
- path_dir /= "ffprobe.exe";
- string ffprobe = "\"" + path_dir.string () + "\" ";
+ PathRemoveFileSpec (dir);
+ SetCurrentDirectory (dir);
+ string ffprobe = "ffprobe.exe ";
#else
string ffprobe = "ffprobe ";
#endif
diff --git a/src/lib/wscript b/src/lib/wscript
index 66207b1e4..7c7a64d58 100644
--- a/src/lib/wscript
+++ b/src/lib/wscript
@@ -69,7 +69,7 @@ def build(bld):
obj.source = sources + ' version.cc'
if bld.env.TARGET_WINDOWS:
- obj.uselib += ' WINSOCK2 BFD DBGHELP IBERTY'
+ obj.uselib += ' WINSOCK2 BFD DBGHELP IBERTY SHLWAPI'
obj.source += ' stack.cpp'
obj.target = 'dvdomatic'