无法使用最新的keil MDK版本(V5.37)进行构建

fen*_*usi 2 c arm keil

all: 我将我的keil MDK版本更新到最新的V5.37,然后我发现该项目无法再构建了。由于V5.37不支持编译器5并设置默认编译器为编译器6,所以我用独立补丁安装了编译器5(Arm编译器版本5,V5.06 update7),然后将编译器5添加到keil中,设置编译器5为默认编译器,但是keil无法编译工程,编译输出如下:

*** Using Compiler 'V5.06 update 7 (build 960)', folder: 'C:\_AnZhuang\keil\Keil\ARMCCv506u7\Bin'
Build target 'LED'
assembling startup_stm32f40_41xxx.s...
startup_stm32f40_41xxx.s: Error: A9511E: Unable to determine the current toolkit. Check that ARM_TOOL_VARIANT is set correctly.
startup_stm32f40_41xxx.s: Check that your license details are correct in the License Management dialog of MDK. Additional information is available at:
startup_stm32f40_41xxx.s:  - ARMLMD_LICENSE_FILE: unset
startup_stm32f40_41xxx.s:  - LM_LICENSE_FILE: unset
startup_stm32f40_41xxx.s:  - ARM_TOOL_VARIANT: unset
startup_stm32f40_41xxx.s:  - ARM_PRODUCT_PATH: unset
startup_stm32f40_41xxx.s:  - Product location: product not found
startup_stm32f40_41xxx.s:  - Toolchain location: C:\_AnZhuang\keil\Keil\ARMCCv506u7\Bin
startup_stm32f40_41xxx.s:  - Selected tool variant: mdk_lite
startup_stm32f40_41xxx.s: Product: unknown
startup_stm32f40_41xxx.s: Component: ARM Compiler 5.06 update 7 (build 960)
startup_stm32f40_41xxx.s: Tool: ArmAsm [4d35fa]
compiling delay.c...
Error: C9511E: Unable to determine the current toolkit. Check that ARM_TOOL_VARIANT is set correctly.
Check that your license details are correct in the License Management dialog of MDK. Additional information is available at:
 - ARMLMD_LICENSE_FILE: unset
 - LM_LICENSE_FILE: unset
 - ARM_TOOL_VARIANT: unset
 - ARM_PRODUCT_PATH: unset
 - Product location: product not found
 - Toolchain location: C:\_AnZhuang\keil\Keil\ARMCCv506u7\Bin
 - Selected tool variant: mdk_lite
Product: unknown
Component: ARM Compiler 5.06 update 7 (build 960)
Tool: ArmCC [4d365d]
compiling main.c...
Error: C9511E: Unable to determine the current toolkit. Check that ARM_TOOL_VARIANT is set correctly.
Check that your license details are correct in the License Management dialog of MDK. Additional information is available at:
 - ARMLMD_LICENSE_FILE: unset
 - LM_LICENSE_FILE: unset
 - ARM_TOOL_VARIANT: unset
 - ARM_PRODUCT_PATH: unset
 - Product location: product not found
 - Toolchain location: C:\_AnZhuang\keil\Keil\ARMCCv506u7\Bin
 - Selected tool variant: mdk_lite
Product: unknown
Component: ARM Compiler 5.06 update 7 (build 960)
Tool: ArmCC [4d365d]
compiling stm32f4xx_syscfg.c...
Error: C9511E: Unable to determine the current toolkit. Check that ARM_TOOL_VARIANT is set correctly.
Check that your license details are correct in the License Management dialog of MDK. Additional information is available at:
 - ARMLMD_LICENSE_FILE: unset
 - LM_LICENSE_FILE: unset
 - ARM_TOOL_VARIANT: unset
 - ARM_PRODUCT_PATH: unset
 - Product location: product not found
 - Toolchain location: C:\_AnZhuang\keil\Keil\ARMCCv506u7\Bin
 - Selected tool variant: mdk_lite
Product: unknown
Component: ARM Compiler 5.06 update 7 (build 960)
Tool: ArmCC [4d365d]
compiling usart.c...
Error: C9511E: Unable to determine the current toolkit. Check that ARM_TOOL_VARIANT is set correctly.
Check that your license details are correct in the License Management dialog of MDK. Additional information is available at:
 - ARMLMD_LICENSE_FILE: unset
 - LM_LICENSE_FILE: unset
 - ARM_TOOL_VARIANT: unset
 - ARM_PRODUCT_PATH: unset
 - Product location: product not found
 - Toolchain location: C:\_AnZhuang\keil\Keil\ARMCCv506u7\Bin
 - Selected tool variant: mdk_lite
Product: unknown
Component: ARM Compiler 5.06 update 7 (build 960)
Tool: ArmCC [4d365d]
compiling sys.c...
Error: C9511E: Unable to determine the current toolkit. Check that ARM_TOOL_VARIANT is set correctly.
Check that your license details are correct in the License Management dialog of MDK. Additional information is available at:
 - ARMLMD_LICENSE_FILE: unset
 - LM_LICENSE_FILE: unset
 - ARM_TOOL_VARIANT: unset
 - ARM_PRODUCT_PATH: unset
 - Product location: product not found
 - Toolchain location: C:\_AnZhuang\keil\Keil\ARMCCv506u7\Bin
 - Selected tool variant: mdk_lite
Product: unknown
Component: ARM Compiler 5.06 update 7 (build 960)
Tool: ArmCC [4d365d]
compiling stm32f4xx_rcc.c...
Error: C9511E: Unable to determine the current toolkit. Check that ARM_TOOL_VARIANT is set correctly.
Check that your license details are correct in the License Management dialog of MDK. Additional information is available at:
 - ARMLMD_LICENSE_FILE: unset
 - LM_LICENSE_FILE: unset
 - ARM_TOOL_VARIANT: unset
 - ARM_PRODUCT_PATH: unset
 - Product location: product not found
 - Toolchain location: C:\_AnZhuang\keil\Keil\ARMCCv506u7\Bin
 - Selected tool variant: mdk_lite
Product: unknown
Component: ARM Compiler 5.06 update 7 (build 960)
Tool: ArmCC [4d365d]
compiling stm32f4xx_usart.c...
Error: C9511E: Unable to determine the current toolkit. Check that ARM_TOOL_VARIANT is set correctly.
Check that your license details are correct in the License Management dialog of MDK. Additional information is available at:
 - ARMLMD_LICENSE_FILE: unset
 - LM_LICENSE_FILE: unset
 - ARM_TOOL_VARIANT: unset
 - ARM_PRODUCT_PATH: unset
 - Product location: product not found
 - Toolchain location: C:\_AnZhuang\keil\Keil\ARMCCv506u7\Bin
 - Selected tool variant: mdk_lite
Product: unknown
Component: ARM Compiler 5.06 update 7 (build 960)
Tool: ArmCC [4d365d]
compiling led.c...
Error: C9511E: Unable to determine the current toolkit. Check that ARM_TOOL_VARIANT is set correctly.
Check that your license details are correct in the License Management dialog of MDK. Additional information is available at:
 - ARMLMD_LICENSE_FILE: unset
 - LM_LICENSE_FILE: unset
 - ARM_TOOL_VARIANT: unset
 - ARM_PRODUCT_PATH: unset
 - Product location: product not found
 - Toolchain location: C:\_AnZhuang\keil\Keil\ARMCCv506u7\Bin
 - Selected tool variant: mdk_lite
Product: unknown
Component: ARM Compiler 5.06 update 7 (build 960)
Tool: ArmCC [4d365d]
compiling misc.c...
Error: C9511E: Unable to determine the current toolkit. Check that ARM_TOOL_VARIANT is set correctly.
Check that your license details are correct in the License Management dialog of MDK. Additional information is available at:
 - ARMLMD_LICENSE_FILE: unset
 - LM_LICENSE_FILE: unset
 - ARM_TOOL_VARIANT: unset
 - ARM_PRODUCT_PATH: unset
 - Product location: product not found
 - Toolchain location: C:\_AnZhuang\keil\Keil\ARMCCv506u7\Bin
 - Selected tool variant: mdk_lite
Product: unknown
Component: ARM Compiler 5.06 update 7 (build 960)
Tool: ArmCC [4d365d]
compiling system_stm32f4xx.c...
Error: C9511E: Unable to determine the current toolkit. Check that ARM_TOOL_VARIANT is set correctly.
Check that your license details are correct in the License Management dialog of MDK. Additional information is available at:
 If you need further help, provide this complete error report to your supplier
 - ARMLMD_LICENSE_FILE: unset
 - LM_LICENSE_FILE: unset
 - ARM_TOOL_VARIANT: unset
 - ARM_PRODUCT_PATH: unset
 - Product location: product not found
 - Toolchain location: C:\_AnZhuang\keil\Keil\ARMCCv506u7\Bin
 - Selected tool variant: mdk_lite
Product: unknown
Component: ARM Compiler 5.06 update 7 (build 960)
Tool: ArmCC [4d365d]
compiling stm32f4xx_gpio.c...
Error: C9511E: Unable to determine the current toolkit. Check that ARM_TOOL_VARIANT is set correctly.
Check that your license details are correct in the License Management dialog of MDK. Additional information is available at:
 If you need further help, provide this complete error report to your supplier
 - ARMLMD_LICENSE_FILE: unset
 - LM_LICENSE_FILE: unset
 - ARM_TOOL_VARIANT: unset
 - ARM_PRODUCT_PATH: unset
 - Product location: product not found
 - Toolchain location: C:\_AnZhuang\keil\Keil\ARMCCv506u7\Bin
 - Selected tool variant: mdk_lite
Product: unknown
Component: ARM Compiler 5.06 update 7 (build 960)
Tool: ArmCC [4d365d]
compiling stm32f4xx_it.c...
Error: C9511E: Unable to determine the current toolkit. Check that ARM_TOOL_VARIANT is set correctly.
Check that your license details are correct in the License Management dialog of MDK. Additional information is available at:
 If you need further help, provide this complete error report to your supplier
 - ARMLMD_LICENSE_FILE: unset
 - LM_LICENSE_FILE: unset
 - ARM_TOOL_VARIANT: unset
 - ARM_PRODUCT_PATH: unset
 - Product location: product not found
 - Toolchain location: C:\_AnZhuang\keil\Keil\ARMCCv506u7\Bin
 - Selected tool variant: mdk_lite
Product: unknown
Component: ARM Compiler 5.06 update 7 (build 960)
Tool: ArmCC [4d365d]
"..\OBJ\LED.axf" - 13 Error(s), 0 Warning(s).
Target not created.
Build Time Elapsed:  00:00:01
Run Code Online (Sandbox Code Playgroud)

从构建输出来看,这意味着 keil 许可证不正确。但是我尝试了由注册机生成的每种类型的许可证代码,但所有这些许可证都失败了。

所以,有人有和我一样的问题吗?以及有什么解决方案或建议可以尝试吗?非常感谢。

小智 6

我遇到了同样的问题,尝试在环境变量中定义路径,将其安装在不同的目录中,...;他们都没有工作。

最终,在他们自己的文档中遇到了这个页面: https://developer.arm.com/documentation/ka005073/1-0/?lang =en

尝试将ARM编译器V5安装在这个路径:【Keil安装路径】\ARM\ARM_Compiler_5.06u7

对我来说是:C:\Keil_v5\ARM\ARM_Compiler_5.06u7

然后将路径添加到Keil的ArmCC Path中,如下所示: Keil ArmCC Path: add compiler