]> Savannah Git Hosting - gnulib.git/commitdiff
mktempd: Invoke mktemp portably.
authorCollin Funk <collin.funk1@gmail.com>
Tue, 11 Jun 2024 21:16:34 +0000 (14:16 -0700)
committerBruno Haible <bruno@clisp.org>
Thu, 13 Jun 2024 15:05:24 +0000 (17:05 +0200)
* build-aux/mktempd (mktempd): Don't use -t when invoking mktemp since
some implementations expect an argument while others do not.

ChangeLog
build-aux/mktempd

index 5de7779195fcc81472eeb0c38d7915afb98c2592..4104be72a93a4bcf446629ec6d4cdd4c5ef1031e 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2024-06-11  Collin Funk  <collin.funk1@gmail.com>
+
+       mktempd: Invoke mktemp portably.
+       * build-aux/mktempd (mktempd): Don't use -t when invoking mktemp since
+       some implementations expect an argument while others do not.
+
 2024-06-08  Collin Funk  <collin.funk1@gmail.com>
 
        test-framework-sh: Don't leave temporary directories on NetBSD.
index e18cf768783bdf0aebe7bd081ea8d17cb78cd039..542a4016fe657ff952d8a336d25ecf391a8cf6c7 100755 (executable)
@@ -1,7 +1,7 @@
 #!/bin/sh
 # Create a temporary directory, much like mktemp -d does.
 
-# Copyright (C) 2007-2023 Free Software Foundation, Inc.
+# Copyright (C) 2007-2024 Free Software Foundation, Inc.
 
 # This program is free software: you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -91,7 +91,7 @@ mktempd()
   fail=0
 
   # First, try to use mktemp.
-  d=`env -u TMPDIR mktemp -d -t -p "$destdir" "$template" 2>/dev/null` \
+  d=`env -u TMPDIR mktemp -d -p "$destdir" "$template" 2>/dev/null` \
     || fail=1
 
   # The resulting name must be in the specified directory.