X-Authentication-Warning: delorie.com: mail set sender to djgpp-bounces using -f From: tm Newsgroups: comp.lang.misc,comp.os.msdos.djgpp Subject: Re: ANN: Seed7 Release 2011-11-11 Date: Tue, 29 Nov 2011 15:28:13 -0800 (PST) Organization: http://groups.google.com Lines: 314 Message-ID: References: <7037d719-14a3-4e62-8ebc-0fdbdbdf1db1 AT r9g2000vbw DOT googlegroups DOT com> <839be453-9721-41d5-9955-14d39a35d31a AT q9g2000yqe DOT googlegroups DOT com> NNTP-Posting-Host: 84.112.82.23 Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 X-Trace: posting.google.com 1322609640 2659 127.0.0.1 (29 Nov 2011 23:34:00 GMT) X-Complaints-To: groups-abuse AT google DOT com NNTP-Posting-Date: Tue, 29 Nov 2011 23:34:00 +0000 (UTC) Complaints-To: groups-abuse AT google DOT com Injection-Info: j10g2000vbe.googlegroups.com; posting-host=84.112.82.23; posting-account=269_QwoAAADSifhJt6OVa6bEjZR2ZMUB User-Agent: G2/1.0 X-Google-Web-Client: true X-Google-Header-Order: HUALESNKRC X-HTTP-UserAgent: Mozilla/5.0 (Ubuntu; X11; Linux i686; rv:8.0) Gecko/20100101 Firefox/8.0,gzip(gfe) Bytes: 13074 To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com On Nov 29, 8:56 am, Rugxulo wrote: > Hi, > > On Nov 28, 5:30 pm, Rugxulo wrote: > > > On Nov 28, 4:23 pm, tm wrote: > > > > I installed DJGPP under Windows XP, to test it. > > > I use the original make.exe from DJGPP/bin to execute mk_djgpp.mak > > > (with C:\DJGPP\bin\make -f mk_djgpp.mak). When I use your patch I > > > get error messages. > > And yet your makefile doesn't work for me (aunts' WinXP cpu). It still > seems to need backslash escapes for both single and double quotes as > well as editing to avoid "Ambiguous redirect error" for > GET_CC_VERSION. I have no idea how to the fix the "Ambiguous redirect error". The purpose of the preprocessor macro C_COMPILER_VERSION is explained in a previous message. Escaping quotes is also done in other makefiles. In this makefiles the argument to echo is a quoted string. Inspired by this I created the following makefile: ------------- begin mk_djgpp.mak --------------- # Makefile for gmake and gcc from MinGW. Commands executed by: cmd.exe # To compile use a windows console and call: # make -f mk_djgpp.mak depend # make -f mk_djgpp.mak # If your version of gmake does not support dos commands use MSYS with mk_msys.mak or mk_nmake.mak. # CFLAGS = -O2 -fomit-frame-pointer -funroll-loops -Wall # CFLAGS = -O2 -fomit-frame-pointer -Wall -Wstrict-prototypes -Winline -Wconversion -Wshadow -Wpointer-arith CFLAGS = -O2 -g -Wall -Wstrict-prototypes -Winline -Wconversion - Wshadow -Wpointer-arith # CFLAGS = -O2 -g -pg -Wall -Wstrict-prototypes -Winline -Wconversion - Wshadow -Wpointer-arith # CFLAGS = -O2 -Wall -Wstrict-prototypes -Winline -Wconversion - Wshadow -Wpointer-arith # CFLAGS = -O2 -pg -Wall -Wstrict-prototypes -Winline -Wconversion - Wshadow -Wpointer-arith # CFLAGS = -O2 -funroll-loops -Wall -pg # Since there is no linker option to determine the stack size # it is determined with STACK_SIZE_DEFINITION (see below). LDFLAGS = # LDFLAGS = -pg # LDFLAGS = -pg -lc_p SYSTEM_LIBS = -lm # SYSTEM_LIBS = -lm -lgmp SYSTEM_CONSOLE_LIBS = SYSTEM_DRAW_LIBS = SEED7_LIB = seed7_05.a CONSOLE_LIB = s7_con.a DRAW_LIB = s7_draw.a COMP_DATA_LIB = s7_data.a COMPILER_LIB = s7_comp.a ALL_S7_LIBS = ..\bin\$(COMPILER_LIB) ..\bin\$(COMP_DATA_LIB) ..\bin\$ (DRAW_LIB) ..\bin\$(CONSOLE_LIB) ..\bin\$(SEED7_LIB) # CC = g++ CC = gcc GET_CC_VERSION_INFO = $(CC) --version > BIGINT_LIB_DEFINE = USE_BIG_RTL_LIBRARY BIGINT_LIB = big_rtl # BIGINT_LIB_DEFINE = USE_BIG_GMP_LIBRARY # BIGINT_LIB = big_gmp MOBJ1 = hi.o POBJ1 = runerr.o option.o primitiv.o LOBJ1 = actlib.o arrlib.o biglib.o blnlib.o bstlib.o chrlib.o cmdlib.o conlib.o dcllib.o drwlib.o LOBJ2 = enulib.o fillib.o fltlib.o hshlib.o intlib.o itflib.o kbdlib.o lstlib.o prclib.o prglib.o LOBJ3 = reflib.o rfllib.o sctlib.o setlib.o soclib.o strlib.o timlib.o typlib.o ut8lib.o EOBJ1 = exec.o doany.o objutl.o AOBJ1 = act_comp.o prg_comp.o analyze.o syntax.o token.o parser.o name.o type.o AOBJ2 = expr.o atom.o object.o scanner.o literal.o numlit.o findid.o AOBJ3 = error.o infile.o symbol.o info.o stat.o fatal.o match.o GOBJ1 = syvarutl.o traceutl.o actutl.o executl.o blockutl.o GOBJ2 = entutl.o identutl.o chclsutl.o sigutl.o ROBJ1 = arr_rtl.o bln_rtl.o bst_rtl.o chr_rtl.o cmd_rtl.o con_rtl.o dir_rtl.o drw_rtl.o fil_rtl.o ROBJ2 = flt_rtl.o hsh_rtl.o int_rtl.o set_rtl.o soc_dos.o str_rtl.o tim_rtl.o ut8_rtl.o ROBJ3 = heaputl.o striutl.o DOBJ1 = $(BIGINT_LIB).o cmd_unx.o fil_dos.o tim_dos.o OBJ = $(MOBJ1) SEED7_LIB_OBJ = $(ROBJ1) $(ROBJ2) $(ROBJ3) $(DOBJ1) DRAW_LIB_OBJ = gkb_rtl.o drw_dos.o CONSOLE_LIB_OBJ = kbd_rtl.o con_wat.o COMP_DATA_LIB_OBJ = typ_data.o rfl_data.o ref_data.o listutl.o flistutl.o typeutl.o datautl.o COMPILER_LIB_OBJ = $(POBJ1) $(LOBJ1) $(LOBJ2) $(LOBJ3) $(EOBJ1) $ (AOBJ1) $(AOBJ2) $(AOBJ3) $(GOBJ1) $(GOBJ2) MSRC1 = hi.c PSRC1 = runerr.c option.c primitiv.c LSRC1 = actlib.c arrlib.c biglib.c blnlib.c bstlib.c chrlib.c cmdlib.c conlib.c dcllib.c drwlib.c LSRC2 = enulib.c fillib.c fltlib.c hshlib.c intlib.c itflib.c kbdlib.c lstlib.c prclib.c prglib.c LSRC3 = reflib.c rfllib.c sctlib.c setlib.c soclib.c strlib.c timlib.c typlib.c ut8lib.c ESRC1 = exec.c doany.c objutl.c ASRC1 = act_comp.c prg_comp.c analyze.c syntax.c token.c parser.c name.c type.c ASRC2 = expr.c atom.c object.c scanner.c literal.c numlit.c findid.c ASRC3 = error.c infile.c symbol.c info.c stat.c fatal.c match.c GSRC1 = syvarutl.c traceutl.c actutl.c executl.c blockutl.c GSRC2 = entutl.c identutl.c chclsutl.c sigutl.c RSRC1 = arr_rtl.c bln_rtl.c bst_rtl.c chr_rtl.c cmd_rtl.c con_rtl.c dir_rtl.c drw_rtl.c fil_rtl.c RSRC2 = flt_rtl.c hsh_rtl.c int_rtl.c set_rtl.c soc_dos.c str_rtl.c tim_rtl.c ut8_rtl.c RSRC3 = heaputl.c striutl.c DSRC1 = $(BIGINT_LIB).c cmd_unx.c fil_dos.c tim_dos.c SRC = $(MSRC1) SEED7_LIB_SRC = $(RSRC1) $(RSRC2) $(RSRC3) $(DSRC1) DRAW_LIB_SRC = gkb_rtl.c drw_dos.c CONSOLE_LIB_SRC = kbd_rtl.c con_wat.c COMP_DATA_LIB_SRC = typ_data.c rfl_data.c ref_data.c listutl.c flistutl.c typeutl.c datautl.c COMPILER_LIB_SRC = $(PSRC1) $(LSRC1) $(LSRC2) $(LSRC3) $(ESRC1) $ (ASRC1) $(ASRC2) $(ASRC3) $(GSRC1) $(GSRC2) hi: ..\bin\hi.exe ..\prg\hi.exe ..\bin\hi level ..\bin\hi.exe: $(OBJ) $(ALL_S7_LIBS) $(CC) $(LDFLAGS) $(OBJ) $(ALL_S7_LIBS) $(SYSTEM_DRAW_LIBS) $ (SYSTEM_CONSOLE_LIBS) $(SYSTEM_LIBS) -o ..\bin\hi.exe ..\prg\hi.exe: ..\bin\hi.exe copy ..\bin\hi.exe ..\prg clear: clean clean: del version.h del *.o del ..\bin\*.a del depend dep: depend strip: strip ..\bin\hi.exe version.h: echo "#define ANSI_C" > version.h echo "#define USE_DIRENT" >> version.h echo "#define PATH_DELIMITER '\\\\'" >> version.h echo "#define SEARCH_PATH_DELIMITER ';'" >> version.h echo "#define MAP_ABSOLUTE_PATH_TO_DRIVE_LETTERS" >> version.h echo "#define CATCH_SIGNALS" >> version.h echo "#define AWAIT_WITH_SELECT" >> version.h echo "#define OS_STRI_USES_CODEPAGE" >> version.h echo "#define os_lstat stat" >> version.h echo "#define os_fseek fseek" >> version.h echo "#define os_ftell ftell" >> version.h echo "#define OS_FSEEK_OFFSET_BITS 32" >> version.h echo "#define os_off_t off_t" >> version.h echo "#define os_putenv putenv" >> version.h echo "#define $(BIGINT_LIB_DEFINE)" >> version.h echo "#define likely(x) __builtin_expect((x),1)" >> version.h echo "#define unlikely(x) __builtin_expect((x),0)" >> version.h $(GET_CC_VERSION_INFO) cc_vers.txt echo "#include \"direct.h\"" > chkccomp.h echo "#define mkdir(path,mode) mkdir(path)" >> chkccomp.h echo "#define LIST_DIRECTORY_CONTENTS \"dir\"" >> chkccomp.h echo "#define long_long_EXISTS" >> chkccomp.h echo "#define long_long_SUFFIX_LL" >> chkccomp.h $(CC) chkccomp.c -lm -o chkccomp.exe .\chkccomp.exe >> version.h del chkccomp.h del chkccomp.exe del cc_vers.txt echo "#define OBJECT_FILE_EXTENSION \".o\"" >> version.h echo "#define LIBRARY_FILE_EXTENSION \".a\"" >> version.h echo "#define EXECUTABLE_FILE_EXTENSION \".exe\"" >> version.h echo "#define C_COMPILER \"$(CC)\"" >> version.h echo "#define GET_CC_VERSION_INFO \"$(GET_CC_VERSION_INFO)\"" >> version.h echo "#define CC_OPT_DEBUG_INFO \"-g\"" >> version.h echo "#define CC_OPT_NO_WARNINGS \"-w\"" >> version.h echo "#define LINKER_OPT_OUTPUT_FILE \"-o \"" >> version.h echo "#define LINKER_FLAGS \"$(LDFLAGS)\"" >> version.h echo "#define SYSTEM_LIBS \"$(SYSTEM_LIBS)\"" >> version.h echo "#define SYSTEM_CONSOLE_LIBS \"$(SYSTEM_CONSOLE_LIBS)\"" >> version.h echo "#define SYSTEM_DRAW_LIBS \"$(SYSTEM_DRAW_LIBS)\"" >> version.h echo "#define SEED7_LIB \"$(SEED7_LIB)\"" >> version.h echo "#define CONSOLE_LIB \"$(CONSOLE_LIB)\"" >> version.h echo "#define DRAW_LIB \"$(DRAW_LIB)\"" >> version.h echo "#define COMP_DATA_LIB \"$(COMP_DATA_LIB)\"" >> version.h echo "#define COMPILER_LIB \"$(COMPILER_LIB)\"" >> version.h echo "#define STACK_SIZE_DEFINITION unsigned _stklen = 4194304" >> version.h $(CC) setpaths.c -o setpaths.exe .\setpaths.exe >> version.h del setpaths.exe depend: version.h echo Working without C header dependency checks. level.h: ..\bin\hi level ..\bin\$(SEED7_LIB): $(SEED7_LIB_OBJ) ar r ..\bin\$(SEED7_LIB) $(SEED7_LIB_OBJ) ..\bin\$(CONSOLE_LIB): $(CONSOLE_LIB_OBJ) ar r ..\bin\$(CONSOLE_LIB) $(CONSOLE_LIB_OBJ) ..\bin\$(DRAW_LIB): $(DRAW_LIB_OBJ) ar r ..\bin\$(DRAW_LIB) $(DRAW_LIB_OBJ) ..\bin\$(COMP_DATA_LIB): $(COMP_DATA_LIB_OBJ) ar r ..\bin\$(COMP_DATA_LIB) $(COMP_DATA_LIB_OBJ) ..\bin\$(COMPILER_LIB): $(COMPILER_LIB_OBJ) ar r ..\bin\$(COMPILER_LIB) $(COMPILER_LIB_OBJ) wc: $(SRC) echo SRC: wc $(SRC) echo SEED7_LIB_SRC: wc $(SEED7_LIB_SRC) echo CONSOLE_LIB_SRC: wc $(CONSOLE_LIB_SRC) echo DRAW_LIB_SRC: wc $(DRAW_LIB_SRC) echo COMP_DATA_LIB_SRC: wc $(COMP_DATA_LIB_SRC) echo COMPILER_LIB_SRC: wc $(COMPILER_LIB_SRC) lint: $(SRC) lint -p $(SRC) $(SYSTEM_DRAW_LIBS) $(SYSTEM_CONSOLE_LIBS) $ (SYSTEM_LIBS) lint2: $(SRC) lint -Zn2048 $(SRC) $(SYSTEM_DRAW_LIBS) $(SYSTEM_CONSOLE_LIBS) $ (SYSTEM_LIBS) ------------- end mk_djgpp.mak --------------- The only difference to the last version are the rules to produce "version.h" with echo commands. Please try this makefile (be careful the usenet system (google groups) might add line breaks), and tell me what is still missing. > And yet it still seems to do it when not using Bash. I don't know why. > Perhaps your Make is old 3.79.1? Yes, my DJGPP make has version 3.79.1 > I'm using /beta/mak381b.zip here. > Also I think you must have Fil41b, Txt20b, Shl2011b (aka, CoreUtils) > installed else it has some other error in the "make depend" stage, > didn't check too closely. Since I installed DJGPP long ago I cannot remember which packages I installed. I certainly did not install all packages of DJGPP. When I was able to compile Seed7 I stopped installing DJGPP packages. > > redir -eo hi chk_all | tee blah.txt As explained elsewhere you can start every chkxxx.sd7 program separately. Separate compilation of every chkxxx.sd7 programs is also possible. > I'm not sure *.cerrs is being created. You are right, no *.cerrs or *.lerrs are created. > You may still have blindly > assumed "2>" works everywhere. No, acually the preprocessor macro REDIRECT_C_ERRORS is used to redirect to *.cerrs. Since the macro is not defined in mk_djgpp.mak, no *.cerrs or *.lerrs is produced. > But let me reiterate that "hi chkbig" > and "hi chkset" both work fine. Honestly, all this fuss may be (only) > over the compiled compiler, which I don't really "need", do I? An > interpreter is good enough. ;-) It would still be interesting to find out why compilation of chkbig.sd7 and chkset.sd7 fails. I want to be sure that the Seed7 compiler is not the cause of the error. > P.S. Does your makefile depend on both "seed7/bin/hi" and "seed7/bin/ > hi.exe" existing? They're the same exact file but wasting space with > duplication. Feel free to directly "-o hi.exe" (instead of "-o hi") to > avoid that. Thank you, I was not aware of that. Greetings Thomas Mertes -- Seed7 Homepage: http://seed7.sourceforge.net Seed7 - The extensible programming language: User defined statements and operators, abstract data types, templates without special syntax, OO with interfaces and multiple dispatch, statically typed, interpreted or compiled, portable, runs under linux/unix/windows.