Opened 3 months ago

Closed 3 weeks ago

#7453 closed defect (invalid)

configure doesn't find ffnvcodec headers on hackintosh

Reported by: w4t3r Owned by:
Priority: normal Component: build system
Version: git-master Keywords: cuda nvenc
Cc: Blocked By:
Blocking: Reproduced by developer: no
Analyzed by developer: no


Summary of the bug:
Unable to compile ffmpeg on macOS 10.13.6 with Nvidia GPU acceleration support. I'm using a GTX 1080ti on a hackintosh.
How to reproduce:

Run configure:

Daniels-iMac:ffmpeg daniel$ ./configure --enable-cuda --enable-cuvid --enable-nvenc --enable-nonfree --enable-libnpp  --extra-cflags=-I/usr/local/cuda/include --extra-ldflags=-L/usr/local/cuda/lib
ERROR: cuda requested, but not all dependencies are satisfied: ffnvcodec
If you think configure made a mistake, make sure you are using the latest
version from Git.  If the latest version fails, report the problem to the mailing list or IRC #ffmpeg on
Include the log file "ffbuild/config.log" produced by configure as this will help
solve the problem.

As you can see it fails.
Proof that nvenc headers are there:

Daniels-iMac:ffmpeg daniel$ pkg-config --cflags ffnvcodec
Daniels-iMac:ffmpeg daniel$ pkg-config ffnvcodec
Daniels-iMac:ffmpeg daniel$ echo $?
Daniels-iMac:ffmpeg daniel$ ls /usr/local/include/ffnvcodec/
dynlink_cuda.h      dynlink_cuviddec.h  dynlink_loader.h    dynlink_nvcuvid.h   nvEncodeAPI.h
Daniels-iMac:ffmpeg daniel$


Also, the last piece of code contained in the config.log file, compiled manually, exits 0

Attachments (1)

config.log (515.9 KB) - added by w4t3r 3 months ago.

Download all attachments as: .zip

Change History (10)

comment:1 Changed 3 months ago by w4t3r

Proof that nvenc headers are there:

Sorry, I meant ffnvcodec

comment:2 Changed 3 months ago by cehoyos

  • Keywords cuda added; hackintosh nvidia gpu gpu acceleration pkgconfig configure removed

Please attach config.log here.

comment:3 Changed 3 months ago by oromit

OSX is not a supported os of the video codec sdk.

Changed 3 months ago by w4t3r

comment:4 Changed 3 months ago by w4t3r

@oromit: Oh, I see, but does that mean it won't work? Because

a) I built it yesterday with ubuntu, following this guide: and I never had to download the video codec sdk. Only drivers+CUDA toolkit
b) I'm not having issues with configure not finding the video codec sdk but with configure not finding headers that clearly are there

@cehoyos: Sorry, I thought a link would also work. Attached the file now.

It would be amazing if it would be possible to get this working, as encoding is 5x faster on my GPU and it sucks to reboot everytime to convert a video

comment:5 Changed 3 months ago by oromit

Apple has their own APIs for video de/encoding on OSX. Nothing else is supported there.

comment:6 Changed 3 months ago by w4t3r

Would ffmpeg utilize the graphics card through videotoolbox?

It doesn't have to be supported as long as it works.
The last test snippet in config.log compiles and exits successfully, so where does it say that it needs video codec sdk headers?

I mean if we could fix that it doesn't find the ffnvcodec headers maybe it would compile with CUDA toolkit?

comment:7 Changed 3 months ago by oromit

It finds the headers but configure is hard wired to disable anything cuda related anywhere but on Windows and Linux, since those are the only platforms it works on.
No idea about VT, but there is code for it in ffmpeg and you can probably use it to do stuff.

comment:8 Changed 3 months ago by w4t3r

That sucks.
Is configure generated somehow? Would it be possible to temporarily disable those checks, because maaaaaybe it would work and simply nobody has tried it on a mac with a nvidia card yet?

However it turns out, thank you for your help!

comment:9 Changed 3 weeks ago by cehoyos

  • Resolution set to invalid
  • Status changed from new to closed
Note: See TracTickets for help on using tickets.