【发布时间】:2017-09-08 04:36:35
【问题描述】:
基本问题/目标:
我希望能够使用一些共享库,它们应该在 cmake step(plugin) 之前从自定义 PPA 中获取。
snapcraft.yaml:
name: mraa-blink-example
version: 'Latest'
summary: mraa for snapcraft
description: |
Blink Example from MRAA lib
grade: stable #devel # must be 'stable' to release into candidate/stable channels
confinement: strict # use 'strict' once you have the right plugs and slots
apps:
blinkapp:
command: bin/blink
parts:
blink:
plugin: cmake
build-packages:
- libmraa1
- libmraa-dev
- mraa-tools
- python-mraa
- python3-mraa
CMakeLists.txt
cmake_minimum_required(VERSION 2.8.9)
project (MRAA)
file(GLOB SOURCES "src/*.cpp")
#For the shared library:
set ( PROJECT_LINK_LIBS libmraa.so )
add_executable(blink ${SOURCES})
target_link_libraries(blink ${PROJECT_LINK_LIBS} )
install(TARGETS blink DESTINATION /bin)
因为构建包来自自定义 PPA,所以我收到错误:
在 'build-packages' 中找不到所需的包:“缓存有 没有名为“libmraa-dev”的包”
有没有办法解决这个问题?
【问题讨论】:
标签: snapcraft