[vlc-devel] [PATCH] ActiveX: Changed files to be compilable by VC.

Sergey Radionov rsatom at gmail.com
Fri Nov 18 12:36:35 CET 2011


2011/11/18 Jean-Baptiste Kempf <jb at videolan.org>

> On Fri, Nov 18, 2011 at 05:56:21PM +0700, Sergey Radionov wrote :
> > +#ifndef _MSC_VER
> >
>  ////////////////////////////////////////////////////////////////////////////////////////////////
> >  DEFINE_GUID(IID_IGlobalInterfaceTable,     0x00000146, 0x0000, 0x0000,
> 0xc0,0x00, 0x00,0x00,0x00,0x00,0x00,0x46);
> >  DEFINE_GUID(CLSID_StdGlobalInterfaceTable, 0x00000323, 0x0000, 0x0000,
> 0xc0,0x00, 0x00,0x00,0x00,0x00,0x00,0x46);
> > @@ -40,6 +41,7 @@ DEFINE_GUID(CLSID_StdGlobalInterfaceTable, 0x00000323,
> 0x0000, 0x0000, 0xc0,0x00
> >  const GUID  IID_IGlobalInterfaceTable = { 0x00000146, 0, 0, {0xc0, 0,
> 0, 0, 0, 0, 0, 0x46} };
> >  const CLSID CLSID_StdGlobalInterfaceTable = { 0x00000323, 0, 0, {0xc0,
> 0, 0, 0, 0, 0, 0, 0x46} };
> >
>  ////////////////////////////////////////////////////////////////////////////////////////////////
> > +#endif
>
> Why not #ifdef _MINGW? It seems the issue is a lack of those GUID in the
> mingw header, not a fault of MSC
>
Ok.


>
> > +#ifdef __MINGW32__
> >  #include <_mingw.h>
> > +#endif
> Ok.
>
> > -#ifdef __MINGW64_VERSION_MAJOR
> > -
> > -#include <guiddef.h>
> >  #include <objsafe.h>
> >
> > -#else /* ! __MINGW64_VERSION_MAJOR */
> > -
> > +#if defined(__MINGW32_MAJOR_VERSION) &&
> !defined(__MINGW64_VERSION_MAJOR)
> >  /*
> >  ** Widl generated code requires guiddef.h,
> >  ** which is not available under MinGW32
> > @@ -54,13 +52,11 @@
> >  /* CATID_InternetAware is declared as extern but not present in library
> */
> >  DEFINE_GUID(CATID_InternetAware, \
> >      0x0DE86A58, 0x2BAA, 0x11CF, 0xA2, 0x29,
> 0x00,0xAA,0x00,0x3D,0x73,0x52);
> > -static DEFINE_GUID(CATID_SafeForInitializing, \
> > -     0x7DD95802, 0x9882, 0x11CF, 0x9F, 0xA9,
> 0x00,0xAA,0x00,0x6C,0x42,0xC4);
> > -static DEFINE_GUID(CATID_SafeForScripting, \
> > -     0x7DD95801, 0x9882, 0x11CF, 0x9F, 0xA9,
> 0x00,0xAA,0x00,0x6C,0x42,0xC4);
> > -
> > -#endif /* __MINGW64_VERSION_MAJOR */
> > -
> > +DEFINE_GUID(CATID_SafeForInitializing, \
> > +    0x7DD95802, 0x9882, 0x11CF, 0x9F, 0xA9,
> 0x00,0xAA,0x00,0x6C,0x42,0xC4);
> > +DEFINE_GUID(CATID_SafeForScripting, \
> > +    0x7DD95801, 0x9882, 0x11CF, 0x9F, 0xA9,
> 0x00,0xAA,0x00,0x6C,0x42,0xC4);
> > +#endif
> OK.
>
> > +#ifdef _MSC_VER
> > +#define PROGID_STR "VideoLAN.VLCPlugin"
> > +#else
> >  #define PROGID_STR COMPANY_STR"."PROGRAM_STR
> > +#endif
>
> Still not at ease with this, but well...
>
> >          // ToolboxBitmap32 key value
> >          {
> > -            TCHAR iconPath[pathLen+3];
> > +            std::vector<TCHAR> iconPathBuf(pathLen+3, 0);
> > +            TCHAR* iconPath = &iconPathBuf[0];
> Ok.
>
> > +#ifdef _MSC_VER
> > +#include "../vc_config.h"
> > +#endif //_MSC_VER
> > +
> >  using namespace std;
> >
> >  ////////////////////////////////////////////////////////////////////////
> > diff --git a/activex/position.h b/activex/position.h
> > index ec1c7f8..8d179df 100644
> > --- a/activex/position.h
> > +++ b/activex/position.h
> > @@ -22,6 +22,10 @@
> >  #ifndef POSITION_H
> >  #define POSITION_H
> >
> > +#ifdef _MSC_VER
> > +#include "../vc_config.h"
> > +#endif //_MSC_VER
>
> I am not such a fan of this... Can we do something clever in autotools?
>
Visual Studio developers usually have no autotools (and MinGW at all) on
computers, so this file must be generated by someone else and included to
repo, or be some sort of this.
Or it can have some other, more appropriate name...


>
> Best Regards,
>
> --
> Jean-Baptiste Kempf
> http://www.jbkempf.com/ - +33 672 704 734
> Sent from my Electronic Device
> _______________________________________________
> vlc-devel mailing list
> To unsubscribe or modify your subscription options:
> http://mailman.videolan.org/listinfo/vlc-devel
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20111118/54d4332e/attachment.html>


More information about the vlc-devel mailing list