diff options
Diffstat (limited to 'meta-xilinx-bsp/recipes-microblaze/gcc/gcc-9/0056-fix-the-lto-wrapper-issue-on-windows.patch')
-rw-r--r-- | meta-xilinx-bsp/recipes-microblaze/gcc/gcc-9/0056-fix-the-lto-wrapper-issue-on-windows.patch | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/meta-xilinx-bsp/recipes-microblaze/gcc/gcc-9/0056-fix-the-lto-wrapper-issue-on-windows.patch b/meta-xilinx-bsp/recipes-microblaze/gcc/gcc-9/0056-fix-the-lto-wrapper-issue-on-windows.patch new file mode 100644 index 00000000..ff524770 --- /dev/null +++ b/meta-xilinx-bsp/recipes-microblaze/gcc/gcc-9/0056-fix-the-lto-wrapper-issue-on-windows.patch | |||
@@ -0,0 +1,36 @@ | |||
1 | From f30b99b5b8d3f2a8d8e4973cd155a4b9f1849039 Mon Sep 17 00:00:00 2001 | ||
2 | From: Nagaraju <nmekala@xilinx.com> | ||
3 | Date: Thu, 14 Mar 2019 18:08:06 +0530 | ||
4 | Subject: [PATCH 56/57] fix the lto-wrapper issue on windows | ||
5 | |||
6 | --- | ||
7 | libiberty/simple-object.c | 6 +++++- | ||
8 | 1 file changed, 5 insertions(+), 1 deletion(-) | ||
9 | |||
10 | diff --git a/libiberty/simple-object.c b/libiberty/simple-object.c | ||
11 | index 42aa6ac..d2465c6 100644 | ||
12 | --- a/libiberty/simple-object.c | ||
13 | +++ b/libiberty/simple-object.c | ||
14 | @@ -44,6 +44,10 @@ Boston, MA 02110-1301, USA. */ | ||
15 | #define SEEK_SET 0 | ||
16 | #endif | ||
17 | |||
18 | +#ifndef O_BINARY | ||
19 | +#define O_BINARY 0 | ||
20 | +#endif | ||
21 | + | ||
22 | #include "simple-object-common.h" | ||
23 | |||
24 | /* The known object file formats. */ | ||
25 | @@ -326,7 +330,7 @@ simple_object_copy_lto_debug_sections (simple_object_read *sobj, | ||
26 | return errmsg; | ||
27 | } | ||
28 | |||
29 | - outfd = creat (dest, 00777); | ||
30 | + outfd = open (dest, O_CREAT|O_WRONLY|O_TRUNC|O_BINARY, 00777); | ||
31 | if (outfd == -1) | ||
32 | { | ||
33 | *err = errno; | ||
34 | -- | ||
35 | 2.7.4 | ||
36 | |||