1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
# DP: let gold accept a dummy -z buildd-<random-string> option.
--- a/gold/options.h
+++ b/gold/options.h
@@ -1162,6 +1162,9 @@
DEFINE_bool_alias(textoff, text, options::DASH_Z, '\0',
N_("Permit relocations in read-only segments (default)"),
NULL, true);
+ DEFINE_bool(buildd, options::DASH_Z, '\0', false,
+ N_("Dummy z option"),
+ NULL);
public:
typedef options::Dir_list Dir_list;
--- a/gold/options.cc
+++ b/gold/options.cc
@@ -859,6 +859,8 @@
{
int dummy_i = 0;
const char* dash_z_arg = *arg;
+ if (strncmp(dash_z_arg, "buildd", strlen("buildd")) == 0)
+ *arg = "buildd";
retval = parse_long_option(1, arg, true, arg, &dummy_i);
if (retval == NULL)
usage(_("unknown -z option"), dash_z_arg);
|