Commit 973cf049 authored by Gildas Bazin's avatar Gildas Bazin

* configure.ac, mozilla/*: the win32 mozilla plugin compiles again (most likely won't yet work).
 Added a --with-mozilla-sdk-path option (win32 only) to ./configure so you can pass the path of your mozilla sdk tree.
 You also need to set the XPIDL env var to the the path of the xpidl mozilla compiler when ./configuring.
parent 50f7bdc9
dnl Autoconf settings for vlc dnl Autoconf settings for vlc
dnl $Id: configure.ac,v 1.74 2003/09/09 12:54:19 jpsaman Exp $ dnl $Id: configure.ac,v 1.75 2003/09/20 13:52:23 gbazin Exp $
AC_INIT(vlc,0.6.3-cvs) AC_INIT(vlc,0.6.3-cvs)
...@@ -3050,7 +3050,7 @@ dnl ...@@ -3050,7 +3050,7 @@ dnl
mozilla=false mozilla=false
AC_ARG_ENABLE(mozilla, AC_ARG_ENABLE(mozilla,
[ --enable-mozilla build a vlc-based Mozilla plugin (default disabled)]) [ --enable-mozilla build a vlc-based Mozilla plugin (default disabled)])
if test "${enable_mozilla}" = "yes" if test "${enable_mozilla}" = "yes" -a "${SYS}" != "mingw32"
then then
AC_PATH_PROG(MOZILLA_CONFIG, mozilla-config, no) AC_PATH_PROG(MOZILLA_CONFIG, mozilla-config, no)
if test "${MOZILLA_CONFIG}" = "no" if test "${MOZILLA_CONFIG}" = "no"
...@@ -3068,12 +3068,36 @@ then ...@@ -3068,12 +3068,36 @@ then
dnl Workaround for http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=150490 dnl Workaround for http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=150490
AX_ADD_CPPFLAGS([mozilla],[[`${MOZILLA_CONFIG} --cflags plugin xpcom java | sed 's,-I\([^ ]*\)/mozilla/\([^ ]*\),-I\1/\2 -I\1/mozilla/\2,g' | xargs`]]) AX_ADD_CPPFLAGS([mozilla],[[`${MOZILLA_CONFIG} --cflags plugin xpcom java | sed 's,-I\([^ ]*\)/mozilla/\([^ ]*\),-I\1/\2 -I\1/mozilla/\2,g' | xargs`]])
AX_ADD_LDFLAGS([mozilla],[`${MOZILLA_CONFIG} --libs plugin xpcom`]) AX_ADD_LDFLAGS([mozilla],[`${MOZILLA_CONFIG} --libs plugin xpcom`])
dnl Not necessarily in ${PATH}
if test -z "${XPIDL}" -o ! -x "${XPIDL}"
then
XPIDL="/usr/lib/mozilla/xpidl"
fi fi
dnl special case for mingw32
elif test "${enable_mozilla}" = "yes"
then
AC_ARG_WITH(mozilla-sdk-path,
[ --with-mozilla-sdk-path=PATH path to win32 mozilla sdk], [
AC_MSG_CHECKING(for mozilla-config.h in ${with_mozilla_sdk_path})
real_mozilla_sdk="`cd ${with_mozilla_sdk_path} 2>/dev/null && pwd`"
if test -z "${real_mozilla_sdk}"; then
dnl The given directory can't be found
AC_MSG_RESULT(no)
AC_MSG_ERROR([cannot cd to ${with_mozilla_sdk_path}])
fi
if test -f "${real_mozilla_sdk}/mozilla-config.h"; then
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])
else
dnl The given path is incorrect
AC_MSG_RESULT(no)
AC_MSG_ERROR([cannot find ${real_mozilla_sdk}/mozilla-config.h])
fi fi
])
fi
dnl Not necessarily in ${PATH}
if test -z "${XPIDL}" -o ! -x "${XPIDL}"; then
XPIDL="/usr/lib/mozilla/xpidl"
fi fi
AM_CONDITIONAL(BUILD_MOZILLA,${mozilla}) AM_CONDITIONAL(BUILD_MOZILLA,${mozilla})
......
...@@ -35,12 +35,9 @@ ...@@ -35,12 +35,9 @@
* *
* ***** END LICENSE BLOCK ***** */ * ***** END LICENSE BLOCK ***** */
#ifndef _NPAPI_H_ #include "nscore.h"
#include "npapi.h" #include "npapi.h"
#endif
#ifndef _NPUPP_H_
#include "npupp.h" #include "npupp.h"
#endif
//\\// DEFINE //\\// DEFINE
#define NP_EXPORT #define NP_EXPORT
...@@ -131,7 +128,7 @@ extern "C" NPError ...@@ -131,7 +128,7 @@ extern "C" NPError
#else #else
NPError WINAPI NP_EXPORT NPError WINAPI NP_EXPORT
#endif #endif
NP_Initialize(NPNetscapeFuncs* pFuncs) NP_Initialize(NPNetscapeFuncs* pFuncs, NPPluginFuncs*)
{ {
// trap a NULL ptr // trap a NULL ptr
if(pFuncs == NULL) if(pFuncs == NULL)
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* vlcshell.cpp: a VLC plugin for Mozilla * vlcshell.cpp: a VLC plugin for Mozilla
***************************************************************************** *****************************************************************************
* Copyright (C) 2002 VideoLAN * Copyright (C) 2002 VideoLAN
* $Id: vlcshell.cpp,v 1.21 2003/08/27 08:44:28 garf Exp $ * $Id: vlcshell.cpp,v 1.22 2003/09/20 13:52:23 gbazin Exp $
* *
* Authors: Samuel Hocevar <sam@zoy.org> * Authors: Samuel Hocevar <sam@zoy.org>
* *
...@@ -99,12 +99,11 @@ static void Redraw( Widget w, XtPointer closure, XEvent *event ); ...@@ -99,12 +99,11 @@ static void Redraw( Widget w, XtPointer closure, XEvent *event );
HINSTANCE g_hDllInstance = NULL; HINSTANCE g_hDllInstance = NULL;
BOOL WINAPI BOOL WINAPI DllMain( HINSTANCE hinstDLL, /* handle of DLL module */
DllMain( HINSTANCE hinstDLL, // handle of DLL module DWORD fdwReason, /* reason for calling the function */
DWORD fdwReason, // reason for calling function LPVOID lpvReserved )
LPVOID lpvReserved)
{ {
switch (fdwReason) switch( fdwReason )
{ {
case DLL_PROCESS_ATTACH: case DLL_PROCESS_ATTACH:
g_hDllInstance = hinstDLL; g_hDllInstance = hinstDLL;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment