Web lists-archives.com

Re: [Mingw-users] Problems creating linkable file from MSVC .lib

On 20/02/16 17:00, Robert Miles wrote:
> One underscore at the beginning of a name usually indicates something
> within a library that is meant to be called only from within that library

No, it does no such thing; one underscore is prefixed to the unadorned
symbol name, the source, when compiled to PE-COFF format, so it is
perfectly normal for all symbols in a library to have at least one
initial underscore; the case to which you refer would have two such
initial underscores, for each symbol name within a library.

The issue is further compounded by Microsoft's practice of prefixing a
single underscore, at source level, to library functions which are
intended for public consumption, just because the associated functions
are not specified by the ISO-C standard; (this kind of infringes the
ISO-C stipulation that such symbols are reserved for use by the system
implementation, in the global file scope).  Such symbols will appear in
the library with two initial underscores, and are very much intended to
be called by user code...

> unless you understand the internals of that library well enough to
> understand the usually undocumented restrictions on calling it.

...so this caveat really isn't applicable in the MS-Windows world.

> The name of that library suggests that it was compiled to run in 32-bit
> mode.  MinGW is usually used in 64-bit mode instead.

Utter rubbish!  MinGW is a 32-bit compiler, intended for the 32-bit
MS-Windows platform.  If you think it's for 64-bit, you aren't using
MinGW; (you may be using mingw-w64, but that's an entirely different
product, from a different project, and not supported here).


Public key available from keys.gnupg.net
Key fingerprint: C19E C018 1547 DE50 E1D4 8F53 C0AD 36C6 347E 5A3F

Attachment: signature.asc
Description: OpenPGP digital signature

Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
MinGW-users mailing list

This list observes the Etiquette found at 
We ask that you be polite and do the same.  Disregard for the list etiquette may cause your account to be moderated.

You may change your MinGW Account Options or unsubscribe at:
Also: mailto:mingw-users-request@xxxxxxxxxxxxxxxxxxxxx?subject=unsubscribe