Build steps to reproduce Zeranoe ffmpeg builds?

Questions that occur when trying to compile FFmpeg.
iamstickfigure
Posts: 8
Joined: Wed May 08, 2019 11:14 pm

Build steps to reproduce Zeranoe ffmpeg builds?

Post by iamstickfigure » Wed May 08, 2019 11:34 pm

What are the specific build steps to reproduce the official Zeranoe ffmpeg builds?
https://ffmpeg.zeranoe.com/builds/
I am running everything within a Ubuntu VM in Virtualbox. (Let me know if this is a mistake)

So far, I've gathered that it is necessary to first build MinGW-w64, which I have done.
Beyond this point, what exactly are the "official" build steps? As in, what are the steps that were used to produced the Zeranoe builds?

In this forum, I've seen lots of recommended automated scripts that are capable of building or cross-compiling ffmpeg. But is there an automated script that was used to produce the Zeranoe ffmpeg builds specifically? Or were the builds "hand-crafted" each dependency cross-compiled manually?

The main reason why I'm asking this is because, when compared to the Zeranoe builds, there always seems to be something missing from many of the builds produced by the automated scripts. An example of this would be dxdva2 missing from ffmpeg-windows-build-helpers

hydra3333
Posts: 195
Joined: Sun Apr 28, 2013 1:03 pm
Contact:

Re: Build steps to reproduce Zeranoe ffmpeg builds?

Post by hydra3333 » Fri May 10, 2019 2:01 pm

Don't know.

This individual has a script which has a fairly decent dependency build list cross-compiling under ubuntu and can include OpenCL: https://github.com/DeadSix27/python_cro ... ile_script

Then there's this which also has a decent dependency build list compiling under Win10 and can include CUDA and OpenCL : https://github.com/jb-alvarado/media-autobuild_suite

My own pitiful unreliable effort based on DeadSix27's old formula cross-compiling under ubuntu, builds with CUDA and OpenCL.

Also note that dependencies change all the time and "break" building formulas as time goes by.
ICD_LOADER for nvidia OpenCL compatibility is a case in point, they changed stuff in the last week or so which broke the building process.
Another case in point is glib2 which moved to using meson/ninja and I can't get it to build (it refuses to find library dependency iconv) so I'm stuck with using an older version.

iamstickfigure
Posts: 8
Joined: Wed May 08, 2019 11:14 pm

Re: Build steps to reproduce Zeranoe ffmpeg builds?

Post by iamstickfigure » Fri May 10, 2019 10:38 pm

Thank you hydra. :-)

I've tried both of those. The one by DeadSix is really nice actually.
And they're close to reproducing the Zeranoe builds, but something is off.

Specifically, in my case, I get a "RTMP_Connect1, TLS_Connect failed" when I try livestreaming to an rtmps endpoint. So something is wrong with TLS. I'm using the same version of GnuTLS as the Zeranoe build. "GnuTLS 3.6.7.1"

Code: Select all

ffmpeg -re  -y -ss 00:00:00.000  -i "input.mp4"  -c:v copy -c:a aac -bsf:a aac_adtstoasc -f flv "rtmps://live-api-s.facebook.com:443/rtmp/xxxxxxxxxxxxx"
And I am not the first person to have this issue when cross-compiling ffmpeg for windows. There have been other posts on this forum about it with no replies.
The Zeranoe builds handle it flawlessly, so if I knew the exact steps to reproduce it, I won't have the issue.

hydra3333
Posts: 195
Joined: Sun Apr 28, 2013 1:03 pm
Contact:

Re: Build steps to reproduce Zeranoe ffmpeg builds?

Post by hydra3333 » Sat May 11, 2019 3:14 am

iamstickfigure wrote:
Fri May 10, 2019 10:38 pm
The Zeranoe builds handle it flawlessly, so if I knew the exact steps to reproduce it, I won't have the issue.
yes indeed, that would be fantastic.

navilor
Posts: 49
Joined: Thu May 12, 2011 5:19 pm

Re: Build steps to reproduce Zeranoe ffmpeg builds?

Post by navilor » Sat May 11, 2019 6:56 am

iamstickfigure wrote:
Fri May 10, 2019 10:38 pm
Thank you hydra. :-)

I've tried both of those. The one by DeadSix is really nice actually.
And they're close to reproducing the Zeranoe builds, but something is off.

Specifically, in my case, I get a "RTMP_Connect1, TLS_Connect failed" when I try livestreaming to an rtmps endpoint. So something is wrong with TLS. I'm using the same version of GnuTLS as the Zeranoe build. "GnuTLS 3.6.7.1"

Code: Select all

ffmpeg -re  -y -ss 00:00:00.000  -i "input.mp4"  -c:v copy -c:a aac -bsf:a aac_adtstoasc -f flv "rtmps://live-api-s.facebook.com:443/rtmp/xxxxxxxxxxxxx"
And I am not the first person to have this issue when cross-compiling ffmpeg for windows. There have been other posts on this forum about it with no replies.
The Zeranoe builds handle it flawlessly, so if I knew the exact steps to reproduce it, I won't have the issue.
You need to add openSSL for SSL/TLS when you are delivering content via RTMPS.

hydra3333
Posts: 195
Joined: Sun Apr 28, 2013 1:03 pm
Contact:

Re: Build steps to reproduce Zeranoe ffmpeg builds?

Post by hydra3333 » Sat May 11, 2019 8:03 am

navilor wrote:
Sat May 11, 2019 6:56 am
iamstickfigure wrote:
Fri May 10, 2019 10:38 pm
The Zeranoe builds handle it flawlessly, so if I knew the exact steps to reproduce it, I won't have the issue.
You need to add openSSL for SSL/TLS when you are delivering content via RTMPS.
OK, just wondering ... https://ffmpeg.zeranoe.com/builds/readm ... readme.txt seems to suggest Zeranoe builds don't build with openSSL ?

iamstickfigure
Posts: 8
Joined: Wed May 08, 2019 11:14 pm

Re: Build steps to reproduce Zeranoe ffmpeg builds?

Post by iamstickfigure » Sat May 11, 2019 3:42 pm

navilor wrote:
Sat May 11, 2019 6:56 am
You need to add openSSL for SSL/TLS when you are delivering content via RTMPS.
Even though it deviates from the Zeranoe build, I went ahead and tried and it, and it totally fixes the problem. :D
hydra3333 wrote:
Sat May 11, 2019 8:03 am
navilor wrote:
Sat May 11, 2019 6:56 am
iamstickfigure wrote:
Fri May 10, 2019 10:38 pm
The Zeranoe builds handle it flawlessly, so if I knew the exact steps to reproduce it, I won't have the issue.
You need to add openSSL for SSL/TLS when you are delivering content via RTMPS.
OK, just wondering ... https://ffmpeg.zeranoe.com/builds/readm ... readme.txt seems to suggest Zeranoe builds don't build with openSSL ?
So, I have a working version now, but I agree that it doesn't really make sense that Zeranoe apparently gets by with GnuTLS alone. There's clearly something Zeranoe is doing differently.

I ended up using LibreSSL because it was suggested over openssl. And using these build flags.

Code: Select all

--enable-nonfree
--enable-openssl
--enable-libtls
Which works, but it is less than ideal, and possibly a no-go because of the "nonfree" flag. Then again, I don't know much about licensing.

hydra3333
Posts: 195
Joined: Sun Apr 28, 2013 1:03 pm
Contact:

Re: Build steps to reproduce Zeranoe ffmpeg builds?

Post by hydra3333 » Sat May 11, 2019 4:37 pm

Just to confirm, you remove this
--enable-gnutls

and add these with libressl
--enable-openssl
--enable-libtls

iamstickfigure
Posts: 8
Joined: Wed May 08, 2019 11:14 pm

Re: Build steps to reproduce Zeranoe ffmpeg builds?

Post by iamstickfigure » Sat May 11, 2019 11:24 pm

hydra3333 wrote:
Sat May 11, 2019 4:37 pm
Just to confirm, you remove this
--enable-gnutls

and add these with libressl
--enable-openssl
--enable-libtls
Yep. Forgot to mention that. It won't build without removing that flag

To be precise, remove this
--enable-gnutls

Add these with libressl
--enable-nonfree
--enable-openssl
--enable-libtls

iamstickfigure
Posts: 8
Joined: Wed May 08, 2019 11:14 pm

Re: Build steps to reproduce Zeranoe ffmpeg builds?

Post by iamstickfigure » Mon May 13, 2019 3:50 pm

Yeah, --enable-nonfree is definitely going to be an issue.

It would be better if I could just get GnuTLS to work instead.

Post Reply