[mingw]_[primary]_[64 bit windres how to compile a 32-bit link file]

Source: Internet
Author: User


Scene:

1. MinGW (TDM) 64-bit gcc,4.8.1,64 bits are very friendly to compiling 64-bit programs, but additional work is required for compiling 32-bit programs.

2. For example, with Windres compile manifest,64 bit environment default is not, with configure or makefile even if added-m32 will not automatically set the Windres to compile 32-bit.

Here you need to add some parameters to configure or make.


./configure rcflags= "--output-format=coff--target=pe-i386" .....

Make rcflags= "--output-format=coff--target=pe-i386" ...

Original address:

Http://stackoverflow.com/questions/18805155/tdm-gcc-w64-script-to-change-windres-for-32bit

To see all possble windres parameters, you can request help:    x86_64-w64-mingw32-windres.exe--helpfor Windows-A-bit F Ormat need COFF format with pe-i386 target. Basically add-f pe-i386 (or--target=pe-i386) after-o COFF flag to your command line if you generate it man Ually. In GNU Autotools It's about the rcflags. So if there ' s some configure script, just add    ./configure rcflags= "--output-format=coff--target=pe-i386" .....

Note: By the way, 4.8.1 's 64-bit GDB 32-bit program compiled by debug crashes.

[mingw]_[primary]_[64 bit windres how to compile a 32-bit link file]

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.