Source-Changes-D archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: CVS commit: src/external/gpl3



Upstream (GCC) is strongly against this change (even under __NetBSD__
ifdef) as /var/tmp is typically larger than /tmp:

> I'd strongly recommend against this as-is.
>
> The whole reason we prefer /var/tmp is because it's often dramatically
larger
> than a ram-backed /tmp.

-- by Jeff Law.

Do we insist on this patch? Can we remove it from local sources?

The same effect can be achieved with env(1) variables: TMP=/tmp
TEMPDIR=/tmp or TEMP=/tmp.

On 10.08.2015 17:45, Jonathan A. Kollasch wrote:
> Module Name:	src
> Committed By:	jakllsch
> Date:		Mon Aug 10 15:45:40 UTC 2015
> 
> Modified Files:
> 	src/external/gpl3/binutils/dist/libiberty: make-temp-file.c
> 	src/external/gpl3/gcc/dist/libiberty: make-temp-file.c
> 	src/external/gpl3/gdb/dist/libiberty: make-temp-file.c
> 
> Log Message:
> Correct temporary directory preference order in libiberty's choose_tmpdir().
> 
> Because it is intended to be persistent, /var/tmp is about the worst possible
> choice for temporary files for most users of libiberty.  /tmp works better,
> because the the defined semantics of /tmp allow for a non-persistent tmpfs
> to be used.  This should improve performance when /tmp is a tmpfs and it is
> difficult or impossible to have an environment variable or command line -pipe
> flag passed to every piece of the toolchain.
> 
> 
> To generate a diff of this commit:
> cvs rdiff -u -r1.1.1.3 -r1.2 \
>     src/external/gpl3/binutils/dist/libiberty/make-temp-file.c
> cvs rdiff -u -r1.1.1.2 -r1.2 \
>     src/external/gpl3/gcc/dist/libiberty/make-temp-file.c
> cvs rdiff -u -r1.1.1.1 -r1.2 \
>     src/external/gpl3/gdb/dist/libiberty/make-temp-file.c
> 
> Please note that diffs are not public domain; they are subject to the
> copyright notices on the relevant files.
> 
> 
> Modified files:
> 
> Index: src/external/gpl3/binutils/dist/libiberty/make-temp-file.c
> diff -u src/external/gpl3/binutils/dist/libiberty/make-temp-file.c:1.1.1.3 src/external/gpl3/binutils/dist/libiberty/make-temp-file.c:1.2
> --- src/external/gpl3/binutils/dist/libiberty/make-temp-file.c:1.1.1.3	Sun Sep 29 13:46:38 2013
> +++ src/external/gpl3/binutils/dist/libiberty/make-temp-file.c	Mon Aug 10 15:45:40 2015
> @@ -130,10 +130,10 @@ choose_tmpdir (void)
>  	base = try_dir (P_tmpdir, base);
>  #endif
>  
> -      /* Try /var/tmp, /usr/tmp, then /tmp.  */
> +      /* Try /tmp, /var/tmp, then /usr/tmp.  */
> +      base = try_dir (tmp, base);
>        base = try_dir (vartmp, base);
>        base = try_dir (usrtmp, base);
> -      base = try_dir (tmp, base);
>        
>        /* If all else fails, use the current directory!  */
>        if (base == 0)
> 
> Index: src/external/gpl3/gcc/dist/libiberty/make-temp-file.c
> diff -u src/external/gpl3/gcc/dist/libiberty/make-temp-file.c:1.1.1.2 src/external/gpl3/gcc/dist/libiberty/make-temp-file.c:1.2
> --- src/external/gpl3/gcc/dist/libiberty/make-temp-file.c:1.1.1.2	Sat Mar  1 08:41:40 2014
> +++ src/external/gpl3/gcc/dist/libiberty/make-temp-file.c	Mon Aug 10 15:45:40 2015
> @@ -130,10 +130,10 @@ choose_tmpdir (void)
>  	base = try_dir (P_tmpdir, base);
>  #endif
>  
> -      /* Try /var/tmp, /usr/tmp, then /tmp.  */
> +      /* Try /tmp, /var/tmp, then /usr/tmp.  */
> +      base = try_dir (tmp, base);
>        base = try_dir (vartmp, base);
>        base = try_dir (usrtmp, base);
> -      base = try_dir (tmp, base);
>        
>        /* If all else fails, use the current directory!  */
>        if (base == 0)
> 
> Index: src/external/gpl3/gdb/dist/libiberty/make-temp-file.c
> diff -u src/external/gpl3/gdb/dist/libiberty/make-temp-file.c:1.1.1.1 src/external/gpl3/gdb/dist/libiberty/make-temp-file.c:1.2
> --- src/external/gpl3/gdb/dist/libiberty/make-temp-file.c:1.1.1.1	Sat Sep 24 19:49:55 2011
> +++ src/external/gpl3/gdb/dist/libiberty/make-temp-file.c	Mon Aug 10 15:45:40 2015
> @@ -130,10 +130,10 @@ choose_tmpdir (void)
>  	base = try_dir (P_tmpdir, base);
>  #endif
>  
> -      /* Try /var/tmp, /usr/tmp, then /tmp.  */
> +      /* Try /tmp, /var/tmp, then /usr/tmp.  */
> +      base = try_dir (tmp, base);
>        base = try_dir (vartmp, base);
>        base = try_dir (usrtmp, base);
> -      base = try_dir (tmp, base);
>        
>        /* If all else fails, use the current directory!  */
>        if (base == 0)
> 


Attachment: signature.asc
Description: OpenPGP digital signature



Home | Main Index | Thread Index | Old Index