OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [bootloaders/] [orpmon/] [config.mk] - Blame information for rev 463

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 2 marcus.erl
#########################################################################
2
 
3
CONFIG_SHELL    := $(shell if [ -x "$$BASH" ]; then echo $$BASH; \
4
                    else if [ -x /bin/bash ]; then echo /bin/bash; \
5
                    else echo sh; fi ; fi)
6
 
7
HOSTCC          = cc
8 246 julius
HOSTCFLAGS      = -Wall -Wstrict-prototypes -fno-omit-frame-pointer
9 2 marcus.erl
 
10
 
11
#########################################################################
12
 
13
#
14
# Include the make variables (CC, etc...)
15
#
16
AS      = $(CROSS_COMPILE)as
17
LD      = $(CROSS_COMPILE)ld
18
CC      = $(CROSS_COMPILE)gcc
19
AR      = $(CROSS_COMPILE)ar
20
NM      = $(CROSS_COMPILE)nm
21
STRIP   = $(CROSS_COMPILE)strip
22
OBJCOPY = $(CROSS_COMPILE)objcopy
23
OBJDUMP = $(CROSS_COMPILE)objdump
24
RANLIB  = $(CROSS_COMPILE)ranlib
25
 
26 355 julius
XCFLAGS += -I$(TOPDIR)/include -DOR1K -Wall -Wstrict-prototypes
27
XCFLAGS += -Werror-implicit-function-declaration
28 463 julius
#XCFLAGS += -fno-omit-frame-pointer
29
XCFLAGS += -fomit-frame-pointer
30 419 julius
#XCFLAGS += -O0
31 463 julius
#XCFLAGS += -O2
32
XCFLAGS += -O3
33 419 julius
#XCFLAGS += -Os
34
XCFLAGS += -fno-strength-reduce -pipe -fno-builtin
35 375 julius
# Use all software flags, so is compatible with minimal implementation
36 463 julius
XCFLAGS += -mhard-mul -mhard-div -msoft-float
37
#XCFLAGS += -mhard-mul -msoft-div -msoft-float
38 419 julius
#XCFLAGS += -msoft-mul -msoft-div -msoft-float
39 463 julius
# We require this as we we won't rely on any existing C library code
40 355 julius
XCFLAGS += -nostdlib
41
#XCFLAGS += -DDEBUG
42 2 marcus.erl
 
43 355 julius
# For CoreMark:
44
FLAGS_STR ="$(XCFLAGS)"
45
# Add back to CFLAGS
46
CFLAGS += $(XCFLAGS) -DFLAGS_STR=\"$(FLAGS_STR)\"
47 140 julius
 
48 2 marcus.erl
LIBGCC := $(shell $(CC) $(CFLAGS) -print-libgcc-file-name)
49
LDFLAGS+= $(LIBGCC)
50
 
51
#########################################################################
52
 
53
export  CONFIG_SHELL HOSTCC HOSTCFLAGS CROSS_COMPILE \
54
        AS LD CC AR NM STRIP OBJCOPY OBJDUMP \
55
        MAKE CFLAGS ASFLAGS
56
 
57
#########################################################################
58
 
59
%.o:    %.S
60
        $(CC) $(CFLAGS) -c -o $@ $(CURDIR)/$<
61
%.o:    %.c
62
        $(CC) $(CFLAGS) -c -o $@ $<
63
 
64
%.bin: %.or32
65
        or32-rtems-objcopy -O binary $< $@
66
 
67
%.img: %.bin
68
        utils/bin2flimg 1 $< > $@
69
 
70
%.srec: %.bin
71
        utils/bin2srec $< > $@
72
 
73
#########################################################################

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.