GDC in Slackware and a bit about GDC development

Iain Buclaw ibuclaw at gdcproject.org
Sun Sep 24 09:27:42 UTC 2017


On 23 September 2017 at 22:55, Eugene Wissner via
Digitalmars-d-announce <digitalmars-d-announce at puremagic.com> wrote:
> On Saturday, 23 September 2017 at 20:34:51 UTC, Iain Buclaw wrote:
>>
>> On 23 September 2017 at 21:45, Eugene Wissner via Digitalmars-d-announce
>> <digitalmars-d-announce at puremagic.com> wrote:
>>>
>>> GDC looks pretty nice. I had only one problem: I got a linking error if I
>>> use core.stdc.stdarg; not sure if it is my failure or a bug. But I could
>>> build my library and run tests. Pretty nice.
>>>
>>
>> What's the linker error?
>
>
> Here is the code, test.d:
>
> import core.stdc.stdarg;
>
> void format(char[] buf, ...)
> {
>     va_list va;
>     va_start(va, buf);
>     va_end(va);
>  }
>
> void main()
> {
> }
>
>
> $ gdc test.d
> /tmp/ccwm5f8o.o: In function `_D4test6formatFAaYv':
> test.d:(.text+0x114): undefined reference to
> `_D4core4stdc6stdarg6va_endFNbPS4core4stdc6stdarg13__va_list_tagZv'
> collect2: ld returned 1 exit status
>
>

That would almost certainly only happen if you were using a different
druntime.  Check where your import modules are coming from, they
probably aren't gdc's.


>> Looks good.  A simpler GCC frontend would be
>> https://github.com/giuseppe/gccbrainfuck
>>
> But without the great explanations :)

True, it's more a skeleton front-end, which shows you only the most
important files and hooks to be aware of in order to get started.


More information about the Digitalmars-d-announce mailing list