diff options
| author | Alexander Karatarakis <alkarata@microsoft.com> | 2016-11-10 11:04:33 -0800 |
|---|---|---|
| committer | Alexander Karatarakis <alkarata@microsoft.com> | 2016-11-10 11:40:27 -0800 |
| commit | eb7ca47d4839a6bf8cea36cba8507750cd5d7746 (patch) | |
| tree | b7a7c0544321cea3f3f6eecf29e186f1166e7fbb /toolsrc/include | |
| parent | 22f681c82d584a9962a0133ef086326f41df9cc1 (diff) | |
| download | vcpkg-eb7ca47d4839a6bf8cea36cba8507750cd5d7746.tar.gz vcpkg-eb7ca47d4839a6bf8cea36cba8507750cd5d7746.zip | |
Add checks for outdated crts
Diffstat (limited to 'toolsrc/include')
| -rw-r--r-- | toolsrc/include/BuildInfo.h | 42 |
1 files changed, 37 insertions, 5 deletions
diff --git a/toolsrc/include/BuildInfo.h b/toolsrc/include/BuildInfo.h index 235c83837..5a85d92d8 100644 --- a/toolsrc/include/BuildInfo.h +++ b/toolsrc/include/BuildInfo.h @@ -36,11 +36,6 @@ namespace vcpkg static const BuildType RELEASE_STATIC; static const BuildType RELEASE_DYNAMIC; - static constexpr int length() - { - return 4; - } - static const std::vector<BuildType>& values() { static const std::vector<BuildType> v = {DEBUG_STATIC, DEBUG_DYNAMIC, RELEASE_STATIC, RELEASE_DYNAMIC}; @@ -69,6 +64,43 @@ namespace vcpkg bool operator !=(const BuildType& lhs, const BuildType& rhs); + struct OutdatedDynamicCrt + { + static const OutdatedDynamicCrt MSVCP100_DLL; + static const OutdatedDynamicCrt MSVCP100D_DLL; + static const OutdatedDynamicCrt MSVCP110_DLL; + static const OutdatedDynamicCrt MSVCP110_WIN_DLL; + static const OutdatedDynamicCrt MSVCP120_DLL; + static const OutdatedDynamicCrt MSVCP120_CLR0400_DLL; + static const OutdatedDynamicCrt MSVCP60_DLL; + static const OutdatedDynamicCrt MSVCP_WIN_DLL; + + static const std::vector<OutdatedDynamicCrt>& values() + { + static const std::vector<OutdatedDynamicCrt> v = { + MSVCP100_DLL, MSVCP100D_DLL, + MSVCP110_DLL,MSVCP110_WIN_DLL, + MSVCP120_DLL, MSVCP120_CLR0400_DLL, + MSVCP60_DLL, MSVCP_WIN_DLL + }; + return v; + } + + OutdatedDynamicCrt() = delete; + + const std::regex& crt_regex() const; + const std::string& toString() const; + + private: + explicit OutdatedDynamicCrt(const std::string& dll_name, const std::string& crt_regex_as_string) + : m_dll_name(dll_name), m_crt_regex_as_string(crt_regex_as_string) + { + } + + std::string m_dll_name; + std::string m_crt_regex_as_string; + }; + struct BuildInfo { static BuildInfo create(const std::unordered_map<std::string, std::string>& pgh); |
