[vlc-commits] winvlc: force plugin and data paths for vlc-static.exe

Rémi Denis-Courmont git at videolan.org
Thu Jul 28 18:51:34 CEST 2011


vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Thu Jul 28 19:47:50 2011 +0300| [00f9c81e01e802c8feabaded52611d41041817d3] | committer: Rémi Denis-Courmont

winvlc: force plugin and data paths for vlc-static.exe

Just like we already do for (Unix) vlc.

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=00f9c81e01e802c8feabaded52611d41041817d3
---

 bin/winvlc.c |   10 +++++++++-
 1 files changed, 9 insertions(+), 1 deletions(-)

diff --git a/bin/winvlc.c b/bin/winvlc.c
index 31d4db4..ebccce7 100644
--- a/bin/winvlc.c
+++ b/bin/winvlc.c
@@ -115,6 +115,11 @@ int WINAPI WinMain( HINSTANCE hInstance, HINSTANCE hPrevInstance,
                     int nCmdShow )
 {
     int argc;
+
+#ifdef TOP_BUILDDIR
+    putenv("VLC_PLUGIN_PATH=Z:"TOP_BUILDDIR"/modules");
+#endif
+
 #ifndef UNDER_CE
     HeapSetInformation(NULL, HeapEnableTerminationOnCorruption, NULL, 0);
 
@@ -137,12 +142,15 @@ int WINAPI WinMain( HINSTANCE hInstance, HINSTANCE hPrevInstance,
     if (wargv == NULL)
         return 1;
 
-    char *argv[argc + 2];
+    char *argv[argc + 3];
     BOOL crash_handling = TRUE;
     int j = 0;
 
     argv[j++] = FromWide( L"--media-library" );
     argv[j++] = FromWide( L"--no-ignore-config" );
+#ifdef TOP_SRCDIR
+    argv[argc++] = FromWide (L"--data-path=Z:"TOP_SRCDIR"/share");
+#endif
     for (int i = 1; i < argc; i++)
     {
         if(!wcscmp(wargv[i], L"--no-crashdump"))



More information about the vlc-commits mailing list