Hex Artifact Content

Artifact 36d16f76acabe21b9395df6343f11507fe45b0e8:


0000: 23 21 20 2f 62 69 6e 2f 62 61 73 68 0a 0a 69 66  #! /bin/bash..if
0010: 20 5b 20 2d 7a 20 22 24 7b 43 52 4f 53 53 7d 22   [ -z "${CROSS}"
0020: 20 5d 3b 20 74 68 65 6e 0a 09 65 63 68 6f 20 27   ]; then..echo '
0030: 45 72 72 6f 72 3a 20 45 6e 76 69 72 6f 6e 6d 65  Error: Environme
0040: 6e 74 20 76 61 72 69 61 62 6c 65 20 43 52 4f 53  nt variable CROS
0050: 53 20 69 73 20 65 6d 70 74 79 2f 75 6e 73 65 74  S is empty/unset
0060: 2e 20 20 41 62 6f 72 74 69 6e 67 2e 27 20 3e 26  .  Aborting.' >&
0070: 32 0a 0a 09 65 78 69 74 20 31 0a 66 69 0a 0a 50  2...exit 1.fi..P
0080: 41 54 48 3d 22 24 28 70 77 64 29 2f 62 75 69 6c  ATH="$(pwd)/buil
0090: 64 2f 66 61 6b 65 2d 62 69 6e 3a 24 7b 48 4f 4d  d/fake-bin:${HOM
00a0: 45 7d 2f 72 6f 6f 74 2f 63 72 6f 73 73 2d 63 6f  E}/root/cross-co
00b0: 6d 70 69 6c 65 72 73 2f 24 7b 43 52 4f 53 53 7d  mpilers/${CROSS}
00c0: 2f 24 7b 43 52 4f 53 53 7d 2f 62 69 6e 3a 24 7b  /${CROSS}/bin:${
00d0: 50 41 54 48 7d 3a 24 7b 48 4f 4d 45 7d 2f 72 6f  PATH}:${HOME}/ro
00e0: 6f 74 2f 63 72 6f 73 73 2d 63 6f 6d 70 69 6c 65  ot/cross-compile
00f0: 72 73 2f 24 7b 43 52 4f 53 53 7d 2f 62 69 6e 22  rs/${CROSS}/bin"
0100: 0a 41 52 3d 22 24 7b 43 52 4f 53 53 7d 2d 61 72  .AR="${CROSS}-ar
0110: 22 0a 43 43 3d 22 24 7b 43 52 4f 53 53 7d 2d 67  ".CC="${CROSS}-g
0120: 63 63 20 24 7b 43 43 5f 41 44 44 7d 22 0a 43 58  cc ${CC_ADD}".CX
0130: 58 3d 22 24 7b 43 52 4f 53 53 7d 2d 67 2b 2b 20  X="${CROSS}-g++ 
0140: 24 7b 43 43 5f 41 44 44 7d 22 0a 52 41 4e 4c 49  ${CC_ADD}".RANLI
0150: 42 3d 22 24 7b 43 52 4f 53 53 7d 2d 72 61 6e 6c  B="${CROSS}-ranl
0160: 69 62 22 0a 53 54 52 49 50 3d 22 24 7b 43 52 4f  ib".STRIP="${CRO
0170: 53 53 7d 2d 73 74 72 69 70 22 0a 65 78 70 6f 72  SS}-strip".expor
0180: 74 20 50 41 54 48 20 41 52 20 43 43 20 43 58 58  t PATH AR CC CXX
0190: 20 52 41 4e 4c 49 42 20 53 54 52 49 50 0a 0a 2e   RANLIB STRIP...
01a0: 2f 6b 69 74 63 72 65 61 74 6f 72 20 22 24 40 22  /kitcreator "$@"
01b0: 20 2d 2d 68 6f 73 74 3d 22 24 7b 43 52 4f 53 53   --host="${CROSS
01c0: 7d 22 0a                                         }".