From: hachti Date: Mon, 20 Nov 2006 08:27:06 +0000 (+0000) Subject: *** empty log message *** X-Git-Url: http://gitweb.hachti.de/?a=commitdiff_plain;h=c8a4d02d5587558cc128f1aba948d1d622aa0a89;p=h316.git *** empty log message *** --- diff --git a/pc-tools/ldc2/Makefile b/pc-tools/ldc2/Makefile index d50c2ee..3a99fe5 100644 --- a/pc-tools/ldc2/Makefile +++ b/pc-tools/ldc2/Makefile @@ -1,32 +1,45 @@ APP_NAME=ldc2 -APP_OBJECTS= main.o silent_code.o - -APP_OBJECTS+= tape_block.o eot_block.o discard_block.o\ +APP_OBJECTS= main.o silent_code.o argument_reader.o +CCFLAGS+=-Wall +BLOCK_OBJECTS=data_block_0_10.o data_block_0_14.o data_block_0_1.o data_block_0_24.o\ + data_block_0_2.o data_block_0_30.o data_block_0_3.o data_block_0_4.o\ + data_block_0_50.o data_block_0_54.o data_block_0_60.o data_block_0_44.o\ + data_block_0_64.o tape_block.o eot_block.o discard_block.o\ data_block.o data_block_0.o data_block_0_0.o\ - data_block_0_label_extractor.o + data_block_0_label_extractor.o data_block_1.o data_block_2.o\ + data_block_3.o data_block_4.o data_block_5.o \ + data_block_6.o data_block_7.o \ + -APP_OBJECTS+= data_block_0_10.o data_block_0_14.o data_block_0_1.o data_block_0_24.o\ - data_block_0_2.o data_block_0_30.o data_block_0_3.o data_block_0_4.o\ - data_block_0_50.o data_block_0_54.o data_block_0_60.o data_block_0_44.o +APP_OBJECTS+=$(BLOCK_OBJECTS) SRC_DIR=src default: $(APP_NAME) -#All objects depend on all headers. simple but works -*.o: $(SRC_DIR)/*.hh +APP_SOURCES=$(foreach obj, $(APP_OBJECTS:.o=.cpp),$(SRC_DIR)/$(obj)) + +##All objects depend on all headers. simple but works +#*.o: $(SRC_DIR)/*.hh + +%.dep : $(SRC_DIR)/%.cpp + @ echo Building dependencies for $<. + @$(SHELL) -c "g++ -M $<" | awk 'BEGIN {N=0}{if(N==0)printf("%s %s\n","$@",$$0);else printf("%s\n", $$0);N+=1;}' > $@ + -%.o : $(SRC_DIR)/%.cpp - g++ -c -o$@ $< +%.o : $(SRC_DIR)/%.cpp %.dep + g++ -c $(CCFLAGS) -o $@ $< $(APP_NAME) : $(APP_OBJECTS) - g++ -o$@ $^ + @g++ -o$@ $^ + +saustall: $(APP_OBJECTS:.o=.dep) clean: - rm -rf $(APP_NAME) *.o doxy/ $(SRC_DIR)/*~ ul_timestamp - $(MAKE) -C doc clean + @rm -rf $(APP_NAME) *.o doxy/ $(SRC_DIR)/*~ ul_timestamp *.dep + @$(MAKE) -C doc clean -doxy/timestamp: $(SRC_DIR)/* +doxy/timestamp: $(APP_OBJECTS) @ if [ ! -d doxy ]; then mkdir doxy; fi @doxygen Doxyfile touch $@ @@ -46,3 +59,9 @@ doc: all: $(APP_NAME) doxy doc .PHONY: all clean doxy upload docdata_block_0_0.o + +.PRECIOUS: *.dep + +#$(APP_OBJECTS:.o=.d) + +include $(wildcard *.dep) diff --git a/pc-tools/ldc2/doc/Makefile b/pc-tools/ldc2/doc/Makefile index 22eb7ce..00999b2 100644 --- a/pc-tools/ldc2/doc/Makefile +++ b/pc-tools/ldc2/doc/Makefile @@ -16,4 +16,4 @@ main.dvi: *.tex *.bib cat ps.gnu $< | gnuplot > $@ clean: - rm -f *.dvi *.ps *.pdf *.toc *~ *.log *.aux *.bbl *.blg *.lof *.lot + @rm -f *.dvi *.ps *.pdf *.toc *~ *.log *.aux *.bbl *.blg *.lof *.lot diff --git a/pc-tools/ldc2/src/data_block_0_0.cpp b/pc-tools/ldc2/src/data_block_0_0.cpp index ece243d..5fc41ee 100644 --- a/pc-tools/ldc2/src/data_block_0_0.cpp +++ b/pc-tools/ldc2/src/data_block_0_0.cpp @@ -16,7 +16,7 @@ data_block_0_0::data_block_0_0(data_block_0 & org) vector data_block_0_0::get_description(){ vector result; vector labels=get_labels(); - for (int i=0; i data_block_0_50::get_description(){ vector result; vector labels=get_labels(); - for (int i=0; i"); ar.add_param("n","name=","Enter other name",&name_set,&name,""); @@ -57,7 +57,7 @@ int main(int argc, char ** args){ ar.add_param("n","name=","Enter other name",&name_set,&name,""); ar.add_param("n","name=","Enter other name",&name_set,&name,""); ar.add_param("n","name=","Enter other name",&name_set,&name,""); - ar.add_free_param("","File to read data from",&file_set,&filename); + ar.add_argument("","File to read data from",&file_set,&filename); dump_vector(ar.read_args(argc,args));