grub2: bring back build of aros-side grub2 tools
[AROS.git] / tools / collect-aros / env.h.in
blob303011f127ddd6a8a01a4c706f72b940150fe174
1 #ifndef _ENV_H_
2 #define _ENV_H_
4 /*
5 * Under Windows we can't use paths provided by configure because they are UNIX-style
6 * and we don't use MSYS
7 */
8 #ifdef _WIN32
9 #ifndef _STANDALONE_
10 #define _STANDALONE_
11 #endif
12 #endif
14 #ifdef _NATIVE_
15 #define LD_NAME "/Development/bin/ld"
16 #define STRIP_NAME "/Development/bin/strip"
17 #define NM_NAME "/Development/bin/nm"
18 #define OBJDUMP_NAME "/Development/bin/objdump"
19 #endif
20 #ifdef _CROSS_
21 #define LD_NAME "@AROS_CROSSTOOLSDIR@/@aros_target_cpu@-aros-ld"
22 #define STRIP_NAME "@AROS_CROSSTOOLSDIR@/@aros_target_cpu@-aros-strip"
23 #define NM_NAME "@AROS_CROSSTOOLSDIR@/@aros_target_cpu@-aros-nm"
24 #define OBJDUMP_NAME "@AROS_CROSSTOOLSDIR@/@aros_target_cpu@-aros-objdump"
25 #endif
26 #ifdef _STANDALONE_
27 #define LD_NAME "@aros_target_cpu@-aros-ld"
28 #define STRIP_NAME "@aros_target_cpu@-aros-strip"
29 #define NM_NAME "@aros_target_cpu@-aros-nm"
30 #define OBJDUMP_NAME "@aros_target_cpu@-aros-objdump"
31 #endif
33 #ifndef LD_NAME
34 /* The following lines will be patched by AROS-SDK-Install */
35 #define LD_NAME "@orig_target_ld@"
36 #define STRIP_NAME "@aros_target_strip@"
37 #define NM_NAME "@aros_target_nm@"
38 #define OBJDUMP_NAME "@aros_target_objdump@"
39 #endif
41 #define TARGET_CPU_@aros_target_cpu@
44 * Having these conditions here helps to bootstrap a crosscompiler.
45 * You don't have to look up a value in configure script any more.
47 #ifdef TARGET_CPU_m68k
48 #define OBJECT_FORMAT "-mm68kelf"
49 #endif
50 #ifdef TARGET_CPU_ppc
51 #define OBJECT_FORMAT "-melf32ppc"
52 #endif
53 #ifdef TARGET_CPU_i386
54 #define OBJECT_FORMAT "-melf_i386"
55 #endif
56 #ifdef TARGET_CPU_x86_64
57 #define OBJECT_FORMAT "-melf_x86_64"
58 #endif
59 #ifdef TARGET_CPU_aarch64
60 #define OBJECT_FORMAT "-maarch64elf_aros"
61 #endif
62 #ifdef TARGET_CPU_arm
63 #define OBJECT_FORMAT "-marmelf_aros"
64 #endif
65 #ifdef TARGET_CPU_sparc
66 #define OBJECT_FORMAT "-melf_sparc"
67 #endif
68 #ifndef OBJECT_FORMAT
69 #error Unknown object format for your target CPU
70 #endif
72 #endif /* !_ENV_H */