python-dataproperty: bump version to 0.17.0
[buildroot-gz.git] / package / ccache / 0001-Convert-argument-to-sysroot-option-to-relative-path.patch
blob33db7d480fb435faf5c6a85df1d0dc762457702a
1 From fe42d6f7b739e8d42811bf46bcccfafa728847a2 Mon Sep 17 00:00:00 2001
2 From: =?UTF-8?q?Mathias=20De=20Mar=C3=A9?= <mathias.de_mare@nokia.com>
3 Date: Mon, 19 Sep 2016 10:38:13 +0200
4 Subject: [PATCH] Convert argument to '--sysroot' option to relative path
6 Previously, only the argument to '--sysroot=' was converted.
7 This changeset adds support for '--sysroot'.
9 Signed-off-by: Brandon Maier <brandon.maier@rockwellcollins.com>
10 Signed-off-by: Matt Weber <matthew.weber@rockwellcollins.com>
11 ---
12 ccache.c | 15 +++++++++++++++
13 1 file changed, 15 insertions(+)
15 diff --git a/ccache.c b/ccache.c
16 index 8ffadcc..76139b9 100644
17 --- a/ccache.c
18 +++ b/ccache.c
19 @@ -2407,6 +2407,21 @@ cc_process_args(struct args *args, struct args **preprocessor_args,
20 free(option);
21 continue;
23 + // Alternate form of specifying sysroot without =
24 + if (str_eq(argv[i], "--sysroot")) {
25 + if (i == argc-1) {
26 + cc_log("Missing argument to %s", argv[i]);
27 + stats_update(STATS_ARGS);
28 + result = false;
29 + goto out;
30 + }
31 + args_add(stripped_args, argv[i]);
32 + char *relpath = make_relative_path(x_strdup(argv[i+1]));
33 + args_add(stripped_args, relpath);
34 + i++;
35 + free(relpath);
36 + continue;
37 + }
38 if (str_startswith(argv[i], "-Wp,")) {
39 if (str_eq(argv[i], "-Wp,-P")
40 || strstr(argv[i], ",-P,")
41 --
42 2.8.3