How To Compile xvid_encraw

0c

Friday, January 4, 2013

The easy way is to insall Microsoft Visual Studio 2008 from here ---> http://www.microsoft.com/en-my/download/details.aspx?id=20682
Install Microsoft Visual C++ 2008 (from the link above) and nasm from here ---> http://sourceforge.net/projects/nasm/
Open Visual C++ 2008, and go to Tools->Options->Projects and Solutions->VC++ Directories and add the folder where nasm was installed (click on the small yellow folder icon)
Go to File->Open->Project/Solution and select file from the source folder xvidcore/build/win32/libxvidcore.sln
Click Yes to load the existing project
Click Yes To All to convert the projects
You will get some errors (maybe e.g, cannot load because it's corrupted) but just ignore it
Just click Yes to all the warnings
Make sure the Active configuration is 'libxvidcore Win32 Release'
 - Go to Build --> Configuration Manager... and select Release and Win32
Finally, press F7 to build xvidcore.dll first
Wait until it finished
Then right click on xvid_encraw (on the left pane) and click Project Only -> Build Only xvid_encraw
Wait until it finished
The binary will be in xvidcore/build/win32/bin folder
You will need the xvidcore.dll and xvid_encraw.exe to be in the same folder in order to use it


The instructions below somehow works, but it might be wrong.
 IGNORE BELOW
1. Install MinGW from here ---> http://sourceforge.net/projects/mingw/files
1.1 Download yasm from here ---> http://yasm.tortall.net/Download.html (according to your windows version 32bit and 64bit)
1.2 Rename the file yasm-1.0.1-win32 to yasm and then copy it to C:\MinGW\bin
1.3 Go to http://www.mingw.org/wiki/Getting_Started
1.4 Scroll down to Environment Settings part, and follow the instructions on how to add PATH.
2. Download xvid source from here ---> http://jawormat.republika.pl/xvid.html
3. Extract it to C:\xvid_source
3.1 Go to folder C:\xvid_source\xvidcore\examples and open a file called Makefile using a Notepad (or any text editor)
3.2 Replace a line:
LDFLAGS = -lc -lm ../build/generic/=build/$(STATIC_LIB) -lpthread
to
LDFLAGS = -lm ../build/generic/=build/$(STATIC_LIB) -lavifil32 -lole32 -lpthread
Save it ( without any extension)
4. After that, open a program Start-->All Programs-->MinGW-->MinGW Shell (right click Run As Administrator)
5. A small window will appear
6. Type this: cd "c:/xvid_source/xvidcore/build/generic" (this is to change the directory to folder "generic")
7. Type this: ./bootstrap.sh (and then wait until it finished)
8. Type this: ./configure (and then wait until it finished)
9. Type this: make (and then wait until it finished)
10. Type this: make install (and then wait until it finished)
11. Type this: cd "c:/xvid_source/xvidcore/examples" (this is to change the directory to folder "examples")
12. Type this: make (and then wait until it finished)
13. The file xvid_encraw.exe should be in C:\xvid_source\xvidcore\examples folder
14. Enjoy

0 comments:

Post a Comment

Echo V6 © 2010