| 30 | | 1: $(SONAME): .depend $(OBJS) $(OBJASM) |
| 31 | | 2: $(CC) -shared -o $@ $(OBJS) $(OBJASM) -Wl,-soname,$(SONAME) $(LDFLAGS) |
| 32 | | 3: ifeq ($(SYS),MINGW) |
| 33 | | 4: $(CC) -shared -Wl,--output-def,libx264.def -o libx264.dll $(OBJS) $(OBJA |
| 34 | | SM) |
| 35 | | 5: lib /machine:i386 /def:libx264.def |
| 36 | | 6: endif |
| | 17 | To build Non-GPL VIC with VS2008, select Release or Debug in the "Solutions Configuration" drop down menu, then click "Configuration Manger..." in the same menu and select Debug (nonGPL) or Release (nonGPL). |
| | 19 | |
| | 20 | ~~~~ |
| | 21 | VIC GPL (Release or Debug) version pre-requisites: |
| | 22 | ~~~~ |
| | 23 | |
| | 24 | - All the non-GPL VIC prerequisites |
| | 25 | |
| | 26 | - Yasm assembler |
| | 27 | http://www.tortall.net/projects/yasm/wiki/Download |
| | 28 | copy it to a directory in your PATH (e.g. C:\Windows) and rename it to yasm.exe |
| | 29 | |
| | 30 | - Info-ZIP 2.21 |
| | 31 | ftp://ftp.info-zip.org/pub/infozip/win32/zip232xn.zip |
| | 32 | |
| | 33 | Extract zip.exe from the above zip file and copy it into a directory in your PATH (e.g. C:\Windows). |
| | 34 | Note: ZIP 3.0 must not be used as it has a bug which prevents it from adjusting the ZIP offset of the zip file that gets appended to vic.exe. |
| | 35 | |
| | 36 | - MinGW and MSYS |
| | 37 | http://www.mingw.org/ |
| | 38 | |
| | 39 | - ffmpeg SVN revision 20462 |
| | 40 | svn checkout -r 20462 svn://svn.ffmpeg.org/ffmpeg/trunk ffmpeg |
| | 41 | |
| | 42 | - libswscale SVN revision 29824 |
| | 43 | svn checkout -r 29824 svn://svn.ffmpeg.org/mplayer/trunk/libswscale ffmpeg/libswscale |
| | 44 | |
| | 45 | - x264-snapshot-20090708-2245 |
| | 46 | http://downloads.videolan.org/pub/videolan/x264/snapshots/ |
| | 47 | |
| | 48 | - pthread-win32 2.8.0 |
| | 49 | http://sourceware.org/pthreads-win32/ |
| | 50 | |
| | 51 | |
| | 52 | |
| | 53 | Please see Preparing the MSys+MinGW system and "Building FFmpeg SVN statically" links on the following page for instructions on how to setup MSys and MinGW for building FFmpeg : |
| | 54 | http://ffmpeg.arrozcru.org/wiki/index.php |
| | 55 | |
| | 56 | |
| | 57 | On the MSYS command-line to build ffmpeg in the ffmpeg svn checkout folder, issue: |
| | 58 | |
| | 59 | ./configure --enable-memalign-hack --enable-gpl --enable-postproc --enable-w32threads |
| 41 | | # Build VIC using Visual studio as normal. |
| 42 | | ~ |
| 43 | | ~ |
| 44 | | ~ |
| 45 | | ~ |
| 46 | | ~ |
| 47 | | ~ |
| 48 | | ~ |
| 49 | | ~ |
| 50 | | ~ |
| 51 | | ~ |
| 52 | | ~ |
| | 63 | On the MSYS command-line to build pthread-win32 2.8.0 in it's unpacked folder, issue: |
| | 64 | |
| | 65 | make clean GC-static |
| | 66 | cp -p pthread.h sched.h /usr/local/include/ |
| | 67 | cp -p libpthreadGC2.a /usr/local/lib/ |
| | 68 | |
| | 69 | |
| | 70 | On the MSYS command-line to build x264 in it's unpacked folder, issue: |
| | 71 | |
| | 72 | CFLAGS=-I/usr/local/include LDFLAGS=-L/usr/local/lib ./configure --disable-avis-input |
| | 73 | make |
| | 74 | make install |
| | 75 | |
| | 76 | Note: x264 must be built after pthread-win32 so that x264's configure can detect pthread support. |
| | 77 | |
| | 78 | |
| | 79 | VIC has an additional dependency on the MinGW zlib package which can be downloaded from: |
| | 80 | http://sourceforge.net/projects/mingw/files/ |
| | 81 | |
| | 82 | |
| | 83 | The Release GPL version of VIC will fail to link in VS2008 if the following isn't performed on the "Visual Studio 2008 Command Prompt" console: |
| | 84 | |
| | 85 | cd C:\MinGW\lib |
| | 86 | lib -remove:mbrtowc.o libmingwex.a |
| | 87 | lib -remove:wcrtomb.o libmingwex.lib |
| | 88 | |
| | 89 | Note: the last line has libmingwex.lib and the previous libmingwex.a |
| | 90 | |
| | 91 | |
| | 92 | [Optional] to reduce the size of vic.exe, strip the debugging info from the MinGW, ffmpeg and x264 libraries, on the MSYS command-line issue : |
| | 93 | |
| | 94 | cd /mingw/lib |
| | 95 | strip -x *.a |
| | 96 | cd /usr/local/lib/ |
| | 97 | strip -x *.a |
| | 98 | |
| | 99 | |
| | 100 | To build GPL VIC with VS2008, select Release or Debug in the "Solutions Configuration" drop down menu, then click 'Configuration Manger..." in the same menu and select Debug (GPL) or Release (GPL). |