diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2023-09-28 14:05:59 +0200 |
---|---|---|
committer | Boris Kolpackov <boris@codesynthesis.com> | 2023-09-28 14:05:59 +0200 |
commit | cbf3f2d5b3787c8281f3227b65ec30170fcd3379 (patch) | |
tree | 6e0bbfdf10bc0b3d91b54ca8b6ff86ae564854a2 /libbuild2/bin/def-rule.cxx | |
parent | 1c14594f791665d2f5c8813bc8c537ff663906c8 (diff) |
Don't mark rdata symbols DATA in MSVC .def file (GH issue #315)
Diffstat (limited to 'libbuild2/bin/def-rule.cxx')
-rw-r--r-- | libbuild2/bin/def-rule.cxx | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/libbuild2/bin/def-rule.cxx b/libbuild2/bin/def-rule.cxx index 0998c89..143cc35 100644 --- a/libbuild2/bin/def-rule.cxx +++ b/libbuild2/bin/def-rule.cxx @@ -417,6 +417,8 @@ namespace build2 // we will try to recognize C/C++ identifiers plus the special symbols // that we need to export (e.g., vtable). // + // Note that it looks like rdata should not be declared DATA. It is + // known to break ??_7 (vtable) exporting (see GH issue 315). // for (const string& s: syms.r) { @@ -424,7 +426,7 @@ namespace build2 (s[0] == '?' && s[1] != '?') || // C++ s.compare (0, 4, "??_7") == 0) // vtable { - os << " " << strip (s) << " DATA\n"; + os << " " << strip (s) << '\n'; } } } @@ -496,6 +498,12 @@ namespace build2 // we will try to recognize C/C++ identifiers plus the special symbols // that we need to export (e.g., vtable and typeinfo). // + // For the description of GNU binutils .def format, see: + // + // https://sourceware.org/binutils/docs/binutils/def-file-format.html + // + // @@ Maybe CONSTANT is more appropriate than DATA? + // for (const string& s: syms.r) { if (s.find_first_of (".") != string::npos) // Special (.refptr.*) |