Hackfix and re-enable strtoull and wcstoull, see bug #3798.
[sdcc.git] / sdcc / device / lib / hc08 / Makefile.in
blob07ccf0ba7479793d9c2c7e4494ed629323cad105
1 # libc/hc08 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 = -mhc08 --max-allocs-per-node 25000
11 SAS = $(top_builddir)/bin/sdas6808
13 # override PORTDIR defined by super (parent) makefile
14 override PORTDIR = ../build/hc08
16 include $(srcdir)/../incl.mk
18 HC08_FLOAT = $(COMMON_FLOAT)
20 HC08_INT = $(COMMON_INT) \
21 _divsint.c \
22 _divuint.c \
23 _modsint.c \
24 _moduint.c
26 HC08_LONG = $(COMMON_LONG) \
27 _mullong.c \
28 _divulong.c
30 HC08_LONGLONG = $(COMMON_LONGLONG) \
31 _srulonglong.c \
32 _srslonglong.c \
33 _slulonglong.c \
34 _slslonglong.c \
35 _mullonglong.c \
36 _divslonglong.c \
37 _divulonglong.c \
38 _modslonglong.c \
39 _modulonglong.c
41 HC08_SDCC = $(COMMON_SDCC) \
42 __itoa.c \
43 __ltoa.c \
44 _startup.c \
45 _strcmp.c \
46 strlen.c \
47 strnlen.c \
48 _strcpy.c \
49 __memcpy.c \
50 div.c \
51 ldiv.c \
52 memcpy.c \
53 _memmove.c \
54 _heap.c \
55 sprintf.c \
56 vprintf.c \
57 atomic_flag_clear.c
59 HC08SOURCES = $(addprefix ../,$(HC08_FLOAT) $(HC08_INT) $(HC08_LONG) $(HC08_LONGLONG) $(HC08_SDCC))
60 HC08OBJECTS = $(patsubst %.c,%.rel,$(HC08_FLOAT) $(HC08_INT) $(HC08_LONG) $(HC08_LONGLONG) $(HC08_SDCC))
62 OBJ = _ret.rel _mulint.rel _setjmp.rel atomic_flag_test_and_set.rel
64 LIB = hc08.lib
65 AS = $(SAS)
66 ASFLAGS = -plosgff
68 CFLAGS = -I$(srcdir)/../../include -I. --std-c23
70 all: $(PORTDIR)/$(LIB)
72 $(PORTDIR)/$(LIB): $(OBJ) $(HC08OBJECTS) Makefile
73 ifeq ($(LIB_TYPE), SDCCLIB)
74 rm -f $@; \
75 $(top_builddir)/bin/sdcclib -a $@ $(OBJ) $(HC08OBJECTS)
76 else
77 ifeq ($(LIB_TYPE), AR)
78 $(SDAR) -rcSD $@ $(OBJ) $(HC08OBJECTS)
79 else
80 ifeq ($(LIB_TYPE), RANLIB)
81 $(SDAR) -rcD $@ $(OBJ) $(HC08OBJECTS)
82 else
83 rm -f $@
84 for i in $(basename $(OBJ) $(HC08OBJECTS)); do echo $$i >>$@; done
85 cp $(OBJ) $(HC08OBJECTS) $(PORTDIR)
86 endif
87 endif
88 endif
90 %.rel: %.c
91 $(CC) $(CFLAGS) ${EXTRA_CFLAGS} -c $<
93 %.rel: ../%.c
94 $(CC) $(CFLAGS) ${EXTRA_CFLAGS} -c $<
96 clean:
97 rm -f *.rel *.sym *.lst *~ $(CLEANSPEC) *.dump* *.asm *.lib
99 distclean: clean
100 rm -f Makefile
102 Makefile: $(srcdir)/Makefile.in
103 cd $(top_builddir); ./config.status device/lib/hc08/Makefile