From 818c0ae53ae7f953a8561a00d910f3fe844d9c4a Mon Sep 17 00:00:00 2001 From: Stepan Blyschak Date: Mon, 6 Jan 2020 18:34:31 +0200 Subject: [PATCH] [slave.mk] make debian package install noninteractive Otherwise, build process gets stuck because isc-dhcp-relay gives promt: ``` $ make SONIC_PROFILING_ON=y INSTALL_DEBUG_TOOLS=y SONIC_BUILD_JOBS=12 target/debs/stretch/isc-dhcp-relay_4.3.5-2_amd64.deb-install +++ --- Making target/debs/stretch/isc-dhcp-relay_4.3.5-2_amd64.deb-install --- +++ EXTRA_JESSIE_TARGETS=isc-dhcp-relay_4.3.5-2_amd64.deb-install make -f Makefile.work jessie make[1]: Entering directory `/build2/stepanb/hitless/sonic-buildimage' SONiC Build System Build Configuration "CONFIGURED_PLATFORM" : "mellanox" "CONFIGURED_ARCH" : "amd64" "SONIC_CONFIG_PRINT_DEPENDENCIES" : "" "SONIC_BUILD_JOBS" : "12" "SONIC_CONFIG_MAKE_JOBS" : "12" "SONIC_USE_DOCKER_BUILDKIT" : "" "USERNAME" : "admin" "PASSWORD" : "YourPaSsWoRd" "ENABLE_DHCP_GRAPH_SERVICE" : "" "SHUTDOWN_BGP_ON_START" : "" "ENABLE_PFCWD_ON_START" : "" "INSTALL_DEBUG_TOOLS" : "" "ROUTING_STACK" : "frr" "FRR_USER_UID" : "300" "FRR_USER_GID" : "300" "ENABLE_SYNCD_RPC" : "" "ENABLE_ORGANIZATION_EXTENSIONS" : "y" "HTTP_PROXY" : "" "HTTPS_PROXY" : "" "ENABLE_SYSTEM_TELEMETRY" : "y" "ENABLE_ZTP" : "" "SONIC_DEBUGGING_ON" : "" "SONIC_PROFILING_ON" : "" "KERNEL_PROCURE_METHOD" : "build" "BUILD_TIMESTAMP" : "20200106.124851" "BLDENV" : "" "VS_PREPARE_MEM" : "yes" "ENABLE_SFLOW" : "y" make: Nothing to be done for 'jessie'. make[1]: Leaving directory `/build2/stepanb/hitless/sonic-buildimage' BLDENV=stretch make -f Makefile.work target/debs/stretch/isc-dhcp-relay_4.3.5-2_amd64.deb-install make[1]: Entering directory `/build2/stepanb/hitless/sonic-buildimage' SONiC Build System Build Configuration "CONFIGURED_PLATFORM" : "mellanox" "CONFIGURED_ARCH" : "amd64" "SONIC_CONFIG_PRINT_DEPENDENCIES" : "" "SONIC_BUILD_JOBS" : "12" "SONIC_CONFIG_MAKE_JOBS" : "12" "SONIC_USE_DOCKER_BUILDKIT" : "" "USERNAME" : "admin" "PASSWORD" : "YourPaSsWoRd" "ENABLE_DHCP_GRAPH_SERVICE" : "" "SHUTDOWN_BGP_ON_START" : "" "ENABLE_PFCWD_ON_START" : "" "INSTALL_DEBUG_TOOLS" : "" "ROUTING_STACK" : "frr" "FRR_USER_UID" : "300" "FRR_USER_GID" : "300" "ENABLE_SYNCD_RPC" : "" "ENABLE_ORGANIZATION_EXTENSIONS" : "y" "HTTP_PROXY" : "" "HTTPS_PROXY" : "" "ENABLE_SYSTEM_TELEMETRY" : "y" "ENABLE_ZTP" : "" "SONIC_DEBUGGING_ON" : "" "SONIC_PROFILING_ON" : "" "KERNEL_PROCURE_METHOD" : "build" "BUILD_TIMESTAMP" : "20200106.124855" "BLDENV" : "stretch" "VS_PREPARE_MEM" : "yes" "ENABLE_SFLOW" : "y" [ 01 ] [ target/debs/stretch/isc-dhcp-relay_4.3.5-2_amd64.deb-install ] Servers the DHCP relay should forward requests to: Interfaces the DHCP relay should listen on: ``` Signed-off-by: Stepan Blyschak --- slave.mk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/slave.mk b/slave.mk index 9a34e5379b14..8f8c4dd87890 100644 --- a/slave.mk +++ b/slave.mk @@ -399,7 +399,7 @@ $(SONIC_INSTALL_TARGETS) : $(DEBS_PATH)/%-install : .platform $$(addsuffix -inst # put a lock here because dpkg does not allow installing packages in parallel while true; do if mkdir $(DEBS_PATH)/dpkg_lock &> /dev/null; then - { sudo dpkg -i $(DEBS_PATH)/$* $(LOG) && rm -d $(DEBS_PATH)/dpkg_lock && break; } || { rm -d $(DEBS_PATH)/dpkg_lock && exit 1 ; } + { sudo DEBIAN_FRONTEND=noninteractive dpkg -i $(DEBS_PATH)/$* $(LOG) && rm -d $(DEBS_PATH)/dpkg_lock && break; } || { rm -d $(DEBS_PATH)/dpkg_lock && exit 1 ; } fi done $(FOOTER)