Files
OpenNetworkLinux/Makefile
Shengzhou Liu 1215e014a0 Update for arm64 on builder9 and arm64-nxp-layerscape struct
Signed-off-by: Guo Hanyue <guo.hanyue@nxp.com>
Signed-off-by: Shengzhou Liu <Shengzhou.Liu@nxp.com>
2018-04-24 13:46:35 +08:00

68 lines
1.7 KiB
Makefile

###########################################################
#
# Work in progress.
#
############################################################
ifneq ($(MAKECMDGOALS),docker)
ifneq ($(MAKECMDGOALS),docker-debug)
ifndef ONL
$(error Please source the setup.env script at the root of the ONL tree)
endif
include $(ONL)/make/config.mk
# All available architectures.
ALL_ARCHES := amd64 powerpc armel arm64
# Build rule for each architecture.
define build_arch_template
$(1) :
$(MAKE) -C builds/$(1)
endef
$(foreach a,$(ALL_ARCHES),$(eval $(call build_arch_template,$(a))))
# Available build architectures based on the current suite
BUILD_ARCHES_wheezy := amd64 powerpc
BUILD_ARCHES_jessie := $(ALL_ARCHES)
BUILD_ARCHES_stretch := arm64 amd64
# Build available architectures by default.
.DEFAULT_GOAL := all
all: $(BUILD_ARCHES_$(ONL_DEBIAN_SUITE))
rebuild:
$(ONLPM) --rebuild-pkg-cache
modclean:
rm -rf $(ONL)/make/modules/modules.*
endif
endif
.PHONY: docker
ifndef VERSION
VERSION := 8
endif
docker_check:
@which docker > /dev/null || (echo "*** Docker appears to be missing. Please install docker.io in order to build OpenNetworkLinux." && exit 1)
docker: docker_check
@docker/tools/onlbuilder -$(VERSION) --isolate --hostname onlbuilder$(VERSION) --pull --autobuild --non-interactive
# create an interative docker shell, for debugging builds
docker-debug: docker_check
@docker/tools/onlbuilder -$(VERSION) --isolate --hostname onlbuilder$(VERSION) --pull
versions:
$(ONL)/tools/make-versions.py --import-file=$(ONL)/tools/onlvi --class-name=OnlVersionImplementation --output-dir $(ONL)/make/versions --force
relclean:
@find $(ONL)/RELEASE -name "ONL-*" -delete