Build setup for a C program

stephen mathieson's Avatar

stephen mathieson

26 Jun, 2014 01:46 PM

I'd like to setup a build for a C program I'm working on to ensure I don't break Windows support. Is C officially supported? If so, what compilers do I have access to?

  1. Support Staff 1 Posted by Feodor Fitsner on 26 Jun, 2014 02:44 PM

    Feodor Fitsner's Avatar

    There are Visual C++ 2010, 2012 and 2013 installed.

    - Feodor

  2. 2 Posted by stephen mathies... on 27 Jun, 2014 12:53 PM

    stephen mathieson's Avatar

    Can I get mingw32 or something similar?

  3. Support Staff 3 Posted by Feodor Fitsner on 27 Jun, 2014 05:51 PM

    Feodor Fitsner's Avatar

    Last time after installing mingw32 build worker VMs we're experiencing some weird performance degradation (lot of files?) - maybe it's unrelated. I will give it another try on test image - will let you know when it's ready.

    - Feodor

  4. 4 Posted by tony on 12 Jul, 2014 07:49 PM

    tony's Avatar

    You can manually install Cygwin and/or MinGW via Chocolatey during your builds, see http://chocolatey.org/packages/cyg-get or http://chocolatey.org/packages/mingw-get

    It should only add a minute or two to your build time.

    There are many distributions of MinGW (especially the w64 version), I think manually picking which one your project needs is a better option than installing something that can conflict with other projects' needs by default.

  5. Support Staff 5 Posted by Feodor Fitsner on 13 Jul, 2014 11:14 AM

    Feodor Fitsner's Avatar

    MinGW has been deployed to build worker images. Give it a try and let me know how it goes.

  6. 6 Posted by Jon Nordby on 18 Jul, 2014 02:37 PM

    Jon Nordby's Avatar

    Hi Feodor.
    Where is MinGW installed to in the worker images? Is there any documentation for using it available?

  7. Support Staff 7 Posted by Feodor Fitsner on 18 Jul, 2014 02:40 PM

    Feodor Fitsner's Avatar

    Hi Jon,

    It's c:\MinGW - default location. It was installed by MinGW installation manager.

  8. 8 Posted by Jon Nordby on 18 Jul, 2014 04:30 PM

    Jon Nordby's Avatar

    Thanks a lot for quick respose Feodor! I have my first passing builds on Windows now :)

  9. Support Staff 9 Posted by Feodor Fitsner on 18 Jul, 2014 05:24 PM

    Feodor Fitsner's Avatar

    Congrats! :)

  10. 10 Posted by Nathanael Jones on 18 Sep, 2014 04:07 PM

    Nathanael Jones's Avatar

    Can we get some more details on what version of MinGW is provided? I.e, bitness (x86 or x64) and exception handling mode(seh, dwarf, or sjlj).

    From what I understand, SEH variants may not support dual-target (producing both 32 and 64-bit output)
    http://stackoverflow.com/questions/16304804/dual-target-mingw-w64-i...

  11. Support Staff 11 Posted by Feodor Fitsner on 18 Sep, 2014 04:22 PM

    Feodor Fitsner's Avatar

    This is some info:

    MINGWBASEDIR=C:\MinGW
    gcc version 4.8.1 (GCC)
    gcc version 4.8.1 (GCC)
    GNU gdb (GDB) 7.6.1
    GNU ld (GNU Binutils) 2.24
    GNU windres (GNU Binutils) 2.24
    GNU dlltool (GNU Binutils) 2.24
    GNU Make 3.82.90
    #define __MINGW32_VERSION 3.20 #define __W32API_VERSION 3.17

  12. 12 Posted by tony on 18 Sep, 2014 04:41 PM

    tony's Avatar

    Is it the conventional MinGW.org version? If so, then it's strictly 32-bit only. The MinGW-w64 compilers are preferred by most MinGW users lately because there are both 32 and 64 bit versions available. There are a variety of builds available however, which differ in 32 vs 64 bit, exception handling (either SJLJ or Dwarf for 32 bit, either SJLJ or SEH for 64 bit), and thread model (Win32 or Posix). Each choice has tradeoffs and different applications have different specific needs. Usually 32 and 64 bit builds are performed with a different set of compiler binaries, switching between them by modifying /etc/fstab or mounts in MSYS, or using different startup batch files with MSYS2.

  13. 13 Posted by Nathanael Jones on 06 Oct, 2014 06:33 PM

    Nathanael Jones's Avatar

    Our solution was to zip up both versions of MinGW and put them in azure blob storage. Chocolatey version wasn't any good.

    https://github.com/imazen/gd-libgd/blob/b6b02499f6ccee930fd6247f185...

    We then had to split the build into 2 versions, as there wasn't enough time to do everything for both architectures in the allotted time.

    We also used AppVeyor's nuget support so all dependencies don't have to be built at the same time, instead, they're reused. https://github.com/imazen/libpng/blob/master/appveyor.yml

  14. Ilya Finkelshteyn closed this discussion on 25 Aug, 2018 01:48 AM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac