summaryrefslogtreecommitdiff
path: root/libc/sysdeps/linux/sh64/Makefile
diff options
context:
space:
mode:
authorPaul Mundt <lethal@linux-sh.org>2008-01-08 08:44:43 +0000
committerPaul Mundt <lethal@linux-sh.org>2008-01-08 08:44:43 +0000
commitb20e5adb661f95f639324b252a3028ac0abeca2f (patch)
tree19a5b2c0ae734b93029a80263afa486d7376cb02 /libc/sysdeps/linux/sh64/Makefile
parentb4937a448bcd897c84de6abb36c39eff492a2b91 (diff)
Bring sh64 support back from the dead.
Diffstat (limited to 'libc/sysdeps/linux/sh64/Makefile')
-rw-r--r--libc/sysdeps/linux/sh64/Makefile61
1 files changed, 6 insertions, 55 deletions
diff --git a/libc/sysdeps/linux/sh64/Makefile b/libc/sysdeps/linux/sh64/Makefile
index 020cc76c8..ecbf14228 100644
--- a/libc/sysdeps/linux/sh64/Makefile
+++ b/libc/sysdeps/linux/sh64/Makefile
@@ -5,60 +5,11 @@
#
# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+top_srcdir=../../../../
+top_builddir=../../../../
+all: objs
+include $(top_builddir)Rules.mak
+include Makefile.arch
+include $(top_srcdir)Makerules
TOPDIR=../../../../
include $(TOPDIR)Rules.mak
-
-CFLAGS += -I..
-ASFLAGS += -I.. -D__ASSEMBLER__ -DASM_GLOBAL_DIRECTIVE=.globl
-
-TARGET_MACHINE_TYPE=$(shell $(CC) -dumpmachine)
-
-CRT_SRC := crt0.S
-CRT_OBJ := crt0.o crt1.o
-CTOR_TARGETS := $(TOPDIR)lib/crti.o $(TOPDIR)lib/crtn.o
-
-SSRC := setjmp.S longjmp.S
-SOBJ := $(patsubst %.S,%.o, $(SSRC))
-
-CSRC := __init_brk.c brk.c sbrk.c syscall.c
-COBJ := $(patsubst %.c,%.o, $(CSRC))
-
-OBJS := $(SOBJ) $(COBJ)
-
-OBJ_LIST := ../../../obj.sysdeps.$(TARGET_ARCH)
-
-all: $(OBJ_LIST) $(CTOR_TARGETS)
-
-$(OBJ_LIST): $(OBJS) $(CRT_OBJ)
- $(STRIPTOOL) -x -R .note -R .comment $^
- $(INSTALL) -d $(TOPDIR)lib/
- cp $(CRT_OBJ) $(TOPDIR)lib/
- echo $(patsubst %, sysdeps/linux/$(TARGET_ARCH)/%, $(OBJS)) > $@
-
-$(CRT_OBJ): $(CRT_SRC)
- $(CC) $(ASFLAGS) -DL_$* $< -c -o $*.o
-
-$(SOBJ): %.o : %.S
- $(CC) $(ASFLAGS) -c $< -o $@
-
-$(COBJ): %.o : %.c
- $(CC) $(CFLAGS) -c $< -o $@
-
-ifeq ($(UCLIBC_CTOR_DTOR),y)
-$(TOPDIR)lib/crti.o: crti.S
- $(INSTALL) -d $(TOPDIR)lib/
- $(CC) $(ASFLAGS) $(SSP_DISABLE_FLAGS) -c $< -o $@
-
-$(TOPDIR)lib/crtn.o: crtn.S
- $(INSTALL) -d $(TOPDIR)lib/
- $(CC) $(ASFLAGS) $(SSP_DISABLE_FLAGS) -c $< -o $@
-else
-$(CTOR_TARGETS):
- $(INSTALL) -d $(TOPDIR)lib/
- $(AR) $(ARFLAGS) $@
-endif
-
-headers:
-
-clean:
- $(RM) *.o *~ core