diff options
author | Denis Vlasenko | 2007-08-12 20:58:27 +0000 |
---|---|---|
committer | Denis Vlasenko | 2007-08-12 20:58:27 +0000 |
commit | 6ca409e0e4c198fe3081346eebbae3f068fe605a (patch) | |
tree | 060cb05d99220a1eda399194d1209c269f0e8cd8 /include | |
parent | 4185548984357df91311f30c8e43d95f33922576 (diff) | |
download | busybox-6ca409e0e4c198fe3081346eebbae3f068fe605a.zip busybox-6ca409e0e4c198fe3081346eebbae3f068fe605a.tar.gz |
trylink: produce even more info about final link stage
trylink: explain how to modify link and drastically decrease amount
of padding (unfortunately, needs hand editing ATM).
*: add ALIGN1 / ALIGN2 to global strings and arrays of bytes and shorts
size saving: 0.5k
Diffstat (limited to 'include')
-rw-r--r-- | include/platform.h | 16 |
1 files changed, 13 insertions, 3 deletions
diff --git a/include/platform.h b/include/platform.h index dcdb5c8..ff23ca1 100644 --- a/include/platform.h +++ b/include/platform.h @@ -169,7 +169,7 @@ __extension__ typedef unsigned long long __u64; # error "Sorry, this libc version is not supported :(" #endif -// Don't perpetuate e2fsck crap into the headers. Clean up e2fsck instead. +/* Don't perpetuate e2fsck crap into the headers. Clean up e2fsck instead. */ #if defined __GLIBC__ || defined __UCLIBC__ \ || defined __dietlibc__ || defined _NEWLIB_VERSION @@ -210,6 +210,16 @@ typedef unsigned smalluint; #include <stdbool.h> #endif +/* Try to defeat gcc's alignment of "char message[]"-like data */ +#if 1 /* if needed: !defined(arch1) && !defined(arch2) */ +#define ALIGN1 __attribute__((aligned(1))) +#define ALIGN2 __attribute__((aligned(2))) +#else +/* Arches which MUST have 2 or 4 byte alignment for everything are here */ +#define ALIGN1 +#define ALIGN2 +#endif + /* uclibc does not implement daemon() for no-mmu systems. * For 0.9.29 and svn, __ARCH_USE_MMU__ indicates no-mmu reliably. @@ -289,7 +299,7 @@ static ALWAYS_INLINE char* strchrnul(const char *s, char c) #if defined(__linux__) #include <sys/mount.h> -// Make sure we have all the new mount flags we actually try to use. +/* Make sure we have all the new mount flags we actually try to use. */ #ifndef MS_BIND #define MS_BIND (1<<12) #endif @@ -303,7 +313,7 @@ static ALWAYS_INLINE char* strchrnul(const char *s, char c) #define MS_SILENT (1<<15) #endif -// The shared subtree stuff, which went in around 2.6.15 +/* The shared subtree stuff, which went in around 2.6.15. */ #ifndef MS_UNBINDABLE #define MS_UNBINDABLE (1<<17) #endif |