本文介绍了在Linux中有STDCALL吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我尝试将Windows应用程式移至Linux。此应用程序使用 __ stdcall 属性标记一些函数。然而,我被一个朋友告诉stdcall只使用在windows和没有意义在linux(但DOES存在于Windows GCC)。
我试图搜索Google,并得到一些结果,在Linux中有stdacll。



因此...

$此外,对于GCC,我看到2个实现: __属性__((__ stdcall __)) __属性__ stdcall))(在stdcall附近没有下划线)。
首选哪一个(如果适用于Linux?)



谢谢!

解决方案

最简单的解决方案是在Linux上将__stdcall定义为无条件。


I'm trying to port a Windows app to Linux. This appplication marks some functions with the __stdcall attribute. However, i was told by a friend that stdcall is used only on windows and has no meaning in linux (but DOES exist in Windows GCC).I tried to search Google about that, and got some results state that there IS stdacll in Linux.

So... ??

Besides, for GCC I saw 2 implementations for that: __attribute__((__stdcall__)) and __attribute__((stdcall)) (without the underscores near stdcall).Which one is preferred (If applied to Linux at all)?

Thanks!

解决方案

The simplest solution is to just define __stdcall to nothing conditionally on Linux.

这篇关于在Linux中有STDCALL吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-05 09:41
查看更多