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

Subversion Repositories or1k

[/] [or1k/] [branches/] [oc/] [orpmon/] [config.mk] - Rev 1778

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

#########################################################################

CONFIG_SHELL    := $(shell if [ -x "$$BASH" ]; then echo $$BASH; \
                    else if [ -x /bin/bash ]; then echo /bin/bash; \
                    else echo sh; fi ; fi)

HOSTCC          = cc
HOSTCFLAGS      = -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer

#########################################################################

#
# Include the make variables (CC, etc...)
#
AS      = $(CROSS_COMPILE)as
LD      = $(CROSS_COMPILE)ld
CC      = $(CROSS_COMPILE)gcc
AR      = $(CROSS_COMPILE)ar
NM      = $(CROSS_COMPILE)nm
STRIP   = $(CROSS_COMPILE)strip
OBJCOPY = $(CROSS_COMPILE)objcopy
OBJDUMP = $(CROSS_COMPILE)objdump
RANLIB  = $(CROSS_COMPILE)ranlib

CFLAGS += -I$(TOPDIR)/include -DOR1K -Wall -Wstrict-prototypes -Werror-implicit-function-declaration -fomit-frame-pointer -fno-strength-reduce -O2 -g -pipe -fno-builtin -nostdlib

#########################################################################

export  CONFIG_SHELL HOSTCC HOSTCFLAGS CROSS_COMPILE \
        AS LD CC AR NM STRIP OBJCOPY OBJDUMP \
        MAKE CFLAGS AFLAGS

#########################################################################

%.s:    %.S
        $(CPP) $(AFLAGS) -o $@ $(CURDIR)/$<
%.o:    %.S
        $(CC) $(AFLAGS) -c -o $@ $(CURDIR)/$<
%.o:    %.c
        $(CC) $(CFLAGS) -c -o $@ $<

%.bin: %.or32
        or32-rtems-objcopy -O binary $< $@

%.img: %.bin
        utils/bin2flimg 1 $< > $@

%.srec: %.bin
        utils/bin2srec $< > $@

#########################################################################

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

powered by: WebSVN 2.1.0

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