Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion. Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules. |
![]() |
#1 | Link |
Registered User
Join Date: Oct 2002
Location: France
Posts: 2,234
|
[GUIDE] x264 Build Tutorial
If moderators find this usefull enough, they can stick it.
Sorry in advance for the english mystakes, my english is not excellent. There was a tutorial on doom10 once, but as doom10 doesn't exist anymore, it's gone. It was from it i've learned my first steps. So, after a long struggle and gathering of informations, i've finaly been able to get a working process, to compile x264. I've first severals peoples to thanks, without them, i wouldn't been able to succed. First komisar, who have been a great help. Have also been a great help, and give me others basis, the L-SMASH Works tutorial of Bruno Rex here. Thanks also to MasterNobody, LoRd_MuldeR and others i may forget. Now, begin the step by stop tutorial, begining form scratch. It's a Windows tutorial, but probably a lot of things can be used outside Windows. Last edited by jpsdr; 23rd September 2015 at 07:23. |
![]() |
![]() |
![]() |
#3 | Link |
Registered User
Join Date: Oct 2002
Location: France
Posts: 2,234
|
PART 1 : Building using MSYS2
Install of MSYS2 First, you have to install msys2, get the version you want (x86 and/or x64) here. Once installed, if leave to default, the installation directory will be C:\msys32 or C:\msys64, according you've installed the x86 or x64 version (or both). Whatever it is, i'll call it from now "msys2 dir". You'll also have 3 icons in "MSYS2 32bit" (or "MSYS2 64bit") menu. The msys2 shell, one mingw32 shell to build for x86 and one mingw64 shell to build for x64. You have to install the necessary packages to be able to build things. Start the msys2 shell, and inside use the following commands : Code:
pacman -Sy pacman -S --needed make autoconf autogen diffutils git p7zip patch perl python2 ruby subversion yasm wget mingw-w64-i686-gcc mingw-w64-i686-gettext mingw-w64-i686-crt-git mingw-w64-i686-libtool mingw-w64-i686-libjpeg-turbo mingw-w64-i686-libpng mingw-w64-i686-libxml2 mingw-w64-i686-tools-git mingw-w64-i686-glib2 pkg-config mingw-w64-i686-cmake nasm pacman -S --needed mingw-w64-x86_64-gcc mingw-w64-x86_64-gettext mingw-w64-x86_64-crt-git mingw-w64-x86_64-libtool mingw-w64-x86_64-libjpeg-turbo mingw-w64-x86_64-libpng mingw-w64-x86_64-libxml2 mingw-w64-x86_64-tools-git mingw-w64-x86_64-glib2 mingw-w64-x86_64-cmake Now, tools have been installed, now you should proceed with the update process, to be sure to have everything up to date. Note : If you've installed both the x86 and x64 version of msys2, you have to do this for both versions. Last edited by jpsdr; 2nd April 2017 at 10:12. |
![]() |
![]() |
![]() |
#4 | Link |
Registered User
Join Date: Oct 2002
Location: France
Posts: 2,234
|
Updates of MSYS2
msys2 is actualy active and frequenlty updated, so, it should be regularly updated. We will first update the core. Start the "msys2 shell", and inside use the following commands : Code:
pacman -Sy pacman --needed -S bash pacman pacman-mirrors msys2-runtime Code:
update-core Note : If your version of MSYS2 is even more recent, update-core is not working anymore. You have to do : Code:
pacman -Syuu Now, go in the "msys2 dir" and launch (double click on it) the autorebase.bat file. Once finished, restart again the "msys2 shell", and finish the update with the following command : Code:
pacman -Su Update is now finished. Note : Again, if you've installed both x86 and x64 versions of msys2, you have to do this for both versions. Last edited by jpsdr; 1st April 2016 at 12:52. |
![]() |
![]() |
![]() |
#5 | Link |
Registered User
Join Date: Oct 2002
Location: France
Posts: 2,234
|
GIT install of programs
We will install all the necessery programs in one directory, you can of course do what you want, but for this tutorial, i'll follow this guideline. Create a "C:\x264_Prg\" directory. Inside "C:\x264_Prg\" create a "ffmpeg-stable" subdirectory, get the last stable version here and decompress and put it inside. In "ffmpeg-stable" directory create a "Build_x264" subdirectory. Inside "C:\x264_Prg\" Clone git l-smash from here. In "l-smash" directory create a "Build_x264" subdirectory. Inside "C:\x264_Prg\" Clone git ffms2 from here. In "ffms2" directory create a "Build_x264" subdirectory. Inside "C:\x264_Prg\" Clone git x264 from here or... you can clone git from my github here (at you own risk ![]() Now, that everything is installed, we will compile ffmpeg and others libs to create the libpack for building the several x264 versions. Last edited by jpsdr; 17th February 2016 at 14:42. |
![]() |
![]() |
![]() |
#6 | Link |
Registered User
Join Date: Oct 2002
Location: France
Posts: 2,234
|
FFMPEG
In "C:\x264_Prg\" create a file named Build_ffmpeg_x264.sh. Put the following inside : Code:
cd ./ffmpeg-stable/Build_x264 _dir="/local-x264" [[ "$1" = "32" ]] && _dir="${_dir}_x86" [[ "$1" = "64" ]] && _dir="${_dir}_x64" [[ "$2" = "posix" ]] && _dir="${_dir}/posix" [[ "$2" = "win32" ]] && _dir="${_dir}/Win32threads" [[ "$3" = "original" ]] && _dir="${_dir}/Original" [[ "$3" = "tmod" ]] && _dir="${_dir}/t_mod" [[ "$3" = "jpsdr" ]] && _dir="${_dir}/jpsdr" _arch="x86" _cf="-mfpmath=sse -march=pentium3 -msse -mtune=pentium3" _ld="-static" _threads="--enable-pthreads --disable-w32threads" _cpu="--cpu=pentium3" _extra="--enable-avresample --disable-hwaccels --disable-network --disable-bsfs --disable-indevs --disable-outdevs --disable-devices --disable-avdevice --disable-d3d11va" [[ "$3" = "tmod" ]] && _extra="${_extra} --enable-protocol=file --enable-swscale --enable-version3 --enable-nonfree" [[ "$3" = "tmod" ]] && _extra="${_extra} --disable-decoder=alac,amrnb,amrwb,ape,ass,atrac1,atrac3,atrac3p,ccaption,mpc7,mpc8,mpl2,msmpeg4_crystalhd,nellymoser,opus,paf_audio,comfortnoise,cook,dsd_*,dsicinaudio,dvbsub,dvdsub,evrc,g723_1,g729,pgssub,pictor,pjs,qcelp,qdm2,ra_144,ra_288,ralf,realtext,roq_dpcm,sami,shorten,sipr,smackaud,sol_dpcm,sonic,srt,ssa,stl,subrip,subviewer,subviewer1,tak,text,gsm,gsm_ms,iac,idf,imc,interplay_dpcm,jacosub,lib*,mace3,mace6,metasound,microdvd,movtext,truespeech,tta,twinvq,vc1_crystalhd,vc1_vdpau,ws_snd1,xan_dpcm,xbin,xsub" [[ "$3" = "jpsdr" ]] && _extra="${_extra} --enable-protocol=file --enable-swscale --enable-version3 --enable-nonfree" [[ "$3" = "jpsdr" ]] && _extra="${_extra} --disable-decoder=alac,amrnb,amrwb,ape,ass,atrac1,atrac3,atrac3p,ccaption,mpc7,mpc8,mpl2,msmpeg4_crystalhd,nellymoser,opus,paf_audio,comfortnoise,cook,dsd_*,dsicinaudio,dvbsub,dvdsub,evrc,g723_1,g729,pgssub,pictor,pjs,qcelp,qdm2,ra_144,ra_288,ralf,realtext,roq_dpcm,sami,shorten,sipr,smackaud,sol_dpcm,sonic,srt,ssa,stl,subrip,subviewer,subviewer1,tak,text,gsm,gsm_ms,iac,idf,imc,interplay_dpcm,jacosub,lib*,mace3,mace6,metasound,microdvd,movtext,truespeech,tta,twinvq,vc1_crystalhd,vc1_vdpau,ws_snd1,xan_dpcm,xbin,xsub" [[ "$3" = "original" ]] && _extra="${_extra} --disable-protocols --enable-protocol=file" [[ "$3" = "original" ]] && _extra="${_extra} --disable-muxers --enable-muxer=avi,rawvideo,yuv4mpegpipe" [[ "$3" = "original" ]] && _extra="${_extra} --disable-encoders --disable-filters" [[ "$3" = "original" ]] && _extra="${_extra} --disable-parser=aac,aac_latm,ac3,cook,dca,dvbsub,dvd_nav,dvdsub,flac,gsm,mlp,mpegaudio,opus,tak,vorbis" [[ "$3" = "original" ]] && _extra="${_extra} --disable-demuxer=aac,ac3,act,adf,adp,adx,aea,afc,aiff,amr,apc,ape,aqtitle,ass,ast,au,avr,bintext,bit,boa,brstm,caf,concat,daud,dsf,dts,dtshd,ea_cdata,eac3,epaf,ffmetadata,flac,g722,g723_1,g729,gsm,srt,stl,subviewer,subviewer1,sup,tak,tedcaptions,truehd,idf,ilbc,ircam,iss,jacosub,latm,libgme,libquvi,live_flv,loas,lrc,microdvd,mlp,mmf,mp3,mpc,mpc8,mpl2,mpsub,tta,txd,vobsub,voc,vplayer,vqf,w64,wav,msnwc_tcp,nistsphere,ogg,oma,pcm_*,pjs,pvf,qcp,realtext,redspark,rsd,rso,rtp,rtsp,sami,sap,sbg,sdp,shorten,sln,sol,sox,spdif,webm_dash_manifest,webvtt,wsaud,wv,xa,xwma" [[ "$3" = "original" ]] && _extra="${_extra} --disable-decoder=aac,aac_latm,ac3,ac3_fixed,adpcm_*,alac,amrnb,amrwb,ape,ass,atrac1,atrac3,atrac3p,ccaption,mp3,mp3adu,mp3adufloat,mp3float,mp3on4,mp3on4float,mpc7,mpc8,mpeg1_vdpau,mpeg2_crystalhd,mpeg4_crystalhd,mpeg4_vdpau,mpeg_vdpau,mpeg_xvmc,mpl2,msmpeg4_crystalhd,nellymoser,opus,paf_audio,pcm_*,binkaudio_*,bmv_audio,comfortnoise,cook,dca,dsd_*,dsicinaudio,dvbsub,dvdsub,eac3,evrc,ffwavesynth,flac,g723_1,g729,pcm_*,pgssub,pictor,pjs,qcelp,qdm2,ra_144,ra_288,ralf,realtext,roq_dpcm,sami,shorten,sipr,smackaud,sol_dpcm,sonic,srt,ssa,stl,subrip,subviewer,subviewer1,tak,text,gsm,gsm_ms,h264_crystalhd,h264_vda,h264_vdpau,iac,idf,imc,interplay_dpcm,jacosub,lib*,mace3,mace6,metasound,microdvd,mlp,movtext,mp1,mp1float,mp2,mp2float,truehd,truespeech,tta,twinvq,vc1_crystalhd,vc1_vdpau,vmdaudio,vorbis,vplayer,wavpack,webvtt,wma*,wmv3_crystalhd,wmv3_vdpau,ws_snd1,xan_dpcm,xbin,xsub" [[ "$1" = "64" ]] && _arch="${_arch}_64" [[ "$3" = "original" ]] && _cf="${_cf} -U__STRICT_ANSI__" [[ "$3" = "jpsdr" ]] && _cf="" [[ "$1" = "64" ]] && _cf="-m64" [[ "$3" = "jpsdr" ]] && _cf="${_cf} -mfpmath=sse -march=haswell -mavx -mavx2 -mtune=haswell" [[ "$1" = "64" ]] && _ld="${_ld} -m64" [[ "$2" = "win32" ]] && _threads="--disable-pthreads --enable-w32threads" [[ "$1" = "64" ]] && _cpu="" [[ "$3" = "jpsdr" ]] && _cpu="--cpu=haswell" ../configure --prefix=${_dir} --target-os=mingw32 --arch=${_arch} \ --extra-cflags="${_cf}" --extra-ldflags="${_ld}" \ --enable-static --disable-shared ${_threads} --enable-gpl \ --disable-debug --disable-programs --disable-doc \ ${_extra} \ --enable-runtime-cpudetect --enable-memalign-hack --enable-postproc ${_cpu} make -j1 make install make clean Warning : It seems for ffmpeg that to compile for x64, you have to be under an x64 OS. In the mingw shell you have opened, go into the "C:\x264_Prg\" directory with the following command : Code:
cd c:/x264_Prg Code:
./Build_ffmpeg_x264.sh param1 param2 param3 param1 : 32 or 64 : You will set if you target x86 or x64. You must nevertheless have launched the proper mingw shell. param2 : posix or win32 : You will set if you will compile using posix or win32 threads. param3 : original, tmod or jpsdr (well... this is the script i'm using... ![]() - original : You'll build the libraries for original version, don't need to much extra, will just be a little smaller. - tmod : You'll build the libraries for tmod and others versions, add a little more stuff. - jpsdr : Identical to tmod, but compile targeting haswell cpu and use of avx/avx2 instructions. Not checked, but probably works only of you have an haswell on the PC you compile with. Build all the versions you need, and be patient... Now, we'll build l-smash. Last edited by jpsdr; 18th January 2016 at 20:53. |
![]() |
![]() |
![]() |
#7 | Link |
Registered User
Join Date: Oct 2002
Location: France
Posts: 2,234
|
l-smash
Warning : If you want to build the t_mod version of x264, you have to create a branch (with GIT, for exemple a branch named "x264_build") and apply the patch described here. Before building, don't forget to git pull to get up to date version, and fecth&rebase if you've created a "x264_build" branch. In "C:\x264_Prg\" create a file named Build_lsmash_x264.sh. Put the following inside : Code:
cd ./l-smash/Build_x264 _dir="/local-x264" [[ "$1" = "32" ]] && _dir="${_dir}_x86" [[ "$1" = "64" ]] && _dir="${_dir}_x64" [[ "$2" = "posix" ]] && _dir="${_dir}/posix" [[ "$2" = "win32" ]] && _dir="${_dir}/Win32threads" [[ "$3" = "original" ]] && _dir="${_dir}/Original" [[ "$3" = "tmod" ]] && _dir="${_dir}/t_mod" [[ "$3" = "jpsdr" ]] && _dir="${_dir}/jpsdr" _ld="-static" _cf="" [[ "$3" = "jpsdr" ]] && _cf="-march=haswell -mavx -mavx2 -mtune=haswell" [[ "$1" = "64" ]] && _ld="${_ld} -m64" [[ "$1" = "64" ]] && _cf="${_cf} -m64" PKG_CONFIG_PATH="${_dir}/lib/pkgconfig" \ ../configure --prefix=${_dir} --extra-ldflags="${_ld}" --extra-cflags="${_cf}" make -j1 lib make install make clean Code:
./Build_lsmash_x264.sh param1 param2 param3 Build all the versions you need, and... this time it'll be a lot faster. Now, we'll build ffms2. Last edited by jpsdr; 1st November 2015 at 10:15. |
![]() |
![]() |
![]() |
#8 | Link |
Registered User
Join Date: Oct 2002
Location: France
Posts: 2,234
|
ffms2
For ffms2, you need to make a little patch to use it with x264. Create a git branch called "x264_build", and make the following change in include\ffms.h, replace : Code:
// And now for some symbol hide-and-seek... #if defined(_WIN32) // MSVC # if defined(FFMS_EXPORTS) // building the FFMS2 library itself, with visible API symbols # define FFMS_API(ret) FFMS_EXTERN_C __declspec(dllexport) ret FFMS_CC Code:
// And now for some symbol hide-and-seek... #if defined(_MSC_VER) // MSVC # if defined(FFMS_EXPORTS) // building the FFMS2 library itself, with visible API symbols # define FFMS_API(ret) FFMS_EXTERN_C __declspec(dllexport) ret FFMS_CC Commit, and now you have your own branch ready for x264 use. Before building, don't forget to git pull to get up to date version, and fecth&rebase. In "C:\x264_Prg\" create a file named Build_ffms2_x264.sh. Put the following inside : Code:
cd ./ffms2/Build_x264 _dir="/local-x264" [[ "$1" = "32" ]] && _dir="${_dir}_x86" [[ "$1" = "64" ]] && _dir="${_dir}_x64" [[ "$2" = "posix" ]] && _dir="${_dir}/posix" [[ "$2" = "win32" ]] && _dir="${_dir}/Win32threads" [[ "$3" = "original" ]] && _dir="${_dir}/Original" [[ "$3" = "tmod" ]] && _dir="${_dir}/t_mod" [[ "$3" = "jpsdr" ]] && _dir="${_dir}/jpsdr" _lav_l="-L${_dir}/lib -lswscale -lavformat -lavcodec -lavutil -lm -lbz2 -lz -lpsapi -ladvapi32 -lshell32" _lav_c="-I${_dir}/include" _av_l="-L${_dir}/lib -lavresample -lavutil -lm" _av_c="-I${_dir}/include" [[ "$2" = "posix" ]] && _lav_l="${_lav_l} -pthread" [[ "$3" = "tmod" ]] && _lav_l="${_lav_l} -lavresample -lswresample -lavfilter -lpostproc" [[ "$3" = "jpsdr" ]] && _lav_l="${_lav_l} -lavresample -lswresample -lavfilter -lpostproc" [[ "$3" = "original" ]] && _av_l="" [[ "$3" = "original" ]] && _av_c="" _cf="-Wno-deprecated-declarations" _cxx="-Wno-deprecated-declarations" _ld="-static" [[ "$3" = "jpsdr" ]] && _cf="${_cf} -march=haswell -mavx -mavx2 -mtune=haswell" [[ "$3" = "jpsdr" ]] && _cxx="${_cxx} -march=haswell -mavx -mavx2 -mtune=haswell" [[ "$1" = "64" ]] && _cf="${_cf} -m64" [[ "$1" = "64" ]] && _cxx="${_cxx} -m64" [[ "$1" = "64" ]] && _ld="${_ld} -m64" _host="i686-w64-mingw32" [[ "$1" = "64" ]] && _host="x86_64-w64-mingw32" PKG_CONFIG_PATH="${_dir}/lib/pkgconfig" \ CFLAGS="${_cf}" \ CXXFLAGS="${_cxx}" \ LDFLAGS="${_ld}" \ ../configure --prefix=${_dir} --build="i686-w64-mingw32" --host=${_host} \ --enable-static --disable-shared make -j1 make install make clean Code:
./Build_ffms2_x264.sh param1 param2 param3 Build all the versions you need, and... this time it'll be also faster. Now, we are finaly ready for the final chapter of this first part, building x264. Last edited by jpsdr; 24th September 2015 at 11:51. |
![]() |
![]() |
![]() |
#9 | Link |
Registered User
Join Date: Oct 2002
Location: France
Posts: 2,234
|
x264
After the long road, we finaly reach the final destination. Before building, don't forget to git pull to get up to date version, and fecth&rebase if necessary. In "C:\x264_Prg\x264" (or any name you put your x264 git cloned files) create a file named Build_x264.sh. Put the following inside : Code:
_dir="/local-x264" [[ "$1" = "32" ]] && _dir="${_dir}_x86" [[ "$1" = "64" ]] && _dir="${_dir}_x64" [[ "$2" = "posix" ]] && _dir="${_dir}/posix" [[ "$2" = "win32" ]] && _dir="${_dir}/Win32threads" [[ "$3" = "original" ]] && _dir="${_dir}/Original" [[ "$3" = "tmod" ]] && _dir="${_dir}/t_mod" [[ "$3" = "jpsdr" ]] && _dir="${_dir}/jpsdr" _cf="" _ld="-static" _extra="--disable-opencl --enable-static --enable-strip" [[ "$3" = "jpsdr" ]] && _cf="${_cf} -march=haswell -mavx -mavx2 -mtune=haswell" [[ "$1" = "64" ]] && _extra="${_extra} --host=x86_64-w64-mingw32" [[ "$2" = "posix" ]] && _extra="${_extra} --disable-win32thread" [[ "$4" = "10" ]] && _extra="${_extra} --bit-depth=10" [[ "$3" = "tmod" ]] && _extra="${_extra} --enable-nonfree" [[ "$3" = "jpsdr" ]] && _extra="${_extra} --enable-nonfree" PKG_CONFIG_PATH="${_dir}/lib/pkgconfig" \ ./configure --extra-cflags="${_cf}" --extra-ldflags="${_ld}" ${_extra} make Code:
make fprofiled VIDS="[your video path file]" In the mingw shell, change directory for the one you have x264 in : Code:
cd x264 And then, launch the building script with the following command : Code:
./Build_x264.sh param1 param2 param3 param4 param4 : 8 or 10 : You will set the bit depth you want to create. Now, if you've for exemple compiled everything with the following parameters : 32 win32 tmod, when using the following command on the t_mod version : Code:
./Build_x264.sh 32 win32 tmod 8 Code:
platform: X86 byte order: little-endian system: WINDOWS cli: yes libx264: internal shared: no static: yes asm: yes interlaced: yes avs: avisynth lavf: yes ffms: yes avi output: yes audio: yes (raw, lavc) mp4: lsmash gpl: yes nonfree: yes thread: win32 opencl: no filters: resize crop select_every hqdn3d pad vflip subtitles yadif debug: no gprof: no strip: yes LTO: no PIC: no bit depth: 8 chroma format: all Last edited by jpsdr; 18th January 2016 at 16:45. |
![]() |
![]() |
![]() |
#10 | Link |
Registered User
Join Date: Oct 2002
Location: France
Posts: 2,234
|
PART 2 : Using MSYS and komisar's builds
This will describe a different way to build x264, it was basicaly the way described in the doom10 tutorial, and it's the way i've begun with, and used during a long time. You can use both method on the same PC. Install of MinGW Create the following directory : "C:\MinGW" Get one gcc version here. Unpack it inside the "C:\MinGW" directory. Get the last win32 yasm version here (actualy when i'm writing this it's the yasm-1.3.0-win32.exe). Rename the file in yasm.exe and put it in "C:\MinGW\bin". Last edited by jpsdr; 9th October 2015 at 10:43. |
![]() |
![]() |
![]() |
#11 | Link |
Registered User
Join Date: Oct 2002
Location: France
Posts: 2,234
|
Install of MSYS
Note : This can be installed even with MSYS2 is installed, they are in different directories, and don't interfer with each others, unless you force things to mess up on purpose ![]() First, get MSYS-1.0.11.exe here and install it. When prompted for the mingw location, enter the directory where you've put komisar's gcc build (it should be "C:/MinGW" if you haven't changed the default of this tutorial). Possible stop point It could be enough if you just want to compile x264, and use the packlibs of komisar for ffmpeg and all. It was what i've done during a long time. But, you're bound to komisar's builds of libpack, which is largely enough for standard x264, but not for t_mod version for exemple. Don't misunderstand me, komisar is doing great job providing what is providing, i'm just saying that if you want more, learn how to do it and do it yourself. I must said that the learning process especialy for ffmpeg has been a little painfull... But if you want to build your own ffmpeg and all versions using this second method, installation continues. Get msysDTK-1.0.1.exe here, and install it. Now, all the others files to install are compressed files. They are not exe you install, but files you unpack and put directly on the msys directory. Browsing and searching inside here get all the following files and install them : Code:
bash-3.1.23-1-msys-1.0.18-bin.tar.xz bzip2-1.0.6-1-msys-1.0.17-bin.tar.lzma coreutils-5.97-3-msys-1.0.13-bin.tar.lzma coreutils-5.97-3-msys-1.0.13-ext.tar.lzma diffutils-2.8.7.20071206cvs-3-msys-1.0.13-bin.tar.lzma file-5.04-1-msys-1.0.13-bin.tar.lzma findutils-4.4.2-2-msys-1.0.13-bin.tar.lzma gawk-3.1.7-2-msys-1.0.13-bin.tar.lzma gettext-0.18.1.1-1-msys-1.0.17-bin.tar.lzma glib_2.34.3-1_win32.zip grep-2.5.4-2-msys-1.0.13-bin.tar.lzma gzip-1.3.12-2-msys-1.0.13-bin.tar.lzma less-436-2-msys-1.0.13-bin.tar.lzma libasprintf-0.18.1.1-1-msys-1.0.17-dll-0.tar.lzma libbz2-1.0.6-1-msys-1.0.17-dll-1.tar.lzma libcharset-1.14-1-msys-1.0.17-dll-1.tar.lzma libgettextpo-0.18.1.1-1-msys-1.0.17-dll-0.tar.lzma libiconv-1.14-1-msys-1.0.17-bin.tar.lzma libiconv-1.14-1-msys-1.0.17-dll-2.tar.lzma libintl-0.18.1.1-1-msys-1.0.17-dll-8.tar.lzma libltdl-2.4-1-msys-1.0.15-dll-7.tar.lzma liblzma-5.0.3-1-msys-1.0.17-dll-5.tar.lzma libmagic-5.04-1-msys-1.0.13-dll-1.tar.lzma libregex-1.20090805-2-msys-1.0.13-dll-1.tar.lzma libtermcap-0.20050421_1-2-msys-1.0.13-dll-0.tar.lzma libtool-2.4-1-msys-1.0.15-bin.tar.lzma locate-4.4.2-2-msys-1.0.13-bin.tar.lzma make-3.81-3-msys-1.0.13-bin.tar.lzma pkg-config_0.28-1_win32.zip sed-4.2.1-2-msys-1.0.13-bin.tar.lzma tar-1.23-1-msys-1.0.13-bin.tar.lzma termcap-0.20050421_1-2-msys-1.0.13-bin.tar.lzma texinfo-4.13a-2-msys-1.0.13-bin.tar.lzma xz-5.0.3-1-msys-1.0.17-bin.tar.lzma zlib-1.2.7-1-msys-1.0.17-dll.tar.lzma You can now launch the shell using either the "MSYS" icon created on desktop, or with menu : MinGW -> MSYS -> MSYS. Unlike the MSYS2 configuration, because using komisar's gcc version, there is no need for an x86 or an x64 specific mingw shell. But msys is a closed project, so there is no updates anymore or anything. You could have guessed, it's been replaced (or updated) by MSYS2. Last edited by jpsdr; 9th October 2015 at 10:44. |
![]() |
![]() |
![]() |
#13 | Link |
Registered User
Join Date: Oct 2002
Location: France
Posts: 2,234
|
ffms2
ffms2 will be more troublesome. Because of the way komisar's gcc is build, at least at the time i'm writing these lines, you can't compile version 2.21 and up, you can compile only until version 2.20. To compile, you have to make changes in the building script. You have to change this : Code:
_cf="-Wno-deprecated-declarations" _cxx="-Wno-deprecated-declarations" _ld="-static" Code:
_cf="-I${_dir}/include -Wno-deprecated-declarations" _cxx="-I${_dir}/include -Wno-deprecated-declarations" _ld="-L${_dir}/lib -static" #_cf="-Wno-deprecated-declarations" #_cxx="-Wno-deprecated-declarations" #_ld="-static" Code:
PKG_CONFIG_PATH="${_dir}/lib/pkgconfig" \ Code:
#PKG_CONFIG_PATH="${_dir}/lib/pkgconfig" \ LIBAV_LIBS="${_lav_l}" \ LIBAV_CFLAGS="${_lav_c}" \ AVRESAMPLE_LIBS="${_av_l}" \ AVRESAMPLE_CFLAGS="${_av_c}" \ |
![]() |
![]() |
![]() |
#15 | Link |
Registered User
Join Date: Oct 2002
Location: France
Posts: 2,234
|
x264
Now, the last step. You have to make changes in the building script also here, changing this : Code:
_cf="" _ld="-static" Code:
_cf="-I${_dir}/include -L${_dir}/lib" _ld="-I${_dir}/include -L${_dir}/lib -static" #_cf="" #_ld="-static" Code:
PKG_CONFIG_PATH="${_dir}/lib/pkgconfig" \ Code:
#PKG_CONFIG_PATH="${_dir}/lib/pkgconfig" \ You can also consider this as a guideline or canvas to help you understand all the necessary processes to build x264, to create you own specific way of building x264. It's of course a Windows tutorial, but i think it may also be used as guideline for others OS. |
![]() |
![]() |
![]() |
#16 | Link |
Registered User
Join Date: Sep 2014
Location: Nanjing, China
Posts: 18
|
Thanks a lot! I think it's a very useful tutorial.
Here is a 7mod x264 version which is very similar to tmod and still update with offical git. https://github.com/Freecom/x264 |
![]() |
![]() |
![]() |
#17 | Link | |
Registered User
Join Date: Jan 2013
Posts: 1
|
Nice gui! Stick it, plz, to the members as I easily search.
P/s: My build is ok? Quote:
|
|
![]() |
![]() |
![]() |
#20 | Link |
Registered User
Join Date: Oct 2002
Location: France
Posts: 2,234
|
No idea about static, but the .exe has always worked without the need of extenal dll. Maybe static is relevant only when building the library, not the exe...? No idea what strip is (well... i know the meaning of the word...
![]() Last edited by jpsdr; 9th October 2015 at 14:59. |
![]() |
![]() |
![]() |
Thread Tools | Search this Thread |
Display Modes | |
|
|