diff options
author | Mikhail Paulyshka <me@mixaill.tk> | 2017-03-22 14:27:13 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2017-03-22 20:20:03 (GMT) |
commit | 97c605fd5bca193d0aeb90a4985fbccc884401ec (patch) | |
tree | f3b8fb0d65358248e99c43f6fb880ff0bab28bc0 | |
parent | 7a8860afbc614f2215e083adadb25963fe8f4dfe (diff) | |
download | CMake-97c605fd5bca193d0aeb90a4985fbccc884401ec.zip CMake-97c605fd5bca193d0aeb90a4985fbccc884401ec.tar.gz CMake-97c605fd5bca193d0aeb90a4985fbccc884401ec.tar.bz2 |
bindexplib: remove unused code
Remove code not used since commit v3.7.0-rc1~395^2 (bindexplib: Export
symbols from objects even with explicit markup, 2016-06-30).
-rw-r--r-- | Source/bindexplib.cxx | 67 |
1 files changed, 0 insertions, 67 deletions
diff --git a/Source/bindexplib.cxx b/Source/bindexplib.cxx index dc7f1a9..4839ec8 100644 --- a/Source/bindexplib.cxx +++ b/Source/bindexplib.cxx @@ -181,60 +181,6 @@ public: /* *---------------------------------------------------------------------- - * HaveExportedObjects -- - * - * Returns true if export directives (declspec(dllexport)) exist. - * - *---------------------------------------------------------------------- - */ - - bool HaveExportedObjects() - { - WORD i = 0; - size_t size = 0; - const char* rawdata = 0; - PIMAGE_SECTION_HEADER pDirectivesSectionHeader = 0; - PIMAGE_SECTION_HEADER pSectionHeaders = this->SectionHeaders; - for (i = 0; (i < this->ObjectImageHeader->NumberOfSections && - !pDirectivesSectionHeader); - i++) - if (!strncmp((const char*)&pSectionHeaders[i].Name[0], ".drectve", 8)) - pDirectivesSectionHeader = &pSectionHeaders[i]; - if (!pDirectivesSectionHeader) - return 0; - - rawdata = (const char*)this->ObjectImageHeader + - pDirectivesSectionHeader->PointerToRawData; - if (!pDirectivesSectionHeader->PointerToRawData || !rawdata) - return 0; - - size = pDirectivesSectionHeader->SizeOfRawData; - const char* posImportFlag = rawdata; - while ((posImportFlag = StrNStr(posImportFlag, " /EXPORT:", size))) { - const char* lookingForDict = posImportFlag + 9; - if (!strncmp(lookingForDict, "_G__cpp_", 8) || - !strncmp(lookingForDict, "_G__set_cpp_", 12)) { - posImportFlag = lookingForDict; - continue; - } - - const char* lookingForDATA = posImportFlag + 9; - while (*(++lookingForDATA) && *lookingForDATA != ' ') - ; - lookingForDATA -= 5; - // ignore DATA exports - if (strncmp(lookingForDATA, ",DATA", 5)) - break; - posImportFlag = lookingForDATA + 5; - } - if (posImportFlag) { - return true; - } - return false; - } - - /* - *---------------------------------------------------------------------- * DumpObjFile -- * * Dump an object file's exported symbols. @@ -319,19 +265,6 @@ public: } } } - } else if (pSymbolTable->SectionNumber == IMAGE_SYM_UNDEFINED && - !pSymbolTable->Type && 0) { - /* - * The IMPORT global variable entry points - */ - if (pSymbolTable->StorageClass == IMAGE_SYM_CLASS_EXTERNAL) { - symbol = stringTable + pSymbolTable->N.Name.Long; - while (isspace(symbol[0])) - symbol.erase(0, 1); - if (symbol[0] == '_') - symbol.erase(0, 1); - this->DataSymbols.insert(symbol); - } } /* |