arch/../src/Makefiles now use only libraries in lib/

git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@5333 42af7a65-404d-4744-a932-0658087f49c3
This commit is contained in:
patacongo 2012-11-11 13:52:31 +00:00
parent 98361244f0
commit 6de9634620
14 changed files with 265 additions and 252 deletions

View File

@ -3601,4 +3601,5 @@
additional logic is needed in the arch/*/src/Makefile's as well. Right
now that logic generate multiple library paths, all pointing to the lib/
directory.
* arch/*/src/Makefile: Now uses only the libraries in lib/

View File

@ -252,7 +252,7 @@ endif
# LINKLIBS derives from NUTTXLIBS and is simply the same list with the subdirectory removed
LINKLIBS = $(patsubst lib/,,$(NUTTXLIBS))
LINKLIBS = $(patsubst lib/%,%,$(NUTTXLIBS))
# This is the name of the final target (relative to the top level directorty)
@ -566,13 +566,13 @@ ifeq ($(CONFIG_BUILD_2PASS),y)
echo "ERROR: No Makefile in CONFIG_PASS1_BUILDIR"; \
exit 1; \
fi
$(Q) $(MAKE) -C $(CONFIG_PASS1_BUILDIR) TOPDIR="$(TOPDIR)" LINKLIBS="$(NUTTXLIBS)" USERLIBS="$(USERLIBS)" "$(CONFIG_PASS1_TARGET)"
$(Q) $(MAKE) -C $(CONFIG_PASS1_BUILDIR) TOPDIR="$(TOPDIR)" LINKLIBS="$(LINKLIBS)" USERLIBS="$(USERLIBS)" "$(CONFIG_PASS1_TARGET)"
endif
pass2deps: context pass2dep $(NUTTXLIBS)
pass2: pass2deps
$(Q) $(MAKE) -C $(ARCH_SRC) TOPDIR="$(TOPDIR)" EXTRA_OBJS="$(EXTRA_OBJS)" LINKLIBS="$(NUTTXLIBS)" EXTRADEFINES=$(KDEFINE) $(BIN)
$(Q) $(MAKE) -C $(ARCH_SRC) TOPDIR="$(TOPDIR)" EXTRA_OBJS="$(EXTRA_OBJS)" LINKLIBS="$(LINKLIBS)" EXTRADEFINES=$(KDEFINE) $(BIN)
$(Q) if [ -w /tftpboot ] ; then \
cp -f $(BIN) /tftpboot/$(BIN).${CONFIG_ARCH}; \
fi

View File

@ -35,51 +35,51 @@
-include $(TOPDIR)/Make.defs
CFLAGS += -I$(TOPDIR)/sched
ASFLAGS = -x -j -g -l -s -p
CPPFLAGS = $(ARCHINCLUDES) $(ARCHDEFINES) $(EXTRADEFINES) -D__ASSEMBLY__
CFLAGS += -I$(TOPDIR)/sched
ASFLAGS = -x -j -g -l -s -p
CPPFLAGS = $(ARCHINCLUDES) $(ARCHDEFINES) $(EXTRADEFINES) -D__ASSEMBLY__
SSRCS =
ASRCS = $(SSRCS:.S=$(ASMEXT))
AOBJS = $(ASRCS:$(ASMEXT)=$(OBJEXT))
CSRCS = up_initialize.c up_idle.c up_interruptcontext.c \
up_initialstate.c up_unblocktask.c up_blocktask.c \
up_releasepending.c up_reprioritizertr.c \
up_exit.c up_assert.c up_allocateheap.c \
up_irq.c up_savecontext.c up_restorecontext.c \
up_timerisr.c up_putc.c up_debug.c up_delay.c
COBJS = $(CSRCS:.c=$(OBJEXT))
SRCS = $(SSRCS) $(CSRCS)
OBJS = $(AOBJS) $(COBJS)
SSRCS =
ASRCS = $(SSRCS:.S=$(ASMEXT))
AOBJS = $(ASRCS:$(ASMEXT)=$(OBJEXT))
CSRCS = up_initialize.c up_idle.c up_interruptcontext.c \
up_initialstate.c up_unblocktask.c up_blocktask.c \
up_releasepending.c up_reprioritizertr.c \
up_exit.c up_assert.c up_allocateheap.c \
up_irq.c up_savecontext.c up_restorecontext.c \
up_timerisr.c up_putc.c up_debug.c up_delay.c
COBJS = $(CSRCS:.c=$(OBJEXT))
SRCS = $(SSRCS) $(CSRCS)
OBJS = $(AOBJS) $(COBJS)
SDCCLIBDIR = /usr/local/share/sdcc/lib/large-stack-auto
SDCCPATH = -L$(SDCCLIBDIR)
SDCCLIBS = -llibfloat.lib -llibint.lib -lliblong.lib -llibmysdcc.lib -lmcs51.lib
SDCCLIBDIR = /usr/local/share/sdcc/lib/large-stack-auto
SDCCPATH = -L$(SDCCLIBDIR)
SDCCLIBS = -llibfloat.lib -llibint.lib -lliblong.lib -llibmysdcc.lib -lmcs51.lib
LINKSSRCS = up_head.S
LINKASRCS = $(LINKSSRCS:.S=$(ASMEXT))
LINKOBJS = $(LINKASRCS:$(ASMEXT)=$(OBJEXT))
LINKLIBS =
LDPATHES = $(addprefix -L$(TOPDIR)/,$(dir $(LINKLIBS)))
LDLIBS = $(addprefix -l,$(notdir $(LINKLIBS)))
LINKSSRCS = up_head.S
LINKASRCS = $(LINKSSRCS:.S=$(ASMEXT))
LINKOBJS = $(LINKASRCS:$(ASMEXT)=$(OBJEXT))
LINKLIBS ?=
LDPATHS = -L"$(TOPDIR)/lib"
LDLIBS = $(patsubst %.a,%,$(patsubst lib%,-l%,$(LINKLIBS)))
TESTSRCS = up_irqtest.c
TESTOBJS = $(TESTSRCS:.c=$(OBJEXT))
TESTLINKOBJS = up_head$(OBJEXT)
TESTEXTRAOBJS = up_savecontext$(OBJEXT) up_restorecontext$(OBJEXT)
TESTSRCS = up_irqtest.c
TESTOBJS = $(TESTSRCS:.c=$(OBJEXT))
TESTLINKOBJS = up_head$(OBJEXT)
TESTEXTRAOBJS = up_savecontext$(OBJEXT) up_restorecontext$(OBJEXT)
BOARDDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src/board
BOARDDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src/board
IRAM_SIZE = 0x100
DEF_STACK_BASE = 0x24
LDFLAGS += --model-large --nostdlib \
--data-loc $(DEF_STACK_BASE) --iram-size $(IRAM_SIZE) \
--code-loc 0x2100 --code-size 0x5f40 \
--xram-loc $(IRAM_SIZE) --xram-size 0x1f00
IRAM_SIZE = 0x100
DEF_STACK_BASE = 0x24
LDFLAGS += --model-large --nostdlib \
--data-loc $(DEF_STACK_BASE) --iram-size $(IRAM_SIZE) \
--code-loc 0x2100 --code-size 0x5f40 \
--xram-loc $(IRAM_SIZE) --xram-size 0x1f00
DEPSRCS = $(SRCS) $(LINKSSRCS)
DEPSRCS = $(SRCS) $(LINKSSRCS)
HEAP1_BASE = ${shell \
HEAP1_BASE = ${shell \
if [ -e pass1.mem ]; then \
cat pass1.mem | grep "EXTERNAL RAM" | \
sed -e "s/[ ][ ]*/ /g" | cut -d' ' -f5 ; \
@ -87,8 +87,8 @@ HEAP1_BASE = ${shell \
echo $(IRAM_SIZE) ; \
fi \
}
DEF_HEAP2_BASE = 0x6000
HEAP2_BASE = ${shell \
DEF_HEAP2_BASE = 0x6000
HEAP2_BASE = ${shell \
if [ -e pass1.mem ]; then \
cat pass1.mem | grep "ROM/EPROM/FLASH" | \
sed -e "s/[ ][ ]*/ /g" | cut -d' ' -f4 ; \
@ -96,7 +96,7 @@ HEAP2_BASE = ${shell \
echo $(DEF_HEAP2_BASE) ; \
fi \
}
STACK_BASE = ${shell \
STACK_BASE = ${shell \
if [ -e pass1.mem ]; then \
cat pass1.mem | grep "Stack starts" | \
cut -d' ' -f4 ; \
@ -173,7 +173,7 @@ board/libboard$(LIBEXT):
pass1.hex: up_mem.h $(SDCCLIBDIR)/libmysdcc.lib $(LINKOBJS) board/libboard$(LIBEXT)
@echo "LD: $@"
@$(CC) $(LDFLAGS) $(LDPATHES) -L$(BOARDDIR) $(SDCCPATH) $(LINKOBJS) \
@$(CC) $(LDFLAGS) $(LDPATHS) -L$(BOARDDIR) $(SDCCPATH) $(LINKOBJS) \
$(LDLIBS) -llibboard$(LIBEXT) $(SDCCLIBS) -o $@
@rm -f up_mem.h
@rm -f up_allocateheap$(OBJEXT) libarch$(LIBEXT)
@ -181,7 +181,7 @@ pass1.hex: up_mem.h $(SDCCLIBDIR)/libmysdcc.lib $(LINKOBJS) board/libboard$(LIBE
nuttx.hex: up_mem.h $(SDCCLIBDIR)/libmysdcc.lib $(LINKOBJS)
@echo "LD: $@"
@$(CC) $(LDFLAGS) $(LDPATHES) -L$(BOARDDIR) $(SDCCPATH) $(LINKOBJS) \
@$(CC) $(LDFLAGS) $(LDPATHS) -L$(BOARDDIR) $(SDCCPATH) $(LINKOBJS) \
$(LDLIBS) -llibboard$(LIBEXT) $(SDCCLIBS) -o $@
nuttx$(EXEEXT): pass1.hex nuttx.hex

View File

@ -74,16 +74,17 @@ LDFLAGS += $(ARCHSCRIPT)
EXTRA_LIBS ?=
EXTRA_LIBPATHS ?=
LINKLIBS ?=
LINKLIBS =
ifeq ($(WINTOOL),y)
LIBPATHS = ${shell for path in $(LINKLIBS); do dir=`dirname $(TOPDIR)/$$path`;echo "-L\"`cygpath -w $$dir`\"";done}
LIBPATHS += -L"${shell cygpath -w "$(TOPDIR)/lib"}"
LIBPATHS += -L"${shell cygpath -w $(BOARDDIR)}"
else
LIBPATHS = $(addprefix -L$(TOPDIR)/,$(dir $(LINKLIBS)))
LIBPATHS += -L"(TOPDIR)/lib"
LIBPATHS += -L"$(BOARDDIR)"
endif
LDLIBS = $(patsubst lib%,-l%,$(basename $(notdir $(LINKLIBS))))
LDLIBS = $(patsubst %.a,%,$(patsubst lib%,-l%,$(LINKLIBS)))
BOARDDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src/board

View File

@ -37,61 +37,62 @@
-include $(TOPDIR)/Make.defs
-include chip/Make.defs
ARCH_SRCDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src
ARCH_SRCDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src
ifeq ($(CONFIG_ARCH_AVR32),y)
ARCH_SUBDIR = avr32
ARCH_SUBDIR = avr32
else ifeq ($(CONFIG_ARCH_AVR),y)
ARCH_SUBDIR = avr
ARCH_SUBDIR = avr
endif
ifeq ($(WINTOOL),y)
NUTTX = "${shell cygpath -w $(TOPDIR)/nuttx}"
INCLUDES += -I "${shell cygpath -w $(ARCH_SRCDIR)/chip}"
INCLUDES += -I "${shell cygpath -w $(ARCH_SRCDIR)/common}"
INCLUDES += -I "${shell cygpath -w $(ARCH_SRCDIR)/$(ARCH_SUBDIR)}"
INCLUDES += -I "${shell cygpath -w $(TOPDIR)/sched}"
NUTTX = "${shell cygpath -w $(TOPDIR)/nuttx}"
INCLUDES += -I "${shell cygpath -w $(ARCH_SRCDIR)/chip}"
INCLUDES += -I "${shell cygpath -w $(ARCH_SRCDIR)/common}"
INCLUDES += -I "${shell cygpath -w $(ARCH_SRCDIR)/$(ARCH_SUBDIR)}"
INCLUDES += -I "${shell cygpath -w $(TOPDIR)/sched}"
else
NUTTX = "$(TOPDIR)/nuttx"
INCLUDES += -I "$(ARCH_SRCDIR)/chip"
INCLUDES += -I "$(ARCH_SRCDIR)/common"
INCLUDES += -I "$(ARCH_SRCDIR)/$(ARCH_SUBDIR)"
INCLUDES += -I "$(TOPDIR)/sched"
NUTTX = "$(TOPDIR)/nuttx"
INCLUDES += -I "$(ARCH_SRCDIR)/chip"
INCLUDES += -I "$(ARCH_SRCDIR)/common"
INCLUDES += -I "$(ARCH_SRCDIR)/$(ARCH_SUBDIR)"
INCLUDES += -I "$(TOPDIR)/sched"
endif
CPPFLAGS += $(INCLUDES)
CFLAGS += $(INCLUDES)
CXXFLAGS += $(INCLUDES)
AFLAGS += $(INCLUDES)
CPPFLAGS += $(INCLUDES)
CFLAGS += $(INCLUDES)
CXXFLAGS += $(INCLUDES)
AFLAGS += $(INCLUDES)
HEAD_OBJ = $(HEAD_ASRC:.S=$(OBJEXT))
HEAD_OBJ = $(HEAD_ASRC:.S=$(OBJEXT))
ASRCS = $(CHIP_ASRCS) $(CMN_ASRCS)
AOBJS = $(ASRCS:.S=$(OBJEXT))
ASRCS = $(CHIP_ASRCS) $(CMN_ASRCS)
AOBJS = $(ASRCS:.S=$(OBJEXT))
CSRCS = $(CHIP_CSRCS) $(CMN_CSRCS)
COBJS = $(CSRCS:.c=$(OBJEXT))
CSRCS = $(CHIP_CSRCS) $(CMN_CSRCS)
COBJS = $(CSRCS:.c=$(OBJEXT))
SRCS = $(ASRCS) $(CSRCS)
OBJS = $(AOBJS) $(COBJS)
SRCS = $(ASRCS) $(CSRCS)
OBJS = $(AOBJS) $(COBJS)
LDFLAGS += $(ARCHSCRIPT)
EXTRA_LIBS ?=
LDFLAGS += $(ARCHSCRIPT)
EXTRA_LIBS ?=
LINKLIBS ?=
LINKLIBS =
ifeq ($(WINTOOL),y)
LIBPATHS = ${shell for path in $(LINKLIBS); do dir=`dirname $(TOPDIR)/$$path`;echo "-L\"`cygpath -w $$dir`\"";done}
LIBPATHS += -L"${shell cygpath -w $(BOARDDIR)}"
LIBPATHS += -L"${shell cygpath -w "$(TOPDIR)/lib"}"
LIBPATHS += -L"${shell cygpath -w $(BOARDDIR)}"
else
LIBPATHS = $(addprefix -L$(TOPDIR)/,$(dir $(LINKLIBS)))
LIBPATHS += -L"$(BOARDDIR)"
LIBPATHS += -L"(TOPDIR)/lib"
LIBPATHS += -L"$(BOARDDIR)"
endif
LDLIBS = $(patsubst lib%,-l%,$(basename $(notdir $(LINKLIBS))))
BOARDDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src/board
LDLIBS = $(patsubst %.a,%,$(patsubst lib%,-l%,$(LINKLIBS)))
LIBGCC = "${shell $(CC) $(ARCHCPUFLAGS) -print-libgcc-file-name}"
BOARDDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src/board
VPATH = chip:common:$(ARCH_SUBDIR)
LIBGCC = "${shell $(CC) $(ARCHCPUFLAGS) -print-libgcc-file-name}"
VPATH = chip:common:$(ARCH_SUBDIR)
all: $(HEAD_OBJ) libarch$(LIBEXT)

View File

@ -36,55 +36,56 @@
-include $(TOPDIR)/Make.defs
-include chip/Make.defs
ARCH_SRCDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src
ARCH_SRCDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src
ifeq ($(CONFIG_ARCH_HC12),y)
ARCH_SUBDIR = hc12
ARCH_SUBDIR = hc12
endif
ifeq ($(CONFIG_ARCH_HCS12),y)
ARCH_SUBDIR = hcs12
ARCH_SUBDIR = hcs12
endif
ifeq ($(WINTOOL),y)
NUTTX = "${shell cygpath -w $(TOPDIR)/nuttx}"
CFLAGS += -I "${shell cygpath -w $(ARCH_SRCDIR)/chip}" \
-I "${shell cygpath -w $(ARCH_SRCDIR)/common}" \
NUTTX = "${shell cygpath -w $(TOPDIR)/nuttx}"
CFLAGS += -I "${shell cygpath -w $(ARCH_SRCDIR)/chip}" \
-I "${shell cygpath -w $(ARCH_SRCDIR)/common}" \
-I "${shell cygpath -w $(ARCH_SRCDIR)/$(ARCH_SUBDIR)}" \
-I "${shell cygpath -w $(TOPDIR)/sched}"
else
NUTTX = $(TOPDIR)/nuttx
CFLAGS += -I$(ARCH_SRCDIR)/chip -I$(ARCH_SRCDIR)/common \
-I$(ARCH_SRCDIR)/$(ARCH_SUBDIR) -I$(TOPDIR)/sched
NUTTX = $(TOPDIR)/nuttx
CFLAGS += -I$(ARCH_SRCDIR)/chip -I$(ARCH_SRCDIR)/common \
-I$(ARCH_SRCDIR)/$(ARCH_SUBDIR) -I$(TOPDIR)/sched
endif
HEAD_OBJ = $(HEAD_ASRC:.S=$(OBJEXT))
HEAD_OBJ = $(HEAD_ASRC:.S=$(OBJEXT))
ASRCS = $(CHIP_ASRCS) $(CMN_ASRCS)
AOBJS = $(ASRCS:.S=$(OBJEXT))
ASRCS = $(CHIP_ASRCS) $(CMN_ASRCS)
AOBJS = $(ASRCS:.S=$(OBJEXT))
CSRCS = $(CHIP_CSRCS) $(CMN_CSRCS)
COBJS = $(CSRCS:.c=$(OBJEXT))
CSRCS = $(CHIP_CSRCS) $(CMN_CSRCS)
COBJS = $(CSRCS:.c=$(OBJEXT))
SRCS = $(ASRCS) $(CSRCS)
OBJS = $(AOBJS) $(COBJS)
SRCS = $(ASRCS) $(CSRCS)
OBJS = $(AOBJS) $(COBJS)
LDFLAGS += $(ARCHSCRIPT)
EXTRA_LIBS ?=
LDFLAGS += $(ARCHSCRIPT)
EXTRA_LIBS ?=
LINKLIBS ?=
LINKLIBS =
ifeq ($(WINTOOL),y)
LIBPATHS = ${shell for path in $(LINKLIBS); do dir=`dirname $(TOPDIR)/$$path`;echo "-L\"`cygpath -w $$dir`\"";done}
LIBPATHS += -L"${shell cygpath -w $(BOARDDIR)}"
LIBPATHS += -L"${shell cygpath -w "$(TOPDIR)/lib"}"
LIBPATHS += -L"${shell cygpath -w $(BOARDDIR)}"
else
LIBPATHS = $(addprefix -L$(TOPDIR)/,$(dir $(LINKLIBS)))
LIBPATHS += -L"$(BOARDDIR)"
LIBPATHS += -L"(TOPDIR)/lib"
LIBPATHS += -L"$(BOARDDIR)"
endif
LDLIBS = $(patsubst lib%,-l%,$(basename $(notdir $(LINKLIBS))))
BOARDDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src/board
LDLIBS = $(patsubst %.a,%,$(patsubst lib%,-l%,$(LINKLIBS)))
LIBGCC = "${shell $(CC) $(ARCHCPUFLAGS) -print-libgcc-file-name}"
BOARDDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src/board
VPATH = chip:common:$(ARCH_SUBDIR)
LIBGCC = "${shell $(CC) $(ARCHCPUFLAGS) -print-libgcc-file-name}"
VPATH = chip:common:$(ARCH_SUBDIR)
all: $(HEAD_OBJ) libarch$(LIBEXT)
.PHONY: board/libboard$(LIBEXT)

View File

@ -36,52 +36,53 @@
-include $(TOPDIR)/Make.defs
-include chip/Make.defs
ARCH_SRCDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src
ARCH_SRCDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src
ifeq ($(CONFIG_ARCH_MIPS),y)
ARCH_SUBDIR = mips32
ARCH_SUBDIR = mips32
endif
ifeq ($(WINTOOL),y)
NUTTX = "${shell cygpath -w $(TOPDIR)/nuttx}"
CFLAGS += -I "${shell cygpath -w $(ARCH_SRCDIR)/chip}" \
-I "${shell cygpath -w $(ARCH_SRCDIR)/common}" \
-I "${shell cygpath -w $(ARCH_SRCDIR)/$(ARCH_SUBDIR)}" \
-I "${shell cygpath -w $(TOPDIR)/sched}"
NUTTX = "${shell cygpath -w $(TOPDIR)/nuttx}"
CFLAGS += -I "${shell cygpath -w $(ARCH_SRCDIR)/chip}" \
-I "${shell cygpath -w $(ARCH_SRCDIR)/common}" \
-I "${shell cygpath -w $(ARCH_SRCDIR)/$(ARCH_SUBDIR)}" \
-I "${shell cygpath -w $(TOPDIR)/sched}"
else
NUTTX = $(TOPDIR)/nuttx
CFLAGS += -I$(ARCH_SRCDIR)/chip -I$(ARCH_SRCDIR)/common \
-I$(ARCH_SRCDIR)/$(ARCH_SUBDIR) -I$(TOPDIR)/sched
NUTTX = $(TOPDIR)/nuttx
CFLAGS += -I$(ARCH_SRCDIR)/chip -I$(ARCH_SRCDIR)/common \
-I$(ARCH_SRCDIR)/$(ARCH_SUBDIR) -I$(TOPDIR)/sched
endif
HEAD_OBJ = $(HEAD_ASRC:.S=$(OBJEXT))
HEAD_OBJ = $(HEAD_ASRC:.S=$(OBJEXT))
ASRCS = $(CHIP_ASRCS) $(CMN_ASRCS)
AOBJS = $(ASRCS:.S=$(OBJEXT))
ASRCS = $(CHIP_ASRCS) $(CMN_ASRCS)
AOBJS = $(ASRCS:.S=$(OBJEXT))
CSRCS = $(CHIP_CSRCS) $(CMN_CSRCS)
COBJS = $(CSRCS:.c=$(OBJEXT))
CSRCS = $(CHIP_CSRCS) $(CMN_CSRCS)
COBJS = $(CSRCS:.c=$(OBJEXT))
SRCS = $(ASRCS) $(CSRCS)
OBJS = $(AOBJS) $(COBJS)
SRCS = $(ASRCS) $(CSRCS)
OBJS = $(AOBJS) $(COBJS)
LDFLAGS += $(ARCHSCRIPT)
EXTRA_LIBS ?=
LDFLAGS += $(ARCHSCRIPT)
EXTRA_LIBS ?=
LINKLIBS ?=
LINKLIBS =
ifeq ($(WINTOOL),y)
LIBPATHS = ${shell for path in $(LINKLIBS); do dir=`dirname $(TOPDIR)/$$path`;echo "-L\"`cygpath -w $$dir`\"";done}
LIBPATHS += -L"${shell cygpath -w $(BOARDDIR)}"
LIBPATHS += -L"${shell cygpath -w "$(TOPDIR)/lib"}"
LIBPATHS += -L"${shell cygpath -w $(BOARDDIR)}"
else
LIBPATHS = $(addprefix -L$(TOPDIR)/,$(dir $(LINKLIBS)))
LIBPATHS += -L"$(BOARDDIR)"
LIBPATHS += -L"(TOPDIR)/lib"
LIBPATHS += -L"$(BOARDDIR)"
endif
LDLIBS = $(patsubst lib%,-l%,$(basename $(notdir $(LINKLIBS))))
BOARDDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src/board
LDLIBS = $(patsubst %.a,%,$(patsubst lib%,-l%,$(LINKLIBS)))
LIBGCC = "${shell $(CC) $(ARCHCPUFLAGS) -print-libgcc-file-name}"
BOARDDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src/board
VPATH = chip:common:$(ARCH_SUBDIR)
LIBGCC = "${shell $(CC) $(ARCHCPUFLAGS) -print-libgcc-file-name}"
VPATH = chip:common:$(ARCH_SUBDIR)
all: $(HEAD_OBJ) libarch$(LIBEXT)

View File

@ -53,9 +53,8 @@ LINKSRCS = rgmp.c bridge.c
LINKOBJS = $(LINKSRCS:.c=$(OBJEXT))
LDFLAGS += -T$(RGMPLKSCPT)
LDPATHS = $(addprefix -L$(TOPDIR)/,$(dir $(LINKLIBS)))
LDLIBS = $(patsubst lib%,-l%,$(basename $(notdir $(LINKLIBS))))
LDPATHS += -L$(RGMPLIBDIR)
LDLIBS = $(patsubst %.a,%,$(patsubst lib%,-l%,$(LINKLIBS)))
LDPATHS += -L"$(TOPDIR)/lib -L$(RGMPLIBDIR)
LDLIBS += -lrgmp $(shell $(CC) -print-libgcc-file-name)
all: libarch$(LIBEXT)

View File

@ -36,32 +36,39 @@
-include $(TOPDIR)/Make.defs
-include chip/Make.defs
ARCH_SRCDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src
CFLAGS += -I$(ARCH_SRCDIR)/chip -I$(ARCH_SRCDIR)/common -I$(TOPDIR)/sched
ARCH_SRCDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src
CFLAGS += -I$(ARCH_SRCDIR)/chip -I$(ARCH_SRCDIR)/common -I$(TOPDIR)/sched
HEAD_OBJ = $(HEAD_ASRC:.S=$(OBJEXT))
HEAD_OBJ = $(HEAD_ASRC:.S=$(OBJEXT))
ASRCS = $(CHIP_ASRCS) $(CMN_ASRCS)
AOBJS = $(ASRCS:.S=$(OBJEXT))
ASRCS = $(CHIP_ASRCS) $(CMN_ASRCS)
AOBJS = $(ASRCS:.S=$(OBJEXT))
CSRCS = $(CHIP_CSRCS) $(CMN_CSRCS)
COBJS = $(CSRCS:.c=$(OBJEXT))
CSRCS = $(CHIP_CSRCS) $(CMN_CSRCS)
COBJS = $(CSRCS:.c=$(OBJEXT))
SRCS = $(ASRCS) $(CSRCS)
OBJS = $(AOBJS) $(COBJS)
SRCS = $(ASRCS) $(CSRCS)
OBJS = $(AOBJS) $(COBJS)
LDFLAGS += $(ARCHSCRIPT)
EXTRA_LIBS ?=
LDFLAGS += $(ARCHSCRIPT)
EXTRA_LIBS ?=
LINKLIBS ?=
LINKLIBS =
LDPATHES = $(addprefix -L$(TOPDIR)/,$(dir $(LINKLIBS)))
LDLIBS = $(patsubst lib%,-l%,$(basename $(notdir $(LINKLIBS))))
ifeq ($(WINTOOL),y)
LIBPATHS += -L"${shell cygpath -w "$(TOPDIR)/lib"}"
LIBPATHS += -L"${shell cygpath -w $(BOARDDIR)}"
else
LIBPATHS += -L"(TOPDIR)/lib"
LIBPATHS += -L"$(BOARDDIR)"
endif
BOARDDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src/board
LDLIBS = $(patsubst %.a,%,$(patsubst lib%,-l%,$(LINKLIBS)))
LIBGCC = ${shell $(CC) $(ARCHCPUFLAGS) -print-libgcc-file-name}
BOARDDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src/board
VPATH = chip:common
LIBGCC = ${shell $(CC) $(ARCHCPUFLAGS) -print-libgcc-file-name}
VPATH = chip:common
all: $(HEAD_OBJ) libarch$(LIBEXT)
@ -83,7 +90,7 @@ board/libboard$(LIBEXT):
nuttx: $(HEAD_OBJ) board/libboard$(LIBEXT)
@echo "LD: nuttx"
@$(LD) --entry=__start $(LDFLAGS) $(LDPATHES) -L$(BOARDDIR) -o $(TOPDIR)/$@ $(HEAD_OBJ) \
@$(LD) --entry=__start $(LDFLAGS) $(LDPATHS) -L$(BOARDDIR) -o $(TOPDIR)/$@ $(HEAD_OBJ) \
--start-group $(LDLIBS) -lboard $(EXTRA_LIBS) $(LIBGCC) --end-group
@$(NM) $(TOPDIR)/$@ | \
grep -v '\(compiled\)\|\(\$(OBJEXT)$$\)\|\( [aUw] \)\|\(\.\.ng$$\)\|\(LASH[RL]DI\)' | \

View File

@ -40,11 +40,11 @@ CFLAGS += -I$(TOPDIR)/sched
ASRCS = up_setjmp.S
AOBJS = $(ASRCS:.S=$(OBJEXT))
CSRCS = up_initialize.c up_idle.c up_interruptcontext.c \
up_initialstate.c up_createstack.c up_usestack.c \
up_releasestack.c up_unblocktask.c up_blocktask.c \
up_releasepending.c up_reprioritizertr.c \
up_exit.c up_schedulesigaction.c up_allocateheap.c \
up_devconsole.c
up_initialstate.c up_createstack.c up_usestack.c \
up_releasestack.c up_unblocktask.c up_blocktask.c \
up_releasepending.c up_reprioritizertr.c \
up_exit.c up_schedulesigaction.c up_allocateheap.c \
up_devconsole.c
HOSTSRCS = up_stdio.c up_hostusleep.c
ifeq ($(CONFIG_NX_LCDDRIVER),y)
@ -126,9 +126,10 @@ endif
# Determine which NuttX libraries will need to be linked in
# Most are provided by LINKLIBS on the MAKE command line
LINKLIBS =
LDPATHS = $(addprefix -L$(TOPDIR)/,$(dir $(LINKLIBS)))
LDLIBS = $(patsubst lib%,-l%,$(basename $(notdir $(LINKLIBS))))
LINKLIBS ?=
LIBPATHS += -L"(TOPDIR)/lib"
LIBPATHS += -L"$(BOARDDIR)"
LDLIBS = $(patsubst %.a,%,$(patsubst lib%,-l%,$(LINKLIBS)))
# Add the board-specific library and directory

View File

@ -36,60 +36,61 @@
-include $(TOPDIR)/Make.defs
-include chip/Make.defs
ARCH_SRCDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src
ARCH_SRCDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src
ifeq ($(CONFIG_ARCH_I486),y)
ARCH_SUBDIR = i486
ARCH_SUBDIR = i486
endif
ifeq ($(WINTOOL),y)
NUTTX = "${shell cygpath -w $(TOPDIR)/nuttx}"
CFLAGS += -I "${shell cygpath -w $(ARCH_SRCDIR)/chip}" \
-I "${shell cygpath -w $(ARCH_SRCDIR)/common}" \
-I "${shell cygpath -w $(ARCH_SRCDIR)/$(ARCH_SUBDIR)}" \
-I "${shell cygpath -w $(TOPDIR)/sched}"
NUTTX = "${shell cygpath -w $(TOPDIR)/nuttx}"
CFLAGS += -I "${shell cygpath -w $(ARCH_SRCDIR)/chip}" \
-I "${shell cygpath -w $(ARCH_SRCDIR)/common}" \
-I "${shell cygpath -w $(ARCH_SRCDIR)/$(ARCH_SUBDIR)}" \
-I "${shell cygpath -w $(TOPDIR)/sched}"
else
NUTTX = $(TOPDIR)/nuttx
CFLAGS += -I$(ARCH_SRCDIR)/chip -I$(ARCH_SRCDIR)/common \
-I$(ARCH_SRCDIR)/$(ARCH_SUBDIR) -I$(TOPDIR)/sched
NUTTX = $(TOPDIR)/nuttx
CFLAGS += -I$(ARCH_SRCDIR)/chip -I$(ARCH_SRCDIR)/common \
-I$(ARCH_SRCDIR)/$(ARCH_SUBDIR) -I$(TOPDIR)/sched
endif
HEAD_OBJ = $(HEAD_ASRC:.S=$(OBJEXT))
HEAD_OBJ = $(HEAD_ASRC:.S=$(OBJEXT))
ASRCS = $(CHIP_ASRCS) $(CMN_ASRCS)
AOBJS = $(ASRCS:.S=$(OBJEXT))
ASRCS = $(CHIP_ASRCS) $(CMN_ASRCS)
AOBJS = $(ASRCS:.S=$(OBJEXT))
CSRCS = $(CHIP_CSRCS) $(CMN_CSRCS)
COBJS = $(CSRCS:.c=$(OBJEXT))
CSRCS = $(CHIP_CSRCS) $(CMN_CSRCS)
COBJS = $(CSRCS:.c=$(OBJEXT))
SRCS = $(ASRCS) $(CSRCS)
OBJS = $(AOBJS) $(COBJS)
SRCS = $(ASRCS) $(CSRCS)
OBJS = $(AOBJS) $(COBJS)
LDFLAGS += $(ARCHSCRIPT)
EXTRA_LIBS ?=
LDFLAGS += $(ARCHSCRIPT)
EXTRA_LIBS ?=
LINKLIBS ?=
LINKLIBS =
ifeq ($(WINTOOL),y)
LIBPATHS = ${shell for path in $(LINKLIBS); do dir=`dirname $(TOPDIR)/$$path`;echo "-L\"`cygpath -w $$dir`\"";done}
LIBPATHS += -L"${shell cygpath -w $(BOARDDIR)}"
LIBPATHS += -L"${shell cygpath -w "$(TOPDIR)/lib"}"
LIBPATHS += -L"${shell cygpath -w $(BOARDDIR)}"
else
LIBPATHS = $(addprefix -L$(TOPDIR)/,$(dir $(LINKLIBS)))
LIBPATHS += -L"$(BOARDDIR)"
LIBPATHS += -L"(TOPDIR)/lib"
LIBPATHS += -L"$(BOARDDIR)"
endif
LDLIBS = $(patsubst lib%,-l%,$(basename $(notdir $(LINKLIBS))))
BOARDDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src/board
LDLIBS = $(patsubst %.a,%,$(patsubst lib%,-l%,$(LINKLIBS)))
LIBGCC = "${shell $(CC) $(ARCHCPUFLAGS) -print-libgcc-file-name}"
BOARDDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src/board
LIBGCC = "${shell $(CC) $(ARCHCPUFLAGS) -print-libgcc-file-name}"
ifeq ($(HOSTOS),FreeBSD)
HOST_ARCH = ${shell uname -m 2>/dev/null || echo "Other"}
HOST_ARCH = ${shell uname -m 2>/dev/null || echo "Other"}
ifeq ($(HOST_ARCH),amd64)
LDFLAGS += -melf_i386
LIBGCC = "/usr/lib32/libgcc.a"
LDFLAGS += -melf_i386
LIBGCC = "/usr/lib32/libgcc.a"
endif
endif
VPATH = chip:common:$(ARCH_SUBDIR)
VPATH = chip:common:$(ARCH_SUBDIR)
all: $(HEAD_OBJ) libarch$(LIBEXT)

View File

@ -36,38 +36,38 @@
-include $(TOPDIR)/Make.defs
-include chip/Make.defs
COMPILER = ${shell basename $(CC)}
ARCHSRCDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src
COMPILER = ${shell basename $(CC)}
ARCHSRCDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src
ifeq ($(COMPILER),zneocc.exe)
WARCHSRCDIR := ${shell cygpath -w $(ARCHSRCDIR)}
USRINCLUDES = -usrinc:'.;$(WTOPDIR)\sched;$(WARCHSRCDIR);$(WARCHSRCDIR)\common'
WARCHSRCDIR := ${shell cygpath -w $(ARCHSRCDIR)}
USRINCLUDES = -usrinc:'.;$(WTOPDIR)\sched;$(WARCHSRCDIR);$(WARCHSRCDIR)\common'
else
WARCHSRCDIR = $(ARCHSRCDIR)
USRINCLUDES = -I$(TOPDIR)/sched -I$(ARCHSRCDIR) -I$(ARCHSRCDIR)/common
WARCHSRCDIR = $(ARCHSRCDIR)
USRINCLUDES = -I$(TOPDIR)/sched -I$(ARCHSRCDIR) -I$(ARCHSRCDIR)/common
endif
INCLUDES = $(ARCHSTDINCLUDES) $(USRINCLUDES)
CFLAGS = $(ARCHWARNINGS) $(ARCHOPTIMIZATION) $(ARCHCPUFLAGS) $(INCLUDES) $(ARCHDEFINES) $(EXTRADEFINES)
CPPFLAGS += -I$(ARCHSRCDIR)
INCLUDES = $(ARCHSTDINCLUDES) $(USRINCLUDES)
CFLAGS = $(ARCHWARNINGS) $(ARCHOPTIMIZATION) $(ARCHCPUFLAGS) $(INCLUDES) $(ARCHDEFINES) $(EXTRADEFINES)
CPPFLAGS += -I$(ARCHSRCDIR)
ifeq ($(COMPILER),zneocc.exe)
LDFLAGS += @"${shell cygpath -w $(ARCHSRCDIR)/nuttx.linkcmd}"
LDFLAGS += @"${shell cygpath -w $(ARCHSRCDIR)/nuttx.linkcmd}"
endif
HEAD_ASRC = $(HEAD_SSRC:.S=$(ASMEXT))
HEAD_OBJ = $(HEAD_SSRC:.S=$(OBJEXT))
HEAD_ASRC = $(HEAD_SSRC:.S=$(ASMEXT))
HEAD_OBJ = $(HEAD_SSRC:.S=$(OBJEXT))
SSRCS = $(CHIP_SSRCS) $(CMN_SSRCS)
ASRCS = $(SSRCS:.S=$(ASMEXT))
AOBJS = $(SSRCS:.S=$(OBJEXT))
SSRCS = $(CHIP_SSRCS) $(CMN_SSRCS)
ASRCS = $(SSRCS:.S=$(ASMEXT))
AOBJS = $(SSRCS:.S=$(OBJEXT))
CSRCS = $(CHIP_CSRCS) $(CMN_CSRCS)
COBJS = $(CSRCS:.c=$(OBJEXT))
CSRCS = $(CHIP_CSRCS) $(CMN_CSRCS)
COBJS = $(CSRCS:.c=$(OBJEXT))
DEPSRCS = $(SSRCS) $(CSRCS)
OBJS = $(AOBJS) $(COBJS)
DEPSRCS = $(SSRCS) $(CSRCS)
OBJS = $(AOBJS) $(COBJS)
BOARDDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src/board
BOARDDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src/board
VPATH = chip:common
VPATH = chip:common
all: $(HEAD_OBJ) libarch$(LIBEXT)
@ -103,7 +103,7 @@ nuttx.linkcmd: $(LINKCMDTEMPLATE)
@echo "\"${shell cygpath -w $(TOPDIR)/nuttx}\"= \\" >>nuttx.linkcmd
@echo " \"${shell cygpath -w $(ARCHSRCDIR)/$(HEAD_OBJ)}\", \\" >>nuttx.linkcmd
@( for lib in $(LINKLIBS); do \
echo " \"`cygpath -w $(TOPDIR)/$${lib}`\", \\" >>nuttx.linkcmd; \
echo " \"`cygpath -w $(TOPDIR)/lib/$${lib}`\", \\" >>nuttx.linkcmd; \
done ; )
@echo " \"${shell cygpath -w $(ARCHSRCDIR)/board/libboard$(LIBEXT)}\", \\" >>nuttx.linkcmd
@echo " \"${shell cygpath -w $(ZDSSTDLIBDIR)/chelpld$(LIBEXT)}\", \\" >>nuttx.linkcmd

View File

@ -37,49 +37,49 @@
# Tools
# CFLAGS, CPPFLAGS, ASFLAGS, LDFLAGS are set in $(TOPDIR)/Make.defs
CFLAGS += -I$(ARCH_SRCDIR)/chip -I$(ARCH_SRCDIR)/common -I$(TOPDIR)/sched
CPPFLAGS += -D__ASSEMBLY__
CFLAGS += -I$(ARCH_SRCDIR)/chip -I$(ARCH_SRCDIR)/common -I$(TOPDIR)/sched
CPPFLAGS += -D__ASSEMBLY__
############################################################################
# Files and directories
# There should be one head source (.asm file)
HEAD_OBJ = $(HEAD_ASRC:$(ASMEXT)=$(OBJEXT))
HEAD_OBJ = $(HEAD_ASRC:$(ASMEXT)=$(OBJEXT))
# Assembly sources and objects
ASRCS = $(CHIP_ASRCS) $(CMN_ASRCS)
AOBJS = $(ASRCS:$(ASMEXT)=$(OBJEXT))
ASRCS = $(CHIP_ASRCS) $(CMN_ASRCS)
AOBJS = $(ASRCS:$(ASMEXT)=$(OBJEXT))
# C sources and objects
CSRCS = $(CHIP_CSRCS) $(CMN_CSRCS)
COBJS = $(CSRCS:.c=$(OBJEXT))
CSRCS = $(CHIP_CSRCS) $(CMN_CSRCS)
COBJS = $(CSRCS:.c=$(OBJEXT))
# All sources and objcts
SRCS = $(ASRCS) $(CSRCS)
OBJS = $(AOBJS) $(COBJS)
SRCS = $(ASRCS) $(CSRCS)
OBJS = $(AOBJS) $(COBJS)
# Sources that can have dependencies (no .asm files)
DEPSRCS = $(CSRCS)
DEPSRCS = $(CSRCS)
# Directories
ARCH_SRCDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src
BOARDDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src/board
ARCH_SRCDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src
BOARDDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src/board
VPATH = chip:common:board
VPATH = chip:common:board
# Libraries
LIBGCC = ${shell $(CC) $(ARCHCPUFLAGS) -print-libgcc-file-name}
LIBGCC = ${shell $(CC) $(ARCHCPUFLAGS) -print-libgcc-file-name}
# Supports dynamic sizing of HEAP.
#
HEAP_BASE = ${shell ./mkhpbase.sh}
HEAP_BASE = ${shell ./mkhpbase.sh}
############################################################################
# Targets
@ -152,7 +152,7 @@ pass1.hex: up_mem.h asm_mem.h $(SDCCLIBDIR)/myz80.lib $(HEAD_OBJ) board/libboard
@echo "-k $(SDCCLIBDIR)" >>pass1.lnk # Path to SDCC z80 library
@echo "-l libboard$(LIBEXT)" >>pass1.lnk # Name of board library
@for LIB in $(LINKLIBS); do \
echo "-l $(TOPDIR)/$$LIB" >> pass1.lnk ;\
echo "-l $(TOPDIR)/lib/$$LIB" >> pass1.lnk ;\
done
@echo "-l myz80.lib" >>pass1.lnk # Name of SDCC z80 library
ifneq ($(CONFIG_LINKER_START_AREA),)
@ -185,7 +185,7 @@ nuttx.hex: up_mem.h asm_mem.h $(SDCCLIBDIR)/myz80.lib $(HEAD_OBJ) board/libboard
@echo "-k $(SDCCLIBDIR)" >>nuttx.lnk # Path to SDCC z80 library
@echo "-l libboard$(LIBEXT)" >>nuttx.lnk # Name of board library
@for LIB in $(LINKLIBS); do \
echo "-l $(TOPDIR)/$$LIB" >> nuttx.lnk ;\
echo "-l $(TOPDIR)/lib/$$LIB" >> nuttx.lnk ;\
done
@echo "-l myz80.lib" >>nuttx.lnk # Name of SDCC z80 library
ifneq ($(CONFIG_LINKER_START_AREA),)

View File

@ -38,42 +38,42 @@
# Board-specific directory, board library, and application library
PASS1_SRCDIR = arch/$(CONFIG_ARCH)/src
PASS1_BOARDDIR = $(PASS1_SRCDIR)/board
PASS1_LIBBOARD = $(PASS1_BOARDDIR)/libboard$(LIBEXT)
PASS1_SRCDIR = arch/$(CONFIG_ARCH)/src
PASS1_BOARDDIR = $(PASS1_SRCDIR)/board
PASS1_LIBBOARD = $(PASS1_BOARDDIR)/libboard$(LIBEXT)
# Where is the application library?
ifneq ($(CONFIG_APPS_DIR),)
PASS1_LIBAPPS = $(CONFIG_APPS_DIR)/libapps$(LIBEXT)
PASS1_LIBAPPS = $(CONFIG_APPS_DIR)/libapps$(LIBEXT)
else
ifneq ($(APPDIR),)
PASS1_LIBAPPS = $(APPDIR)/libapps$(LIBEXT)
PASS1_LIBAPPS = $(APPDIR)/libapps$(LIBEXT)
endif
endif
# Remove the application library (libapps) from the list of libraries. Add
# the boad library (liboard)
PASS1_LINKLIBS = $(filter-out $(PASS1_LIBAPPS),$(LINKLIBS))
PASS1_LINKLIBS += $(PASS1_LIBBOARD)
PASS1_LINKLIBS = $(filter-out $(PASS1_LIBAPPS),$(LINKLIBS))
PASS1_LINKLIBS += $(PASS1_LIBBOARD)
# Get the paths to the libraries and the links script path in format that
# is appropriate for the host OS
ifeq ($(WINTOOL),y)
# Windows-native toolchains
PASS1_LIBPATHS = ${shell for path in $(PASS1_LINKLIBS); do dir=`dirname $(TOPDIR)/$$path`;echo "-L\"`cygpath -w $$dir`\"";done}
PASS1_LDSCRIPT = -T "${shell cygpath -w $(TOPDIR)/configs/$(CONFIG_ARCH_BOARD)/locked/ld-locked.inc}"
PASS1_LIBPATHS += -L"${shell cygpath -w "$(TOPDIR)/lib"}"
PASS1_LDSCRIPT = -T "${shell cygpath -w $(TOPDIR)/configs/$(CONFIG_ARCH_BOARD)/locked/ld-locked.inc}"
else
# Linux/Cygwin-native toolchain
PASS1_LIBPATHS = $(addprefix -L$(TOPDIR)/,$(dir $(PASS1_LINKLIBS)))
PASS1_LDSCRIPT = -T$(TOPDIR)/configs/$(CONFIG_ARCH_BOARD)/locked/ld-locked.inc
PASS1_LIBPATHS += -L"(TOPDIR)/lib"
PASS1_LDSCRIPT = -T$(TOPDIR)/configs/$(CONFIG_ARCH_BOARD)/locked/ld-locked.inc
endif
PASS1_LDFLAGS = -r $(PASS1_LDSCRIPT)
PASS1_LDLIBS = $(patsubst lib%,-l%,$(basename $(notdir $(PASS1_LINKLIBS))))
PASS1_LIBGCC = "${shell $(CC) -print-libgcc-file-name}"
PASS1_LDFLAGS = -r $(PASS1_LDSCRIPT)
PASS1_LDLIBS = $(patsubst %.a,%,$(patsubst lib%,-l%,$(PASS1_LINKLIBS)))
PASS1_LIBGCC = "${shell $(CC) -print-libgcc-file-name}"
# Targets: