# http://www.gknw.net/development/prgtools/awk.zip
AWK = awk
ZIP = zip -qzR9
+MV = mv -fv
# must be equal to DEBUG or NDEBUG
DB = NDEBUG
ARFLAGS = -cq
LIBEXT = a
CFLAGS += -fno-builtin -fpack-struct -fpcc-struct-return -fno-strict-aliasing
-CFLAGS += -Wall -Wno-unused # -pedantic
+CFLAGS += -Wall -Wno-unused -Wno-return-type # -pedantic
ifeq ($(LIBARCH),LIBC)
PRELUDE = $(SDK_LIBC)/imports/libcpre.gcc.o
else
all: rrdtool rrdcgi
-rrdtool: $(OBJDIR) $(PROOT)/config.h $(OBJDIR)/rrdtool.nlm
-rrdcgi: $(OBJDIR) $(PROOT)/config.h $(OBJDIR)/rrdcgi.$(CGIEXT)
-librrd: $(OBJDIR) $(PROOT)/config.h $(OBJDIR)/librrd.$(LIBEXT)
+rrdtool: $(OBJDIR) $(PROOT)/rrd_config.h $(OBJDIR)/rrdtool.nlm
+rrdcgi: $(OBJDIR) $(PROOT)/rrd_config.h $(OBJDIR)/rrdcgi.$(CGIEXT)
+librrd: $(OBJDIR) $(PROOT)/rrd_config.h $(OBJDIR)/librrd.$(LIBEXT)
dist: all $(DISTDIR) $(DISTDIR)/readme.txt
# @-$(CP) $(OBJDIR)/librrd.$(LIBEXT) $(DISTDIR)
@-mkdir $(DEVLDIR)$(DS)lib
@-mkdir $(DEVLDIR)$(DS)src
@-$(CP) $(OBJDIR)/librrd.$(LIBEXT) $(DEVLDIR)/lib
- @-$(CP) $(PROOT)/config.h $(DEVLDIR)/include
+ @-$(CP) $(PROOT)/rrd_config.h $(DEVLDIR)/include
@-$(CP) $(PROOT)/src/rrd.h $(DEVLDIR)/include
@-$(CP) $(PROOT)/src/*.ttf $(DEVLDIR)/src
@-$(CP) $(PROOT)/CHANGES $(DEVLDIR)
clean:
-$(RM) -r $(OBJDIR)
- -$(RM) $(PROOT)/config.h
+ -$(RM) $(PROOT)/rrd_config.h
distclean: clean
-$(RM) -r $(DISTDIR)
@echo Linking $@
@-$(RM) $@
@$(LD) $(LDFLAGS) $(@:.$(CGIEXT)=.def)
+ifeq ($(LD),nlmconv)
+ @$(MV) $(notdir $@) $@
+endif
ifneq ($(CGIEXT),nlm)
ifeq ($(LD),mwldnlm)
@$(FIXNLMN) $@
@echo Linking $@
@-$(RM) $@
@$(LD) $(LDFLAGS) $(@:.nlm=.def)
+ifeq ($(LD),nlmconv)
+ @$(MV) $(notdir $@) $@
+endif
$(OBJDIR)/librrd.$(LIBEXT): $(OBJS)
@echo Creating $@
$(PROOT)/rrd_config.h: Makefile
@echo Creating $@
- @echo $(DL)/* $(notdir $@) for NetWare target.$(DL) > $@
+ @echo $(DL)/* $(notdir $@) for NetWare target.$(DL) > $@
@echo $(DL)** Do not edit this file - it is created by make!$(DL) >> $@
@echo $(DL)** All your changes will be lost!!$(DL) >> $@
@echo $(DL)*/$(DL) >> $@
@echo $(DL)#ifndef NETWARE$(DL) >> $@
- @echo $(DL)#error This $(notdir $@) is created for NetWare platform!$(DL) >> $@
+ @echo $(DL)#error This $(notdir $@) is created for NetWare platform!$(DL) >> $@
@echo $(DL)#endif$(DL) >> $@
- @echo $(DL)#ifndef RRD_CONFIG_H$(DL) >> $@
- @echo $(DL)#define RRD_CONFIG_H$(DL) >> $@
+ @echo $(DL)#ifndef RRD_CONFIG_H$(DL) >> $@
+ @echo $(DL)#define RRD_CONFIG_H$(DL) >> $@
@echo $(DL)#define OS "i586-pc-NetWare"$(DL) >> $@
@echo $(DL)#define PACKAGE_VERSION "$(RRD_VERSION_STR)"$(DL) >> $@
@echo $(DL)#define PACKAGE_BUGREPORT "tobi@oetiker.ch"$(DL) >> $@