jc-kynesim / rpi-ffmpeg

FFmpeg work for RPI
Other
111 stars 27 forks source link

Some build fixes #7

Closed justinkb closed 3 years ago

justinkb commented 3 years ago

These also all apply cleanly to test/4.3.2/rpi_main

jc-kynesim commented 3 years ago

I'll merge these but do the 1st 3 actually produce warnings for you? On my Pi the files compile cleanly without.

justinkb commented 3 years ago

They produce actual errors with clang. Guess you're using gcc?

On Mon, Jul 5, 2021 at 11:39 AM jc-kynesim @.***> wrote:

Merged #7 https://github.com/jc-kynesim/rpi-ffmpeg/pull/7 into dev/4.3.2/clean_3.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/jc-kynesim/rpi-ffmpeg/pull/7#event-4977482750, or unsubscribe https://github.com/notifications/unsubscribe-auth/AABVHKFS7FB3E73IBEQW5UTTWF4W3ANCNFSM47ZIDFBA .

jc-kynesim commented 3 years ago

Yup - default compiler

justinkb commented 3 years ago

That explains it. Anyway, thanks for the great work on this!

jc-kynesim commented 3 years ago

Either way, as I said I'll merge. You should be aware that clean_3 is about to be an obsolete branch - next time I do more dev work it will be a new branch off rpi_main.

justinkb commented 3 years ago

understood, I'll keep a close look on the branches

jc-kynesim commented 3 years ago

OK - that'll teach me to not go "Can't see why that shouldn't cause any problems" and merge blindly. The last commit "epoxy option requires Xlib" causes the following link error for me (creating a static ffmpeg):

jc@jc-buster-armv7l-pi4:~/rpi/FFmpeg $ make -j8 -C out/armv7-buster-static-rel/ make: Entering directory '/net/scooby/home/jc/rpi/FFmpeg/out/armv7-buster-static-rel' LD ffmpeg_g LD ffprobe_g /usr/bin/ld: libavdevice/libavdevice.a(xv.o): undefined reference to symbol 'XShmDetach' /usr/bin/ld: //lib/arm-linux-gnueabihf/libXext.so.6: error adding symbols: DSO missing from command line collect2: error: ld returned 1 exit status /usr/bin/ld: libavdevice/libavdevice.a(xv.o): undefined reference to symbol 'XShmDetach' /usr/bin/ld: //lib/arm-linux-gnueabihf/libXext.so.6: error adding symbols: DSO missing from command line collect2: error: ld returned 1 exit status make: *** [/home/jc/rpi/FFmpeg/Makefile:114: ffmpeg_g] Error 1 make: *** Waiting for unfinished jobs.... make: *** [/home/jc/rpi/FFmpeg/Makefile:114: ffprobe_g] Error 1 make: Leaving directory '/net/scooby/home/jc/rpi/FFmpeg/out/armv7-buster-static-rel' jc@jc-buster-armv7l-pi4:~/rpi/FFmpeg $ Any clues? Without the patch all is fine. So for now I'm pulling that commit from rpi_main

jc-kynesim commented 3 years ago

Thats really weird - in edit mode there are line breaks in the correct places, but on display its all one line. Can you read it?

justinkb commented 3 years ago

I can read it. I'm on phone now, going to computer in a few minutes, I'll check it out right away

On Mon, Jul 5, 2021, 12:57 PM jc-kynesim @.***> wrote:

Thats really weird - in edit mode there are line breaks in the correct places, but on display its all one line. Can you read it?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/jc-kynesim/rpi-ffmpeg/pull/7#issuecomment-874018535, or unsubscribe https://github.com/notifications/unsubscribe-auth/AABVHKFXHHPRVD5M6FTEHHTTWGF3DANCNFSM47ZIDFBA .

justinkb commented 3 years ago

Hm try replacing -lX11 with -lX11 -lXext?

On Mon, Jul 5, 2021, 1:01 PM Paul Mulders @.***> wrote:

I can read it. I'm on phone now, going to computer in a few minutes, I'll check it out right away

On Mon, Jul 5, 2021, 12:57 PM jc-kynesim @.***> wrote:

Thats really weird - in edit mode there are line breaks in the correct places, but on display its all one line. Can you read it?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/jc-kynesim/rpi-ffmpeg/pull/7#issuecomment-874018535, or unsubscribe https://github.com/notifications/unsubscribe-auth/AABVHKFXHHPRVD5M6FTEHHTTWGF3DANCNFSM47ZIDFBA .

justinkb commented 3 years ago

hm, looks like this is caused by xv outdev being enabled (which I don't have for my rpi, that's why I didn't run into this). passing --disable-outdev=xv to configure should be a workaround while i fix this. if that's acceptable

jc-kynesim commented 3 years ago

That changes it and we now move on to:

LD      ffmpeg_g
/usr/bin/ld: libavdevice/libavdevice.a(xv.o): in function `xv_repaint':
/net/scooby/home/jc/rpi/FFmpeg/out/armv7-buster-static-rel/src/libavdevice/xv.c:285: undefined reference to `XvShmPutImage'
/usr/bin/ld: libavdevice/libavdevice.a(xv.o): in function `xv_write_header':
/net/scooby/home/jc/rpi/FFmpeg/out/armv7-buster-static-rel/src/libavdevice/xv.c:166: undefined reference to `XvQueryAdaptors'
/usr/bin/ld: /net/scooby/home/jc/rpi/FFmpeg/out/armv7-buster-static-rel/src/libavdevice/xv.c:175: undefined reference to `XvFreeAdaptorInfo'
/usr/bin/ld: /net/scooby/home/jc/rpi/FFmpeg/out/armv7-buster-static-rel/src/libavdevice/xv.c:177: undefined reference to `XvListImageFormats'
/usr/bin/ld: /net/scooby/home/jc/rpi/FFmpeg/out/armv7-buster-static-rel/src/libavdevice/xv.c:200: undefined reference to `XvShmCreateImage'
collect2: error: ld returned 1 exit status
make: *** [/home/jc/rpi/FFmpeg/Makefile:114: ffmpeg_g] Error 1
make: Leaving directory '/net/scooby/home/jc/rpi/FFmpeg/out/armv7-buster-static-rel'

I think this is probably the wrong way to do this and the requirement should be in the xxx_select, xxx_deps logic which seems to get the libs right

justinkb commented 3 years ago

It seems we commented at the same time, wanna make sure you saw my comment about --disable-outdev=xv above as a workaround

jc-kynesim commented 3 years ago

Given I don't need this patch to compile my workaround is going to be drop the commit till it works

justinkb commented 3 years ago

good idea, I'll work on a proper fix in the meantime

justinkb commented 3 years ago

8 fixes it. sorry for breaking your build!