Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2022-02-02 09:06:21 +0300
committerMike Frysinger <vapier@gentoo.org>2022-02-11 14:14:55 +0300
commit66dfedc28778e81d9d75a4a3fa1e74192138bf62 (patch)
tree9b7baf6afa1365e7fad67030a082fb15ef30ebd0 /libgloss/bfin
parent62e580f01b8d1c5a3bce5c046853332217cf6458 (diff)
libgloss: merge bfin into top-level Makefile
Avoid a recursive make to speed things up a bit.
Diffstat (limited to 'libgloss/bfin')
-rw-r--r--libgloss/bfin/Makefile.in207
-rw-r--r--libgloss/bfin/Makefile.inc71
2 files changed, 71 insertions, 207 deletions
diff --git a/libgloss/bfin/Makefile.in b/libgloss/bfin/Makefile.in
deleted file mode 100644
index f3d4cb624..000000000
--- a/libgloss/bfin/Makefile.in
+++ /dev/null
@@ -1,207 +0,0 @@
-#
-#
-
-DESTDIR =
-VPATH = @srcdir@ @srcdir@/..
-srcdir = @srcdir@
-objdir = .
-srcroot = $(srcdir)/../..
-objroot = $(objdir)/../..
-
-prefix = @prefix@
-exec_prefix = @exec_prefix@
-
-host_alias = @host_alias@
-target_alias = @target_alias@
-
-bindir = @bindir@
-libdir = @libdir@
-tooldir = $(exec_prefix)/$(target_alias)
-
-INSTALL = @INSTALL@
-INSTALL_PROGRAM = @INSTALL_PROGRAM@
-INSTALL_DATA = @INSTALL_DATA@
-
-# Multilib support variables.
-# TOP is used instead of MULTI{BUILD,SRC}TOP.
-MULTIDIRS =
-MULTISUBDIR =
-
-SHELL = /bin/sh
-
-mkinstalldirs = $(SHELL) $(srcroot)/mkinstalldirs
-
-CC = @CC@
-
-AS = @AS@
-AR = @AR@
-LD = @LD@
-RANLIB = @RANLIB@
-
-OBJDUMP = `if [ -f ${objroot}/../binutils/objdump ] ; \
- then echo ${objroot}/../binutils/objdump ; \
- else t='$(program_transform_name)'; echo objdump | sed -e $$t ; fi`
-OBJCOPY = `if [ -f ${objroot}/../binutils/objcopy ] ; \
- then echo ${objroot}/../binutils/objcopy ; \
- else t='$(program_transform_name)'; echo objcopy | sed -e $$t ; fi`
-
-OBJS =
-CFLAGS =
-SCRIPTS =
-
-# Here is all of the simulator stuff
-SIM_SCRIPTS =
-SIM_LDFLAGS =
-SIM_BSP = libsim.a
-SIM_CRT0 = crt0.o
-SIM_OBJS = syscalls.o clear_cache_range.o
-SIM_TEST = sim-test
-SIM_INSTALL = install-sim
-
-# Here is all of the development board stuff
-BOARD_SCRIPTS = bfin-common-sc.ld bfin-common-mc.ld bfin-common-mc0.ld \
- bf504.ld bf506.ld \
- bf512.ld bf514.ld bf516.ld bf518.ld \
- bf522.ld bf523.ld bf524.ld bf525.ld bf526.ld bf527.ld \
- bf531.ld bf532.ld bf533.ld \
- bf534.ld bf536.ld bf537.ld \
- bf538.ld bf539.ld \
- bf542.ld bf544.ld bf547.ld bf548.ld bf549.ld \
- bf561.ld bf561a.ld bf561b.ld bf561m.ld \
- bf606.ld bf606c0.ld bf606c1.ld bf606m.ld \
- bf607.ld bf607c0.ld bf607c1.ld bf607m.ld \
- bf608.ld bf608c0.ld bf608c1.ld bf608m.ld \
- bf609.ld bf609c0.ld bf609c1.ld bf609m.ld \
- bf592.ld
-BOARD_LDFLAGS =
-BOARD_BSP = libbfinbsp.a
-BOARD_CRT0S = basiccrt.o basiccrts.o
-BOARD_CRT0S += basiccrt561.o basiccrt561s.o basiccrt561b.o
-# BOARD_CRT0S += basiccrt60x.o basiccrt60xs.o basiccrt60xc1.o
-BOARD_OBJS = clear_cache_range.o _exit.o
-BOARD_TEST =
-BOARD_INSTALL = install-board
-
-# Host specific makefile fragment comes in here.
-@host_makefile_frag@
-
-INCLUDES += -I$(srcdir)/include
-#
-# build a test program for each target board. Just trying to get
-# it to link is a good test, so we ignore all the errors for now.
-#
-all: ${SIM_CRT0} ${SIM_BSP} ${BOARD_CRT0S} ${BOARD_BSP}
-
-#
-# here's where we build the board support packages for each target
-#
-${BOARD_BSP}: ${OBJS} ${BOARD_OBJS}
- ${AR} ${ARFLAGS} $@ $^
- ${RANLIB} $@
-
-${SIM_BSP}: ${OBJS} ${SIM_OBJS}
- ${AR} ${ARFLAGS} ${SIM_BSP} ${SIM_OBJS} ${OBJS}
- ${RANLIB} ${SIM_BSP}
-
-#
-#
-#
-crt0.o: crt0.S
-
-basiccrt.o: basiccrt.S
-ifeq (,$(findstring mcpu=,$(CFLAGS)))
- $(CC) $(CFLAGS_FOR_TARGET) $(INCLUDES) $(CFLAGS) -mcpu=bf532-any -o $@ -c $<
-else
- $(CC) $(CFLAGS_FOR_TARGET) $(INCLUDES) $(CFLAGS) -o $@ -c $<
-endif
-
-basiccrts.o: basiccrt.S
-ifeq (,$(findstring mcpu=,$(CFLAGS)))
- $(CC) -D__BFIN_SDRAM $(CFLAGS_FOR_TARGET) $(INCLUDES) $(CFLAGS) -mcpu=bf532-any -o $@ -c $<
-else
- $(CC) -D__BFIN_SDRAM $(CFLAGS_FOR_TARGET) $(INCLUDES) $(CFLAGS) -o $@ -c $<
-endif
-
-basiccrt561.o: basiccrt.S
-ifneq (,$(findstring mcpu=bf532-none,$(CFLAGS)))
- $(CC) $(CFLAGS_FOR_TARGET) $(INCLUDES) $(CFLAGS) -mcpu=bf561-none -o $@ -c $<
-else
- $(CC) $(CFLAGS_FOR_TARGET) $(INCLUDES) $(CFLAGS) -mcpu=bf561-any -o $@ -c $<
-endif
-
-basiccrt561s.o: basiccrt.S
-ifneq (,$(findstring mcpu=bf532-none,$(CFLAGS)))
- $(CC) -D__BFIN_SDRAM $(CFLAGS_FOR_TARGET) $(INCLUDES) $(CFLAGS) -mcpu=bf561-none -o $@ -c $<
-else
- $(CC) -D__BFIN_SDRAM $(CFLAGS_FOR_TARGET) $(INCLUDES) $(CFLAGS) -mcpu=bf561-any -o $@ -c $<
-endif
-
-basiccrt561b.o: basiccrt.S
-ifneq (,$(findstring mcpu=bf532-none,$(CFLAGS)))
- $(CC) -D__ADSPBF561_COREB__ $(CFLAGS_FOR_TARGET) $(INCLUDES) $(CFLAGS) -mcpu=bf561-none -o $@ -c $<
-else
- $(CC) -D__ADSPBF561_COREB__ $(CFLAGS_FOR_TARGET) $(INCLUDES) $(CFLAGS) -mcpu=bf561-any -o $@ -c $<
-endif
-
-basiccrt60x.o: basiccrt.S
-ifneq (,$(findstring mcpu=bf532-none,$(CFLAGS)))
- $(CC) $(CFLAGS_FOR_TARGET) $(INCLUDES) $(CFLAGS) -mcpu=bf608-none -o $@ -c $<
-else
- $(CC) $(CFLAGS_FOR_TARGET) $(INCLUDES) $(CFLAGS) -mcpu=bf608-any -o $@ -c $<
-endif
-
-basiccrt60xs.o: basiccrt.S
-ifneq (,$(findstring mcpu=bf532-none,$(CFLAGS)))
- $(CC) -D__BFIN_SDRAM $(CFLAGS_FOR_TARGET) $(INCLUDES) $(CFLAGS) -mcpu=bf608-none -o $@ -c $<
-else
- $(CC) -D__BFIN_SDRAM $(CFLAGS_FOR_TARGET) $(INCLUDES) $(CFLAGS) -mcpu=bf608-any -o $@ -c $<
-endif
-
-basiccrt60xc1.o: basiccrt.S
-ifneq (,$(findstring mcpu=bf532-none,$(CFLAGS)))
- $(CC) -D__ADSPBF60x_CORE1__ $(CFLAGS_FOR_TARGET) $(INCLUDES) $(CFLAGS) -mcpu=bf608-none -o $@ -c $<
-else
- $(CC) -D__ADSPBF60x_CORE1__ $(CFLAGS_FOR_TARGET) $(INCLUDES) $(CFLAGS) -mcpu=bf608-any -o $@ -c $<
-endif
-
-clean mostlyclean:
- rm -f a.out core *.i *.o ${SIM_BSP} ${BOARD_BSP}
-
-distclean maintainer-clean realclean: clean
- rm -f Makefile *~
-
-.PHONY: install info install-info clean-info
-install: ${SIM_INSTALL} ${BOARD_INSTALL}
-
-install-sim:
- ${mkinstalldirs} ${DESTDIR}${tooldir}/lib${MULTISUBDIR}
- for x in ${SIM_CRT0} ${SIM_BSP} ${SIM_SCRIPTS}; do \
- ${INSTALL_DATA} $$x $(DESTDIR)${tooldir}/lib${MULTISUBDIR}/$$x || exit $$?; \
- done
-
-install-board:
- ${mkinstalldirs} ${DESTDIR}${tooldir}/lib${MULTISUBDIR}
- for x in ${BOARD_CRT0S} ${BOARD_BSP}; do \
- ${INSTALL_DATA} $$x $(DESTDIR)${tooldir}/lib${MULTISUBDIR}/$$x || exit $$?; \
- done
- -if [ -z "${MULTISUBDIR}" ]; then \
- for x in ${BOARD_SCRIPTS}; do \
- ${INSTALL_DATA} ${srcdir}/$$x $(DESTDIR)${tooldir}/lib/$$x; \
- done; \
- ${mkinstalldirs} ${DESTDIR}${tooldir}/include; \
- for i in ${srcdir}/include/*.h; do \
- ${INSTALL_DATA} $$i ${DESTDIR}${tooldir}/include/`basename $$i`; \
- done; \
- ${mkinstalldirs} ${DESTDIR}${tooldir}/include/sys; \
- for i in ${srcdir}/include/sys/*.h; do \
- ${INSTALL_DATA} $$i ${DESTDIR}${tooldir}/include/sys/`basename $$i`; \
- done; \
- else true; fi
-
-doc:
-info:
-install-info:
-clean-info:
-
-Makefile: Makefile.in ../config.status
- cd .. && $(SHELL) config.status
diff --git a/libgloss/bfin/Makefile.inc b/libgloss/bfin/Makefile.inc
new file mode 100644
index 000000000..35e880809
--- /dev/null
+++ b/libgloss/bfin/Makefile.inc
@@ -0,0 +1,71 @@
+# Here is all of the simulator stuff.
+multilibtool_LIBRARIES += %D%/libsim.a
+%C%_libsim_a_SOURCES = \
+ %D%/clear_cache_range.c \
+ %D%/syscalls.c
+%C%_libsim_a_CPPFLAGS = \
+ $(AM_CPPFLAGS) \
+ -I$(srcdir)/%D/include
+
+check_PROGRAMS += %D%/sim-test
+
+# Here is all of the development board stuff.
+multilibtool_DATA += \
+ %D%/crt0.o \
+ %D%/basiccrt.o \
+ %D%/basiccrts.o \
+ %D%/basiccrt561.o \
+ %D%/basiccrt561s.o \
+ %D%/basiccrt561b.o
+# %D%/basiccrt60x.o \
+# %D%/basiccrt60xs.o \
+# %D%/basiccrt60xc1.o
+libobjs_a_SOURCES += \
+ %D%/crt0.S \
+ %D%/basiccrt.S
+
+if !HAVE_MULTISUBDIR
+multilibtool_DATA += \
+ %D%/bfin-common-sc.ld %D%/bfin-common-mc.ld %D%/bfin-common-mc0.ld \
+ %D%/bf504.ld %D%/bf506.ld \
+ %D%/bf512.ld %D%/bf514.ld %D%/bf516.ld %D%/bf518.ld \
+ %D%/bf522.ld %D%/bf523.ld %D%/bf524.ld %D%/bf525.ld %D%/bf526.ld %D%/bf527.ld \
+ %D%/bf531.ld %D%/bf532.ld %D%/bf533.ld \
+ %D%/bf534.ld %D%/bf536.ld %D%/bf537.ld \
+ %D%/bf538.ld %D%/bf539.ld \
+ %D%/bf542.ld %D%/bf544.ld %D%/bf547.ld %D%/bf548.ld %D%/bf549.ld \
+ %D%/bf561.ld %D%/bf561a.ld %D%/bf561b.ld %D%/bf561m.ld \
+ %D%/bf606.ld %D%/bf606c0.ld %D%/bf606c1.ld %D%/bf606m.ld \
+ %D%/bf607.ld %D%/bf607c0.ld %D%/bf607c1.ld %D%/bf607m.ld \
+ %D%/bf608.ld %D%/bf608c0.ld %D%/bf608c1.ld %D%/bf608m.ld \
+ %D%/bf609.ld %D%/bf609c0.ld %D%/bf609c1.ld %D%/bf609m.ld \
+ %D%/bf592.ld
+
+includetool_DATA += $(wildcard $(srcdir)/%D%/include/*.h)
+includesystool_DATA += $(wildcard $(srcdir)/%D%/include/sys/*.h)
+endif
+
+multilibtool_LIBRARIES += %D%/libbfinbsp.a
+%C%_libbfinbsp_a_SOURCES = \
+ %D%/clear_cache_range.c \
+ %D%/_exit.c
+%C%_libbfinbsp_a_CPPFLAGS = \
+ $(AM_CPPFLAGS) \
+ -I$(srcdir)/%D/include
+
+%D%/basiccrt.$(OBJEXT): %D%/basiccrt.S
+ $(AM_V_CC)$(COMPILE) -o $@ -c $< $(if $(findstring mcpu=,$(CFLAGS)),,-mcpu=bf532-any)
+%D%/basiccrts.$(OBJEXT): %D%/basiccrt.S
+ $(AM_V_CC)$(COMPILE) -o $@ -c $< $(if $(findstring mcpu=,$(CFLAGS)),,-mcpu=bf532-any) -D__BFIN_SDRAM
+%D%/basiccrt561.$(OBJEXT): %D%/basiccrt.S
+ $(AM_V_CC)$(COMPILE) -o $@ -c $< $(if $(findstring mcpu=,$(CFLAGS)),-mcpu=bf561-any,-mcpu=bf561-none)
+%D%/basiccrt561s.$(OBJEXT): %D%/basiccrt.S
+ $(AM_V_CC)$(COMPILE) -o $@ -c $< $(if $(findstring mcpu=,$(CFLAGS)),-mcpu=bf561-any,-mcpu=bf561-none) -D__BFIN_SDRAM
+%D%/basiccrt561b.$(OBJEXT): %D%/basiccrt.S
+ $(AM_V_CC)$(COMPILE) -o $@ -c $< $(if $(findstring mcpu=,$(CFLAGS)),-mcpu=bf561-any,-mcpu=bf561-none) -D__ADSPBF561_COREB__
+%D%/basiccrt60x.$(OBJEXT): %D%/basiccrt.S
+ $(AM_V_CC)$(COMPILE) -o $@ -c $< $(if $(findstring mcpu=,$(CFLAGS)),-mcpu=bf608-any,-mcpu=bf608-none)
+%D%/basiccrt60xs.$(OBJEXT): %D%/basiccrt.S
+ $(AM_V_CC)$(COMPILE) -o $@ -c $< $(if $(findstring mcpu=,$(CFLAGS)),-mcpu=bf608-any,-mcpu=bf608-none) -D__BFIN_SDRAM
+%D%/basiccrt60xc1.$(OBJEXT): %D%/basiccrt.S
+ $(AM_V_CC)$(COMPILE) -o $@ -c $< $(if $(findstring mcpu=,$(CFLAGS)),-mcpu=bf608-any,-mcpu=bf608-none) -D__ADSPBF60x_CORE1__