pkg-infra: put optional step_user def and assignment in one block
authorDanomi Manchego <danomimanchego123@gmail.com>
Mon, 15 Sep 2014 01:31:11 +0000 (21:31 -0400)
committerThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Sun, 21 Sep 2014 20:57:30 +0000 (22:57 +0200)
Signed-off-by: Danomi Manchego <danomimanchego123@gmail.com>
Acked-by: "Yann E. MORIN" <yann.morin.1998 at free.fr>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
package/pkg-generic.mk

index d04fd36db91f7b4eec61fb83aad81b8a472d0f56..4b6d818bf9de3d2444e62832656c87315f0d8093 100644 (file)
@@ -56,11 +56,11 @@ endef
 GLOBAL_INSTRUMENTATION_HOOKS += step_time
 
 # User-supplied script
+ifneq ($(BR2_INSTRUMENTATION_SCRIPTS),)
 define step_user
        @$(foreach user_hook, $(BR2_INSTRUMENTATION_SCRIPTS), \
                $(EXTRA_ENV) $(user_hook) "$(1)" "$(2)" "$(3)"$(sep))
 endef
-ifneq ($(BR2_INSTRUMENTATION_SCRIPTS),)
 GLOBAL_INSTRUMENTATION_HOOKS += step_user
 endif