![](/img/trans.png)
[英]ImportError: DLL load failed: The specified procedure could not be found. Python
[英]Installing mapnik on Windows XP fails with the message “ImportError: DLL load failed: The specified procedure could not be found.”
我正在嘗試在Windows XP上安裝mapnik。
在努力遵循其網站( http://trac.mapnik.org/wiki/WindowsInstallation )上的說明后,它失敗並顯示以下消息:
File "<stdin>", line 1, in <module>
File "C:\mapnik-0.7.1\python\2.6\site-packages\mapnik\__init__.py", line 43, in <module> from _mapnik import *
ImportError: DLL load failed: The specified procedure could not be found.
我也嘗試了OSGEO4W安裝程序,這不再成功,但在顯示相同的錯誤消息之前還會產生一個彈出窗口:
"The procedure entry point xmlCtxtReadMemory could not be located in the dynamic link library libxml2.dll."
故障排除建議強調了幾個可能缺失的dll。 我安裝了這兩個但未能解決問題。
Dependency Walker確定了另外三個缺失的dll,我也安裝了它,但仍然沒有解決問題。
任何建議非常感謝!
這是一個很老的線索。 然而,我遇到了同樣的問題,並且能夠通過我在網絡上找到的不同提示來解決它。
之后我能夠執行命令“import mapnik”而沒有任何問題。 我還能夠執行這里所述的python演示,編號為5: https : //gist.github.com/springmeyer/5651701
所以我想我有兩個問題。 首先,我在某種程度上錯過了libxml2.dll文件,其次是因為我把mapnik條目放在最后的PATH變量中,因為我的系統上有許多相同的dll,所以python不知何故錯了。
希望我能在這里提供缺少的解決方案。
我遇到了同樣的問題(在Windows Server 2012 R2上)。 我在谷歌搜索了很多,我嘗試了所有上述答案。 順便說一下今天mapnik通過鏈接靜態地址來修復libxml2.dll。
最后我的問題是在PATH變量的第一個和最后一個mapnik路徑(“C:\\ mapnik-v2.2.0 \\ lib”)中使用雙引號!
你不應該在系統環境變量中使用雙引號。
我將“C:\\ mapnik-v2.2.0 \\ lib”改為C:\\ mapnik-v2.2.0 \\ lib,一切正常。 ;)
嘗試為windows安裝libxml / libxml2。 似乎您可能會遺漏,因為依賴或您的libxml2.dll可能已過期。 zlatkovic.com是libxml的windows二進制文件的地方:
下載地址: ftp : //ftp.zlatkovic.com/libxml/
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.