diff options
| author | Ed Maste <emaste@FreeBSD.org> | 2021-01-13 19:21:38 +0000 |
|---|---|---|
| committer | Ed Maste <emaste@FreeBSD.org> | 2021-01-26 14:43:42 +0000 |
| commit | 49d3dcb041f058880486e3489ca79c9476ac7abf (patch) | |
| tree | 6947007d1acf67f5fc0ae1c97df1b2392e384666 /usr.bin/elfctl | |
| parent | 70cdab054c8ffe7f5561ab8f31db33ee62d12c9c (diff) | |
Diffstat (limited to 'usr.bin/elfctl')
| -rw-r--r-- | usr.bin/elfctl/elfctl.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/usr.bin/elfctl/elfctl.c b/usr.bin/elfctl/elfctl.c index 725752375d16..efc993302c60 100644 --- a/usr.bin/elfctl/elfctl.c +++ b/usr.bin/elfctl/elfctl.c @@ -234,6 +234,16 @@ convert_to_feature_val(char *feature_str, uint32_t *feature_val) input |= featurelist[i].value; break; } + /* XXX Backwards compatibility for "no"-prefix flags. */ + if (strncmp(featurelist[i].alias, "no", 2) == 0 && + strcmp(featurelist[i].alias + 2, feature) == 0) { + input |= featurelist[i].value; + warnx( + "interpreting %s as %s; please specify %s", + feature, featurelist[i].alias, + featurelist[i].alias); + break; + } } if (i == len) { warnx("%s is not a valid feature", feature); |
