Compare commits

...

53 Commits

Author SHA1 Message Date
Hemlata Bhatt
58899f6d4f mdmngr :Added the missing lib in Makefile 2019-04-10 16:00:50 +02:00
Hemlata Bhatt
10489b170d mdmngr: correct commit hash 2019-04-10 09:06:26 +02:00
Hemlata Bhatt
f2bf60c59c mdmngr :Change folder name and Updated Makefile 2019-04-09 16:02:06 +02:00
Arun Muthusamy
0544d02cbc libmobile: update hash & comment dongle_nl package 2019-04-09 15:06:24 +02:00
Arun Muthusamy
151a68d333 libmobile: update hash 2019-04-09 15:06:24 +02:00
Jakob Olsson
7efdbecb12 Makefile: add eval for dongle_nl package 2019-04-09 15:06:24 +02:00
Ionuț-Alex Oprea
ea1baf4909 update hash 2019-04-09 15:06:24 +02:00
Arun Muthusamy
2161aafc21 libmobile: update pkg source hash 2019-04-09 15:06:24 +02:00
Arun Muthusamy
0939135a42 add dongle netlink package 2019-04-09 15:06:24 +02:00
Jakob Olsson
e2cf14effe Makefile: hash update 2019-04-09 15:06:24 +02:00
Jakob Olsson
e6dbc91173 init.d: add default value to debug
Add default value to debug so that an extra check whether debug has been initiated is not required prior to checking if it is greater than 0.
2019-04-09 15:06:24 +02:00
Jakob Olsson
b81e389317 init.d: remove unused stuff, only send debug flag if debug is active 2019-04-09 15:06:24 +02:00
Jakob Olsson
c49e51be49 hotplug/usb: remove unused code/testing prints, update ubus method name to call 2019-04-09 15:06:24 +02:00
Jakob Olsson
3ddef6c3e2 hotplug/iface: remove some unused prints, update call to method name change from update to refresh 2019-04-09 15:06:24 +02:00
Jakob Olsson
0ee1ecacb0 config/mdmngr: remove unused variable 2019-04-09 15:06:24 +02:00
Jakob Olsson
eee8093b40 Makefile: update hash, change binary name of file to transfer 2019-04-09 15:06:24 +02:00
Jakob Olsson
d189cb0bc7 hash udpate 2019-04-09 15:06:24 +02:00
Jakob Olsson
0337bbcd13 Makefile: update hash and lib name 2019-04-09 15:06:24 +02:00
Jakob Olsson
4af09dcba7 hash update 2019-04-09 15:06:24 +02:00
Jakob Olsson
7df6acc5c0 Makefile: remove old library transfers 2019-04-09 15:06:24 +02:00
Jakob Olsson
936351ebef add hotplug scripts, hash update 2019-04-09 15:06:24 +02:00
Jakob Olsson
42a18d51ff update to include wrapper files, hash 2019-04-09 15:06:24 +02:00
Jakob Olsson
9eb9d5e389 fix tupo, hash 2019-04-09 15:06:24 +02:00
Jakob Olsson
0aa7f32adb hash and xml2 2019-04-09 15:06:24 +02:00
Jakob Olsson
f6deb70281 hash and add xml lib 2019-04-09 15:06:24 +02:00
Jakob Olsson
1bfa0092f8 hash 2019-04-09 15:06:24 +02:00
Jakob Olsson
c59e765478 hash change 2019-04-09 15:06:24 +02:00
Jakob Olsson
e7871035e4 hash update 2019-04-09 15:06:24 +02:00
Jakob Olsson
4eb9357408 changes to lib names and hash 2019-04-09 15:06:24 +02:00
Jakob Olsson
81790aface hash update 2019-04-09 15:06:24 +02:00
Jakob Olsson
48055462f5 change libmobiled to mdmngr, hash 2019-04-09 15:06:24 +02:00
Jakob Olsson
04ab109469 hash 2019-04-09 15:06:24 +02:00
Jakob Olsson
099aa8f897 hash 2019-04-09 15:06:24 +02:00
Jakob Olsson
4399634f9d hash update 2019-04-09 15:06:24 +02:00
Jakob Olsson
01e863dcc5 minor errors and hash update 2019-04-09 15:06:24 +02:00
Jakob Olsson
cc481fe2af remove uci dependency, hash update 2019-04-09 15:06:24 +02:00
Jakob Olsson
7f03dcc3e3 hash update 2019-04-09 15:06:24 +02:00
Jakob Olsson
e5a2eb9156 further accomodations for uci 2019-04-09 15:06:24 +02:00
Jakob Olsson
8ba26fb21d some changes for uci 2019-04-09 15:06:24 +02:00
Jakob Olsson
1763e12b14 hash update 2019-04-09 15:06:24 +02:00
Jakob Olsson
9e554571a6 update hash, change files to accomodate single application & lib 2019-04-09 15:06:24 +02:00
Jakob Olsson
3d5e45b737 hash change, update initd script 2019-04-09 15:06:24 +02:00
Jakob Olsson
7f7a1023ff hash updates 2019-04-09 15:06:24 +02:00
Jakob Olsson
992a156f3f removed unnecessary libraries, update hash 2019-04-09 15:06:24 +02:00
Jakob Olsson
be2ce1e2b4 hash change 2019-04-09 15:06:24 +02:00
Jakob Olsson
a82ad9a2da add new package option to libmobile, DOES NOT WORK THOUGH, and hash updates 2019-04-09 15:06:24 +02:00
Jakob Olsson
68f0bc5bcf hash update 2019-04-09 15:06:24 +02:00
Jakob Olsson
85109a9621 fix to makefile 2019-04-09 15:06:24 +02:00
Jakob Olsson
a824a68b63 newest verison, need use installdev somehow... 2019-04-09 15:06:24 +02:00
Jakob Olsson
e0ca687e26 include build/installDev, remove some old stuff 2019-04-09 15:06:24 +02:00
Jakob Olsson
7a6e79edd3 hash and small fix 2019-04-09 15:06:24 +02:00
Jakob Olsson
7a7072994a using onboarding as 2nd repo for application daemons 2019-04-09 15:06:24 +02:00
Jakob Olsson
e1c253c7ae some makefile experiement - will not work from same git repo 2019-04-09 15:06:24 +02:00
5 changed files with 138 additions and 0 deletions

77
mdmngr/Makefile Normal file
View File

@@ -0,0 +1,77 @@
#
# Copyright (C) 2019 Iopsys
#
include $(TOPDIR)/rules.mk
include $(INCLUDE_DIR)/kernel.mk
PKG_NAME:=mdmngr
PKG_VERSION:=0.1
PKG_SOURCE_VERSION:=b36329396852519f136a3ff5feda10bc36444688
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/iopsys/mdmngr.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/libmobile
CATEGORY:=Libraries
DEPENDS:=+libubox +ubus +libcurl +libxml2
TITLE:=package for 4g dongle stuff
endef
define Package/mdmngr
CATEGORY:=Utilities
DEPENDS:=+libubox +ubus +libmobile +libnl-genl
TITLE:=application package for 4g dongle stuff
endef
#define Package/dongle_nl
# CATEGORY:=Utilities
# TITLE:=Dongle Netlink
# URL:=
# DEPENDS:=+libuci +libubus +libblobmsg-json +libnl-genl
#endef
define Package/libmobile/description
a library to communicate with dongles through HTTP requests
endef
define Package/mdmngr/description
application using libmobile to communicate with a 4g dongle
endef
#define Package/dongle_nl/description
# Dongle application handling netlink messages from kernel and sending them out on ubus.
#endef
define Build/InstallDev
$(INSTALL_DIR) $(1)/usr/include/ $(1)/usr/lib
$(INSTALL_DATA) $(PKG_BUILD_DIR)/libmobile.h $(1)/usr/include/
$(INSTALL_DATA) $(PKG_BUILD_DIR)/libmobile.so $(1)/usr/lib/
endef
define Package/libmobile/install
$(INSTALL_DIR) $(1)/usr/lib/
$(INSTALL_BIN) $(PKG_BUILD_DIR)/libmobile.so $(1)/usr/lib/
endef
define Package/mdmngr/install
$(CP) ./files/* $(1)/ # copy from files to final image
$(INSTALL_DIR) $(1)/sbin # make the dir
$(INSTALL_BIN) $(PKG_BUILD_DIR)/mdmngr $(1)/sbin/ # copy binaries to new directory
endef
#define Package/dongle_nl/install
# $(INSTALL_BIN) $(1)/sbin # make the dir
# $(INSTALL_BIN) $(PKG_BUILD_DIR)/dongle_nl $(1)/sbin/
#endef
$(eval $(call BuildPackage,libmobile))
$(eval $(call BuildPackage,mdmngr))
#$(eval $(call BuildPackage,dongle_nl))

View File

@@ -0,0 +1,2 @@
config mdmngr mdmngr
option debug 1

View File

@@ -0,0 +1,8 @@
if echo $DEVICE | grep "eth";then
ubus call dongle refresh
fi
if echo $DEVICE | grep "usb";then
ubus call dongle refresh
fi

View File

@@ -0,0 +1,17 @@
DEV_MOUNTPATH=`echo "$DEVPATH" | cut -d'/' -f 1-7`
JUNK=`echo "$DEVPATH" | cut -d'/' -f 8`
case "$ACTION" in
add)
if [ -z "$JUNK" ];then
#ubus call dongle alert '{"path":"/sys'${DEV_MOUNTPATH}'"}'
ubus call dongle refresh
fi
;;
remove)
ubus call dongle refresh
;;
*)
;;
esac

34
mdmngr/files/etc/init.d/mdmngr Executable file
View File

@@ -0,0 +1,34 @@
#!/bin/sh /etc/rc.common
START=14
STOP=96
USE_PROCD=1
NAME=dongled
start_service() {
procd_open_instance
config_load mdmngr
config_get debug mdmngr debug 0
procd_set_param command "/sbin/mdmngr"
# procd_append_param command --debug "$debug"
if [ "$debug" -gt 0 ]
then
procd_append_param command --debug "$debug"
fi
procd_set_param respawn
procd_set_param stdout 1
procd_set_param stderr 1
procd_close_instance
}
service_triggers()
{
procd_add_reload_trigger mdmngr
}
reload_service() {
stop
start
}