Discussion:
[m-dev.] Errors compiling Mercury ROTD using Cygwin
Martin McDonough
2015-11-19 20:30:00 UTC
Permalink
I've run into an error compiling Mercury (most recent ROTD) using Cygwin
(64-bit) on Windows 7 64-bit.


https://gist.github.com/FlyingJester/66643007fb8f6d46b00a

The main error seems to be when linking:
top_level_init.o:top_level_init.c:(.rdata$.refptr._bss_start__[.refptr._bss_start__]+0x0):
undefined reference to `_bss_start__'
top_level_init.o:top_level_init.c:(.rdata$.refptr._data_start__[.refptr._data_start__]+0x0):
undefined reference to `_data_start__'
top_level_init.o:top_level_init.c:(.rdata$.refptr._bss_end__[.refptr._bss_end__]+0x0):
undefined reference to `_bss_end__'
top_level_init.o:top_level_init.c:(.rdata$.refptr._data_end__[.refptr._data_end__]+0x0):
undefined reference to `_data_end__'



A quick web search suggests this may mean a bad/mismatched linker script,
although I have no idea if that is applicable here.

Any help would be greatly appreciated!
Mark Brown
2015-11-19 21:53:43 UTC
Permalink
Hi Martin,

On Fri, Nov 20, 2015 at 7:30 AM, Martin McDonough
Post by Martin McDonough
I've run into an error compiling Mercury (most recent ROTD) using Cygwin
(64-bit) on Windows 7 64-bit.
https://gist.github.com/FlyingJester/66643007fb8f6d46b00a
undefined reference to `_bss_start__'
undefined reference to `_data_start__'
undefined reference to `_bss_end__'
undefined reference to `_data_end__'
A quick web search suggests this may mean a bad/mismatched linker script,
although I have no idea if that is applicable here.
Any help would be greatly appreciated!
Running './configure' is not portable; you need to run 'sh configure'.
That makes a difference on Cygwin.

See README.Cygwin and the INSTALL file.

Mark.
Martin McDonough
2015-11-19 22:34:44 UTC
Permalink
I get the same result using `sh configure` instead.
Post by Mark Brown
Hi Martin,
On Fri, Nov 20, 2015 at 7:30 AM, Martin McDonough
Post by Martin McDonough
I've run into an error compiling Mercury (most recent ROTD) using Cygwin
(64-bit) on Windows 7 64-bit.
https://gist.github.com/FlyingJester/66643007fb8f6d46b00a
undefined reference to `_bss_start__'
undefined reference to `_data_start__'
undefined reference to `_bss_end__'
undefined reference to `_data_end__'
A quick web search suggests this may mean a bad/mismatched linker script,
although I have no idea if that is applicable here.
Any help would be greatly appreciated!
Running './configure' is not portable; you need to run 'sh configure'.
That makes a difference on Cygwin.
See README.Cygwin and the INSTALL file.
Mark.
Julien Fischer
2015-12-09 05:06:58 UTC
Permalink
Hi all,
I've run into an error compiling Mercury (most recent ROTD) using Cygwin (64-bit) on Windows 7 64-bit.
https://gist.github.com/FlyingJester/66643007fb8f6d46b00a
top_level_init.o:top_level_init.c:(.rdata$.refptr._bss_start__[.refptr._bss_start__]+0x0): undefined reference to `_bss_start__'
top_level_init.o:top_level_init.c:(.rdata$.refptr._data_start__[.refptr._data_start__]+0x0): undefined reference to `_data_start__'
top_level_init.o:top_level_init.c:(.rdata$.refptr._bss_end__[.refptr._bss_end__]+0x0): undefined reference to `_bss_end__'
top_level_init.o:top_level_init.c:(.rdata$.refptr._data_end__[.refptr._data_end__]+0x0): undefined reference to `_data_end__'
A similar issue appears to be occurring with the MinGW64 GCC 4.9. I've
added an entry to the bug database for this one
(https://www.mercurylang.org/bugs/view.php?id=398).

Further updates will be posted there.

Julien.

Loading...