mirror of
https://github.com/torvalds/linux.git
synced 2026-09-22 12:44:03 +02:00
drm/amd/display: Fix DML file discovery for out-of-tree builds
By anchoring the search to the DML top-level Makefile directory, FPU CFLAGS are now correctly applied to all relevant source files. Signed-off-by: Prike Liang <Prike.Liang@amd.com> Reviewed-by: Leo Li <sunpeng.li@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
parent
d3b00fd163
commit
18bcc49d87
|
|
@ -55,8 +55,11 @@ subdir-ccflags-y += -I$(FULL_AMD_DISPLAY_PATH)/dc/dml2_0/dml21/
|
|||
|
||||
# Add FPU flags to all dml2 files by default, remove NO_FPU flags.
|
||||
# FPU flags step 1: Find all .c files in dal/dc/dml2_0 and it's subfolders
|
||||
DML2_ABS_PATH := $(FULL_AMD_DISPLAY_PATH)/dc/dml2_0
|
||||
DML2_C_FILES := $(shell find $(DML2_ABS_PATH) -name '*.c' -type f)
|
||||
|
||||
THIS_MAKEFILE_PATH := $(abspath $(lastword $(MAKEFILE_LIST)))
|
||||
DML2_ABS_PATH := $(patsubst %/,%,$(dir $(THIS_MAKEFILE_PATH)))
|
||||
|
||||
DML2_C_FILES := $(shell find $(DML2_ABS_PATH) -name '*.c')
|
||||
|
||||
# FPU flags step 2: Convert to .o and make paths relative to $(AMDDALPATH)/dc/dml2_0/
|
||||
DML2_RELATIVE_O_FILES := $(patsubst $(DML2_ABS_PATH)/%,dc/dml2_0/%,$(patsubst %.c,%.o,$(DML2_C_FILES)))
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user