From dc8abaa3ed2010763e621f8baa1bfda78e4ae2e0 Mon Sep 17 00:00:00 2001 From: Alex Crichton Date: Fri, 28 Jul 2017 11:41:14 -0700 Subject: [PATCH] Fix compile on dist-i686-linux builder If this lines are present then we apparently get errors [1] when compiling in the current [2] dist-i686-linux container. Attempts to upgrade both gcc and binutils did not fix the error, so it appears that this may just be a bug in the super old glibc we're using on the dist-i686-linux container. We don't actually need this code anyway, so just work around these issues by removing references to the `*64` functions. This'll get things compiling locally and shouldn't be a regression in functionality. [1]: https://travis-ci.org/rust-lang/rust/jobs/257578199 [2]: https://github.com/rust-lang/rust/tree/eba9d7f08ce5c90549ee52337aca0010ad566f0d/src/ci/docker/dist-i686-linux --- .../RuntimeDyld/RTDyldMemoryManager.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/lib/ExecutionEngine/RuntimeDyld/RTDyldMemoryManager.cpp b/lib/ExecutionEngine/RuntimeDyld/RTDyldMemoryManager.cpp index 99e84b7496d4..57cd9fa37354 100644 --- a/lib/ExecutionEngine/RuntimeDyld/RTDyldMemoryManager.cpp +++ b/lib/ExecutionEngine/RuntimeDyld/RTDyldMemoryManager.cpp @@ -119,10 +119,10 @@ void RTDyldMemoryManager::deregisterEHFramesInProcess(uint8_t *Addr, void RTDyldMemoryManager::registerEHFramesInProcess(uint8_t *Addr, size_t Size) { - // On Linux __register_frame takes a single argument: + // On Linux __register_frame takes a single argument: // a pointer to the start of the .eh_frame section. - // How can it find the end? Because crtendS.o is linked + // How can it find the end? Because crtendS.o is linked // in and it has an .eh_frame section with four zero chars. __register_frame(Addr); } @@ -243,9 +243,9 @@ RTDyldMemoryManager::getSymbolAddressInProcess(const std::string &Name) { if (Name == "stat") return (uint64_t)&stat; if (Name == "fstat") return (uint64_t)&fstat; if (Name == "lstat") return (uint64_t)&lstat; - if (Name == "stat64") return (uint64_t)&stat64; - if (Name == "fstat64") return (uint64_t)&fstat64; - if (Name == "lstat64") return (uint64_t)&lstat64; + // if (Name == "stat64") return (uint64_t)&stat64; + // if (Name == "fstat64") return (uint64_t)&fstat64; + // if (Name == "lstat64") return (uint64_t)&lstat64; if (Name == "atexit") return (uint64_t)&atexit; if (Name == "mknod") return (uint64_t)&mknod; @@ -255,7 +255,7 @@ RTDyldMemoryManager::getSymbolAddressInProcess(const std::string &Name) { return (uint64_t)&__morestack; #endif #endif // __linux__ && __GLIBC__ - + // See ARM_MATH_IMPORTS definition for explanation #if defined(__BIONIC__) && defined(__arm__) if (Name.compare(0, 8, "__aeabi_") == 0) {