Warning: file_get_contents(/data/phpspider/zhask/data//catemap/6/eclipse/9.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
C 在windows上重新编译SWT DLL_C_Eclipse_Windows_Dll_Swt - Fatal编程技术网

C 在windows上重新编译SWT DLL

C 在windows上重新编译SWT DLL,c,eclipse,windows,dll,swt,C,Eclipse,Windows,Dll,Swt,我有一个基于eclipse的富客户端应用程序,在某些情况下会崩溃。获取JVM转储时,显示的错误是对swt dll的0xC0000005(无效访问) Current thread (0x02b58400): JavaThread "main" [_thread_in_native, id=5032, stack(0x00090000,0x00190000)] siginfo: ExceptionCode=0xc0000005, reading address 0xfeeefef6 [...]

我有一个基于eclipse的富客户端应用程序,在某些情况下会崩溃。获取JVM转储时,显示的错误是对swt dll的0xC0000005(无效访问)

Current thread (0x02b58400):  JavaThread "main" [_thread_in_native, id=5032, stack(0x00090000,0x00190000)]
siginfo: ExceptionCode=0xc0000005, reading address 0xfeeefef6
[...]

Stack: [0x00090000,0x00190000],  sp=0x0018dd78,  free space=1015k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native  code)
C  [swt-win32-3659.dll+0x1131f]  Java_org_eclipse_swt_internal_win32_OS_VtblCall__II+0xb
J  org.eclipse.swt.internal.ole.win32.IUnknown.Release()I
j  org.eclipse.swt.ole.win32.OleControlSite.releaseObjectInterfaces()V+9
j  org.eclipse.swt.ole.win32.OleClientSite.onDispose(Lorg/eclipse/swt/widgets/Event;)V+83
我无法理解为什么会崩溃,所以我从org.eclipse.SWT.win32.win32.x86.source_3.6.3.v3659f插件获得了SWT dll的源代码,并尝试构建它

当我尝试启动构建时,会出现此错误

Microsoft(R)程序维护实用程序版本7.10.3077 版权所有(C)微软公司。版权所有

cl -O1 -DNDEBUG -c -DCRTAPI1=_cdecl -DCRTAPI2=_cdecl -nologo -D_X86_=1-DWIN32 -D_WIN32 -W3 -D_WINNT -D_WIN32_WINNT=0x0500-D_WIN32_IE=0x0500 -DWINVER=0x0500  -D_MT -MTd   -DSWT_VERSION=3659  -DUSE_ASSEMBLER  /I"S:\swt-builddir\ibm-java2-sdk-50-win-i386\include" /I"S:\swt-builddir\ibm-java2-sdk-50-win-i386\include\win32" /I"C:\Program Files (x86)\Microsoft Visual Studio .NET 2003\Vc7\PlatformSDK\Include" /I. os.c
    os.c
c:\temp\secnew\SWT_3659\os_structs.h(100) : error C2143: syntax error : missing    '{' before '*'
c:\temp\secnew\SWT_3659\os_structs.h(100) : error C2143: syntax error : missing    ')' before '*'
c:\temp\secnew\SWT_3659\os_structs.h(100) : error C2081: 'BUTTON_IMAGELIST' : name in formal parameter list illegal
我使用VS和JRE的正确路径更改了build.bat,但没有任何效果。我错过了什么


谢谢

我下载了一个类似的版本
org.eclipse.swt.win32.win32.x86.source_3.6.1.v3655c.jar.zip
,我可以使用VS2010编译64位(一些tweeks)。我注意到您正在使用(古代)VS2003。但是,在编译将加载到应用程序中的dll时,应谨慎使用,因为它们应使用相同的C(VC)运行时。如果他们不这样做,程序可能会在某些情况下崩溃(可能也是你的情况)。在
JAVA\u主页中查找
jvm.dll
,并将其加载。在左边的树视图中,查找
MSVCR*.DLL
,然后发布结果。我使用的是JRE 1.7.0.25(oracle标准),没有找到jvm.DLL,而是找到依赖于MSVCRT100.DLL的java.DLL,然后我检查了swt.win32.3659.DLL的依赖关系,它只依赖于MSVC.DLL。我不记得这种差异是与不同的运行时有关,还是与所需的MSVCRT的不同版本有关。目前我怀疑在使用SWT 3659和jre 1.7时存在一些问题,您的看法如何?谢谢