I suspect that I can only help a little there.

2 things I still notice ...
Or 3...

gst is still linked to the original mediaframwork handling. I think it would be better to completely separate from it.

It is possible that the gcc used was simply not intended for this case.
Maybe you can test the same locally with the 4.9.4 and take note of the error messages.

But all in all, the gst is simply not worth thinking at all.
I build the in my pli Images only out of laziness and use the best to wonder about the mistakes.
Use takes place exclusively with exteplayer / libeplayer3.
It works and makes no complaints.
ffmpeg 4.1 or 3.4.2 or whatever it does not matter at all.
The box runs so well.

greetings