dumpbin un-undecorate [英] dumpbin un-undecorate

查看:93
本文介绍了dumpbin un-undecorate的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

根据dumpbin,我的外部C表示__stdcall''函数不是

装饰......根据取决于它们没有装饰......根据

文档,(以及之前发布的vc ++),它们应该是...


这是预期的吗?


我知道externC应该意味着没有名字装饰,但它之前从未出现过

案件。


谢谢

解决方案
>根据dumpbin,我的外部C和__stdcall''函数不是

装饰......根据取决于它们没有装饰......根据
文档,(以及vc ++的早期版本),它们应该是...

这是预期的吗?

我知道externC应该暗示没有名字装饰,但它从来都不是以前的情况。




是的,这是预期的。

如果你阅读了MSDN文档,对于externC,你可以阅读它。并且,你会发现它将明确地创建无瑕疵的名字。
http://msdn2.microsoft.com/en-us/library/wf2w9f6x.aspx


extern" ; C"我总是这样做,所以如果它不适合你,那可能是另一个问题。


-
< br $>
亲切的问候,

Bruno van Dooren
br ********************** @ hotmail.com

仅删除_nos_pam


" Bruno van Dooren"写道:

是的,这是预期的。
如果您阅读MSDN文档,对于externC而且,你会发现它将明确地创建无瑕疵的名字。
http://msdn2.microsoft.com/en-us/library/wf2w9f6x.aspx

externC我总是这样做,所以如果它不适合你,那可能还有另外一个问题。




你能帮我调试吗请:


C:\work\dll> cat dll.cpp

extern" C" __declspec(dllexport)int __stdcall fndll(void);


//这是导出函数的一个示例。

externC __declspec(dllexport)int __stdcall fndll(void)

{

返回42;

}


C:\work\dll> cl / LD dll.cpp

Microsoft(R)32位C / C ++优化编译器版本13.10.3077 for 80x86

版权所有(C)Microsoft Corporation 1984-2002。保留所有权利。


dll.cpp

Microsoft(R)增量链接器版本7.10.3077

版权所有(C)Microsoft公司。保留所有权利。


/out:dll.dll

/ dll

/implib:dll.lib

dll.obj

创建库dll.lib和对象dll.exp

C:\work\dll> dumpbin / exports dll .dll

Microsoft(R)COFF / PE Dumper版本7.10.3077

版权所有(C)Microsoft Corporation。保留所有权利。

转储文件dll.dll


文件类型:DLL


部分包含以下内容出口dll.dll


00000000特征

448F1D09时间日期戳Tue Jun 13 13:16:09 2006

0.00版本

1序数基础

1个功能数量

1个名称数量


序数提示RVA姓名


1 0 00001000 _fndll @ 0


[snipped]


" ; Bruno van Dooren写道:

externC我总是这样做,所以如果它不适合你,那可能还有另一个问题。




为了完整性(vs 2k5):


C:\ TEMP> cl / LD dll.cpp

Microsoft(R)C / C ++优化编译器版本14.00.50727.42 for x64

版权所有(C)Microsoft Corporation。保留所有权利。


dll.cpp

Microsoft(R)增量链接器版本8.00.50727.42

版权所有(C)Microsoft公司。保留所有权利。


/out:dll.dll

/ dll

/implib:dll.lib

dll.obj

创建库dll.lib和对象dll.exp

C:\ TEMP> dumpbin / exports dll.dll

Microsoft(R)COFF / PE Dumper版本8.00.50727.42

版权所有(C)Microsoft Corporation。保留所有权利。

转储文件dll.dll


文件类型:DLL


部分包含以下内容出口dll.dll


00000000特征

448F1DD6时间戳印章Tue Jun 13 13:19:34 2006

0.00版本

1序数基础

1个功能数量

1个名称数量


序数提示RVA姓名


1 0 00001000 fndll


[snipped]


According to dumpbin, my extern "C" __stdcall''ed functions are not
decorated... According to depends they are not decorated... According to the
documentation, (and previous releases of vc++), they should be...

Is this expected?

I know extern "C" should imply no name decorating but its never been the
case before.

Thanks

解决方案

> According to dumpbin, my extern "C" __stdcall''ed functions are not

decorated... According to depends they are not decorated... According to
the
documentation, (and previous releases of vc++), they should be...

Is this expected?

I know extern "C" should imply no name decorating but its never been the
case before.



Yes, this is to be expected.
If you read the MSDN docs, for extern "C" and, you''ll find that it will
explicitly create unmangled names.
http://msdn2.microsoft.com/en-us/library/wf2w9f6x.aspx

extern "C" has always done this for me, so if it didn''t for you, there was
probably another problem.

--

Kind regards,
Bruno van Dooren
br**********************@hotmail.com
Remove only "_nos_pam"


"Bruno van Dooren" wrote:

Yes, this is to be expected.
If you read the MSDN docs, for extern "C" and, you''ll find that it will
explicitly create unmangled names.
http://msdn2.microsoft.com/en-us/library/wf2w9f6x.aspx

extern "C" has always done this for me, so if it didn''t for you, there was
probably another problem.



Can you help me debug this then please:

C:\work\dll>cat dll.cpp
extern "C" __declspec(dllexport) int __stdcall fndll(void);

// This is an example of an exported function.
extern "C" __declspec(dllexport) int __stdcall fndll(void)
{
return 42;
}

C:\work\dll>cl /LD dll.cpp
Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 13.10.3077 for 80x86
Copyright (C) Microsoft Corporation 1984-2002. All rights reserved.

dll.cpp
Microsoft (R) Incremental Linker Version 7.10.3077
Copyright (C) Microsoft Corporation. All rights reserved.

/out:dll.dll
/dll
/implib:dll.lib
dll.obj
Creating library dll.lib and object dll.exp

C:\work\dll>dumpbin /exports dll.dll
Microsoft (R) COFF/PE Dumper Version 7.10.3077
Copyright (C) Microsoft Corporation. All rights reserved.
Dump of file dll.dll

File Type: DLL

Section contains the following exports for dll.dll

00000000 characteristics
448F1D09 time date stamp Tue Jun 13 13:16:09 2006
0.00 version
1 ordinal base
1 number of functions
1 number of names

ordinal hint RVA name

1 0 00001000 _fndll@0

[snipped]


"Bruno van Dooren" wrote:

extern "C" has always done this for me, so if it didn''t for you, there was
probably another problem.



For completeness (vs 2k5):

C:\TEMP>cl /LD dll.cpp
Microsoft (R) C/C++ Optimizing Compiler Version 14.00.50727.42 for x64
Copyright (C) Microsoft Corporation. All rights reserved.

dll.cpp
Microsoft (R) Incremental Linker Version 8.00.50727.42
Copyright (C) Microsoft Corporation. All rights reserved.

/out:dll.dll
/dll
/implib:dll.lib
dll.obj
Creating library dll.lib and object dll.exp

C:\TEMP>dumpbin /exports dll.dll
Microsoft (R) COFF/PE Dumper Version 8.00.50727.42
Copyright (C) Microsoft Corporation. All rights reserved.
Dump of file dll.dll

File Type: DLL

Section contains the following exports for dll.dll

00000000 characteristics
448F1DD6 time date stamp Tue Jun 13 13:19:34 2006
0.00 version
1 ordinal base
1 number of functions
1 number of names

ordinal hint RVA name

1 0 00001000 fndll

[snipped]


这篇关于dumpbin un-undecorate的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆