![](/img/trans.png)
[英]The term 'import' is not recognized as the name of a cmdlet, function, script file, or operable program
[英]LLC Compiler is not recognized as the name of a cmdlet, function, script file, or operable program
我使用 python 創建自定義編程語言,PLY 作為詞法分析器和解析器,LLVMlite 作為低級中間語言來進行代碼生成。 我已經使用 Python pip 安裝了 PLY 和 LLC
我使用LLC創建一個object文件output.o和GCC創建最終的可執行文件如下。
$ llc -filetype=obj output.ll
$ gcc output.o -o output
當我執行llc -filetype=obj output.ll
我得到
llc : The term 'llc' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included,
verify that the path is correct and try again.
At line:1 char:1
+ llc -filetype=obj output.ll
+ CategoryInfo : ObjectNotFound: (llc:String) [], CommandNotFoundException
+ FullyQualifiedErrorId : CommandNotFoundException
我已經花了幾個小時在這上,但無法弄清楚。 怎么了?
PyPi package llc與 LLVM 的llc
工具無關。 您不能通過pip
安裝后者,因為它不是 Python package。 您需要安裝 LLVM 工具才能獲得它。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.