Install the autotools suite:
pacman -S git subversion cvs automake autoconf libtool m4 make gettext pkg-config mingw-w64-i686-lua findutils mingw-w64-i686-headers yasm patch
Download gcc from: mingw-w64.
Unzip it to C:\MSys2\
Exit MSys2, run autorebase.bat and re-run MSys2 from mingw32_shell.bat
Run
gcc -v
And check that it says
Thread model: win32 gcc version 4.9.2 (i686-win32-sjlj-rev0, Built by MinGW-W64 project)
YOU MUST keep the native line-endings of the repo.
git config core.autocrlf=false
Clone the git repo
git clone git://git.videolan.org/vlc.git
Nota Bene: ensure your Windows user name does not contain spaces so that the cloning folder of VLC will not not have spaces in it.
cd vlc/contrib mkdir win32 && cd win32 ../bootstrap --build=i686-w64-mingw32 make prebuilt
Note: check that all is well with moc -v
In VLC root folder, do:
./bootstrap
mkdir win32 cd win32 sh ../extras/package/win32/configure.sh --host=i686-w64-mingw32 --disable-nls
Note: If you want any custom options, like "--disable-lua" or anything of that nature, you can append them.
make -j4
Note: If your <username> starts with the "u" or "x" character, change C:\MSys\1.0\home\<username>\config.h and double all backslashes in VLC_COMPILED_BY constant.
Once the compilation is done, build self-contained VLC packages with one of the following "make" commands:
make package-win-common
This will create a subdirectory named vlc-x.x.x with all the binaries with debugging symbols. You can run ./vlc.exe from there.
make package-win32-zip
(Same as above but will package the directory in a zip file).
make package-win32-exe
(Same as above but will also create an auto-installer package. You will need to have NSIS installed in its default location for this to work).
See Win32CompileMSYSTroubleShooting.
This howto was re-created by Jean-Baptiste Kempf and updated in June 2009, September 2009, December 2009 and March 2010.
It was updated in June 2010 by Vicne with the help of J-b, gnosygnu and MichaelMc
It was updated in July 2012 by gnosygnu. Note that there are several new notes in Win32CompileMSYSTroubleShooting. These reflect problems that were encountered on gnosygnu's setup (Windows XP SP3). Refer to this forum thread for more information.
This howto was re-re-created by Jean-Baptiste Kempf in September 2012 and updated until 2015, with MSys2
sh ../extras/package/win32/configure.sh --host=i686-w64-mingw32 --enable-update-check --disable-faad --disable-dvdread --enable-flac --enable-theora --disable-avcodec --disable-swscale --disable-merge-ffmpeg --enable-dca --enable-libass --enable-schroedinger --enable-goom --enable-caca --disable-qt --disable-skins2 --enable-sse --enable-mmx --enable-libcddb --enable-zvbi --disable-telx --disable-lua --disable-a52 -disable-chromecast
微信
支付宝