aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbellard <bellard>2005-04-10 21:43:10 +0000
committerbellard <bellard>2005-04-10 21:43:10 +0000
commitbdd09709d7b412c2cd7380172264d985fabafa6d (patch)
treec11efa9857c408ed442c47c436dd11a0ce1061b8
parentfc72e41a557fe90d4ff4e547d7c10a2b8dc0b964 (diff)
downloadtinycc-bdd09709d7b412c2cd7380172264d985fabafa6d.tar.gz
tinycc-bdd09709d7b412c2cd7380172264d985fabafa6d.tar.bz2
ELF visibility defines
-rw-r--r--elf.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/elf.h b/elf.h
index 4670958..c509760 100644
--- a/elf.h
+++ b/elf.h
@@ -402,6 +402,20 @@ typedef struct
#define STN_UNDEF 0 /* End of a chain. */
+/* How to extract and insert information held in the st_other field. */
+
+#define ELF32_ST_VISIBILITY(o) ((o) & 0x03)
+
+/* For ELF64 the definitions are the same. */
+#define ELF64_ST_VISIBILITY(o) ELF32_ST_VISIBILITY (o)
+
+/* Symbol visibility specification encoded in the st_other field. */
+#define STV_DEFAULT 0 /* Default symbol visibility rules */
+#define STV_INTERNAL 1 /* Processor specific hidden class */
+#define STV_HIDDEN 2 /* Sym unavailable in other modules */
+#define STV_PROTECTED 3 /* Not preemptible, not exported */
+
+
/* Relocation table entry without addend (in section of type SHT_REL). */
typedef struct