Page 1 of 1
[r3579] Clang fails to build ZDoom
Posted: Sun Apr 22, 2012 7:44 pm
by MP2E
Clang fails to build ZDoom due to dumb using a variable named "restrict" which is a reserved keyword, and failing on some inline ASM that GCC uses. This was fixed using the patch below and doesn't effect anything other than compilation with clang.
http://pastebin.com/pvCFxw0U
Re: [r3579] Clang fails to build ZDoom
Posted: Sun Apr 22, 2012 8:47 pm
by randi
So clang has progressed enough to be able to compile ZDoom now? That's pretty impressive.
Re: [r3579] Clang fails to build ZDoom
Posted: Sun Apr 22, 2012 10:20 pm
by MP2E
Yep! Works with stable release 3.0 and the 3.1 current svn branch. Not only does it work but it runs well

Haven't bench-marked it against the GCC build in my linux distribution yet but that's planned.
(By the way, I wrote the post/patch above I just hadn't logged in to the ZDoom forums for a while so I forgot my pass :X)
Re: [r3579] Clang fails to build ZDoom
Posted: Sun Apr 22, 2012 10:39 pm
by wildweasel
MP2E wrote:(By the way, I wrote the post/patch above I just hadn't logged in to the ZDoom forums for a while so I forgot my pass :X)
That little "issue" just got corrected, by the way - your post is now properly attributed to you.
Re: [r3579] Clang fails to build ZDoom
Posted: Tue Apr 24, 2012 5:12 am
by MP2E
Seems I somehow deleted a random line and it was included as part of my patch, creating an error with dumb. Gez found it and fixed it in r1365 of GZDoom, sorry about that.
(Also thanks for attributing the post to me)
EDIT: Also GZDoom builds perfectly now as well with clang