[Xvid-devel] Compilation of Latest SVN

Michael Militzer michael at xvid.org
Fri Jul 20 23:54:10 CEST 2012


Hi Brendan,

of course the '#' was not intended to be in the commit. Thanks for pointing
that out. As to the "lib" prefix of xvidcore.dll: The change of the library
name was made as a result of the discussion below:

http://list.xvid.org/pipermail/xvid-devel/2011-September/006343.html

Regards,
Michael


Quoting Brendan Brewster <brendan.brewster at gmail.com>:

> Hi Michael,
>
> Great, thank you!
>
> I will try it out myself later in the weekend but in the meantime, I was
> curious, did you really mean to check in the Makefile with the '#' in front
> of the '-lgdi32'?
>
> On a nearly related note, once I got to checking out the completed build, I
> noticed that the xvid core dll that is produced is now generated as
> 'libxvidcore.dll' as opposed to 'xvidcore.dll' which the xvid.inf does not
> expect.
>
> Thanks,
> Brendan
>
> On Fri, Jul 20, 2012 at 10:27 AM, Michael Militzer <michael at xvid.org> wrote:
>
>> Hi Brendan,
>>
>> confirmed. I see the same errors when cross-compiling with mingw 3.4.x
>> on a linux host. Will do some more tests and then apply your patch...
>>
>> Regards,
>> Michael
>>
>>
>> Quoting Brendan Brewster <brendan.brewster at gmail.com>:
>>
>> > Apologies but I'm thinking that this list doesn't allow the attachment so
>> > am providing it in-line just in case.
>> >
>> > $ more xvid_120719.patch
>> > diff -urN xvidcore_120719.orig/dshow/Makefile xvidcore/dshow/Makefile
>> > --- xvidcore_120719.orig/dshow/Makefile 2012-07-19 23:41:58.000000000
>> -0400
>> > +++ xvidcore/dshow/Makefile     2012-07-19 23:47:12.000000000 -0400
>> > @@ -112,7 +112,7 @@
>> >                         $(OBJECTS) xvid.ax.def \
>> >                         -L$(DXTREE)/Lib -lstrmiids \
>> >                         $(DXBASECLASSES)/strmbase.lib \
>> > -                       -luuid -lwinmm -lole32 -loleaut32 -lcomctl32
>> > -lstdc++
>> > +                       -luuid -lwinmm -lole32 -loleaut32 -lcomctl32
>> > -lstdc++ -lgdi32
>> >
>> >  clean:
>> >         @echo "  Cl: Object files and target lib"
>> > diff -urN xvidcore_120719.orig/dshow/src/CXvidDecoder.h
>> > xvidcore/dshow/src/CXvidDecoder.h
>> > --- xvidcore_120719.orig/dshow/src/CXvidDecoder.h       2012-07-19
>> > 23:41:57.000000000 -0400
>> > +++ xvidcore/dshow/src/CXvidDecoder.h   2012-07-19 23:49:09.375000000
>> -0400
>> > @@ -29,6 +29,10 @@
>> >  #include <xvid.h>
>> >  #include "IXvidDecoder.h"
>> >
>> > +#ifndef HWND_MESSAGE
>> > +#define HWND_MESSAGE ((HWND)-3)
>> > +#endif
>> > +
>> >  #define XVID_NAME_L            L"Xvid MPEG-4 Video Decoder"
>> >
>> >  /* --- fourcc --- */
>> >
>> > Thanks again!
>> > Brendan
>> >
>> > On Fri, Jul 20, 2012 at 12:18 AM, Brendan Brewster <
>> > brendan.brewster at gmail.com> wrote:
>> >
>> >> Hi,
>> >>
>> >> I am using a moderately older version of MinGW and have not had any true
>> >> problems compiling XviD in the past.
>> >>
>> >> I obtained the latest SVN (first time in a long while), compiled the
>> >> xvidcore.dll and xvidvfw.dll fine but had issues compiling the dshow
>> module.
>> >>
>> >> $ make DXTREE=/d/dx90/
>> >>   D: =build
>> >>   C: ./config.c
>> >>   C: ./debug.c
>> >>   C: ./Configure.cpp
>> >> In file included from <command line>:3:
>> >> d:/dx90/mingw_dshow_port.h:6:1: warning: "_WINGDI_" redefined
>> >> In file included from
>> >> d:/MinGW/bin/../lib/gcc/mingw32/3.4.5/../../../../include/windows.h:52,
>> >>                  from
>> >> d:/MinGW/bin/../lib/gcc/mingw32/3.4.5/../../../../include/rpc.h:2,
>> >>                  from
>> >> d:/MinGW/bin/../lib/gcc/mingw32/3.4.5/../../../../include/wtypes.h:1,
>> >>                  from d:/dx90/mingw_dshow_port.h:1,
>> >>                  from <command line>:3:
>> >> d:/MinGW/bin/../lib/gcc/mingw32/3.4.5/../../../../include/wingdi.h:3:1:
>> >> warning: this is the location of the previous definition
>> >>   C: ./CAbout.cpp
>> >> In file included from <command line>:3:
>> >> d:/dx90/mingw_dshow_port.h:6:1: warning: "_WINGDI_" redefined
>> >> In file included from
>> >> d:/MinGW/bin/../lib/gcc/mingw32/3.4.5/../../../../include/windows.h:52,
>> >>                  from
>> >> d:/MinGW/bin/../lib/gcc/mingw32/3.4.5/../../../../include/rpc.h:2,
>> >>                  from
>> >> d:/MinGW/bin/../lib/gcc/mingw32/3.4.5/../../../../include/wtypes.h:1,
>> >>                  from d:/dx90/mingw_dshow_port.h:1,
>> >>                  from <command line>:3:
>> >> d:/MinGW/bin/../lib/gcc/mingw32/3.4.5/../../../../include/wingdi.h:3:1:
>> >> warning: this is the location of the previous definition
>> >>   C: ./CXvidDecoder.cpp
>> >> In file included from <command line>:3:
>> >> d:/dx90/mingw_dshow_port.h:6:1: warning: "_WINGDI_" redefined
>> >> In file included from
>> >> d:/MinGW/bin/../lib/gcc/mingw32/3.4.5/../../../../include/windows.h:52,
>> >>                  from
>> >> d:/MinGW/bin/../lib/gcc/mingw32/3.4.5/../../../../include/rpc.h:2,
>> >>                  from
>> >> d:/MinGW/bin/../lib/gcc/mingw32/3.4.5/../../../../include/wtypes.h:1,
>> >>                  from d:/dx90/mingw_dshow_port.h:1,
>> >>                  from <command line>:3:
>> >> d:/MinGW/bin/../lib/gcc/mingw32/3.4.5/../../../../include/wingdi.h:3:1:
>> >> warning: this is the location of the previous definition
>> >> src/CXvidDecoder.cpp: In member function `virtual long int
>> >> CXvidDecoder::CompleteConnect(PIN_DIRECTION, IPin*)':
>> >> src/CXvidDecoder.cpp:966: error: `HWND_MESSAGE' was not declared in this
>> >> scope
>> >> make: *** [CXvidDecoder.obj] Error 1
>> >>
>> >> I patched CXvidDecoder.h as follows (to define HWND_MESSAGE if needed).
>> >>
>> >> $ diff -u src/CXvidDecoder.h.v0 src/CXvidDecoder.h
>> >> --- src/CXvidDecoder.h.v0       2012-07-19 23:41:58.000000000 -0400
>> >> +++ src/CXvidDecoder.h  2012-07-19 23:49:09.375000000 -0400
>> >> @@ -29,6 +29,10 @@
>> >>  #include <xvid.h>
>> >>  #include "IXvidDecoder.h"
>> >>
>> >> +#ifndef HWND_MESSAGE
>> >>  +#define HWND_MESSAGE ((HWND)-3)
>> >> +#endif
>> >> +
>> >>  #define XVID_NAME_L            L"Xvid MPEG-4 Video Decoder"
>> >>
>> >>  /* --- fourcc --- */
>> >>
>> >> I then retried make.
>> >>
>> >> $ make DXTREE=/d/dx90/
>> >>   C: ./CXvidDecoder.cpp
>> >> In file included from <command line>:3:
>> >> d:/dx90/mingw_dshow_port.h:6:1: warning: "_WINGDI_" redefined
>> >> In file included from
>> >> d:/MinGW/bin/../lib/gcc/mingw32/3.4.5/../../../../include/windows.h:52,
>> >>                  from
>> >> d:/MinGW/bin/../lib/gcc/mingw32/3.4.5/../../../../include/rpc.h:2,
>> >>                  from
>> >> d:/MinGW/bin/../lib/gcc/mingw32/3.4.5/../../../../include/wtypes.h:1,
>> >>                  from d:/dx90/mingw_dshow_port.h:1,
>> >>                  from <command line>:3:
>> >> d:/MinGW/bin/../lib/gcc/mingw32/3.4.5/../../../../include/wingdi.h:3:1:
>> >> warning: this is the location of the previous definition
>> >>   W: ./xvid.ax.rc
>> >>   L: xvid.ax
>> >> Creating library file: xvid.ax.a
>> >> CXvidDecoder.obj:CXvidDecoder.cpp:(.text+0x1b9b): undefined reference to
>> >> `GetStockObject at 4'
>> >> collect2: ld returned 1 exit status
>> >> make: *** [xvid.ax] Error 1
>> >>
>> >> So, I then patched the Makefile after some further research as follows
>> (to
>> >> pick up the gdi32 lib).
>> >>
>> >> $ diff -u Makefile.v0 Makefile
>> >> --- Makefile.v0 2012-07-19 23:41:58.000000000 -0400
>> >> +++ Makefile    2012-07-19 23:47:12.000000000 -0400
>> >> @@ -112,7 +112,7 @@
>> >>                         $(OBJECTS) xvid.ax.def \
>> >>                         -L$(DXTREE)/Lib -lstrmiids \
>> >>                         $(DXBASECLASSES)/strmbase.lib \
>> >> -                       -luuid -lwinmm -lole32 -loleaut32 -lcomctl32
>> >> -lstdc++
>> >> +                       -luuid -lwinmm -lole32 -loleaut32 -lcomctl32
>> >> -lstdc++ -lgdi32
>> >>
>> >>  clean:
>> >>         @echo "  Cl: Object files and target lib"
>> >>
>> >> As can be seen, I was then able to successfully build xvid.ax.
>> >>
>> >> $ make DXTREE=/d/dx90/
>> >>   L: xvid.ax
>> >> Creating library file: xvid.ax.a
>> >>
>> >> Is this just due to changes in XviD and given my old tool chain or am I
>> >> just doing something wrong?
>> >>
>> >> I am attaching a patch [xvid_120719.patch] with the above mods that
>> allows
>> >> me to build in my environment.
>> >>
>> >> Please let me know if you have any thoughts or if there is any further
>> >> info I can provide.
>> >>
>> >> Thanks,
>> >> Brendan
>> >>
>> > _______________________________________________
>> > Xvid-devel mailing list
>> > Xvid-devel at xvid.org
>> > http://list.xvid.org/mailman/listinfo/xvid-devel
>> >
>> >
>>
>>
>>
>> _______________________________________________
>> Xvid-devel mailing list
>> Xvid-devel at xvid.org
>> http://list.xvid.org/mailman/listinfo/xvid-devel
>>
> _______________________________________________
> Xvid-devel mailing list
> Xvid-devel at xvid.org
> http://list.xvid.org/mailman/listinfo/xvid-devel
>
>





More information about the Xvid-devel mailing list