Don't allow text relocations on 64-bit.

I've also updated our <sys/exec_elf.h> to match upstream.

Change-Id: I52f9fce3167541811208d273ff23ceaa112f7135
diff --git a/linker/linker.h b/linker/linker.h
index 4ba354d..b9e1237 100644
--- a/linker/linker.h
+++ b/linker/linker.h
@@ -183,7 +183,9 @@
   // value to get the corresponding address in the process' address space.
   Elf_Addr load_bias;
 
+#if !defined(__LP64__)
   bool has_text_relocations;
+#endif
   bool has_DT_SYMBOLIC;
 
   void CallConstructors();
@@ -195,15 +197,16 @@
   void CallFunction(const char* function_name, linker_function_t function);
 };
 
-extern soinfo libdl_info;
+// The possible DT_FLAGS bits are in
+// http://www.sco.com/developers/gabi/latest/ch5.dynamic.html#dynamic_section
+// but not in the upstream NetBSD <sys/exec_elf.h> header file ours is based on.
+#define DF_ORIGIN 0x1
+#define DF_SYMBOLIC 0x2
+#define DF_TEXTREL 0x4
+#define DF_BIND_NOW 0x8
+#define DF_STATIC_TLS 0x10
 
-// These aren't defined in <sys/exec_elf.h>.
-#ifndef DT_PREINIT_ARRAY
-#define DT_PREINIT_ARRAY   32
-#endif
-#ifndef DT_PREINIT_ARRAYSZ
-#define DT_PREINIT_ARRAYSZ 33
-#endif
+extern soinfo libdl_info;
 
 void do_android_update_LD_LIBRARY_PATH(const char* ld_library_path);
 soinfo* do_dlopen(const char* name, int flags);