Tôi có cùng một vấn đề gây ra bởi gvim không thể tải python pyd dll. Có một số mẹo để giải quyết dll .pyd gây ra vấn đề trên. Tôi không chắc chắn là có bất kỳ cách nào để giải quyết Runtime Error cho tất cả các dll. Đề cập đến Not embed the correct manifest for the msvc runtimes on windows liên kết về cách giải quyết vấn đề của bạn.
Cập nhật: Thay vì cập nhật tệp kê khai cho tệp .pyd. Tôi đã cố gắng cập nhật tệp kê khai cho gvim trực tiếp bằng cách cập nhật tệp kê khai gvim ban đầu với một số thay đổi từ tệp kê khai python.exe.
# dump manifest from gvim.exe
>> mt.exe -inputresource:gvim.exe;#1 -out:gvim.manifest
# dump manifest from python.exe
# *I use python26 for gvim, default gvim come with python27
>> mt.exe -inputresource:c:\python26\python.exe;#1 -out:python.manifest
# manually edit gvim.manifest, just change the line with dependentAssembly with
# line from the python.manifest which will depend on VC90.CRT
# Then, update the edited manifest into gvim.exe
>> mt.exe -manifest gvim.manifest -outputresource:gvim.exe;1
Dưới đây là gvim.manifest tôi chỉnh sửa:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0" xmlns:asmv3="urn:schemas-microsoft-com:asm.v3">
<assemblyIdentity processorArchitecture="*" version="7.3.0.0" type="win32" name="Vim"></assemblyIdentity>
<description>Vi Improved - A Text Editor</description>
<dependency>
<dependentAssembly>
<assemblyIdentity type="win32" name="Microsoft.VC90.CRT" version="9.0.21022.8" processorArchitecture="x86" publicKeyToken="1fc8b3b9a1e18e3b"></assemblyIdentity>
</dependentAssembly>
</dependency>
<trustInfo xmlns="urn:schemas-microsoft-com:asm.v3">
<security>
<requestedPrivileges>
<requestedExecutionLevel level="asInvoker" uiAccess="false"></requestedExecutionLevel>
</requestedPrivileges>
</security>
</trustInfo>
<asmv3:application>
<asmv3:windowsSettings xmlns="http://schemas.microsoft.com/SMI/2005/WindowsSettings">
<dpiAware>true</dpiAware>
</asmv3:windowsSettings>
</asmv3:application>
</assembly>
Bạn là người đàn ông! Cảm ơn rất nhiều! –
+1 Thật lố bịch khi phải làm vậy, nhưng điều này đã khắc phục được vấn đề. – Hubro
Do môi trường của tôi, tôi đã có rất nhiều cuộc đấu tranh nhận được vim và python để chơi độc đáo với nhau. Sửa đổi tệp kê khai cho gvim như đã đề cập ở trên đã giải quyết được hoàn toàn vấn đề của tôi. Tôi sẽ không nghĩ về điều này. Cảm ơn! – Mark