我們要爲arm芯片搭配帶arm工具鏈的鈷。用新配置構建樹莓(Pi2)
首先,我們引用此鏈接「How to build for Raspberry Pi2」
然後,我們設置RASPI_HOME="./"
,創建一個文件夾"./sysroot"
,與"raspi-2_"
在1gyp_configuration.gypi1和設置我們的胳膊工具鏈中gyp_configuration.py
更換"raspi-1_"
。
,但我們得到了如下一些錯誤消息,
Traceback (most recent call last):
File "./gyp_cobalt", line 271, in <module>
sys.exit(main(sys.argv[1:]))
File "./gyp_cobalt", line 261, in main
gyp_return = gyp_runner.BuildConfig(config_name)
File "./gyp_cobalt", line 175, in BuildConfig
return gyp.main(args)
File "/cobalt/cobalt-git/src/tools/gyp/pylib/gyp/__init__.py", line 541, in main
return gyp_main(args)
File "/cobalt/cobalt-git/src/tools/gyp/pylib/gyp/__init__.py", line 526, in gyp_main
generator.GenerateOutput(flat_list, targets, data, params)
File "/cobalt/cobalt-git/src/tools/gyp/pylib/gyp/generator/ninja.py", line 2277, in GenerateOutput
user_config)
File "/cobalt/cobalt-git/src/tools/gyp/pylib/gyp/generator/ninja.py", line 2223, in GenerateOutputForConfig
spec, config_name, generator_flags)
File "/cobalt/cobalt-git/src/tools/gyp/pylib/gyp/generator/ninja.py", line 405, in WriteSpec
config = spec['configurations'][config_name]
KeyError: 'raspi-2_debug'
爲什麼我們要正確設置其它配置?
改進的語法和格式 –