diff --git a/src/Makefile.mingw b/src/Makefile.mingw new file mode 100644 index 0000000..68e0bac --- /dev/null +++ b/src/Makefile.mingw @@ -0,0 +1,74 @@ +# +# makefile for MingW +# + +CFLAGS = -O3 -Wall +LIBS = -lm +CC = gcc +RM = rm + +#SRC = + +PROGS = acme.exe +BINDIR = /usr/local/bin +USERBIN = $(HOME)/bin + +all: $(PROGS) + +acme.exe: acme.o alu.o basics.o cliargs.o cpu.o dynabuf.o encoding.o flow.o global.o input.o label.o macro.o mnemo.o output.o platform.o section.o tree.o _dos.o resource.res + $(CC) $(LIBS) $(CFLAGS) -o acme acme.o alu.o basics.o cliargs.o cpu.o dynabuf.o encoding.o flow.o global.o input.o label.o macro.o mnemo.o output.o platform.o section.o tree.o resource.res + strip acme.exe + + + +acme.o: config.h platform.h acme.h alu.h basics.h cpu.h dynabuf.h encoding.h flow.h global.h input.h label.h macro.h mnemo.h output.h section.h acme.h _dos.h acme.c + +alu.o: config.h platform.h cpu.h dynabuf.h encoding.h global.h input.h label.h section.h tree.h alu.h alu.c + +cliargs.o: cliargs.h cliargs.c + +cpu.o: config.h alu.h dynabuf.h global.h input.h mnemo.h output.h tree.h cpu.h cpu.c + +dynabuf.o: config.h acme.h global.h input.h dynabuf.h dynabuf.c + +encoding.o: config.h alu.h acme.h dynabuf.h global.h output.h input.h tree.h encoding.h encoding.c + +flow.o: config.h acme.h alu.h dynabuf.h global.h input.h label.h macro.h mnemo.h tree.h flow.h flow.c + +global.o: config.h platform.h acme.h cpu.h input.h label.h macro.h section.h global.h global.c + +input.o: config.h dynabuf.h global.h section.h tree.h input.h input.c + +label.o: config.h acme.h alu.h cpu.h dynabuf.h global.h input.h mnemo.h section.h tree.h label.h label.c + +macro.o: config.h acme.h alu.h dynabuf.h global.h input.h label.h section.h tree.h macro.h macro.c + +mnemo.o: config.h alu.h cpu.h dynabuf.h global.h input.h output.h tree.h mnemo.h mnemo.c + +output.o: config.h acme.h alu.h cpu.h dynabuf.h global.h input.h tree.h output.h output.c + +platform.o: config.h platform.h platform.c + +section.o: config.h dynabuf.h global.h section.h tree.h section.h section.c + +tree.o: config.h dynabuf.h global.h label.h tree.h tree.c + +# _dos.o: _dos.h + +resource.res: win/resource.rc win/logo.ico + cd win; windres resource.rc -O coff -o ../resource.res + cp -f win/logo.ico . + +clean: + -$(RM) -f *.o $(PROGS) *~ core resource.res logo.ico + + +install: all + install -d $(BINDIR) + install $(PROGS) $(BINDIR) + +userinstall: all + install -d $(USERBIN) + install $(PROGS) $(USERBIN) + +# DO NOT DELETE diff --git a/src/flow.c b/src/flow.c index 0c2ddf8..d154281 100644 --- a/src/flow.c +++ b/src/flow.c @@ -127,7 +127,11 @@ static enum eos_t PO_do(void) // Now GotByte = illegal char char *loop_body; int go_on, loop_start; // line number of loop pseudo opcode - + // Init + condition2.type = ID_UNTIL; + condition2.body = NULL; + condition1.body = NULL; + // Read head condition to buffer SKIPSPACE(); store_condition(&condition1, CHAR_SOB); diff --git a/src/input.c b/src/input.c index a350d72..635a63d 100644 --- a/src/input.c +++ b/src/input.c @@ -78,7 +78,7 @@ void Input_new_file(const char *filename, FILE *fd) // Deliver source code from current file (!) in shortened high-level format static char get_processed_from_file(void) { - int from_file; + int from_file = 0; for (;;) { switch (Input_now->state) { diff --git a/src/win/logo.ico b/src/win/logo.ico new file mode 100644 index 0000000..5b0cc3b Binary files /dev/null and b/src/win/logo.ico differ diff --git a/src/win/resource.rc b/src/win/resource.rc new file mode 100644 index 0000000..8fe5d47 --- /dev/null +++ b/src/win/resource.rc @@ -0,0 +1,34 @@ +// Iconfile (64/32/16) +ID ICON "Logo.ico" + +// Infos for windows +1 VERSIONINFO +FILEVERSION 0,94,4,0 +PRODUCTVERSION 0,94,4,0 +FILEFLAGSMASK 0x3fL +FILEFLAGS 0x0L +FILEOS 0x40004L +FILETYPE 0x2L +FILESUBTYPE 0x0L +BEGIN + BLOCK "StringFileInfo" + BEGIN + BLOCK "040904E4" + BEGIN + VALUE "CompanyName", "Smørbrød Software" + VALUE "FileDescription", "Acme crossassembler" + VALUE "FileVersion", "0.94.4 testing" + VALUE "InternalName", "ACME crossassembler" + VALUE "LegalCopyright", "Copyright © 2013 Marco Baye" + VALUE "OriginalFilename", "acme.exe" + VALUE "ProductName", "ACME Crossassembler" + VALUE "ProductVersion", "0.94.4 testing" + VALUE "PorductLicence","GNU General Public License" + VALUE "WindowsPort","Dirk Höpfner hoeppie@gmx.de" + END + END + BLOCK "VarFileInfo" + BEGIN + VALUE "Translation", 0x409, 1252 + END +END \ No newline at end of file