system_server_current is accepted
Previously, has-system-sdk-version incorrectly returned true for
the sdk version 'system_server_current', just because it started with
system_. Since system_server_current is a totally different API surface
than system_*, make the macro to return false for system_server_*.
Bug: 146757305
Test: m
Test: add 'sdk_version: "system_server_current" to wifi-service-pre-jarjar
Change-Id: I43700545b0f120fa987696b8f03a4765d97e13e2
diff --git a/core/definitions.mk b/core/definitions.mk
index fb11ab6..3d56f4c 100644
--- a/core/definitions.mk
+++ b/core/definitions.mk
@@ -3242,11 +3242,12 @@
###########################################################
## Find system_$(VER) in LOCAL_SDK_VERSION
+## note: system_server_* is excluded. It's a different API surface
##
## $(1): LOCAL_SDK_VERSION
###########################################################
define has-system-sdk-version
-$(filter system_%,$(1))
+$(filter-out system_server_%,$(filter system_%,$(1)))
endef
###########################################################