configure: Only create serdep.tmp if needed

Message ID 20230115055842.3965247-1-pefoley2@pefoley.com
State Accepted
Headers
Series configure: Only create serdep.tmp if needed |

Checks

Context Check Description
snail/gcc-patch-check success Github commit url

Commit Message

Peter Foley Jan. 15, 2023, 5:58 a.m. UTC
  There's no reason to create this file if none of the serial configure
options are passed.

ChangeLog:

	* configure: Regenerate.
	* configure.ac: Only create serdep.tmp if needed

Signed-off-by: Peter Foley <pefoley2@pefoley.com>
---
 configure    | 2 ++
 configure.ac | 2 ++
 2 files changed, 4 insertions(+)
  

Patch

diff --git a/configure b/configure
index 85883099410..47caaeb23fe 100755
--- a/configure
+++ b/configure
@@ -9918,7 +9918,9 @@  esac
 # These force 'configure's to be done one at a time, to avoid problems
 # with contention over a shared config.cache.
 rm -f serdep.tmp
+if  "x${enable_serial_build_configure}" = xyes || "x${enable_serial_host_configure}" = xyes || "x${enable_serial_target_configure}" = xyes ; then
 echo '# serdep.tmp' > serdep.tmp
+fi
 olditem=
 test "x${enable_serial_build_configure}" = xyes &&
 for item in ${build_configdirs} ; do
diff --git a/configure.ac b/configure.ac
index 2b612dce6e9..847df0c99b5 100644
--- a/configure.ac
+++ b/configure.ac
@@ -3071,7 +3071,9 @@  esac
 # These force 'configure's to be done one at a time, to avoid problems
 # with contention over a shared config.cache.
 rm -f serdep.tmp
+if [ "x${enable_serial_build_configure}" = xyes || "x${enable_serial_host_configure}" = xyes || "x${enable_serial_target_configure}" = xyes ]; then
 echo '# serdep.tmp' > serdep.tmp
+fi
 olditem=
 test "x${enable_serial_build_configure}" = xyes &&
 for item in ${build_configdirs} ; do