mirror of
https://dev.iopsys.eu/feed/iopsys.git
synced 2025-12-21 01:24:10 +08:00
Compare commits
15 Commits
add_libblo
...
jwt
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
9d0b02adef | ||
|
|
45b5f2c09e | ||
|
|
1a118e9aaf | ||
|
|
909515b4bb | ||
|
|
8b6b1b5ac5 | ||
|
|
9b64ae9348 | ||
|
|
87be8345a0 | ||
|
|
e3d39bb8a4 | ||
|
|
2353a0a0f2 | ||
|
|
1b55cee8e0 | ||
|
|
8925f9625b | ||
|
|
fa10a9536f | ||
|
|
43eb8b4962 | ||
|
|
e40f3cd4f5 | ||
|
|
0cec084471 |
52
libjwt/Makefile
Normal file
52
libjwt/Makefile
Normal file
@@ -0,0 +1,52 @@
|
||||
|
||||
# Copyright (C) 2018 Iopsys
|
||||
#
|
||||
|
||||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=libjwt
|
||||
PKG_VERSION:=1.0.0
|
||||
|
||||
PKG_SOURCE_PROTO:=git
|
||||
PKG_SOURCE_VERSION:=866607c7741421c8ac99876e7201eb32d9af1b92
|
||||
PKG_SOURCE_URL:=https://github.com/benmcollins/libjwt.git
|
||||
|
||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)_$(PKG_SOURCE_VERSION).tar.xz
|
||||
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
|
||||
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
|
||||
|
||||
PKG_FIXUP:=autoreconf
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
define Package/libjwt
|
||||
CATEGORY:=Libraries
|
||||
DEPENDS:=+libopenssl +jansson
|
||||
TITLE:= libjwt
|
||||
endef
|
||||
|
||||
|
||||
#TARGET_CFLAGS += \
|
||||
# -I$(STAGING_DIR)/usr/include
|
||||
# -I$(STAGING_DIR)/usr/include/libnl3
|
||||
|
||||
#MAKE_FLAGS += \
|
||||
# CFLAGS="$(TARGET_CFLAGS)" \
|
||||
# LDFLAGS="$(TARGET_LDFLAGS)" \
|
||||
# FPIC="$(FPIC)" \
|
||||
# PLATFORM="$(TARGET_PLATFORM)" \
|
||||
# subdirs="$(subdirs)"
|
||||
|
||||
define Build/InstallDev
|
||||
$(INSTALL_DIR) $(1)/usr/include
|
||||
$(INSTALL_DIR) $(1)/usr/lib
|
||||
$(CP) $(PKG_BUILD_DIR)/include/jwt.h $(1)/usr/include/
|
||||
$(CP) $(PKG_BUILD_DIR)/libjwt/.libs/libjwt.so* $(1)/usr/lib/
|
||||
endef
|
||||
|
||||
define Package/libjwt/install
|
||||
$(INSTALL_DIR) $(1)/usr/lib
|
||||
$(CP) $(PKG_BUILD_DIR)/libjwt/.libs/libjwt.so* $(1)/usr/lib/
|
||||
endef
|
||||
|
||||
$(eval $(call BuildPackage,libjwt))
|
||||
36
mqtt-ciotc/Makefile
Normal file
36
mqtt-ciotc/Makefile
Normal file
@@ -0,0 +1,36 @@
|
||||
#
|
||||
# Copyright (C) 2013 Inteno
|
||||
#
|
||||
|
||||
include $(TOPDIR)/rules.mk
|
||||
include $(INCLUDE_DIR)/kernel.mk
|
||||
|
||||
PKG_NAME:=mqtt-ciotc
|
||||
PKG_VERSION:=0.1
|
||||
|
||||
PKG_SOURCE_VERSION:=eda5bc711c215cbfe50ddd0e8725b69d4a3cff4f
|
||||
PKG_SOURCE_PROTO:=git
|
||||
PKG_SOURCE_URL:=https://dev.iopsys.eu/iopsys/wifilife-testbed.git
|
||||
|
||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
|
||||
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
|
||||
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
define Package/mqtt-ciotc
|
||||
CATEGORY:=Utilities
|
||||
DEPENDS:=+libjwt +lib-paho-mqtt +libopenssl +libubox +ubus +libblobmsg-json
|
||||
TITLE:=mqtt google iot clinet
|
||||
endef
|
||||
|
||||
define Package/mqtt-ciotc/description
|
||||
mqtt google iot client
|
||||
endef
|
||||
|
||||
define Package/mqtt-ciotc/install
|
||||
$(INSTALL_DIR) $(1)/sbin
|
||||
$(INSTALL_BIN) $(PKG_BUILD_DIR)/mqtt_ciotc $(1)/sbin/
|
||||
endef
|
||||
|
||||
$(eval $(call BuildPackage,mqtt-ciotc))
|
||||
3
mqtt-ciotc/files/etc/config/mqtt-ciotc
Normal file
3
mqtt-ciotc/files/etc/config/mqtt-ciotc
Normal file
@@ -0,0 +1,3 @@
|
||||
config mqtt-ciotc mqtt-ciotc
|
||||
option private-cert '/etc/mqtt-ciotc/rsa_private.pem'
|
||||
option root-cert '/etc/mqtt-ciotc/roots.pem'
|
||||
35
mqtt-ciotc/files/etc/init.d/mqtt-ciotc
Executable file
35
mqtt-ciotc/files/etc/init.d/mqtt-ciotc
Executable file
@@ -0,0 +1,35 @@
|
||||
#!/bin/sh /etc/rc.common
|
||||
|
||||
START=96
|
||||
STOP=10
|
||||
PROG=/sbin/mqtt-ciotc
|
||||
|
||||
USE_PROCD=1
|
||||
|
||||
start_service() {
|
||||
procd_open_instance
|
||||
procd_set_param command ${PROG}
|
||||
config_load mqtt-ciotc
|
||||
config_get private-cert mqtt-ciotc private-cert
|
||||
config_get root-cert mqtt-ciotc root-cert
|
||||
|
||||
[ -n $private-cert ] && procd_append_param command --private-cert $private-cert
|
||||
[ -n $root-cert ] && procd_append_param command --root-cert $root-cert
|
||||
procd_set_param respawn
|
||||
procd_close_instance
|
||||
}
|
||||
|
||||
stop_service()
|
||||
{
|
||||
service_stop ${PROG}
|
||||
}
|
||||
|
||||
reload_service() {
|
||||
# procd_send_signal wifilife # use SIGHUP
|
||||
stop
|
||||
start
|
||||
}
|
||||
|
||||
service_triggers() {
|
||||
procd_add_reload_trigger "mqtt-ciotc"
|
||||
}
|
||||
43
paho-mqtt-c/Makefile
Normal file
43
paho-mqtt-c/Makefile
Normal file
@@ -0,0 +1,43 @@
|
||||
#
|
||||
# Copyright (C) 2013 Inteno
|
||||
#
|
||||
|
||||
include $(TOPDIR)/rules.mk
|
||||
include $(INCLUDE_DIR)/kernel.mk
|
||||
|
||||
PKG_NAME:=lib-paho-mqtt
|
||||
PKG_VERSION:=0.1
|
||||
|
||||
PKG_SOURCE_VERSION:=9f715d0862a8e16099b5837c4e53a1bf6a6a0675
|
||||
PKG_SOURCE_PROTO:=git
|
||||
PKG_SOURCE_URL:=https://github.com/eclipse/paho.mqtt.c.git
|
||||
|
||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
|
||||
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
|
||||
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
define Package/lib-paho-mqtt
|
||||
CATEGORY:=Libraries
|
||||
DEPENDS:=+libopenssl
|
||||
TITLE:=package for mqtt stuff
|
||||
endef
|
||||
|
||||
|
||||
define Package/lib-paho-mqtt/description
|
||||
a library
|
||||
endef
|
||||
|
||||
define Build/InstallDev
|
||||
$(INSTALL_DIR) $(1)/usr/include/ $(1)/usr/lib
|
||||
$(INSTALL_DATA) $(PKG_BUILD_DIR)/src/*.h $(1)/usr/include/
|
||||
$(INSTALL_DATA) $(PKG_BUILD_DIR)/build/output/*.so* $(1)/usr/lib/
|
||||
endef
|
||||
|
||||
define Package/lib-paho-mqtt/install
|
||||
$(INSTALL_DIR) $(1)/usr/lib/
|
||||
$(INSTALL_BIN) $(PKG_BUILD_DIR)/build/output/*.so* $(1)/usr/lib/
|
||||
endef
|
||||
|
||||
$(eval $(call BuildPackage,lib-paho-mqtt))
|
||||
Reference in New Issue
Block a user