Hello When I compile, I encounter an error. #6

Closed
opened 2025-12-23 10:30:08 +01:00 by backuprepo · 2 comments
Owner

Originally created by @lvjunping on GitHub (Jan 16, 2024).

libavfilter/rkrga_common.c: In function 'get_drm_afbc_format':
libavfilter/rkrga_common.c:154:38: error: 'DRM_FORMAT_INVALID' undeclared (first use in this function); did you mean 'DRM_FORMAT_MOD_INVALID'?
154 | default: return DRM_FORMAT_INVALID;
| ^~~~~~~~~~~~~~~~~~
| DRM_FORMAT_MOD_INVALID
libavfilter/rkrga_common.c:154:38: note: each undeclared identifier is reported only once for each function it appears in
CC libavfilter/setpts.o
libavfilter/rkrga_common.c: In function 'query_frame':
libavfilter/rkrga_common.c:554:29: error: 'DRM_FORMAT_INVALID' undeclared (first use in this function); did you mean 'DRM_FORMAT_MOD_INVALID'?
554 | if (drm_afbc_fmt == DRM_FORMAT_INVALID) {
| ^~~~~~~~~~~~~~~~~~
| DRM_FORMAT_MOD_INVALID
libavfilter/rkrga_common.c:562:13: error: implicit declaration of function 'DRM_FORMAT_MOD_ARM_AFBC'; did you mean 'DRM_FORMAT_MOD_ARM_TYPE_AFBC'? [-Werror=implicit-function-declaration]
562 | DRM_FORMAT_MOD_ARM_AFBC(AFBC_FORMAT_MOD_SPARSE | AFBC_FORMAT_MOD_BLOCK_SIZE_16x16);
| ^~~~~~~~~~~~~~~~~~~~~~~
| DRM_FORMAT_MOD_ARM_TYPE_AFBC
libavfilter/rkrga_common.c:562:37: error: 'AFBC_FORMAT_MOD_SPARSE' undeclared (first use in this function)
562 | DRM_FORMAT_MOD_ARM_AFBC(AFBC_FORMAT_MOD_SPARSE | AFBC_FORMAT_MOD_BLOCK_SIZE_16x16);
| ^~~~~~~~~~~~~~~~~~~~~~
libavfilter/rkrga_common.c:562:62: error: 'AFBC_FORMAT_MOD_BLOCK_SIZE_16x16' undeclared (first use in this function)
562 | DRM_FORMAT_MOD_ARM_AFBC(AFBC_FORMAT_MOD_SPARSE | AFBC_FORMAT_MOD_BLOCK_SIZE_16x16);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
libavfilter/rkrga_common.c: In function 'get_drm_afbc_format':
libavfilter/rkrga_common.c:156:1: error: control reaches end of non-void function [-Werror=return-type]
156 | }

Originally created by @lvjunping on GitHub (Jan 16, 2024). libavfilter/rkrga_common.c: In function 'get_drm_afbc_format': libavfilter/rkrga_common.c:154:38: error: 'DRM_FORMAT_INVALID' undeclared (first use in this function); did you mean 'DRM_FORMAT_MOD_INVALID'? 154 | default: return DRM_FORMAT_INVALID; | ^~~~~~~~~~~~~~~~~~ | DRM_FORMAT_MOD_INVALID libavfilter/rkrga_common.c:154:38: note: each undeclared identifier is reported only once for each function it appears in CC libavfilter/setpts.o libavfilter/rkrga_common.c: In function 'query_frame': libavfilter/rkrga_common.c:554:29: error: 'DRM_FORMAT_INVALID' undeclared (first use in this function); did you mean 'DRM_FORMAT_MOD_INVALID'? 554 | if (drm_afbc_fmt == DRM_FORMAT_INVALID) { | ^~~~~~~~~~~~~~~~~~ | DRM_FORMAT_MOD_INVALID libavfilter/rkrga_common.c:562:13: error: implicit declaration of function 'DRM_FORMAT_MOD_ARM_AFBC'; did you mean 'DRM_FORMAT_MOD_ARM_TYPE_AFBC'? [-Werror=implicit-function-declaration] 562 | DRM_FORMAT_MOD_ARM_AFBC(AFBC_FORMAT_MOD_SPARSE | AFBC_FORMAT_MOD_BLOCK_SIZE_16x16); | ^~~~~~~~~~~~~~~~~~~~~~~ | DRM_FORMAT_MOD_ARM_TYPE_AFBC libavfilter/rkrga_common.c:562:37: error: 'AFBC_FORMAT_MOD_SPARSE' undeclared (first use in this function) 562 | DRM_FORMAT_MOD_ARM_AFBC(AFBC_FORMAT_MOD_SPARSE | AFBC_FORMAT_MOD_BLOCK_SIZE_16x16); | ^~~~~~~~~~~~~~~~~~~~~~ libavfilter/rkrga_common.c:562:62: error: 'AFBC_FORMAT_MOD_BLOCK_SIZE_16x16' undeclared (first use in this function) 562 | DRM_FORMAT_MOD_ARM_AFBC(AFBC_FORMAT_MOD_SPARSE | AFBC_FORMAT_MOD_BLOCK_SIZE_16x16); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ libavfilter/rkrga_common.c: In function 'get_drm_afbc_format': libavfilter/rkrga_common.c:156:1: error: control reaches end of non-void function [-Werror=return-type] 156 | }
Author
Owner

@nyanmisaka commented on GitHub (Jan 17, 2024):

@lvjunping
These definitions are part of the header files in libdrm-dev package. If you are using a very old distro please download and compile latest header files from the drm repo.

https://gitlab.freedesktop.org/mesa/drm
https://github.com/nyanmisaka/ffmpeg-rockchip/wiki/Compilation

@nyanmisaka commented on GitHub (Jan 17, 2024): @lvjunping These definitions are part of the header files in `libdrm-dev` package. If you are using a very old distro please download and compile latest header files from the drm repo. https://gitlab.freedesktop.org/mesa/drm https://github.com/nyanmisaka/ffmpeg-rockchip/wiki/Compilation
Author
Owner

@lvjunping commented on GitHub (Jan 18, 2024):

Thank you very much! I have compilation was successful!

@lvjunping commented on GitHub (Jan 18, 2024): Thank you very much! I have compilation was successful!
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: starred/ffmpeg-rockchip#6
No description provided.