From 1a3bdccd51302cca9ba3ce3a11a7a05753ea17d4 Mon Sep 17 00:00:00 2001 From: Martin Braun Date: Thu, 20 Feb 2025 09:23:37 +0100 Subject: [PATCH] Revert "Get rid of unnecessary bash wrappers in subprocesses.Popen" This reverts commit e572bab3ee5aa40f57bdc6e11d6381cad1d1401a. The problem with skipping the "unnecessary" bash wrappers is that Ubuntu systems use 'dash' as a default shell, which does not support our build infrastructure. While we do recommend not using dash for building FPGA builds in our documentation, it's not obvious that dash is the problem when calling rfnoc_image_builder. Original-commit: 888850d6417c93f561e0555c693e3f11e9f40856 --- tools/utils/repeat_fpga_build.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/tools/utils/repeat_fpga_build.py b/tools/utils/repeat_fpga_build.py index 1b03a63..5ededf2 100755 --- a/tools/utils/repeat_fpga_build.py +++ b/tools/utils/repeat_fpga_build.py @@ -374,11 +374,9 @@ def run_fpga_build( cmd_build_num, ) logging.info(f"Running FPGA build command: {cmd}") - my_env = os.environ.copy() with subprocess.Popen( cmd, shell=True, - env=my_env, stdout=subprocess.PIPE, stderr=subprocess.STDOUT, bufsize=1, @@ -462,7 +460,7 @@ def run_ip_build( logging.info(f"Running IP build with command: {cmd}") output = "" with subprocess.Popen( - cmd, + f'/bin/bash -c "{cmd}"', shell=True, stdout=subprocess.PIPE, stderr=subprocess.STDOUT,