m-ab-s / media-autobuild_suite

This Windows Batchscript helps setup a Mingw-w64 compiler environment for building ffmpeg and other media tools under Windows.
GNU General Public License v3.0
1.49k stars 257 forks source link

build static ffmpeg release/6.1 fails #2641

Closed mojie126 closed 2 months ago

mojie126 commented 2 months ago

The test failed to compile on all branches except master. The tested branches include release/6.1 and release/7.0 Tags include n7.0 and n6.1.1

logs.zip

L4cache commented 2 months ago

You need a patch that was removed in https://github.com/m-ab-s/media-autobuild_suite/commit/64bf59ff7fe8fdb79769ac791403b43e06f455c6 What the patch does is just remove the -lHLSL -lOGLCompiler from ffmpeg configure.

The weird thing is, the master branch code contains those flags as well and don't make trouble. This problem was exist in master branch too, the patch was created to solve it, but somehow the problem just vanished without any change to those flags, magically, and the patch was removed (at least that's what I think that happened)

你需要一个在 https://github.com/m-ab-s/media-autobuild_suite/commit/64bf59ff7fe8fdb79769ac791403b43e06f455c6 中被移除了的 patch, 该 patch 的作用只是从 ffmpeg 的 configure 中删除 -lHLSL -lOGLCompiler。 可以在 commit 历史中找到这个 patch。 https://github.com/m-ab-s/mabs-patches/blob/386c19581166ade6edfe1c36ed5dda5fb7170ff5/ffmpeg/0001-glslang-Remove-HLSL-and-OGLCompiler-libraries.patch

mojie126 commented 2 months ago

哥,还是我...咱说中文吧,省的还得谷歌翻译...

mojie126 commented 2 months ago

https://raw.githubusercontent.com/m-ab-s/mabs-patches/master/ffmpeg/0001-glslang-Remove-HLSL-and-OGLCompiler-libraries.patch 这个链接已经是404了

L4cache commented 2 months ago

你可以 fork 一个 ffmpeg 手动改,或者自己做一个 patch,也可以从 commit 历史中死者苏生 https://github.com/m-ab-s/mabs-patches/blob/a5c19970c4aa9024349947dea34168c15bd3f725/ffmpeg/0001-glslang-Remove-HLSL-and-OGLCompiler-libraries.patch

mojie126 commented 2 months ago

这个补丁已经弄上了,但是出了新的错误... logs.zip

LigH-de commented 2 months ago

It would be lovely if you could return to English, I do not understand Japanese.

mojie126 commented 2 months ago

this is chinese After applying the above patch, the branches release7.0 and release6.1 reported errors when compiling. The specific error is:

D:/CLionProjects/ma/build/ffmpeg-git/libavformat/file.c: In function 'fd_dup':
D:/CLionProjects/ma/build/ffmpeg-git/libavformat/file.c:210:9: error: implicit declaration of function 'fcntl' [-Werror=implicit-function-declaration]
  210 |     if (fcntl(newfd, F_SETFD, FD_CLOEXEC) == -1)
      |         ^~~~~
D:/CLionProjects/ma/build/ffmpeg-git/libavformat/file.c:210:22: error: 'F_SETFD' undeclared (first use in this function)
  210 |     if (fcntl(newfd, F_SETFD, FD_CLOEXEC) == -1)
      |                      ^~~~~~~
D:/CLionProjects/ma/build/ffmpeg-git/libavformat/file.c:210:22: note: each undeclared identifier is reported only once for each function it appears in
D:/CLionProjects/ma/build/ffmpeg-git/libavformat/file.c:210:31: error: 'FD_CLOEXEC' undeclared (first use in this function); did you mean 'FD_CLOSE'?
  210 |     if (fcntl(newfd, F_SETFD, FD_CLOEXEC) == -1)
      |                               ^~~~~~~~~~
      |                               FD_CLOSE
cc1.exe: some warnings being treated as errors
mojie126 commented 2 months ago

It seems that all branch compilations now report errors. master, release/7.0, release/6.1 logs.zip

L4cache commented 2 months ago

That looks a lot like some problem specific to your environment, maybe you can try completely start from scratch, remove the non-ascii characters from your environment variables, or run m-ab-s in a virtual machine?