1 2 3 ifeq ($(NEOTONIC_ROOT),) 4 NEOTONIC_ROOT = .. 5 endif 6 7 include $(NEOTONIC_ROOT)/rules.mk 8 9 UTL_LIB = $(LIB_DIR)libneo_utl.a 10 UTL_SRC = neo_err.c neo_files.c neo_misc.c neo_rand.c ulist.c neo_hdf.c \ 11 neo_str.c neo_date.c wildmat.c neo_hash.c $(EXTRA_UTL_SRC) 12 13 UTL_OBJ = $(UTL_SRC:%.c=%.o) $(EXTRA_UTL_OBJS) 14 UTL_HDR = $(UTL_SRC:%.c=%.h) 15 16 TARGETS = $(UTL_LIB) 17 18 all: $(TARGETS) 19 20 $(UTL_LIB): $(UTL_OBJ) 21 $(AR) $@ $(UTL_OBJ) 22 $(RANLIB) $@ 23 24 install: all 25 $(NEOTONIC_ROOT)/mkinstalldirs $(DESTDIR)$(cs_includedir)/util 26 $(INSTALL) -m 644 $(UTL_HDR) $(DESTDIR)$(cs_includedir)/util 27 $(INSTALL) -m 644 $(UTL_LIB) $(DESTDIR)$(libdir) 28 29 clean: 30 $(RM) *.o 31 32 distclean: 33 $(RM) Makefile.depends $(TARGETS) *.o 34