rdp / ffmpeg-windows-build-helpers

Helper script for cross compiling some media tools for windows, like customizable ffmpeg.exe (with or without non-free components, etc), and some other bonuses like mplayer, mp4box, mxf, etc.
GNU General Public License v3.0
1.07k stars 409 forks source link

Problems cross compiling on Debian 9 for target win64 #354

Open yethie opened 5 years ago

yethie commented 5 years ago

Hello,

I ran the script on a debian 9 machine, targeting win64 and enabling non-free support. I got a fatal error while building tesseract:

checking build system type... x86_64-pc-linux-gnu
checking host system type... x86_64-w64-mingw32
./configure: line 4220: syntax error near unexpected token `-mavx,'
./configure: line 4220: `AX_CHECK_COMPILE_FLAG(-mavx, avx=true, avx=false)'

I removed the support for tesseract and the build completed successfully. But the executables do not work as expected, when encoding a file with the libvpx encoder the program exits almost immediately with a segmentation fault error. Encoding the same video with libx264 works fine.

Is there anything I can do to help on this issue? Thanks!

rdp commented 5 years ago

Does it link for you if you remove the fno... Part from vpx' configure? That's recent...

On Tuesday, November 6, 2018, yethie notifications@github.com wrote:

Hello,

I ran the script on a debian 9 machine, targeting win64 and enabling non-free support. I got a fatal error while building tesseract:

checking build system type... x86_64-pc-linux-gnu checking host system type... x86_64-w64-mingw32 ./configure: line 4220: syntax error near unexpected token -mavx,' ./configure: line 4220:AX_CHECK_COMPILE_FLAG(-mavx, avx=true, avx=false)'

I removed the support for tesseract and the build completed successfully. But the executables do not work as expected, when encoding a file with the libvpx encoder the program exits almost immediately with a segmentation fault error. Encoding the same video with libx264 works fine.

Is there anything I can do to help on this issue? Thanks!

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub, or mute the thread.< https://ci5.googleusercontent.com/proxy/nf2b_WTSndIdl-0QI_l3UAluDL5CkrAEtaEx1-Dk_1vuPh4gbUJyfaPb5LMzmF-FXwTtQy9mS8IEeU1pW6Y1m-Du0gmWRv3PAPgBbio4mdDij9TkW_llcf8iqvMhnZxf6g-5O9jxV04yM8zx_S4cPFq00g=s0-d-e1-ft#https://github.com/notifications/beacon/AAAw0LW8J6ssHzl55xUz4ApIK2DFBbwPks5usU7QgaJpZM4YQAMN.gif>

yethie commented 5 years ago

No, if I remove the fno... part the compiler complains with this message:

/tmp/ccLGT9SD.s: Assembler messages:
/tmp/ccLGT9SD.s:19: Error: invalid register for .seh_savexmm
Makefile:155: recipe for target 'vpx_dsp/x86/sad4d_avx512.c.o' failed
make[1]: *** [vpx_dsp/x86/sad4d_avx512.c.o] Error 1
make[1]: *** Waiting for unfinished jobs....
Makefile:17: recipe for target '.DEFAULT' failed
ghost commented 5 years ago

I fixed it with with following steps:

  1. Install additional dependency for building libtesseract: sudo apt install autoconf-archive

  2. Add the following line "./autogen.sh" to cross_compile_ffmpeg.sh into this function:

  build_libtesseract() {
  build_libleptonica
  build_libtiff # no disable configure option for this in tesseract? odd...
  do_git_checkout https://github.com/tesseract-ocr/tesseract.git tesseract_git a2e72f258a3bd6811cae226a01802d # #315
  cd tesseract_git
  ./autogen.sh # <-------
  generic_configure_make_install
  ...

For reference:

jftuga commented 5 years ago

I would like to independently confirm that this is a problem on Debian 9.6 for target Win64.

@8pr previous post fixed this issue for me.

Phane7 commented 4 years ago

This problem is either still present or has re-emerged. Debian 10 host, same fix works.