From 50320b1d4a1dd06db70aeea485e0ffd9871548e0 Mon Sep 17 00:00:00 2001 From: marxin Date: Thu, 26 Jul 2018 12:13:14 +0000 Subject: Copy from GCC: Add linker_output as prefix for LTO temps (PR lto/86548). 2018-07-26 Martin Liska PR lto/86548 * libiberty.h (make_temp_file_with_prefix): New function. 2018-07-26 Martin Liska PR lto/86548 * make-temp-file.c (TEMP_FILE): Remove leading 'cc'. (make_temp_file): Call make_temp_file_with_prefix with first argument set to NULL. (make_temp_file_with_prefix): Support also prefix. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@262999 138bc75d-0d04-0410-961f-82ee72b054a4 --- include/ChangeLog | 8 ++++++++ include/libiberty.h | 5 +++++ 2 files changed, 13 insertions(+) (limited to 'include') diff --git a/include/ChangeLog b/include/ChangeLog index f47059fd7f5..3dbc887c133 100644 --- a/include/ChangeLog +++ b/include/ChangeLog @@ -1,3 +1,11 @@ +2018-08-01 Richard Earnshaw + + Copy over from GCC + 2018-07-26 Martin Liska + + PR lto/86548 + * libiberty.h (make_temp_file_with_prefix): New function. + 2018-07-30 Jim Wilson * opcode/riscv.h (INSN_TYPE, INSN_BRANCH, INSN_CONDBRANCH, INSN_JSR) diff --git a/include/libiberty.h b/include/libiberty.h index dc09e791e41..0823614c00e 100644 --- a/include/libiberty.h +++ b/include/libiberty.h @@ -239,6 +239,11 @@ extern char *choose_temp_base (void) ATTRIBUTE_MALLOC ATTRIBUTE_RETURNS_NONNULL; extern char *make_temp_file (const char *) ATTRIBUTE_MALLOC; +/* Return a temporary file name with given PREFIX and SUFFIX + or NULL if unable to create one. */ + +extern char *make_temp_file_with_prefix (const char *, const char *) ATTRIBUTE_MALLOC; + /* Remove a link to a file unless it is special. */ extern int unlink_if_ordinary (const char *); -- cgit v1.2.1