* src/misc/modules.c: small clean-up and fixed --plugin-path on win32.
dnl Autoconf settings for vlc
-dnl $Id: configure.ac,v 1.76 2003/09/20 15:52:19 gbazin Exp $
+dnl $Id: configure.ac,v 1.77 2003/09/23 16:07:48 gbazin Exp $
AC_INIT(vlc,0.6.3-cvs)
AC_MSG_RESULT(${real_mozilla_sdk}/mozilla-config.h)
mozilla=:
AX_ADD_CPPFLAGS([mozilla],[-DXPCOM_GLUE -I${real_mozilla_sdk}/embedstring/include -I${real_mozilla_sdk}/xpcom/include -I${real_mozilla_sdk}/nspr/include -I${real_mozilla_sdk}/string/include -I${real_mozilla_sdk}/plugin/include -I${real_mozilla_sdk}/java/include])
- AX_ADD_LDFLAGS([mozilla],[-L${real_mozilla_sdk}/embedstring/bin -L${real_mozilla_sdk}/xpcom/bin -L${real_mozilla_sdk}/nspr/bin -L${real_mozilla_sdk}/string/bin -lnspr4 -lplds4 -lplc4 -lembedstring -lxpcomglue])
+ AX_ADD_LDFLAGS([mozilla],[-L${real_mozilla_sdk}/embedstring/bin -L${real_mozilla_sdk}/xpcom/bin -L${real_mozilla_sdk}/nspr/bin -L${real_mozilla_sdk}/string/bin -lnspr4 -lplds4 -lplc4 -lembedstring -lxpcomglue -Wl,--kill-at])
XPIDL_INCL="-I${real_mozilla_sdk}/xpcom/idl"
else
dnl The given path is incorrect
// by using the NP_LOADDS macro, when compiling for Win16
//
#ifdef __MINGW32__
-extern "C" NPError
+extern "C" __declspec(dllexport) NPError WINAPI
#else
NPError WINAPI NP_EXPORT
#endif
// called immediately after the plugin DLL is loaded
//
#ifdef __MINGW32__
-extern "C" NPError
+extern "C" __declspec(dllexport) NPError WINAPI
#else
NPError WINAPI NP_EXPORT
#endif
-NP_Initialize(NPNetscapeFuncs* pFuncs, NPPluginFuncs*)
+NP_Initialize(NPNetscapeFuncs* pFuncs)
{
// trap a NULL ptr
if(pFuncs == NULL)
// unloadable or it needs to stay in memory.
//
#ifdef __MINGW32__
-extern "C" NPError
+extern "C" __declspec(dllexport) NPError WINAPI
#else
NPError WINAPI NP_EXPORT
#endif
* vlcshell.cpp: a VLC plugin for Mozilla
*****************************************************************************
* Copyright (C) 2002 VideoLAN
- * $Id: vlcshell.cpp,v 1.23 2003/09/20 22:52:27 gbazin Exp $
+ * $Id: vlcshell.cpp,v 1.24 2003/09/23 16:07:48 gbazin Exp $
*
* Authors: Samuel Hocevar <sam@zoy.org>
*
* Windows-only declarations
*****************************************************************************/
#ifdef XP_WIN
-# define VOUT_PLUGINS "directx,dummy"
-# define AOUT_PLUGINS "none" /* "directx,waveout,dummy" */
+# define VOUT_PLUGINS "directx,wingdi,dummy"
+# define AOUT_PLUGINS "directx,waveout,dummy"
HINSTANCE g_hDllInstance = NULL;
ppsz_argv[2] = plugin_path;
#elif defined(XP_WIN)
- char *ppsz_argv[] = { "vlc", "--plugin-path", NULL };
+ char *ppsz_argv[] = { "vlc", "--plugin-path", NULL, "-vv" };
HKEY h_key;
DWORD i_type, i_data;
char p_data[MAX_PATH + 1];
* modules.c : Builtin and plugin modules management functions
*****************************************************************************
* Copyright (C) 2001 VideoLAN
- * $Id: modules.c,v 1.131 2003/09/10 11:37:52 fenrir Exp $
+ * $Id: modules.c,v 1.132 2003/09/23 16:07:49 gbazin Exp $
*
* Authors: Samuel Hocevar <sam@zoy.org>
* Ethan C. Baldridge <BaldridgeE@cadmus.com>
char ** ppsz_path = path;
char * psz_fullpath;
-#if defined( SYS_BEOS ) || defined( SYS_DARWIN ) \
- || ( defined( WIN32 ) && !defined( UNDER_CE ) )
- int i_vlclen = strlen( p_this->p_libvlc->psz_vlcpath );
- vlc_bool_t b_notinroot;
-#endif
#if defined( UNDER_CE )
wchar_t psz_dir[MAX_PATH];
{
#if defined( SYS_BEOS ) || defined( SYS_DARWIN ) \
|| ( defined( WIN32 ) && !defined( UNDER_CE ) )
- /* Store strlen(*ppsz_path) for later use. */
- int i_dirlen = strlen( *ppsz_path );
- b_notinroot = VLC_FALSE;
- /* Under BeOS, we need to add beos_GetProgramPath() to access
- * files under the current directory */
+ /* Handle relative as well as absolute paths */
#ifdef WIN32
- if( i_dirlen < 3 || (*ppsz_path)[3] != '\\' )
+ if( !(*ppsz_path)[0] || (*ppsz_path)[1] != ':' )
#else
if( (*ppsz_path)[0] != '/' )
#endif
{
- i_dirlen += i_vlclen + 2;
- b_notinroot = VLC_TRUE;
+ int i_dirlen = strlen( *ppsz_path );
+ i_dirlen += strlen( p_this->p_libvlc->psz_vlcpath ) + 2;
psz_fullpath = malloc( i_dirlen );
if( psz_fullpath == NULL )
else
#endif
{
- psz_fullpath = *ppsz_path;
+ psz_fullpath = strdup( *ppsz_path );
}
msg_Dbg( p_this, "recursively browsing `%s'", psz_fullpath );
AllocatePluginDir( p_this, psz_fullpath, 5 );
#endif
-#if defined( SYS_BEOS ) || defined( SYS_DARWIN )
- if( b_notinroot )
- {
- free( psz_fullpath );
- }
-#endif
+ free( psz_fullpath );
}
/* Free plugin-path */