OpenSync:修訂間差異
出自flip the world
| 第62行: | 第62行: | ||
$(eval $(call BuildPackage,opensync)) | $(eval $(call BuildPackage,opensync)) | ||
</pre> | |||
*patches | |||
<pre> | |||
<diff -Nur build/arm.mk build.new/arm.mk | |||
--- a/build/arm.mk 1970-01-01 08:00:00.000000000 +0800 | |||
+++ b/build.new/arm.mk 2019-01-30 14:07:56.003034972 +0800 | |||
@@ -0,0 +1,61 @@ | |||
+# Copyright (c) 2015, Plume Design Inc. All rights reserved. | |||
+# | |||
+# Redistribution and use in source and binary forms, with or without | |||
+# modification, are permitted provided that the following conditions are met: | |||
+# 1. Redistributions of source code must retain the above copyright | |||
+# notice, this list of conditions and the following disclaimer. | |||
+# 2. Redistributions in binary form must reproduce the above copyright | |||
+# notice, this list of conditions and the following disclaimer in the | |||
+# documentation and/or other materials provided with the distribution. | |||
+# 3. Neither the name of the Plume Design Inc. nor the | |||
+# names of its contributors may be used to endorse or promote products | |||
+# derived from this software without specific prior written permission. | |||
+# | |||
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND | |||
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED | |||
+# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE | |||
+# DISCLAIMED. IN NO EVENT SHALL Plume Design Inc. BE LIABLE FOR ANY | |||
+# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES | |||
+# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; | |||
+# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND | |||
+# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | |||
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS | |||
+# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | |||
+ | |||
+# | |||
+# native configuration | |||
+# | |||
+ | |||
+BUILD_SHARED_LIB = n | |||
+ | |||
+DIST_NAME = $(shell if [ -e /etc/os-release ]; then . /etc/os-release; echo $$ID$$VERSION_ID; fi) | |||
+ifneq ($(DIST_NAME),) | |||
+endif | |||
+ | |||
+SDK_ROOTFS = $(OBJDIR)/rootfs | |||
+ | |||
+CC = arm-none-eabi-gcc | |||
+CXX = arm-none-eabi-g++ | |||
+AR = arm-none-eabi-ar | |||
+STRIP = arm-none-eabi-strip -g | |||
+ | |||
+ | |||
+# Includes | |||
+CFLAGS += -I/usr/include/protobuf-c | |||
+# Flags | |||
+CFLAGS += -O3 -pipe | |||
+CFLAGS += -rdynamic | |||
+CFLAGS += -fno-caller-saves | |||
+CFLAGS += -fno-strict-aliasing | |||
+CFLAGS += -fasynchronous-unwind-tables | |||
+CFLAGS += -Wno-error=unused-but-set-variable | |||
+CFLAGS += -Wno-error=cpp | |||
+ | |||
+# Defines | |||
+CFLAGS += -D_U_="__attribute__((unused))" | |||
+ | |||
+export CC | |||
+export CXX | |||
+export CFLAGS | |||
+export LIBS | |||
+ | |||
</pre> | </pre> | ||
2019年2月28日 (四) 15:25的版本
ESPlorer
Yocto
OpenWrt
- Makefile
#
# Copyright (C) 2019 Tommy C. Liu
#
# This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information.
#
include $(TOPDIR)/rules.mk
PKG_NAME:=opensync
PKG_VERSION:=master
PKG_RELEASE:=1
PKG_MAINTAINER:=Tommy C. Liu <tommy.using@gmail.com>
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
PKG_LICENSE:=GPL-2.0
PKG_LICENSE_FILES:=docs/LICENSE
PKG_USE_MIPS16:=0
#PKG_AUTOMAKE_PATHS:=src
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://github.com/plume-design/opensync
PKG_SOURCE_VERSION:=e368be0df2763895ed7877ae9e802c40fd38af40
PKG_MIRROR_HASH:=2036cedd366c9f38583986d27b1aabb49a0e120641cc9e9023c83e4ac5dae5ed
include $(INCLUDE_DIR)/package.mk
#CONFIGURE_PATH:=src
#MAKE_PATH:=src
define Package/opensync
SECTION:=net
CATEGORY:=Network
SUBMENU:=wireless
TITLE:=Cloud-agnostic software for the delivery, curation, and management of services for the modern home.
URL:=https://github.com/plume-design/opensync
DEPENDS:=+jansson +libev +libprotobuf-c +libopenssl +libmosquitto +zlib
CFLAGS="$(TARGET_CFLAGS) -Wall"
endef
define Package/opensync/description
It acts as a silicon, CPE, and cloud-agnostic connection between in-home hardware devices and the cloud. It provides modern utilities for collecting measurements and statistics from devices, controlling and managing devices, and provides capabilities for specific services including Wi-Fi meshing, access control, cyber security, parental controls, and IoT onboarding and telemetry.
endef
define Build/Compile
$(call Build/Compile/Default)
endef
define Package/opensync/install
$(INSTALL_DIR) $(1)/usr/sbin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/work/native/bin/* $(1)/usr/sbin/
endef
$(eval $(call BuildPackage,opensync))
- patches
<diff -Nur build/arm.mk build.new/arm.mk --- a/build/arm.mk 1970-01-01 08:00:00.000000000 +0800 +++ b/build.new/arm.mk 2019-01-30 14:07:56.003034972 +0800 @@ -0,0 +1,61 @@ +# Copyright (c) 2015, Plume Design Inc. All rights reserved. +# +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions are met: +# 1. Redistributions of source code must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# 2. Redistributions in binary form must reproduce the above copyright +# notice, this list of conditions and the following disclaimer in the +# documentation and/or other materials provided with the distribution. +# 3. Neither the name of the Plume Design Inc. nor the +# names of its contributors may be used to endorse or promote products +# derived from this software without specific prior written permission. +# +# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND +# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +# DISCLAIMED. IN NO EVENT SHALL Plume Design Inc. BE LIABLE FOR ANY +# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +# +# native configuration +# + +BUILD_SHARED_LIB = n + +DIST_NAME = $(shell if [ -e /etc/os-release ]; then . /etc/os-release; echo $$ID$$VERSION_ID; fi) +ifneq ($(DIST_NAME),) +endif + +SDK_ROOTFS = $(OBJDIR)/rootfs + +CC = arm-none-eabi-gcc +CXX = arm-none-eabi-g++ +AR = arm-none-eabi-ar +STRIP = arm-none-eabi-strip -g + + +# Includes +CFLAGS += -I/usr/include/protobuf-c +# Flags +CFLAGS += -O3 -pipe +CFLAGS += -rdynamic +CFLAGS += -fno-caller-saves +CFLAGS += -fno-strict-aliasing +CFLAGS += -fasynchronous-unwind-tables +CFLAGS += -Wno-error=unused-but-set-variable +CFLAGS += -Wno-error=cpp + +# Defines +CFLAGS += -D_U_="__attribute__((unused))" + +export CC +export CXX +export CFLAGS +export LIBS +
