Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4643b73a authored by Cole Faust's avatar Cole Faust Committed by Automerger Merge Worker
Browse files

Merge "Support disting in soong-only builds" into main am: 1be75c02 am: 2624b1e6

parents ca98669e 2624b1e6
Loading
Loading
Loading
Loading
+0 −2
Original line number Diff line number Diff line
@@ -45,5 +45,3 @@ ifeq ($(DIST),true)
endif

copy-one-dist-file :=
DIST_GOAL_OUTPUT_PAIRS :=
DIST_SRC_DST_PAIRS :=
+55 −0
Original line number Diff line number Diff line
# Copyright (C) 2025 The Android Open Source Project
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#      http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

ifndef KATI
$(error Only Kati is supported.)
endif

$(info [1/4] initializing packaging system ...)

.KATI_READONLY := KATI_PACKAGE_MK_DIR

include build/make/common/core.mk
include build/make/common/strings.mk

# Define well-known goals and their dependency graph that they've
# traditionally had in make builds. Also it's important to define
# droid first so that it's built by default.

.PHONY: droid
droid: droid_targets

.PHONY: droid_targets
droid_targets: dist_files

.PHONY: dist_files
dist_files:

$(info [2/4] including distdir.mk ...)

include build/make/packaging/distdir.mk

$(info [3/4] defining phony modules ...)

include $(OUT_DIR)/soong/soong_phony_targets.mk

goals := $(sort $(foreach pair,$(DIST_GOAL_OUTPUT_PAIRS),$(call word-colon,1,$(pair))))
$(warning goals: $(goals))
$(foreach goal,$(goals), \
  $(eval .PHONY: $$(goal)) \
  $(eval $$(goal):) \
  $(if $(call streq,$(DIST),true),\
    $(eval $$(goal): _dist_$$(goal))))

$(info [4/4] writing packaging rules ...)