Dibya Posted November 17, 2018 Posted November 17, 2018 (edited) I have great luck compiling FFMPEG in Visual studio but unfortunately VS2013 is not installing on Windows 8.1 which i installed today freshly . I came across http://www.msys2.org/ can someone help me to compile ? Configure is not working Edited November 17, 2018 by Dibya
Dibya Posted November 17, 2018 Author Posted November 17, 2018 Msys2 seems to be a bloated tool chain. Can someone recommend me a another mysys style environment ? Anywhere offline binary of msys available?
FranceBB Posted November 17, 2018 Posted November 17, 2018 (edited) Ask Corone directly, he's the one that is supporting ffmpeg on WinXP. By the way, all you need is Visual Studio 2017, GCC and Perl via MSYS2 and YASM. Quote Msys2 seems to be a bloated tool chain Actually, it works fine on Windows Server 2019. Quote unfortunately VS2013 is not installing on Windows 8.1 I think you could try to use Visual Studio 2012 and MSYS, but please note that the code is not C89 complaint, so you would have to modify it. Anyway, which platform are you targeting? Unless you are targeting XP/Vista, every other platform is pretty straightforward. Just follow the guide on the official site Edited November 17, 2018 by FranceBB
Dibya Posted November 17, 2018 Author Posted November 17, 2018 (edited) @FranceBB I am targeting XP . Please can you be little more detailed. Latest visual studio that I have is Vs 2015 update 3 Why hell in earth configure command don't work in MSYS2? Edited November 17, 2018 by Dibya
FranceBB Posted November 17, 2018 Posted November 17, 2018 Download MSYS2: http://repo.msys2.org/distrib/x86_64/msys2-x86_64-20180531.exe Download and run the installer - "x86_64". Click "Next". Enter Installation Folder "C:\msys64". Tick Run MSYS2 now Update the package database and core system packages by typing the following command the MSYS2 console: pacman -Syu Update the make package: pacman -S make Install GCC: pacman -S gcc Remove link.exe in the MSYS2 usr bin folder (C:\msys64\usr\bin\link.exe) Install perl: pacman -S perl Install diffutils: pacman -S diffutils Download YASM: http://www.tortall.net/projects/yasm/releases/yasm-1.3.0-win64.exe Rename the downloaded executable to yasm.exe and place it in your MSYS2 path: "C:\msys64\usr\bin\yasm.exe". Download gas-preprocessor: https://github.com/FFmpeg/gas-preprocessor/blob/master/gas-preprocessor.pl Place the downloaded Perl script in your MSYS2 path: "C:\msys64\usr\bin\gas-preprocessor.pl". Launch VS2015 x86 x64 Cross Tools Command Prompt: C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Visual Studio 2015\Visual Studio Tools\Windows Desktop Command Prompts\VS2015 x86 x64 Cross Tools Command Prompt Set the following environment variables in the launched command prompt above: SET LIB=%VSINSTALLDIR%VC\lib\store\amd64;%VSINSTALLDIR%VC\atlmfc\lib\amd64;%UniversalCRTSdkDir%lib\%UCRTVersion%\ucrt\x64;;%UniversalCRTSdkDir%lib\%UCRTVersion%\um\x64;C:\Program Files (x86)\Windows Kits\NETFXSDK\4.6\lib\um\x64;;C:\Program Files (x86)\Windows Kits\NETFXSDK\4.6\Lib\um\x64 SET LIBPATH=%VSINSTALLDIR%VC\atlmfc\lib\amd64;%VSINSTALLDIR%VC\lib\amd64; SET INCLUDE=%VSINSTALLDIR%VC\include;%VSINSTALLDIR%VC\atlmfc\include;%UniversalCRTSdkDir%Include\%UCRTVersion%\ucrt;%UniversalCRTSdkDir%Include\%UCRTVersion%\um;%UniversalCRTSdkDir%Include\%UCRTVersion%\shared;%UniversalCRTSdkDir%Include\%UCRTVersion%\winrt;C:\Program Files (x86)\Windows Kits\NETFXSDK\4.6\Include\um; Open MSYS2 Shell from the command prompt above: C:\msys64\msys2_shell.cmd Download FFmpeg from GitHub (click "Clone/Download"): https://github.com/FFmpeg/FFmpeg Place the folder in C. In your MSYS2 shell navigate to your cloned FFmpeg folder: Invoke the following make commands: mkdir -p Output/Windows/x64 Then navigate to the newly created folder: cd Output/Windows/x64 Type the following commands: ../../../configure \ --toolchain=msvc \ --disable-programs \ --disable-d3d11va \ --disable-dxva2 \ --arch=x86_64 \ --enable-shared \ --enable-cross-compile \ --target-os=win32 \ --extra-cflags="-MD -DWINAPI_FAMILY=WINAPI_FAMILY_APP -D_WIN32_WINNT=0x0A00" \ --extra-ldflags="-APPCONTAINER WindowsApp.lib" \ --prefix=../../../Build/Windows/x64 make make install It will take quite some time to compile. Once everything is done, you'll find the binaries in "Build/Windows/x64". Please note that these binaries WILL NOT work on Windows XP/Vista x64. In order to make them work, you gotta disable more things, not just d3d11 and dxva2. For instance, VistaLover said that libmfx breaks XP as well, but I don't know what else. Besides, compiling ffmpeg to make it work on XP/Vista has become trickier with time. Last time I did it was a year ago; I have used Corone's build ever since. Your best shot is asking @CoRoNe what must be disabled. Cheers and regards. 1
Dibya Posted November 18, 2018 Author Posted November 18, 2018 I actually came here because my client wanted to have Standalone FFMPEG. when i wrote FFMPEG updated to 4.1 he wanted to have it. I use some portion of FFMPEG in my project. I failed to compile it standalone.. Here modified source which has w32pthread codes restored so that it runs on XP. https://mega.nz/#!fupEnKYD!ZVHN0KPfkn-v8FfUssUMeEF4X43RktoeZXYT-HZiXZ0 It is kinda based on https://github.com/tumagonx/XPitory/tree/master/static_port/ffmpeg --enable-nonfree --enable-gpl --enable-version3 --enable-small --enable-avresample --enable-avisynth --enable-chromaprint --enable-frei0r --enable-gnutls --enable-ladspa --enable-libass --enable-libbluray --enable-libbs2b - -enable-libcaca --enable-libcdio --enable-openal --enable-libdc1394 --enable-libfdk-aac --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgme --enable-libilbc --enable-libkvazaar --enable-libmodplug --enable-libmp3lame --enable-libnut --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopencv --enable-libopenh264 --enable-libopenjpeg --enable-libopenmpt --enable-libopus --enable-libpulse --enable-librubberband --enable-librtmp --enable-libschroedinger --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libssh --enable-libtesseract --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvo-amrwbenc --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxavs --enable-libxvid --enable-libzimg --enable-libzmq --enable-libzvbi --enable-decklink --enable-netcdf --enable-openal --enable-opencl --enable-opengl --enable-libmfx --disable-d3d11va --disable-avx --disable-avx2
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now