Hackfix and re-enable strtoull and wcstoull, see bug #3798.
[sdcc.git] / sdcc / device / lib / r2ka / Makefile.in
blob9f9b2cd935e4da1617764cc9c03e6aa22b8d6336
1 # libc/r2ka Makefile
3 VPATH = @srcdir@
4 srcdir = @srcdir@
5 top_builddir = @top_builddir@
6 abs_top_builddir = @abs_top_builddir@
8 LIB_TYPE = @LIB_TYPE@
10 EXTRA_CFLAGS = -mr2ka --max-allocs-per-node 25000
11 SAS = $(top_builddir)/bin/sdasrab
13 # override PORTDIR defined by super (parent) makefile
14 override PORTDIR = ../build/r2ka
16 # BUG?
17 %.rel: %.s
18 @# TODO: sdas should place it\'s output in the current dir
19 test $(srcdir) = . || cp $< .
20 -$(AS) $(ASFLAGS) $(notdir $<)
21 test $(srcdir) = . || rm $(notdir $<)
23 include $(srcdir)/../incl.mk
25 Z80_FLOAT = $(COMMON_FLOAT)
27 Z80_INT = $(COMMON_INT)
29 Z80_LONG = $(COMMON_LONG) \
30 _divulong.c \
31 _mullong.c
33 Z80_LONGLONG = $(COMMON_LONGLONG) \
34 _mullonglong.c \
35 _divslonglong.c \
36 _divulonglong.c \
37 _modslonglong.c \
38 _modulonglong.c
40 Z80_SDCC = $(COMMON_SDCC) \
41 __itoa.c \
42 __ltoa.c \
43 _startup.c \
44 div.c \
45 ldiv.c \
46 lldiv.c \
47 sprintf.c \
48 vprintf.c \
49 strlen.c \
50 strnlen.c \
51 _strcmp.c \
52 atomic_flag_clear.c
54 Z80SOURCES = $(addprefix ../,$(Z80_FLOAT) $(Z80_INT) $(Z80_LONG) $(Z80_LONGLONG) $(Z80_SDCC))
55 Z8OBJECTS = $(patsubst %.c,%.rel,$(Z80_FLOAT) $(Z80_INT) $(Z80_LONG) $(Z80_LONGLONG) $(Z80_SDCC))
57 OBJ = divunsigned.rel divsigned.rel divmixed.rel modunsigned.rel modsigned.rel modmixed.rel mulchar.rel \
58 heap.rel memmove.rel strcpy.rel abs.rel __sdcc_call_hl.rel __sdcc_call_iy.rel crtenter.rel memcpy.rel \
59 setjmp.rel atomic_flag_test_and_set.rel
61 LIB = r2ka.lib
62 AS = $(SAS)
63 ASFLAGS = -plosgff
65 CFLAGS = -I$(srcdir)/../../include -I. --std-c23
67 all: $(PORTDIR)/$(LIB) $(PORTDIR)/crt0.rel
69 $(PORTDIR)/crt0.rel: crt0.rel
70 cp crt0.rel $(PORTDIR)/crt0.rel
72 Makefile: $(srcdir)/Makefile.in
73 cd $(top_builddir); ./config.status device/lib/r2ka/Makefile
75 $(PORTDIR)/$(LIB): $(OBJ) $(Z8OBJECTS) Makefile
76 rm -f $@
77 ifeq ($(LIB_TYPE), SDCCLIB)
78 $(top_builddir)/bin/sdcclib -a $@ $(OBJ) $(Z8OBJECTS)
79 else
80 ifeq ($(LIB_TYPE), AR)
81 $(SDAR) -rcSD $@ $(OBJ) $(Z8OBJECTS)
82 else
83 ifeq ($(LIB_TYPE), RANLIB)
84 $(SDAR) -rcD $@ $(OBJ) $(Z8OBJECTS)
85 else
86 for i in $(basename $(OBJ) $(Z8OBJECTS)); do echo $$i >>$@; done
87 cp $(OBJ) $(Z8OBJECTS) $(PORTDIR)
88 endif
89 endif
90 endif
92 clean:
93 rm -f *.rel *.sym *.lst *~ $(CLEANSPEC) *.dump* *.asm *.lib
95 distclean: clean
96 rm -f Makefile
98 Makefile: $(srcdir)/Makefile.in
99 cd $(top_builddir); ./config.status device/lib/r2ka/Makefile