From 5777eae02600466cb88719dcee2463b4b8fd2112 Mon Sep 17 00:00:00 2001 From: hendricks266 Date: Sun, 8 Apr 2012 07:23:24 +0000 Subject: [PATCH] Build tools: - clearbufbyte --> Bmemset - add libm to $(UTILLIBS) to fix building of mkpalette - add self-explanatory Makefile commands: dxutils, sdlutils, printdxutils, printsdlutils git-svn-id: https://svn.eduke32.com/eduke32@2597 1a8010ca-5511-0410-912e-c29ae57300e0 --- polymer/eduke32/build/Makefile | 32 +++++++++++++++++++----- polymer/eduke32/build/src/util/wad2map.c | 8 +++--- 2 files changed, 30 insertions(+), 10 deletions(-) diff --git a/polymer/eduke32/build/Makefile b/polymer/eduke32/build/Makefile index dcdac4eb4..987e45bba 100644 --- a/polymer/eduke32/build/Makefile +++ b/polymer/eduke32/build/Makefile @@ -58,7 +58,7 @@ ifneq ($(LUNATIC),0) OURCFLAGS+= -DLUNATIC_ENABLE endif -UTILLIBS= # -lpthread +UTILLIBS= -lm # -lpthread UTILADDOBJS= ifneq (0,$(NEDMALLOC)) UTILADDOBJS+= $(OBJ)/nedmalloc.$o @@ -191,7 +191,7 @@ OURCFLAGS+= $(BUILDCFLAGS) UTILOBJS=$(OBJ)/kextract.$o $(OBJ)/kgroup.$o $(OBJ)/transpal.$o $(OBJ)/wad2art.$o $(OBJ)/wad2map.$o $(OBJ)/kmd2tool.$o \ $(OBJ)/md2tool.$o \ - $(OBJ)/generateicon.$o $(OBJ)/cacheinfo.$o $(OBJ)/enumdisplay.$o $(OBJ)/arttool.$o $(OBJ)/givedepth.$o $(OBJ)/mkpalette.$o \ + $(OBJ)/generateicon.$o $(OBJ)/cacheinfo.$o $(OBJ)/arttool.$o $(OBJ)/givedepth.$o $(OBJ)/mkpalette.$o \ $(OBJ)/unpackssi.$o $(OBJ)/bsuite.$o \ $(OBJ)/compat.$o $(OBJ)/compat_tools.$o $(OBJ)/pragmas.$o $(OBJ)/kplib.$o $(OBJ)/cache1d.$o UTILS=kextract$(EXESUFFIX) kgroup$(EXESUFFIX) transpal$(EXESUFFIX) wad2art$(EXESUFFIX) wad2map$(EXESUFFIX) kmd2tool$(EXESUFFIX) \ @@ -199,16 +199,32 @@ UTILS=kextract$(EXESUFFIX) kgroup$(EXESUFFIX) transpal$(EXESUFFIX) wad2art$(EXES generateicon$(EXESUFFIX) cacheinfo$(EXESUFFIX) arttool$(EXESUFFIX) givedepth$(EXESUFFIX) mkpalette$(EXESUFFIX) \ unpackssi$(EXESUFFIX) bsuite$(EXESUFFIX) +DXUTILOBJS=$(OBJ)/enumdisplay.$o $(OBJ)/getdxdidf.$o +DXUTILS=enumdisplay$(EXESUFFIX) getdxdidf$(EXESUFFIX) + +SDLUTILOBJS=$(OBJ)/makesdlkeytrans.$o +SDLUTILS=makesdlkeytrans$(EXESUFFIX) + # all: $(OBJ)/$(ENGINELIB) $(OBJ)/$(EDITORLIB) -utils: start $(UTILS) finish +utils: start $(UTILS) finish utilfinish +dxutils: start $(DXUTILS) finish dxutilfinish +sdlutils: start $(SDLUTILS) finish sdlutilfinish start: $(BUILD_STARTED) finish: $(BUILD_FINISHED) + +utilfinish: @ls -l $(UTILS) +dxutilfinish: + @ls -l $(DXUTILS) + +sdlutilfinish: + @ls -l $(SDLUTILS) + enginelib: $(OBJ)/$(ENGINELIB) $(OBJ)/$(ENGINELIB): $(ENGINEOBJS) $(BUILD_ECHOFLAGS) @@ -349,13 +365,17 @@ clean: echo -n "" > $(OBJ)/keep.me cleanutils: - -rm -f $(UTILS) $(UTILOBJS) $(UTILADDOBJS) \ - enumdisplay$(EXESUFFIX) getdxdidf$(EXESUFFIX) makesdlkeytrans$(EXESUFFIX) \ - $(OBJ)/compat.$o $(OBJ)/getdxdidf.$o $(OBJ)/makesdlkeytrans.$o + -rm -f $(UTILS) $(UTILOBJS) $(DXUTILS) $(DXUTILOBJS) $(SDLUTILS) $(SDLUTILOBJS) $(UTILADDOBJS) printutils: echo "$(UTILS)" +printdxutils: + echo "$(DXUTILS)" + +printsdlutils: + echo "$(SDLUTILS)" + veryclean: clean cleanutils -rm -f $(ENGINELIB) $(EDITORLIB) diff --git a/polymer/eduke32/build/src/util/wad2map.c b/polymer/eduke32/build/src/util/wad2map.c index 84cf69d87..3ee422def 100644 --- a/polymer/eduke32/build/src/util/wad2map.c +++ b/polymer/eduke32/build/src/util/wad2map.c @@ -300,7 +300,7 @@ void parsescript(void) int spritenumstat, slen; char ch; - clearbufbyte(§spri[0], sizeof(short) * MAXSECTS * 8, 0xffffffff); + Bmemset(sectspri, 0xffffffff, MAXSECTS*8*sizeof(short)); if (scriptname[0] == 0) { @@ -1050,9 +1050,9 @@ int main(int argc, char **argv) } } - clearbufbyte(§or[0], sizeof(sectortype) * MAXSECTORS, 0); - clearbufbyte(&wall[0], sizeof(walltype) * MAXWALLS, 0); - clearbufbyte(&sprite[0], sizeof(spritetype) * MAXSPRITES, 0); + Bmemset(sector, 0, MAXSECTORS*sizeof(sectortype)); + Bmemset(wall, 0, MAXWALLS*sizeof(walltype)); + Bmemset(sprite, 0, MAXSPRITES*sizeof(spritetype)); for(i=0;i