Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build ffmpeg for win32 #168

Closed
totaam opened this issue Jul 18, 2012 · 6 comments
Closed

Build ffmpeg for win32 #168

totaam opened this issue Jul 18, 2012 · 6 comments

Comments

@totaam
Copy link
Collaborator

totaam commented Jul 18, 2012

Issue migrated from trac ticket # 168

component: platforms | priority: major | resolution: duplicate

2012-07-18 09:03:39: ahuillet created the issue


We have many problems with the pre-made builds of ffmpeg for win32, and they are much bigger than our needs. It therefore makes sense to build it ourselves, using only the components we need, and a stable release number instead of git revisions.

To build ffmpeg for win32, you need to set up mingw32.

Then, until the following ticket is fixed, you need to patch the "configure" script.
http://ffmpeg.org/trac/ffmpeg/ticket/349?cversion=2&cnum_hist=3

# must change
#        SLIB_EXTRA_CMD='-lib.exe /machine:$(LIBTARGET)  def:$$(@:$(SLIBSUF)=.def) /out:$(SUBDIR)$(SLIBNAME:$(SLIBSUF)=.lib)'
#to         SLIB_EXTRA_CMD=-'i486-mingw32-dlltool -m $(LIBTARGET) -d $$(@:$(SLIBSUF)=.def) -l $(SUBDIR)$(SLIBNAME:$(SLIBSUF)=.lib) -D $(SLIBNAME_WITH_MAJOR)'

Change "i486-mingw32-dlltool" to the name for your mingw32 dlltool. (Sometimes i686-pc-mingw32-dlltool, ...).

Then:

./configure --disable-filters --disable-indevs --disable-encoders --disable-muxers --disable-avfilter --enable-runtime-cpudetect --disable-network --enable-gpl --enable-shared --enable-memalign-hack --disable-ffplay --disable-ffprobe --disable-ffserver --disable-ffmpeg --disable-dxva2 --cross-prefix=i486-mingw32- --enable-cross-compile --target-os=mingw32 --arch=x86  --prefix=/tmp/mingw32_ffmpeg_ah 
make
make install

Notes:

  • build hasn't been tested yet
  • dxva2 is not built but it should - my mingw is missing dxva headers and I don't know where to find them
@totaam
Copy link
Collaborator Author

totaam commented Jul 23, 2012

2012-07-23 18:21:14: antoine commented


See also #159

@totaam
Copy link
Collaborator Author

totaam commented Feb 16, 2013

2013-02-16 03:38:42: antoine changed status from new to closed

@totaam
Copy link
Collaborator Author

totaam commented Feb 16, 2013

2013-02-16 03:38:42: antoine changed resolution from ** to duplicate

@totaam
Copy link
Collaborator Author

totaam commented Feb 16, 2013

2013-02-16 03:38:42: antoine commented


Moving to #253 (ahuillet: this is months old!)

@totaam totaam closed this as completed Feb 16, 2013
@totaam
Copy link
Collaborator Author

totaam commented Feb 20, 2017

2017-02-20 12:15:31: antoine commented


See also #678 as we now get our ffmpeg win32 builds from msys2.

@totaam
Copy link
Collaborator Author

totaam commented Sep 18, 2017

2017-09-18 05:50:45: antoine

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant