depends: Amend handling flags environment variables

If any of {C,CXX,CPP,LD}FLAGS is specified it should be assigned to
a non-type-specific variable.
This commit is contained in:
Hennadii Stepanov 2024-02-04 22:12:50 +00:00
parent 90cec4d251
commit 6522af62af
No known key found for this signature in database
GPG key ID: 410108112E7EA81F

View file

@ -28,8 +28,8 @@ endef
define add_host_flags_func
ifeq ($(filter $(origin $1),undefined default),)
$(host_arch)_$(host_os)_$1 =
$(host_arch)_$(host_os)_$(release_type)_$1 = $($1)
$(host_arch)_$(host_os)_$1 = $($1)
$(host_arch)_$(host_os)_$(release_type)_$1 =
else
$(host_arch)_$(host_os)_$1 += $($(host_os)_$1)
$(host_arch)_$(host_os)_$(release_type)_$1 += $($(host_os)_$(release_type)_$1)