check-deprecated-variable: move from pkg-generic.mk to pkg-utils.mk

Suggested-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Thomas De Schampheleire <thomas.de.schampheleire@gmail.com>
Acked-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
This commit is contained in:
Thomas De Schampheleire 2014-10-05 09:58:31 +02:00 committed by Thomas Petazzoni
parent 6a25cec33d
commit 2dc51b7c4d
2 changed files with 9 additions and 15 deletions

View File

@ -263,21 +263,6 @@ be selected at a time. Please fix your configuration)
endif
endef
################################################################################
# check-deprecated-variable -- throw an error on deprecated variables
#
# argument 1 is the deprecated variable
# argument 2 is the new variable to use
#
# example:
# $(eval $(call check-deprecated-variable,FOO_MAKE_OPT,FOO_MAKE_OPTS))
################################################################################
define check-deprecated-variable
ifneq ($$(origin $(1)),undefined)
$$(error Package error: use $(2) instead of $(1). Please fix your .mk file)
endif
endef
################################################################################
# inner-generic-package -- generates the make targets needed to build a
# generic package

View File

@ -88,6 +88,15 @@ define sep
endef
# check-deprecated-variable -- throw an error on deprecated variables
# example:
# $(eval $(call check-deprecated-variable,FOO_MAKE_OPT,FOO_MAKE_OPTS))
define check-deprecated-variable # (deprecated var, new var)
ifneq ($$(origin $(1)),undefined)
$$(error Package error: use $(2) instead of $(1). Please fix your .mk file)
endif
endef
#
# legal-info helper functions
#