Artifact
f4669e4ffeeee83d7d00d6bba9f7e3d3f1d3db5c:
0000: 2f 2f 20 41 73 73 65 6d 62 6c 79 20 6c 61 6e 67 // Assembly lang
0010: 75 61 67 65 20 73 75 70 70 6f 72 74 20 66 6f 72 uage support for
0020: 20 6d 36 38 6b 20 43 50 55 2e 0a 2f 2f 20 42 72 m68k CPU..// Br
0030: 75 6e 6f 20 48 61 69 62 6c 65 20 32 39 2e 35 2e uno Haible 29.5.
0040: 31 39 39 39 0a 0a 23 69 66 64 65 66 20 41 53 4d 1999..#ifdef ASM
0050: 5f 55 4e 44 45 52 53 43 4f 52 45 0a 2f 2f 20 53 _UNDERSCORE.// S
0060: 75 6e 4f 53 2c 20 4e 65 74 42 53 44 2c 20 4f 70 unOS, NetBSD, Op
0070: 65 6e 42 53 44 2c 20 4c 69 6e 75 78 2f 61 2e 6f enBSD, Linux/a.o
0080: 75 74 0a 23 69 66 64 65 66 20 5f 5f 53 54 44 43 ut.#ifdef __STDC
0090: 5f 5f 0a 23 64 65 66 69 6e 65 20 43 28 65 6e 74 __.#define C(ent
00a0: 72 79 70 6f 69 6e 74 29 20 5f 23 23 65 6e 74 72 rypoint) _##entr
00b0: 79 70 6f 69 6e 74 0a 23 65 6c 73 65 0a 23 64 65 ypoint.#else.#de
00c0: 66 69 6e 65 20 43 28 65 6e 74 72 79 70 6f 69 6e fine C(entrypoin
00d0: 74 29 20 5f 2f 2a 2a 2f 65 6e 74 72 79 70 6f 69 t) _/**/entrypoi
00e0: 6e 74 0a 23 65 6e 64 69 66 0a 23 65 6c 73 65 0a nt.#endif.#else.
00f0: 2f 2f 20 53 56 52 34 2c 20 41 2f 55 58 2c 20 41 // SVR4, A/UX, A
0100: 4d 49 58 2c 20 41 74 61 72 69 2c 20 4c 69 6e 75 MIX, Atari, Linu
0110: 78 2f 45 4c 46 0a 23 64 65 66 69 6e 65 20 43 28 x/ELF.#define C(
0120: 65 6e 74 72 79 70 6f 69 6e 74 29 20 65 6e 74 72 entrypoint) entr
0130: 79 70 6f 69 6e 74 0a 23 65 6e 64 69 66 0a 0a 2f ypoint.#endif../
0140: 2f 20 57 68 65 6e 20 61 73 73 65 6d 62 6c 79 20 / When assembly
0150: 6c 61 6e 67 75 61 67 65 20 63 6f 64 65 20 69 73 language code is
0160: 20 63 6f 6d 70 69 6c 65 64 20 69 6e 74 6f 20 61 compiled into a
0170: 20 73 68 61 72 65 64 20 6c 69 62 72 61 72 79 2c shared library,
0180: 20 45 4c 46 20 6c 69 6e 6b 65 72 73 0a 2f 2f 20 ELF linkers.//
0190: 6e 65 65 64 20 74 6f 20 6b 6e 6f 77 20 77 68 69 need to know whi
01a0: 63 68 20 73 79 6d 62 6f 6c 73 20 61 72 65 20 66 ch symbols are f
01b0: 75 6e 63 74 69 6f 6e 73 2e 0a 23 69 66 20 64 65 unctions..#if de
01c0: 66 69 6e 65 64 28 5f 5f 4e 65 74 42 53 44 5f 5f fined(__NetBSD__
01d0: 29 20 7c 7c 20 64 65 66 69 6e 65 64 28 5f 5f 4f ) || defined(__O
01e0: 70 65 6e 42 53 44 5f 5f 29 20 7c 7c 20 64 65 66 penBSD__) || def
01f0: 69 6e 65 64 28 5f 5f 45 4c 46 5f 5f 29 20 7c 7c ined(__ELF__) ||
0200: 20 64 65 66 69 6e 65 64 28 5f 5f 73 76 72 34 5f defined(__svr4_
0210: 5f 29 0a 23 64 65 66 69 6e 65 20 44 45 43 4c 41 _).#define DECLA
0220: 52 45 5f 46 55 4e 43 54 49 4f 4e 28 6e 61 6d 65 RE_FUNCTION(name
0230: 29 20 2e 74 79 70 65 20 43 28 6e 61 6d 65 29 2c ) .type C(name),
0240: 40 66 75 6e 63 74 69 6f 6e 0a 23 65 6c 73 65 0a @function.#else.
0250: 23 64 65 66 69 6e 65 20 44 45 43 4c 41 52 45 5f #define DECLARE_
0260: 46 55 4e 43 54 49 4f 4e 28 6e 61 6d 65 29 0a 23 FUNCTION(name).#
0270: 65 6e 64 69 66 0a endif.