#
# GNUmakefile - Setting Env and Call u-boot Makefile
#
# Copyright (c) 2020 Panasonic Corporation
# 2020-10-19 Modified
#
# This file may be used subject to the terms and conditions of the
# GNU General Public License Version 2, or any later version
# at your option, as published by the Free Software Foundation.
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#

ifneq ($(PVCPF_MTYPE),pvc04v)
	$(error invalid PVCPF_MTYPE.)
endif

DEFCONFIG=pvc04v_$(PVCPF_SUBMODEL)$(PVCPF_HW_VERSION)_defconfig

GNUmakefile: ;

.config:
	LOCALVERSION= $(MAKE) -f Makefile $(DEFCONFIG)
	LOCALVERSION= $(MAKE) -f Makefile clean

install: .config
	LOCALVERSION= $(MAKE) -f Makefile   ARCH=arm CROSS_COMPILE=$(PVCPF_LINARO_CROSS_COMPILE)

clean:
	$(MAKE) clean -f Makefile

distclean:
	$(MAKE) distclean -f Makefile

menuconfig:
	$(MAKE) menuconfig ARCH=arm -f Makefile

savedefconfig:
	$(MAKE) savedefconfig -f Makefile

%: FORCE
	LOCALVERSION= $(MAKE) -f Makefile $@

FORCE: ;
