-# Makefile for OpenWrt
+# SPDX-License-Identifier: GPL-2.0-only
#
# Copyright (C) 2007 OpenWrt.org
-#
-# This is free software, licensed under the GNU General Public License v2.
-# See /LICENSE for more information.
-#
TOPDIR:=${CURDIR}
LC_ALL:=C
world:
-DISTRO_PKG_CONFIG:=$(shell which -a pkg-config | grep -E '\/usr' | head -n 1)
+DISTRO_PKG_CONFIG:=$(shell command -pv pkg-config | grep -E '\/usr' | head -n 1)
export PATH:=$(TOPDIR)/staging_dir/host/bin:$(PATH)
ifneq ($(OPENWRT_BUILD),1)
cacheclean:
ifneq ($(CONFIG_CCACHE),)
- rm -rf $(if $(call qstrip,$(CONFIG_CCACHE_DIR)),$(call qstrip,$(CONFIG_CCACHE_DIR)),$(TOPDIR)/.ccache)
+ $(STAGING_DIR_HOST)/bin/ccache -C
endif
ifndef DUMP_TARGET_DB
# check prerequisites before starting to build
prereq: $(target/stamp-prereq) tmp/.prereq_packages
- @if [ ! -f "$(INCLUDE_DIR)/site/$(ARCH)" ]; then \
- echo 'ERROR: Missing site config for architecture "$(ARCH)" !'; \
- echo ' The missing file will cause configure scripts to fail during compilation.'; \
- echo ' Please provide a "$(INCLUDE_DIR)/site/$(ARCH)" file and restart the build.'; \
- exit 1; \
- fi
$(BIN_DIR)/profiles.json: FORCE
$(if $(CONFIG_JSON_OVERVIEW_IMAGE_INFO), \