[b0562e74] | 1 | # |
---|
| 2 | # Config file for the PowerPC 60x simulator - psim |
---|
| 3 | # |
---|
| 4 | # $Id$ |
---|
| 5 | # |
---|
| 6 | |
---|
| 7 | include $(RTEMS_ROOT)/make/custom/default.cfg |
---|
| 8 | |
---|
| 9 | RTEMS_CPU=powerpc |
---|
| 10 | RTEMS_CPU_MODEL=ppc603e |
---|
| 11 | |
---|
| 12 | # This is the actual bsp directory used during the build process. |
---|
| 13 | RTEMS_BSP_FAMILY=psim |
---|
| 14 | |
---|
| 15 | # This target does NOT support the KA9Q TCP/IP stack so ignore requests |
---|
| 16 | # to enable it. |
---|
| 17 | HAS_KA9Q=no |
---|
| 18 | |
---|
| 19 | # This section makes the target dependent options file. |
---|
| 20 | |
---|
| 21 | # NDEBUG (C library) |
---|
| 22 | # if defined asserts do not generate code. This is commonly used |
---|
| 23 | # as a command line option. |
---|
| 24 | # |
---|
| 25 | # RTEMS_TEST_NO_PAUSE (RTEMS tests) |
---|
| 26 | # do not pause between screens of output in the rtems tests |
---|
| 27 | # |
---|
| 28 | # STACK_CHECKER_ON (RTEMS support code) |
---|
| 29 | # If defined, stack bounds checking is enabled. |
---|
| 30 | # |
---|
| 31 | # STACK_CHECKER_REPORT_USAGE (RTEMS support code) |
---|
| 32 | # If this and STACK_CHECKER_ON are defined, then a report on stack usage |
---|
| 33 | # per task is printed when the program exits. |
---|
| 34 | # |
---|
| 35 | # RTEMS_DEBUG (RTEMS) |
---|
| 36 | # If defined, debug checks in RTEMS and support library code are enabled. |
---|
| 37 | # |
---|
| 38 | # CONSOLE_USE_POLLED (psim_bsp) |
---|
| 39 | # CONSOLE_USE_INTERRUPTS (psim_bsp) |
---|
| 40 | # The psim console driver has the structure to operate in either |
---|
| 41 | # polled or interrupt mode. However both modes only trap to the |
---|
| 42 | # monitor currently. |
---|
| 43 | # |
---|
| 44 | # PSIM_FAST_IDLE (psim_bsp) |
---|
| 45 | # If defined, speed up the clock ticks while the idle task is running so |
---|
| 46 | # time spent in the idle task is minimized. This significantly reduces |
---|
| 47 | # the wall time required to execute the RTEMS test suites. |
---|
| 48 | # |
---|
| 49 | # PPC_VECTOR_FILE_BASE (ppc) |
---|
| 50 | # This defines the base address of the exception table. |
---|
| 51 | # NOTE: Vectors are actually at 0xFFF00000 but file starts at offset 0x0100 |
---|
| 52 | # |
---|
| 53 | # PPC_ABI (ppc) |
---|
| 54 | # This defines the calling convention (Application Binary Interface) |
---|
| 55 | # used in this configuration. EABI is the only one supported. |
---|
| 56 | # |
---|
| 57 | # PPC_ASM (ppc) |
---|
| 58 | # This defines the assembly language format used in this configuration. |
---|
| 59 | # ELF is the only one supported. |
---|
| 60 | # |
---|
| 61 | # PPC_USE_SPRG (RTEMS PowerPC port) |
---|
| 62 | # If defined, then the PowerPC specific code in RTEMS will use some |
---|
| 63 | # of the special purpose registers to slightly optimize interrupt |
---|
| 64 | # response time. The use of these registers can conflict with |
---|
| 65 | # other tools like debuggers. |
---|
| 66 | |
---|
| 67 | |
---|
| 68 | |
---|
| 69 | define make-target-options |
---|
| 70 | @echo "/* #define NDEBUG 1 */ " >>$@ |
---|
| 71 | @echo "#define RTEMS_TEST_NO_PAUSE 1" >>$@ |
---|
| 72 | @echo "/* #define STACK_CHECKER_ON 1 */" >>$@ |
---|
| 73 | @echo "/* #define STACK_CHECKER_REPORT_USAGE 1 */" >>$@ |
---|
| 74 | @echo "/* #define RTEMS_DEBUG 1 */" >>$@ |
---|
| 75 | @echo "#define CONSOLE_USE_INTERRUPTS 0" >>$@ |
---|
| 76 | @echo "#define CONSOLE_USE_POLLED ~CONSOLE_USE_INTERRUPTS" >>$@ |
---|
| 77 | @echo "#define PSIM_FAST_IDLE 1" >>$@ |
---|
| 78 | @echo "#define PPC_VECTOR_FILE_BASE 0xFFF00100" >>$@ |
---|
| 79 | @echo "#define PPC_ABI PPC_ABI_EABI" >>$@ |
---|
| 80 | @echo "#define PPC_ASM PPC_ASM_ELF" >>$@ |
---|
| 81 | @echo "#define PPC_USE_SPRG 1" >>$@ |
---|
| 82 | endef |
---|
| 83 | |
---|
| 84 | # This contains the compiler options necessary to select the CPU model |
---|
| 85 | # and (hopefully) optimize for it. |
---|
| 86 | # |
---|
| 87 | CPU_CFLAGS = -mcpu=603 |
---|
| 88 | |
---|
| 89 | # optimize flag: typically -0, could use -O4 or -fast |
---|
| 90 | # -O4 is ok for RTEMS |
---|
| 91 | # NOTE: some level of -O may be actually required by inline assembler |
---|
| 92 | CFLAGS_OPTIMIZE_V=-O4 -fno-keep-inline-functions |
---|
| 93 | |
---|
| 94 | # Define this to yes if this target supports multiprocessor environments. |
---|
| 95 | HAS_MP=no |
---|
| 96 | |
---|
| 97 | # This target does not support the ka9q tcp/ip stack so ignore requests |
---|
| 98 | # to enable it. |
---|
| 99 | HAS_KA9Q=no |
---|
| 100 | |
---|
| 101 | # The following is a linkcmds file which will work without using the |
---|
| 102 | # -specs system in gcc 2.8. |
---|
| 103 | # $(LD) $(XLDFLAGS) -T $(LINKCMDS) \ |
---|
| 104 | # -o $@ -u atexit -u __vectors -u download_entry $(LINK_FILES) |
---|
| 105 | # $(LD) $(XLDFLAGS) -Ttext 0x20000 \ |
---|
| 106 | # -o $@ -u atexit -u __vectors -u download_entry $(LINK_FILES) |
---|
| 107 | |
---|
| 108 | # $(CC) -mmvme -mrtems -nostartfiles -mcpu=603 \ |
---|
| 109 | # -o $(basename $@).exe -L $(PROJECT_RELEASE)/lib \ |
---|
| 110 | # $(START_FILE) $(LINK_OBJS) \ |
---|
| 111 | # $(LD_LIBS) \ |
---|
| 112 | # -Wl,-\( -Wl,-lc -Wl,-lrtemsall -Wl,-lgcc -Wl,-\) |
---|
| 113 | define make-exe |
---|
| 114 | $(CC) $(CFLAGS) -o $(basename $@).exe $(LINK_OBJS) |
---|
| 115 | $(NM) -g -n $@ > $(basename $@).num |
---|
| 116 | $(SIZE) $@ |
---|
| 117 | endef |
---|
| 118 | |
---|
| 119 | # Miscellaneous additions go here |
---|
| 120 | |
---|
| 121 | # No start file |
---|
| 122 | START_BASE= |
---|