<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=us-ascii">
<META NAME="Generator" CONTENT="MS Exchange Server version 6.5.7036.0">
<TITLE>Found my extras/contrib x264 bug on Cygwin</TITLE>
</HEAD>
<BODY>
<!-- Converted from text/rtf format -->

<P><FONT FACE="Times New Roman">I was getting an error related to an undefined pthreads item:</FONT>

<BR><FONT FACE="Times New Roman">gcc -mno-cygwin -isystem /usr/include/mingw -o x264.exe x264.o matroska.o muxers</FONT>

<BR><FONT FACE="Times New Roman">.o libx264.a -L/home/mfm/vlc-trunk/extras/contrib/lib -mno-cygwin -mno-cygwin -l</FONT>

<BR><FONT FACE="Times New Roman">pthread -lvfw32 -s</FONT>

<BR><FONT FACE="Times New Roman">libx264.a(cpu.o):cpu.c:(.text+0x192): undefined reference to `__imp__pthread_num</FONT>

<BR><FONT FACE="Times New Roman">_processors_np'</FONT>

<BR><FONT FACE="Times New Roman">collect2: ld returned 1 exit status</FONT>

<BR><FONT FACE="Times New Roman">make[3]: *** [x264.exe] Error 1</FONT>
</P>

<P><FONT FACE="Times New Roman">It turns out that pthreads is being built as libpthreadGC2.a, instead of libpthread.a</FONT>
</P>

<P><FONT FACE="Times New Roman">Now I'm making it to:</FONT>

<BR><FONT FACE="Times New Roman">gcc -mno-cygwin -isystem /usr/include/mingw -o x264.exe x264.o matroska.o muxers</FONT>

<BR><FONT FACE="Times New Roman">.o libx264.a -L/home/mfm/vlc-trunk/extras/contrib/lib -mno-cygwin -mno-cygwin -l</FONT>

<BR><FONT FACE="Times New Roman">vfw32 -s</FONT>

<BR><FONT FACE="Times New Roman">make[3]: Leaving directory `/home/mfm/vlc-trunk/extras/contrib/src/x264'</FONT>

<BR><FONT FACE="Times New Roman">make[3]: Entering directory `/home/mfm/vlc-trunk/extras/contrib/src/x264'</FONT>

<BR><FONT FACE="Times New Roman">install -d /home/mfm/vlc-trunk/extras/contrib/bin /home/mfm/vlc-trunk/extras/con</FONT>

<BR><FONT FACE="Times New Roman">trib/include</FONT>

<BR><FONT FACE="Times New Roman">install -d /home/mfm/vlc-trunk/extras/contrib/lib /home/mfm/vlc-trunk/extras/con</FONT>

<BR><FONT FACE="Times New Roman">trib/lib/pkgconfig</FONT>

<BR><FONT FACE="Times New Roman">install -m 644 x264.h /home/mfm/vlc-trunk/extras/contrib/include</FONT>

<BR><FONT FACE="Times New Roman">install -m 644 libx264.a /home/mfm/vlc-trunk/extras/contrib/lib</FONT>

<BR><FONT FACE="Times New Roman">install -m 644 x264.pc /home/mfm/vlc-trunk/extras/contrib/lib/pkgconfig</FONT>

<BR><FONT FACE="Times New Roman">install x264.exe /home/mfm/vlc-trunk/extras/contrib/bin</FONT>

<BR><FONT FACE="Times New Roman">/home/mfm/vlc-trunk/extras/contrib/lib/libx264.a</FONT>

<BR><FONT FACE="Times New Roman">/home/mfm/vlc-trunk/extras/contrib/lib/libx264.a: line 1: syntax error near unex</FONT>

<BR><FONT FACE="Times New Roman">pected token `newline'</FONT>

<BR><FONT FACE="Times New Roman">/home/mfm/vlc-trunk/extras/contrib/lib/libx264.a: line 1: `!<arch>'</FONT>

<BR><FONT FACE="Times New Roman">make[3]: *** [install] Error 2</FONT>
</P>

<P><FONT FACE="Times New Roman">A lot of little oddities :)  For some reason I expect that !<arch> is going to be similar to the problem I saw previously, things just not being defined in ways that work under Cygwin. (those AR, RANLIB, STRIP substitutions)</FONT></P>

</BODY>
</HTML>