Skip to content

Commit

Permalink
depends: set env-provided flags to per-release
Browse files Browse the repository at this point in the history
Users can now safely set flags and have them override the optional
per-release-type flags.

This also means that user-provided flags will now be forwarded to CMake's
build-type flags variables so that they'll correctly override the existing
values.
  • Loading branch information
theuni committed Jan 14, 2025
1 parent c4049f8 commit b446774
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions depends/hosts/default.mk
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,11 @@ endef

define add_host_flags_func
ifeq ($(filter $(origin $1),undefined default),)
$(host_arch)_$(host_os)_$1 = $($1)
$(host_arch)_$(host_os)_$(release_type)_$1 =
$(host_arch)_$(host_os)_$(release_type)_$1 = $($1)
else
$(host_arch)_$(host_os)_$1 += $($(host_os)_$1)
$(host_arch)_$(host_os)_$(release_type)_$1 += $($(host_os)_$(release_type)_$1)
endif
$(host_arch)_$(host_os)_$1 += $($(host_os)_$1)
host_$1 = $$($(host_arch)_$(host_os)_$1)
host_$(release_type)_$1 = $$($(host_arch)_$(host_os)_$(release_type)_$1)
endef
Expand Down

0 comments on commit b446774

Please sign in to comment.