MAC OS X Pebble SDK 3.0错误构建:编译错误InverterLayer

MAC OS X Pebble SDK 3.0 error building: Compilation error InverterLayer

几个月前,我 运行 在我的 mac 上安装了 pebble SDK 3.0,它运行良好,我 运行 我的应用程序使用 basalt 模拟器。

最近我清理(擦除)了我的 mac,因为它 运行 速度很慢。今天我打算再次 运行 我的应用程序,但显然我没有安装 Pebble SDK。

我使用 pebble 开发者网站上出现的 brew 命令安装了它:http://developer.getpebble.com/sdk/download/

brew install pebble/pebble-sdk/pebble-sdk

我在这里找到了目录:

/usr/local/Cellar/pebble-sdk/3.0

我尝试 运行 pebble 构建,但我记得我需要创建并克隆 pebbles 存储库。 我这样做了,然后当我进行 pebble build 时,它开始正常构建,但随后发生了这种情况:

[17/63] Start build for aplite: 
[25/63] app_resources.pbpack.manifest: build/resources/aplite/images/menu_icon.pbi build/resources/aplite/images/logo_splash.pbi build/resources/aplite/images/tile_splash.pbi build/resources/aplite/fonts/UbuntuMono-Regular.ttf.MONO_FONT_14.pfo ../Pebble/common/tools/pbpack_meta_data.py -> build/aplite/app_resources.pbpack.manifest
[28/63] c: src/simply/simply.c -> build/src/simply/simply.c.28.o
[31/63] c: src/simply/simply_msg.c -> build/src/simply/simply_msg.c.28.o
[35/63] c: src/simply/simply_splash.c -> build/src/simply/simply_splash.c.28.o
In file included from ../src/simply/simply.c:6:0:
../src/simply/simply_stage.h:102:3: error: unknown type name 'InverterLayer'
../src/simply/simply_splash.c: In function 'simply_splash_create':
../src/simply/simply_splash.c:45:3: error: implicit declaration of function 'window_set_fullscreen' [-Werror=implicit-function-declaration]
cc1: all warnings being treated as errors
In file included from ../src/simply/simply_msg.c:5:0:
../src/simply/simply_stage.h:102:3: error: unknown type name 'InverterLayer'

Waf: Leaving directory `/usr/local/Cellar/pebble-sdk/3.0/pebblejs/build'
Build failed
 -> task in 'basalt/pebble-app.elf' failed (exit status 1): 
    {task 4378463632: c simply.c -> simply.c.28.o}
['arm-none-eabi-gcc', '-std=c99', '-mcpu=cortex-m3', '-mthumb', '-ffunction-sections', '-fdata-sections', '-g', '-Os', '-D_TIME_H_', '-Wall', '-Wextra', '-Werror', '-Wno-unused-parameter', '-Wno-error=unused-function', '-Wno-error=unused-variable', '-Wno-address', '-Wno-type-limits', '-Wno-missing-field-initializers', '-fPIE', '-I/usr/local/Cellar/pebble-sdk/3.0/pebblejs/Pebble/basalt/include', '-I/usr/local/Cellar/pebble-sdk/3.0/Pebble/basalt/include', '-I/usr/local/Cellar/pebble-sdk/3.0/pebblejs/build', '-I/usr/local/Cellar/pebble-sdk/3.0/pebblejs', '-I/usr/local/Cellar/pebble-sdk/3.0/pebblejs/build/src', '-I/usr/local/Cellar/pebble-sdk/3.0/pebblejs/src', '-I/usr/local/Cellar/pebble-sdk/3.0/pebblejs/build/basalt', '-I/usr/local/Cellar/pebble-sdk/3.0/pebblejs/basalt', '-DRELEASE', '-DPBL_PLATFORM_BASALT', '-DPBL_COLOR', '-DPBL_SDK_3', '-D__FILE_NAME__="simply.c"', '../src/simply/simply.c', '-c', '-o', 'src/simply/simply.c.28.o']
 -> task in 'basalt/pebble-app.elf' failed (exit status 1): 
    {task 4378501264: c simply_splash.c -> simply_splash.c.28.o}
['arm-none-eabi-gcc', '-std=c99', '-mcpu=cortex-m3', '-mthumb', '-ffunction-sections', '-fdata-sections', '-g', '-Os', '-D_TIME_H_', '-Wall', '-Wextra', '-Werror', '-Wno-unused-parameter', '-Wno-error=unused-function', '-Wno-error=unused-variable', '-Wno-address', '-Wno-type-limits', '-Wno-missing-field-initializers', '-fPIE', '-I/usr/local/Cellar/pebble-sdk/3.0/pebblejs/Pebble/basalt/include', '-I/usr/local/Cellar/pebble-sdk/3.0/Pebble/basalt/include', '-I/usr/local/Cellar/pebble-sdk/3.0/pebblejs/build', '-I/usr/local/Cellar/pebble-sdk/3.0/pebblejs', '-I/usr/local/Cellar/pebble-sdk/3.0/pebblejs/build/src', '-I/usr/local/Cellar/pebble-sdk/3.0/pebblejs/src', '-I/usr/local/Cellar/pebble-sdk/3.0/pebblejs/build/basalt', '-I/usr/local/Cellar/pebble-sdk/3.0/pebblejs/basalt', '-DRELEASE', '-DPBL_PLATFORM_BASALT', '-DPBL_COLOR', '-DPBL_SDK_3', '-D__FILE_NAME__="simply_splash.c"', '../src/simply/simply_splash.c', '-c', '-o', 'src/simply/simply_splash.c.28.o']
 -> task in 'basalt/pebble-app.elf' failed (exit status 1): 
    {task 4378464016: c simply_msg.c -> simply_msg.c.28.o}
['arm-none-eabi-gcc', '-std=c99', '-mcpu=cortex-m3', '-mthumb', '-ffunction-sections', '-fdata-sections', '-g', '-Os', '-D_TIME_H_', '-Wall', '-Wextra', '-Werror', '-Wno-unused-parameter', '-Wno-error=unused-function', '-Wno-error=unused-variable', '-Wno-address', '-Wno-type-limits', '-Wno-missing-field-initializers', '-fPIE', '-I/usr/local/Cellar/pebble-sdk/3.0/pebblejs/Pebble/basalt/include', '-I/usr/local/Cellar/pebble-sdk/3.0/Pebble/basalt/include', '-I/usr/local/Cellar/pebble-sdk/3.0/pebblejs/build', '-I/usr/local/Cellar/pebble-sdk/3.0/pebblejs', '-I/usr/local/Cellar/pebble-sdk/3.0/pebblejs/build/src', '-I/usr/local/Cellar/pebble-sdk/3.0/pebblejs/src', '-I/usr/local/Cellar/pebble-sdk/3.0/pebblejs/build/basalt', '-I/usr/local/Cellar/pebble-sdk/3.0/pebblejs/basalt', '-DRELEASE', '-DPBL_PLATFORM_BASALT', '-DPBL_COLOR', '-DPBL_SDK_3', '-D__FILE_NAME__="simply_msg.c"', '../src/simply/simply_msg.c', '-c', '-o', 'src/simply/simply_msg.c.28.o']

[ERROR   ] A compilation error occurred

我不知道该怎么做。 谢谢!

凯文

更新:已解决!

问题: 我阅读了更多有关 pebble 一直在更新的新 sdk 的信息,似乎新的 sdk 弃用了 inverterLayer 和一些其他功能,这就是它没有编译的原因。

修复: 我所做的是进入 developer.pebble 网站上的示例页面并在 github 上浏览其中一个页面,克隆那个消除了我遇到的问题的页面,然后我复制了我的代码并 运行它。