[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Gm2] Compiling with pim-coroutine
From: |
Gaius Mulley |
Subject: |
Re: [Gm2] Compiling with pim-coroutine |
Date: |
Mon, 02 Dec 2013 20:26:08 +0000 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/23.4 (gnu/linux) |
Johannes von Rotz <address@hidden> writes:
> Hello,
>
> I'm trying to port a 30-or-so-year old application over to GNU Modula-2.
> Historically it was translated to C using Glance's M2CC and then built
> on the target platform using the appropriate C compiler. Since the
> number of supported platforms has shrunk dramatically (Basically it's
> all Linux on x86 now), this seems to be no longer necessary and so I've
> been slimming down the build process. Now I'd like to slim it down even
> more, trying to get rid of the translation to C.
>
> The problem I'm running into is the compilation of a module that imports
> the NEWPROCESS routine from SYSTEM. As it is my understanding, GNU
> Modula-2 provides exactly that with the pim-coroutine library. However,
> when trying to compile with -flibs=pim-coroutine this happens:
>
> $ /opt/gcc-4.1.2+gm2-1.0.4/bin/gm2 -flibs=pim-coroutine \
> -c sys.mod
> failed to find definition module M2RTS.def
>
> So I was thinking: Maybe the pim-coroutine extends the basic pim library
> and I have to include it too. But then:
>
> $ /opt/gcc-4.1.2+gm2-1.0.4/bin/gm2 -flibs=pim-coroutine,pim \
> -c sys.mod
> /opt/gcc-4.1.2+gm2-1.0.4/lib/gcc/x86_64-unknown-linux-gnu/4.1.2
> /gm2/pim-coroutine/SYSTEM.def:19:1: error: unknown symbol
> 'CARDINAL32' found
> /opt/gcc-4.1.2+gm2-1.0.4/lib/gcc/x86_64-unknown-linux-gnu/4.1.2
> /gm2/pim-coroutine/SYSTEM.def:19:1: error: unknown symbol
> 'INTEGER16' found
> /opt/gcc-4.1.2+gm2-1.0.4/lib/gcc/x86_64-unknown-linux-gnu/4.1.2
> /gm2/pim-coroutine/SYSTEM.def:19:1: error: unknown symbol
> 'INTEGER32' found
> /opt/gcc-4.1.2+gm2-1.0.4/lib/gcc/x86_64-unknown-linux-gnu/4.1.2
> /gm2/pim-coroutine/SYSTEM.def:19:1: error: unknown symbol
> 'CARDINAL16' found
> /opt/gcc-4.1.2+gm2-1.0.4/lib/gcc/x86_64-unknown-linux-gnu/4.1.2
> /gm2/pim-coroutine/SYSTEM.def:118:5: error: the following
> symbols are unknown at the end of module 'SYS' when requested
> by another modules import (symbols have not been exported by
> the appropriate definition module)
>
> Can someone shed some light onto this? I'm puzzled.
>
> Cheers,
> Johannes
Hi Johannes,
this should indeed be possible - it would be interesting to know if this
works with:
http://floppsie.comp.glam.ac.uk/download/c/gcc-4.1.2+gm2-20131007.tar.gz
which I think fixes the above bug (or at least there were corrections
with the SYSTEM.def sized types).
regards,
Gaius