diff options
author | Adam Lesinski <adamlesinski@google.com> | 2014-11-03 12:05:15 -0800 |
---|---|---|
committer | Adam Lesinski <adamlesinski@google.com> | 2014-11-03 12:09:58 -0800 |
commit | c3dc0b57b8d0b3875f868788e110aa67fb032b4a (patch) | |
tree | d29bf5702b81c4f283ae5e463af00c1e9327d459 /tools/split-select/SplitDescription.cpp | |
parent | 425b1dc88c47e0e9d3a653ad902a69f3ec09b966 (diff) | |
download | frameworks_base-c3dc0b57b8d0b3875f868788e110aa67fb032b4a.zip frameworks_base-c3dc0b57b8d0b3875f868788e110aa67fb032b4a.tar.gz frameworks_base-c3dc0b57b8d0b3875f868788e110aa67fb032b4a.tar.bz2 |
Build the split-select tool without C++11 support
It was complicated to get the tool building on Windows, Linux,
and OSX with C++11 support.
OSX uses Clang to build C++11 binaries, which requires the libc++
standard library. Since most of the dependencies of this program
are built against libstdc++, this was difficult to resolve.
Now we build without C++11 support.
Change-Id: I4e537c113734508a8f480a1c402ed237de4f0e60
Diffstat (limited to 'tools/split-select/SplitDescription.cpp')
-rw-r--r-- | tools/split-select/SplitDescription.cpp | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/tools/split-select/SplitDescription.cpp b/tools/split-select/SplitDescription.cpp index 8037ef0..99bc23d 100644 --- a/tools/split-select/SplitDescription.cpp +++ b/tools/split-select/SplitDescription.cpp @@ -27,7 +27,7 @@ using namespace android; namespace split { SplitDescription::SplitDescription() -: abi(abi::Variant::none) { +: abi(abi::Variant_none) { } int SplitDescription::compare(const SplitDescription& rhs) const { @@ -38,11 +38,11 @@ int SplitDescription::compare(const SplitDescription& rhs) const { } bool SplitDescription::isBetterThan(const SplitDescription& o, const SplitDescription& target) const { - if (abi != abi::Variant::none || o.abi != abi::Variant::none) { + if (abi != abi::Variant_none || o.abi != abi::Variant_none) { abi::Family family = abi::getFamily(abi); abi::Family oFamily = abi::getFamily(o.abi); if (family != oFamily) { - return family != abi::Family::none; + return family != abi::Family_none; } if (int(target.abi) - int(abi) < int(target.abi) - int(o.abi)) { @@ -53,7 +53,7 @@ bool SplitDescription::isBetterThan(const SplitDescription& o, const SplitDescri } bool SplitDescription::match(const SplitDescription& o) const { - if (abi != abi::Variant::none) { + if (abi != abi::Variant_none) { abi::Family family = abi::getFamily(abi); abi::Family oFamily = abi::getFamily(o.abi); if (family != oFamily) { @@ -69,7 +69,7 @@ bool SplitDescription::match(const SplitDescription& o) const { String8 SplitDescription::toString() const { String8 extension; - if (abi != abi::Variant::none) { + if (abi != abi::Variant_none) { if (extension.isEmpty()) { extension.append(":"); } else { @@ -85,40 +85,40 @@ String8 SplitDescription::toString() const { ssize_t parseAbi(const Vector<String8>& parts, const ssize_t index, SplitDescription* outSplit) { const ssize_t N = parts.size(); - abi::Variant abi = abi::Variant::none; + abi::Variant abi = abi::Variant_none; ssize_t endIndex = index; if (parts[endIndex] == "arm64") { endIndex++; if (endIndex < N) { if (parts[endIndex] == "v8a") { endIndex++; - abi = abi::Variant::arm64_v8a; + abi = abi::Variant_arm64_v8a; } } } else if (parts[endIndex] == "armeabi") { endIndex++; - abi = abi::Variant::armeabi; + abi = abi::Variant_armeabi; if (endIndex < N) { if (parts[endIndex] == "v7a") { endIndex++; - abi = abi::Variant::armeabi_v7a; + abi = abi::Variant_armeabi_v7a; } } } else if (parts[endIndex] == "x86") { endIndex++; - abi = abi::Variant::x86; + abi = abi::Variant_x86; } else if (parts[endIndex] == "x86_64") { endIndex++; - abi = abi::Variant::x86_64; + abi = abi::Variant_x86_64; } else if (parts[endIndex] == "mips") { endIndex++; - abi = abi::Variant::mips; + abi = abi::Variant_mips; } else if (parts[endIndex] == "mips64") { endIndex++; - abi = abi::Variant::mips64; + abi = abi::Variant_mips64; } - if (abi == abi::Variant::none && endIndex != index) { + if (abi == abi::Variant_none && endIndex != index) { return -1; } |