Commit 7421a92f authored by rubo77's avatar rubo77

add i18n support to Makefile

parent 5c80482d
gluon-ssid-changer gluon-ssid-changer
================== ==================
This package adds a script, that changes the SSID when there is no connection to This package adds a script to change the SSID to an Offline-SSID when there is
the selected Gateway. no connection to any gateway.
This SSID can be generated from the nodes hostname with the first
and last part of the nodename or the mac address, to allow observers to
recognise which node is down. The script is called once a minute by micron.d
and it will change from online to offline-SSID maximum once every (definable)
timeframe.
You can enable/disable it in the config mode. You can enable/disable it in the config mode.
......
...@@ -7,6 +7,9 @@ PKG_BUILD_DIR := $(BUILD_DIR)/$(PKG_NAME) ...@@ -7,6 +7,9 @@ PKG_BUILD_DIR := $(BUILD_DIR)/$(PKG_NAME)
include $(TOPDIR)/../package/gluon.mk include $(TOPDIR)/../package/gluon.mk
PKG_CONFIG_DEPENDS += $(GLUON_I18N_CONFIG)
define Package/gluon-ssid-changer define Package/gluon-ssid-changer
SECTION:=gluon SECTION:=gluon
CATEGORY:=Gluon CATEGORY:=Gluon
...@@ -31,6 +34,7 @@ define Build/Configure ...@@ -31,6 +34,7 @@ define Build/Configure
endef endef
define Build/Compile define Build/Compile
$(call GluonBuildI18N,gluon-ssid-changer,i18n)
$(call GluonSrcDiet,./luasrc,$(PKG_BUILD_DIR)/luadest/) $(call GluonSrcDiet,./luasrc,$(PKG_BUILD_DIR)/luadest/)
endef endef
...@@ -38,6 +42,7 @@ define Package/gluon-ssid-changer/install ...@@ -38,6 +42,7 @@ define Package/gluon-ssid-changer/install
$(CP) ./files/* $(1)/ $(CP) ./files/* $(1)/
$(CP) $(PKG_BUILD_DIR)/luadest/* $(1)/ $(CP) $(PKG_BUILD_DIR)/luadest/* $(1)/
./gluonShellDiet.sh $(1)/lib/gluon/ssid-changer/ssid-changer.sh ./gluonShellDiet.sh $(1)/lib/gluon/ssid-changer/ssid-changer.sh
$(call GluonInstallI18N,gluon-ssid-changer,$(1))
endef endef
define Package/gluon-ssid-changer/postinst define Package/gluon-ssid-changer/postinst
......
...@@ -17,5 +17,5 @@ msgid "" ...@@ -17,5 +17,5 @@ msgid ""
"Here you can enable to automatically change the SSID to the OFFLINE-SSID " "Here you can enable to automatically change the SSID to the OFFLINE-SSID "
"when the node has no connection to the selected Gateway." "when the node has no connection to the selected Gateway."
msgstr "" msgstr ""
"Hier hast du aktivieren, dass dein Knoten automatisch die SSID auf die " "Hier kannst du aktivieren, dass dein Knoten automatisch die SSID auf die "
"OFFLINE-SSID ändert wenn keine Verbundung zum Freifunk Server besteht." "OFFLINE-SSID ändert wenn keine Verbundung zum Freifunk Server besteht."
...@@ -20,14 +20,14 @@ function f:write() ...@@ -20,14 +20,14 @@ function f:write()
if enabled.data then if enabled.data then
uci:section('ssid-changer', 'settings', 'settings', { uci:section('ssid-changer', 'settings', 'settings', {
enabled = '1', enabled = '1',
-- prefix = prefix.data -- prefix = prefix.data
-- switch_timeframe = switch_timeframe.data or '1440' -- switch_timeframe = switch_timeframe.data or '1440'
-- tq_limit_max = tq_limit_max.data or '55' -- tq_limit_max = tq_limit_max.data or '55'
-- first = first.data or '5' -- first = first.data or '5'
-- prefix = prefix.data or 'FF_OFFLINE_' -- prefix = prefix.data or 'FF_OFFLINE_'
-- suffix = suffix.data or 'nodename' -- suffix = suffix.data or 'nodename'
-- tq_limit_min = tq_limit_min.data or '45' -- tq_limit_min = tq_limit_min.data or '45'
-- tq_limit_enabled = tq_limit_enabled.data or '0' -- tq_limit_enabled = tq_limit_enabled.data or '0'
}) })
else else
uci:set('ssid-changer', 'settings', 'enabled', '0') uci:set('ssid-changer', 'settings', 'enabled', '0')
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment