|
From: <sv...@va...> - 2011-07-12 11:04:16
|
Author: sewardj
Date: 2011-07-12 11:59:27 +0100 (Tue, 12 Jul 2011)
New Revision: 11884
Log:
Conditionalise code that uses some ELF constants that Android doesn't
know about, and remove three unnecessary #defines.
Modified:
trunk/coregrind/launcher-linux.c
Modified: trunk/coregrind/launcher-linux.c
===================================================================
--- trunk/coregrind/launcher-linux.c 2011-07-12 07:27:23 UTC (rev 11883)
+++ trunk/coregrind/launcher-linux.c 2011-07-12 10:59:27 UTC (rev 11884)
@@ -47,12 +47,9 @@
#include <elf.h>
#include <errno.h>
#include <fcntl.h>
-#include <stdarg.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
-#include <sys/mman.h>
-#include <sys/user.h>
#include <unistd.h>
@@ -201,15 +198,19 @@
platform = "amd64-linux";
}
} else if (header[EI_DATA] == ELFDATA2MSB) {
+# if !defined(VGPV_arm_linux_android)
if (ehdr->e_machine == EM_PPC64 &&
(ehdr->e_ident[EI_OSABI] == ELFOSABI_SYSV ||
ehdr->e_ident[EI_OSABI] == ELFOSABI_LINUX)) {
platform = "ppc64-linux";
- } else if (ehdr->e_machine == EM_S390 &&
- (ehdr->e_ident[EI_OSABI] == ELFOSABI_SYSV ||
- ehdr->e_ident[EI_OSABI] == ELFOSABI_LINUX)) {
+ }
+ else
+ if (ehdr->e_machine == EM_S390 &&
+ (ehdr->e_ident[EI_OSABI] == ELFOSABI_SYSV ||
+ ehdr->e_ident[EI_OSABI] == ELFOSABI_LINUX)) {
platform = "s390x-linux";
}
+# endif
}
}
}
|