gm2
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Gm2] Possible bug when using -fmakeall / ncurses example


From: Christoph Schlegel
Subject: Re: [Gm2] Possible bug when using -fmakeall / ncurses example
Date: Fri, 2 Jan 2015 11:47:58 +0100

To be more precise, the module

MODULE test;
BEGIN
END test.

does not compile when gm2 is called with -fmakeall. 'gm2 -fmakeall test.mod' 
results in

$ gm2 -fmakeall test.mod
/home/Christoph/opt/lib/gcc//i686-pc-cygwin/4.7.3gm2 -c -fmakeall0 
-B/home/Christoph/opt/lib/gcc//i686-pc-cygwin/4.7.3 -fonlylink 
-ftarget-ar=/usr/bin/ar -ftarget-ranlib=/usr/bin/ranlib 
-fobject-path=/home/Christoph/opt/lib/gcc/i686-pc-cygwin/4.7.3/gm2/pim 
-fmakeall -I/home/Christoph/opt/lib/gcc/i686-pc-cygwin/4.7.3/m2/pim test.mod
make: /home/Christoph/opt/lib/gcc//i686-pc-cygwin/4.7.3gm2: command not found
/tmp/ccFX0XeM.m:11: recipe for target 'test.o' failed
make: *** [test.o] Error 127

I picked up the temporary makefile in /tmp and found it to look like this:

OPTIONS=  \
        -fmakeall0 -B/home/Christoph/opt/lib/gcc//i686-pc-cygwin/4.7.3 
-fonlylink -ftarget-ar=/usr/bin/ar -ftarget-ranlib=/usr/bin/ranlib 
-fobject-path=/home/Christoph/opt/lib/gcc/i686-pc-cygwin/4.7.3/gm2/pim 
-fmakeall -I/home/Christoph/opt/lib/gcc/i686-pc-cygwin/4.7.3/m2/pim
M2C= /home/Christoph/opt/lib/gcc//i686-pc-cygwin/4.7.3gm2 \
         -c $(OPTIONS)
M2L= /home/Christoph/opt/lib/gcc//i686-pc-cygwin/4.7.3gm2 \
         -fonlylink -I. $(OPTIONS) 

test: test.o

test.o: test.mod
        $(M2C) test.mod

clean: force
        $(RM)  test.o

force:

I don't understand the lines M2C and M2L. Should there be a gm2.exe in 
/home/Christoph/opt/lib/gcc//i686-pc-cygwin/4.7.3 (there isn't)?

Regards,
Christoph


On Mon, 29 Dec 2014 20:20:37 +0100
Christoph Schlegel <address@hidden> wrote:

> Hello Gaius,
> 
> another report after testing the newly built gm2 compiler on Cygwin32.
> 
> The following error occured when I tried to compile the ncurses-example. Note 
> the command 'home/Christoph/opt/lib/gcc//i686-pc-cygwin/4.7.3gm2 -c etc.' 
> where a slash seems to be missing. I remember a similar problem which 
> appeared a few months ago 
> (http://lists.gnu.org/archive/html/gm2/2014-01/msg00003.html). I tried and 
> the example code from back then compiles now. I guess the Makefile created by 
> -fmakeall carries some bug within. I really tried to provide more but I 
> cannot reproduce/understand the way -fmakeall works, so here is the error: 
> 
> address@hidden ~/gm2build/gcc/gm2/examples/ncurses
> $ make post-install
> gm2 -g -fmake-I=../../../../../gcc-4.7.3/gcc/gm2/examples/ncurses 
> -flibs=pim-coroutine -fmakeall 
> -I../../../../../gcc-4.7.3/gcc/gm2/examples/ncurses/../../gm2-libs-coroutines:../../../../../gcc-4.7.3/gcc/gm2/examples/ncurses
>  ../../../../../gcc-4.7.3/gcc/gm2/examples/ncurses/testwin.mod -lncurses -lpth
> make[1]: Entering directory 
> '/home/Christoph/gm2build/gcc/gm2/examples/ncurses'
> /home/Christoph/opt/lib/gcc//i686-pc-cygwin/4.7.3gm2 -c -fmakeall0 
> -B/home/Christoph/opt/lib/gcc//i686-pc-cygwin/4.7.3 -g -fonlylink 
> -fobject-path=../../../../../gcc-4.7.3/gcc/gm2/examples/ncurses/../../gm2-libs-coroutines:../../../../../gcc-4.7.3/gcc/gm2/examples/ncurses
>  -ftarget-ar=/usr/bin/ar -ftarget-ranlib=/usr/bin/ranlib 
> -fmake-I=../../../../../gcc-4.7.3/gcc/gm2/examples/ncurses 
> -flibs=pim-coroutine -fmakeall 
> -I../../../../../gcc-4.7.3/gcc/gm2/examples/ncurses/../../gm2-libs-coroutines:../../../../../gcc-4.7.3/gcc/gm2/examples/ncurses
>  -I/home/Christoph/opt/lib/gcc/i686-pc-cygwin/4.7.3/m2/pim-coroutine  \
> ../../../../../gcc-4.7.3/gcc/gm2/examples/ncurses/testwin.mod
> make[1]: /home/Christoph/opt/lib/gcc//i686-pc-cygwin/4.7.3gm2: Kommando nicht 
> gefunden (command not found)
> /tmp/ccFJSbkI.m:12: recipe for target 'testwin.o' failed
> make[1]: *** [testwin.o] Error 127
> make[1]: Leaving directory '/home/Christoph/gm2build/gcc/gm2/examples/ncurses'
> Makefile:38: recipe for target 'post-install' failed
> make: *** [post-install] Error 1
> 
> And a sidenote: A small change that could be made to be more compatible with 
> platforms like Windows: Using the size command results in an error when 
> called like in the hello world example of gm2. It could be written like: 
> 'size a$(EXEEXT)' instead of 'size a.out' to take care of the Windows .exe 
> extension (for example in the Makefile of the hello-example, lines 37, 39, 43 
> and 45). Reference: 
> http://www.gnu.org/software/automake/manual/html_node/EXEEXT.html -
> 
> And one more thing, I forgot to wish you a merry christmas and a happy new 
> year - just wanted to catch up...
> 
> Regards,
> Christoph
> 
> 
> _______________________________________________
> gm2 mailing list
> address@hidden
> https://lists.nongnu.org/mailman/listinfo/gm2


-- 
Christoph Schlegel <address@hidden>



reply via email to

[Prev in Thread] Current Thread [Next in Thread]