Jump to content
Chiron

[ShowCase] Clang4Win

Recommended Posts

Hi folks, (I don't know the correct area to post this... Sorry)

  Today, i've finished an unusual and free way to compile the Emulator on Windows O.S. As all developers know , the microsoft doesn't care about C support (Stuck on C89...Since they have a broken support to C99 (1999) Standard in most recent versions of MVSC). With batch script (Challenge with weird syntax, but at least run in all windows editions) and one very small version of Clang (18MB in .rar format... can be even less if i remove some files :). No install process) arranged by me, i've developed one little script with clang calls which can generate the emulator binaries for windows platform. There's no need to stuck with giant microsoft IDE just for deploy to windows: K.I.S.S... I'm from another community and, unfortunately, the development is no longer active. I like to share things (i don't like this kind of divisions between communities) , so here we go:

(The messages below still in portuguese)

How to compile? Two clicks in .bat file and just wait :

screenshot_765.png

 

 

screenshot_771.png

 

 

screenshot_770.png



The source code error reports (The script stops if any error is found):

screenshot_767.png



PS: The script will erase all object files created by the process.


  The compilation process is very fast (Less than one minute in my dual core machine passing  -O2 (still faster even with -O3) -std=c99 -Wall -Wextra -pedantic... and many others) . I don't know if this would be useful for the Hercules Community. If people like the idea, then i'll release it for all in few days (clean that bizarre batch code and create an english version), but this will require some changes: Introducing the right static libraries for GNU Linker and few changes inside the libconfig source. I'm planning generate some binaries for the LLVM Interpreter in *near future* (Yes, JIT feat bitcode format) ..The overall performance will increase massively ;)

 

Comments and ideas are welcome :) (Sorry for the bad english)

Edited by Chiron

Share this post


Link to post
Share on other sites

Awesome,

its good for those who dont know how to install msvc or dont have msvc, and still can compile on windows easily with your tool.

hope you release it.

Share this post


Link to post
Share on other sites

Awesome,

its good for those who dont know how to install msvc or dont have msvc, and still can compile on windows easily with your tool.

hope you release it.

 

  Yes, that's right. Also, most members *only* download the MVS (with all dependencies, development libraries, extensions... Huge download) just to play with Hercules. This not seems right to me, because only few here are developers. Users want easy things.

Share this post


Link to post
Share on other sites

woahhhhh very nice work sir chiron! i hope it will have a own repo :)

 

Yes. Also, i'll put one GNU Debugger for Windows (Latest version) to track the possible issues (crashs and etc) . It's just pass the -g -O0 before compiling (To avoid "optimized out" effect) then,  open the prompt and pass the binary to debug ("Path to gdb" map-server.exe). There's no need to use dbghelp.dll extension.

Edited by Chiron

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.