From 9da4d5673440ad0e5599f99181c28b9a189f1ed0 Mon Sep 17 00:00:00 2001 From: Frank Hunleth Date: Tue, 11 Sep 2018 11:56:50 -0400 Subject: [PATCH] erlang: run autoconf via otp_build Erlang runs autoconf on many directories. The recommended way is to run otp_build. --- package/erlang/erlang.mk | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/package/erlang/erlang.mk b/package/erlang/erlang.mk index fe9b93c1b6..45e03fa62d 100644 --- a/package/erlang/erlang.mk +++ b/package/erlang/erlang.mk @@ -8,15 +8,12 @@ ERLANG_VERSION = 21.0 ERLANG_SITE = https://github.com/erlang/otp/archive ERLANG_SOURCE = OTP-$(ERLANG_VERSION).tar.gz -ERLANG_DEPENDENCIES = host-erlang +ERLANG_DEPENDENCIES = host-erlang host-autoconf ERLANG_LICENSE = Apache-2.0 ERLANG_LICENSE_FILES = LICENSE.txt ERLANG_INSTALL_STAGING = YES -# Patched erts/aclocal.m4 -ERLANG_AUTORECONF = YES - # Whenever updating Erlang, this value should be updated as well, to the # value of EI_VSN in the file lib/erl_interface/vsn.mk ERLANG_EI_VSN = 3.10.3 @@ -81,6 +78,12 @@ ifneq ($(BR2_PACKAGE_ERLANG_MEGACO),y) ERLANG_REMOVE_PACKAGES += megaco endif +define ERLANG_RUN_OTP_BUILD + # otp_build runs autoconf and autoheader across several Erlang + # directories. Running autoreconf is insufficient. + ERL_TOP=$(@D) $(HOST_MAKE_ENV) $(@D)/otp_build autoconf +endef + define ERLANG_REMOVE_STAGING_UNUSED # Remove intermediate build products that can get copied Erlang # release tools. @@ -122,8 +125,11 @@ define ERLANG_REMOVE_TARGET_UNUSED find $(TARGET_DIR)/usr/lib/erlang -type d -empty -delete endef +ERLANG_PRE_CONFIGURE_HOOKS += ERLANG_RUN_OTP_BUILD ERLANG_POST_INSTALL_STAGING_HOOKS += ERLANG_REMOVE_STAGING_UNUSED ERLANG_POST_INSTALL_TARGET_HOOKS += ERLANG_REMOVE_TARGET_UNUSED +HOST_ERLANG_PRE_CONFIGURE_HOOKS += ERLANG_RUN_OTP_BUILD + $(eval $(autotools-package)) $(eval $(host-autotools-package)) -- 2.17.1