From 869d39730f04b048c10f558115dd77f51564d2db Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Tue, 17 Mar 2015 22:46:58 +0100 Subject: [PATCH 01/32] Update openwrt base --- modules | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules b/modules index 56e542a0..decd5a53 100644 --- a/modules +++ b/modules @@ -1,7 +1,7 @@ GLUON_FEEDS='openwrt gluon routing luci' OPENWRT_REPO=git://git.openwrt.org/14.07/openwrt.git -OPENWRT_COMMIT=878af3117f68c2f8d6b3d6582e50c6cef521f6f7 +OPENWRT_COMMIT=64ae631f20eb349b47dae30c461ab33b5c4ac5c2 PACKAGES_OPENWRT_REPO=git://github.com/openwrt/packages.git PACKAGES_OPENWRT_COMMIT=01fcd1f29174a56d6ddb59901ed8c67ea42c3a8f From f031a03ffab0f81ab9dc15c47b4e9f45a0ade240 Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Tue, 17 Mar 2015 23:54:36 +0100 Subject: [PATCH 02/32] Update gluon packages --- modules | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules b/modules index decd5a53..80255956 100644 --- a/modules +++ b/modules @@ -8,7 +8,7 @@ PACKAGES_OPENWRT_COMMIT=01fcd1f29174a56d6ddb59901ed8c67ea42c3a8f PACKAGES_OPENWRT_BRANCH=for-14.07 PACKAGES_GLUON_REPO=git://github.com/freifunk-gluon/packages.git -PACKAGES_GLUON_COMMIT=2d0f8b38dbf6b01f77c780c7c80a995116e3eca8 +PACKAGES_GLUON_COMMIT=e58fd35f1835bfe093006bf194d508fd60d73f6b PACKAGES_ROUTING_REPO=git://github.com/openwrt-routing/packages.git PACKAGES_ROUTING_COMMIT=5d4ad63897b435d5df0f39a49bd58962c22c33b8 From 8fbe5d88e00049b632a6fc5006714acb260f3740 Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Wed, 18 Mar 2015 20:18:54 +0100 Subject: [PATCH 03/32] Refresh openwrt patches --- ...y-detect-hardware-revision-on-TP-Link-Archer-C5-and-C7.patch | 2 +- ...0006-ar71xx-add-support-for-TP-LINK-CPE210-220-510-520.patch | 2 +- .../0008-ar71xx-add-board-support-for-ubnt-loco-m-xw.patch | 2 +- ...0012-ar71xx-fix-board-detection-for-TP-LINK-TL-WA860RE.patch | 2 +- .../0015-Add-support-for-the-TP-LINK-TL-WR941ND-v5.patch | 2 +- .../0016-ar71xx-add-support-for-the-UniFi-AP-Outdoor-Plus.patch | 2 +- patches/openwrt/0024-ar71xx-detect-GL.iNet-model.patch | 2 +- ...odel-string-detection-on-NETGEAR-WNDR3700-3800-WNDRMAC.patch | 2 +- 8 files changed, 8 insertions(+), 8 deletions(-) diff --git a/patches/openwrt/0003-ar71xx-correctly-detect-hardware-revision-on-TP-Link-Archer-C5-and-C7.patch b/patches/openwrt/0003-ar71xx-correctly-detect-hardware-revision-on-TP-Link-Archer-C5-and-C7.patch index 0201dcf9..7b85d1e7 100644 --- a/patches/openwrt/0003-ar71xx-correctly-detect-hardware-revision-on-TP-Link-Archer-C5-and-C7.patch +++ b/patches/openwrt/0003-ar71xx-correctly-detect-hardware-revision-on-TP-Link-Archer-C5-and-C7.patch @@ -3,7 +3,7 @@ Date: Sat, 16 Aug 2014 17:52:34 +0200 Subject: ar71xx: correctly detect hardware revision on TP-Link Archer C5 and C7 diff --git a/target/linux/ar71xx/base-files/lib/ar71xx.sh b/target/linux/ar71xx/base-files/lib/ar71xx.sh -index df35775..6694839 100755 +index 18da356..1709356 100755 --- a/target/linux/ar71xx/base-files/lib/ar71xx.sh +++ b/target/linux/ar71xx/base-files/lib/ar71xx.sh @@ -214,6 +214,13 @@ tplink_board_detect() { diff --git a/patches/openwrt/0006-ar71xx-add-support-for-TP-LINK-CPE210-220-510-520.patch b/patches/openwrt/0006-ar71xx-add-support-for-TP-LINK-CPE210-220-510-520.patch index 529593e9..8e109662 100644 --- a/patches/openwrt/0006-ar71xx-add-support-for-TP-LINK-CPE210-220-510-520.patch +++ b/patches/openwrt/0006-ar71xx-add-support-for-TP-LINK-CPE210-220-510-520.patch @@ -62,7 +62,7 @@ index 4be30b8..78f4992 100755 rb-2011l | \ rb-2011uas |\ diff --git a/target/linux/ar71xx/base-files/lib/ar71xx.sh b/target/linux/ar71xx/base-files/lib/ar71xx.sh -index 6694839..c13a8eb 100755 +index 1709356..9fb4102 100755 --- a/target/linux/ar71xx/base-files/lib/ar71xx.sh +++ b/target/linux/ar71xx/base-files/lib/ar71xx.sh @@ -229,6 +229,39 @@ tplink_board_detect() { diff --git a/patches/openwrt/0008-ar71xx-add-board-support-for-ubnt-loco-m-xw.patch b/patches/openwrt/0008-ar71xx-add-board-support-for-ubnt-loco-m-xw.patch index 137bf991..f3e496d1 100644 --- a/patches/openwrt/0008-ar71xx-add-board-support-for-ubnt-loco-m-xw.patch +++ b/patches/openwrt/0008-ar71xx-add-board-support-for-ubnt-loco-m-xw.patch @@ -44,7 +44,7 @@ index 78f4992..c494310 100755 mr600v2 |\ rb-411 |\ diff --git a/target/linux/ar71xx/base-files/lib/ar71xx.sh b/target/linux/ar71xx/base-files/lib/ar71xx.sh -index c13a8eb..19cd1a7 100755 +index 9fb4102..79b6073 100755 --- a/target/linux/ar71xx/base-files/lib/ar71xx.sh +++ b/target/linux/ar71xx/base-files/lib/ar71xx.sh @@ -396,6 +396,9 @@ ar71xx_board_detect() { diff --git a/patches/openwrt/0012-ar71xx-fix-board-detection-for-TP-LINK-TL-WA860RE.patch b/patches/openwrt/0012-ar71xx-fix-board-detection-for-TP-LINK-TL-WA860RE.patch index 8065eace..31c4304c 100644 --- a/patches/openwrt/0012-ar71xx-fix-board-detection-for-TP-LINK-TL-WA860RE.patch +++ b/patches/openwrt/0012-ar71xx-fix-board-detection-for-TP-LINK-TL-WA860RE.patch @@ -5,7 +5,7 @@ Subject: ar71xx: fix board detection for TP-LINK TL-WA860RE Signed-off-by: Matthias Schiffer diff --git a/target/linux/ar71xx/base-files/lib/ar71xx.sh b/target/linux/ar71xx/base-files/lib/ar71xx.sh -index 19cd1a7..b0a0bd6 100755 +index 79b6073..13c5bf2 100755 --- a/target/linux/ar71xx/base-files/lib/ar71xx.sh +++ b/target/linux/ar71xx/base-files/lib/ar71xx.sh @@ -630,6 +630,9 @@ ar71xx_board_detect() { diff --git a/patches/openwrt/0015-Add-support-for-the-TP-LINK-TL-WR941ND-v5.patch b/patches/openwrt/0015-Add-support-for-the-TP-LINK-TL-WR941ND-v5.patch index 8e0b92ac..48079fc6 100644 --- a/patches/openwrt/0015-Add-support-for-the-TP-LINK-TL-WR941ND-v5.patch +++ b/patches/openwrt/0015-Add-support-for-the-TP-LINK-TL-WR941ND-v5.patch @@ -48,7 +48,7 @@ index c494310..3ccb917 100755 wnr2200 |\ wnr612-v2) diff --git a/target/linux/ar71xx/base-files/lib/ar71xx.sh b/target/linux/ar71xx/base-files/lib/ar71xx.sh -index b0a0bd6..c03fe72 100755 +index 13c5bf2..5fbca92 100755 --- a/target/linux/ar71xx/base-files/lib/ar71xx.sh +++ b/target/linux/ar71xx/base-files/lib/ar71xx.sh @@ -681,6 +681,9 @@ ar71xx_board_detect() { diff --git a/patches/openwrt/0016-ar71xx-add-support-for-the-UniFi-AP-Outdoor-Plus.patch b/patches/openwrt/0016-ar71xx-add-support-for-the-UniFi-AP-Outdoor-Plus.patch index e5c63e4a..c5d18bf6 100644 --- a/patches/openwrt/0016-ar71xx-add-support-for-the-UniFi-AP-Outdoor-Plus.patch +++ b/patches/openwrt/0016-ar71xx-add-support-for-the-UniFi-AP-Outdoor-Plus.patch @@ -19,7 +19,7 @@ index f0d5d70..6aac86a 100755 status_led="ubnt:white:status" ;; diff --git a/target/linux/ar71xx/base-files/lib/ar71xx.sh b/target/linux/ar71xx/base-files/lib/ar71xx.sh -index c03fe72..9e70397 100755 +index 5fbca92..61a7936 100755 --- a/target/linux/ar71xx/base-files/lib/ar71xx.sh +++ b/target/linux/ar71xx/base-files/lib/ar71xx.sh @@ -723,6 +723,9 @@ ar71xx_board_detect() { diff --git a/patches/openwrt/0024-ar71xx-detect-GL.iNet-model.patch b/patches/openwrt/0024-ar71xx-detect-GL.iNet-model.patch index 5b3b7687..9996872a 100644 --- a/patches/openwrt/0024-ar71xx-detect-GL.iNet-model.patch +++ b/patches/openwrt/0024-ar71xx-detect-GL.iNet-model.patch @@ -6,7 +6,7 @@ There are two versions of the GL.iNet, the 6408A and the 6416A. The only difference is the flash size. diff --git a/target/linux/ar71xx/base-files/lib/ar71xx.sh b/target/linux/ar71xx/base-files/lib/ar71xx.sh -index 9e70397..ac7f787 100755 +index 61a7936..a698ce5 100755 --- a/target/linux/ar71xx/base-files/lib/ar71xx.sh +++ b/target/linux/ar71xx/base-files/lib/ar71xx.sh @@ -262,6 +262,19 @@ tplink_pharos_board_detect() { diff --git a/patches/openwrt/0027-ar71xx-fix-model-string-detection-on-NETGEAR-WNDR3700-3800-WNDRMAC.patch b/patches/openwrt/0027-ar71xx-fix-model-string-detection-on-NETGEAR-WNDR3700-3800-WNDRMAC.patch index 23baa97c..a6868085 100644 --- a/patches/openwrt/0027-ar71xx-fix-model-string-detection-on-NETGEAR-WNDR3700-3800-WNDRMAC.patch +++ b/patches/openwrt/0027-ar71xx-fix-model-string-detection-on-NETGEAR-WNDR3700-3800-WNDRMAC.patch @@ -10,7 +10,7 @@ There were a few issues with the existing code to detect the model string: confuse other scripts) diff --git a/target/linux/ar71xx/base-files/lib/ar71xx.sh b/target/linux/ar71xx/base-files/lib/ar71xx.sh -index ac7f787..f50a236 100755 +index a698ce5..0f9be69 100755 --- a/target/linux/ar71xx/base-files/lib/ar71xx.sh +++ b/target/linux/ar71xx/base-files/lib/ar71xx.sh @@ -37,16 +37,28 @@ wndr3700_board_detect() { From 7401d02ca4e644e709f9562474bfb7eff1ddf31c Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Wed, 18 Mar 2015 18:14:21 +0100 Subject: [PATCH 04/32] Add i18n support --- Makefile | 2 + include/gluon.mk | 3 ++ include/package.mk | 52 +++++++++++++++++++ ...-define-STAMP_CONFIGURED-recursively.patch | 26 ++++++++++ 4 files changed, 83 insertions(+) create mode 100644 patches/openwrt/0030-build-define-STAMP_CONFIGURED-recursively.patch diff --git a/Makefile b/Makefile index d12b97a8..f341f36c 100644 --- a/Makefile +++ b/Makefile @@ -206,6 +206,8 @@ config: FORCE cat $(GLUONDIR)/include/config $(GLUONDIR)/targets/$(GLUON_TARGET)/config; \ echo '$(patsubst %,CONFIG_PACKAGE_%=m,$(sort $(filter-out -%,$(GLUON_DEFAULT_PACKAGES) $(GLUON_SITE_PACKAGES) $(PROFILE_PACKAGES))))' \ | sed -e 's/ /\n/g'; \ + echo '$(patsubst %,CONFIG_GLUON_LANG_%=y,$(GLUON_LANGS))' \ + | sed -e 's/ /\n/g'; \ ) > .config +$(NO_TRACE_MAKE) defconfig OPENWRT_BUILD=0 diff --git a/include/gluon.mk b/include/gluon.mk index 2f461b20..e0c6b49b 100644 --- a/include/gluon.mk +++ b/include/gluon.mk @@ -26,6 +26,9 @@ $(GLUON_SITEDIR)/site.mk: GLUON_VERSION := $(shell cd $(GLUONDIR) && git describe --always 2>/dev/null || echo unknown) export GLUON_VERSION +GLUON_LANGS ?= en +export GLUON_LANGS + ifeq ($(OPENWRT_BUILD),1) ifeq ($(GLUON_TOOLS),1) diff --git a/include/package.mk b/include/package.mk index 8e2af5b1..9277aff2 100644 --- a/include/package.mk +++ b/include/package.mk @@ -6,3 +6,55 @@ define GluonCheckSite $(shell cat $(1) | sed -ne '1h; 1!H; $$ {g; s/@/+@/g; s/\n/-@/g; p}') END__GLUON__CHECK__SITE endef + + +# Languages supported by LuCi +GLUON_SUPPORTED_LANGS := ca zh_cn en fr de el he hu it ja ms no pl pt_br pt ro ru es sv uk vi + +GLUON_LANG_ca := catalan +GLUON_LANG_zh_cn := chinese +GLUON_LANG_en := english +GLUON_LANG_fr := french +GLUON_LANG_de := german +GLUON_LANG_el := greek +GLUON_LANG_he := hebrew +GLUON_LANG_hu := hungarian +GLUON_LANG_it := italian +GLUON_LANG_ja := japanese +GLUON_LANG_ms := malay +GLUON_LANG_no := norwegian +GLUON_LANG_pl := polish +GLUON_LANG_pt_br := portuguese-brazilian +GLUON_LANG_pt := portuguese +GLUON_LANG_ro := romanian +GLUON_LANG_ru := russian +GLUON_LANG_es := spanish +GLUON_LANG_sv := swedish +GLUON_LANG_uk := ukrainian +GLUON_LANG_vi := vietnamese + +GLUON_I18N_PACKAGES := $(foreach lang,$(GLUON_SUPPORTED_LANGS),+GLUON_LANG_$(lang):luci-i18n-$(GLUON_LANG_$(lang))) +GLUON_I18N_CONFIG := $(foreach lang,$(GLUON_SUPPORTED_LANGS),CONFIG_GLUON_LANG_$(lang)) +GLUON_ENABLED_LANGS := $(foreach lang,$(GLUON_SUPPORTED_LANGS),$(if $(CONFIG_GLUON_LANG_$(lang)),$(lang))) + + +GLUON_PO2LMO := $(BUILD_DIR)/luci/build/po2lmo + +define GluonBuildI18N + mkdir -p $$(PKG_BUILD_DIR)/i18n + for lang in $$(GLUON_ENABLED_LANGS); do \ + if [ -e i18n/$$$$lang.po ]; then \ + rm -f $$(PKG_BUILD_DIR)/i18n/$(1).$$$$lang.lmo; \ + $(GLUON_PO2LMO) i18n/$$$$lang.po $$(PKG_BUILD_DIR)/i18n/$(1).$$$$lang.lmo; \ + fi; \ + done +endef + +define GluonInstallI18N + $$(INSTALL_DIR) $(2)/usr/lib/lua/luci/i18n + for lang in $$(GLUON_ENABLED_LANGS); do \ + if [ -e $$(PKG_BUILD_DIR)/i18n/$(1).$$$$lang.lmo ]; then \ + $$(INSTALL_DATA) $$(PKG_BUILD_DIR)/i18n/$(1).$$$$lang.lmo $(2)/usr/lib/lua/luci/i18n/$(1).$$$$lang.lmo; \ + fi; \ + done +endef diff --git a/patches/openwrt/0030-build-define-STAMP_CONFIGURED-recursively.patch b/patches/openwrt/0030-build-define-STAMP_CONFIGURED-recursively.patch new file mode 100644 index 00000000..5e68ad4c --- /dev/null +++ b/patches/openwrt/0030-build-define-STAMP_CONFIGURED-recursively.patch @@ -0,0 +1,26 @@ +From: Matthias Schiffer +Date: Wed, 18 Mar 2015 20:07:22 +0100 +Subject: build: define STAMP_CONFIGURED recursively + +Defining STAMP_CONFIGURED statically caused it not to reflect changes to +PKG_CONFIG_DEPENDS made after including package.mk, like the additional options +added by feeds.mk for all packages. + +Furthermore, as STAMP_CONFIGURED_WILDCARD was already defined recursively, the +patsubst in its definition would never match, and in consequence, the stamps +were never removed. This caused packages not to be rebuilt when they should have +been. + +diff --git a/include/package.mk b/include/package.mk +index 53ca6de..402fb1a 100644 +--- a/include/package.mk ++++ b/include/package.mk +@@ -60,7 +60,7 @@ ifneq ($(PREV_STAMP_PREPARED),) + else + STAMP_PREPARED=$(PKG_BUILD_DIR)/.prepared$(if $(QUILT)$(DUMP),,_$(shell $(call find_md5,${CURDIR} $(PKG_FILE_DEPENDS),))$(call confvar,$(PKG_PREPARED_DEPENDS))) + endif +-STAMP_CONFIGURED:=$(PKG_BUILD_DIR)/.configured$(if $(DUMP),,_$(call confvar,$(PKG_CONFIG_DEPENDS))) ++STAMP_CONFIGURED=$(PKG_BUILD_DIR)/.configured$(if $(DUMP),,_$(call confvar,$(PKG_CONFIG_DEPENDS))) + STAMP_CONFIGURED_WILDCARD=$(patsubst %_$(call confvar,$(PKG_CONFIG_DEPENDS)),%_*,$(STAMP_CONFIGURED)) + STAMP_BUILT:=$(PKG_BUILD_DIR)/.built + STAMP_INSTALLED:=$(STAGING_DIR)/stamp/.$(PKG_NAME)_installed From c457e7a99bf751ae5284cb4932d01df3368d8052 Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Wed, 18 Mar 2015 20:53:53 +0100 Subject: [PATCH 05/32] Update gluon packages --- modules | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules b/modules index 80255956..b9eecf2e 100644 --- a/modules +++ b/modules @@ -8,7 +8,7 @@ PACKAGES_OPENWRT_COMMIT=01fcd1f29174a56d6ddb59901ed8c67ea42c3a8f PACKAGES_OPENWRT_BRANCH=for-14.07 PACKAGES_GLUON_REPO=git://github.com/freifunk-gluon/packages.git -PACKAGES_GLUON_COMMIT=e58fd35f1835bfe093006bf194d508fd60d73f6b +PACKAGES_GLUON_COMMIT=4e47e4ce047d7b0bd757d9b439b7b7e1d6b9321a PACKAGES_ROUTING_REPO=git://github.com/openwrt-routing/packages.git PACKAGES_ROUTING_COMMIT=5d4ad63897b435d5df0f39a49bd58962c22c33b8 From 746d0c6b8ac6b207d43930efab9fa930a054af91 Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Thu, 19 Mar 2015 02:37:41 +0100 Subject: [PATCH 06/32] Update gluon packages --- modules | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules b/modules index b9eecf2e..4f66b08c 100644 --- a/modules +++ b/modules @@ -8,7 +8,7 @@ PACKAGES_OPENWRT_COMMIT=01fcd1f29174a56d6ddb59901ed8c67ea42c3a8f PACKAGES_OPENWRT_BRANCH=for-14.07 PACKAGES_GLUON_REPO=git://github.com/freifunk-gluon/packages.git -PACKAGES_GLUON_COMMIT=4e47e4ce047d7b0bd757d9b439b7b7e1d6b9321a +PACKAGES_GLUON_COMMIT=b39a315ce81f102814f51623d69a1dbe4e6b76a8 PACKAGES_ROUTING_REPO=git://github.com/openwrt-routing/packages.git PACKAGES_ROUTING_COMMIT=5d4ad63897b435d5df0f39a49bd58962c22c33b8 From f6b68184abcc27fd9e8b3704ad5642617ac2aa02 Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Thu, 19 Mar 2015 19:06:52 +0100 Subject: [PATCH 07/32] Update gluon packages --- modules | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules b/modules index 4f66b08c..771ee9c8 100644 --- a/modules +++ b/modules @@ -8,7 +8,7 @@ PACKAGES_OPENWRT_COMMIT=01fcd1f29174a56d6ddb59901ed8c67ea42c3a8f PACKAGES_OPENWRT_BRANCH=for-14.07 PACKAGES_GLUON_REPO=git://github.com/freifunk-gluon/packages.git -PACKAGES_GLUON_COMMIT=b39a315ce81f102814f51623d69a1dbe4e6b76a8 +PACKAGES_GLUON_COMMIT=ee6543524020342c05f674a5c0fb77992733829d PACKAGES_ROUTING_REPO=git://github.com/openwrt-routing/packages.git PACKAGES_ROUTING_COMMIT=5d4ad63897b435d5df0f39a49bd58962c22c33b8 From 3d2bc2a1885ea504acaaf90c70b08772ab581ff1 Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Thu, 19 Mar 2015 19:07:27 +0100 Subject: [PATCH 08/32] build: allow setting the source directory for PO files --- include/package.mk | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/package.mk b/include/package.mk index 9277aff2..271d1de0 100644 --- a/include/package.mk +++ b/include/package.mk @@ -43,9 +43,9 @@ GLUON_PO2LMO := $(BUILD_DIR)/luci/build/po2lmo define GluonBuildI18N mkdir -p $$(PKG_BUILD_DIR)/i18n for lang in $$(GLUON_ENABLED_LANGS); do \ - if [ -e i18n/$$$$lang.po ]; then \ + if [ -e $(2)/$$$$lang.po ]; then \ rm -f $$(PKG_BUILD_DIR)/i18n/$(1).$$$$lang.lmo; \ - $(GLUON_PO2LMO) i18n/$$$$lang.po $$(PKG_BUILD_DIR)/i18n/$(1).$$$$lang.lmo; \ + $(GLUON_PO2LMO) $(2)/$$$$lang.po $$(PKG_BUILD_DIR)/i18n/$(1).$$$$lang.lmo; \ fi; \ done endef From 267831b04dd6168c3f4afbca286507ff4aaef737 Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Thu, 19 Mar 2015 19:08:41 +0100 Subject: [PATCH 09/32] Remove now unused md5sum.sh script --- Makefile | 1 - scripts/md5sum.sh | 18 ------------------ 2 files changed, 19 deletions(-) delete mode 100755 scripts/md5sum.sh diff --git a/Makefile b/Makefile index f341f36c..09be32c5 100644 --- a/Makefile +++ b/Makefile @@ -245,7 +245,6 @@ clean: FORCE rm -f $(gluon_prepared_stamp) -export MD5SUM := $(GLUONDIR)/scripts/md5sum.sh export SHA512SUM := $(GLUONDIR)/scripts/sha512sum.sh diff --git a/scripts/md5sum.sh b/scripts/md5sum.sh deleted file mode 100755 index 61600583..00000000 --- a/scripts/md5sum.sh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh - -check_command() { - which $1 >/dev/null 2>&1 -} - -if check_command md5sum; then - ret="$(md5sum "$@")" -elif check_command md5; then - ret="$(md5 -q "$@")" -else - echo "$0: no suitable md5sum implementation was found" >&1 - exit 1 -fi - -[ "$?" -eq 0 ] || exit 1 - -echo "$ret" | awk '{ print $1 }' From 34b34d0c3f055f6923da47c8cf3edcdf66ab11be Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Thu, 19 Mar 2015 21:29:30 +0100 Subject: [PATCH 10/32] luci: fall back to English if no language matches --- ...none-provided-by-the-browser-matches.patch | 28 +++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 patches/packages/luci/0002-modules-base-dispatcher-set-default-language-if-none-provided-by-the-browser-matches.patch diff --git a/patches/packages/luci/0002-modules-base-dispatcher-set-default-language-if-none-provided-by-the-browser-matches.patch b/patches/packages/luci/0002-modules-base-dispatcher-set-default-language-if-none-provided-by-the-browser-matches.patch new file mode 100644 index 00000000..2e1da79c --- /dev/null +++ b/patches/packages/luci/0002-modules-base-dispatcher-set-default-language-if-none-provided-by-the-browser-matches.patch @@ -0,0 +1,28 @@ +From: Matthias Schiffer +Date: Thu, 19 Mar 2015 18:44:52 +0100 +Subject: modules/base: dispatcher: set default language if none provided by the browser matches + +diff --git a/modules/base/luasrc/dispatcher.lua b/modules/base/luasrc/dispatcher.lua +index f7e16e7..479ac54 100644 +--- a/modules/base/luasrc/dispatcher.lua ++++ b/modules/base/luasrc/dispatcher.lua +@@ -211,6 +211,7 @@ function dispatch(request) + assert(conf.main, + "/etc/config/luci seems to be corrupt, unable to find section 'main'") + ++ local i18n = require "luci.i18n" + local lang = conf.main.lang or "auto" + if lang == "auto" then + local aclang = http.getenv("HTTP_ACCEPT_LANGUAGE") or "" +@@ -222,7 +223,10 @@ function dispatch(request) + end + end + end +- require "luci.i18n".setlanguage(lang) ++ if lang == "auto" then ++ lang = i18n.default ++ end ++ i18n.setlanguage(lang) + + local c = ctx.tree + local stat From 175abc61effa40f94a6a6996e6d7defa18e3c452 Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Thu, 19 Mar 2015 22:23:23 +0100 Subject: [PATCH 11/32] Update gluon packages --- modules | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules b/modules index 771ee9c8..69ed0902 100644 --- a/modules +++ b/modules @@ -8,7 +8,7 @@ PACKAGES_OPENWRT_COMMIT=01fcd1f29174a56d6ddb59901ed8c67ea42c3a8f PACKAGES_OPENWRT_BRANCH=for-14.07 PACKAGES_GLUON_REPO=git://github.com/freifunk-gluon/packages.git -PACKAGES_GLUON_COMMIT=ee6543524020342c05f674a5c0fb77992733829d +PACKAGES_GLUON_COMMIT=c882f286af701efc8ec7c8cb35c0b88366681f86 PACKAGES_ROUTING_REPO=git://github.com/openwrt-routing/packages.git PACKAGES_ROUTING_COMMIT=5d4ad63897b435d5df0f39a49bd58962c22c33b8 From 0f0abd2c7f2684b14a02f1b0f9e1c0f5830ff31a Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Thu, 19 Mar 2015 22:46:01 +0100 Subject: [PATCH 12/32] docs: update site-example for i18n support --- docs/site-example/i18n/de.po | 35 +++++++++++++++++++++++++++++++++ docs/site-example/i18n/en.po | 33 +++++++++++++++++++++++++++++++ docs/site-example/site.conf | 38 ------------------------------------ docs/site-example/site.mk | 3 +++ 4 files changed, 71 insertions(+), 38 deletions(-) create mode 100644 docs/site-example/i18n/de.po create mode 100644 docs/site-example/i18n/en.po diff --git a/docs/site-example/i18n/de.po b/docs/site-example/i18n/de.po new file mode 100644 index 00000000..271172a4 --- /dev/null +++ b/docs/site-example/i18n/de.po @@ -0,0 +1,35 @@ +msgid "" +msgstr "" +"Content-Type: text/plain; charset=UTF-8\n" +"Project-Id-Version: PACKAGE VERSION\n" +"PO-Revision-Date: 2015-03-19 20:28+0100\n" +"Last-Translator: Matthias Schiffer \n" +"Language-Team: German\n" +"Language: de\n" +"MIME-Version: 1.0\n" +"Content-Transfer-Encoding: 8bit\n" +"Plural-Forms: nplurals=2; plural=(n != 1);\n" + +msgid "gluon-config-mode:welcome" +msgstr "" +"Willkommen zum Einrichtungsassistenten für deinen neuen Entenhausener " +"Freifunk-Knoten. Fülle das folgende Formular deinen Vorstellungen " +"entsprechend aus und sende es ab." + +msgid "gluon-config-mode:pubkey" +msgstr "" +"Dies ist der öffentliche Schlüssel deines Freifunk-Knotens. Erst nachdem " +"er auf den Servern des Entenhausener Freifunk-Projektes eingetragen wurde, " +"kann sich dein Knoten mit dem Entenhausener Mesh-VPN zu verbinden. Bitte " +"schicke dazu diesen Schlüssel und den Namen deines Knotens " +"(<%=hostname%>) an " +"keys@entenhausen.freifunk.net." + +msgid "gluon-config-mode:reboot" +msgstr "" +"

Dein Knoten startet gerade neu und wird anschließend versuchen, " +"sich mit anderen Freifunkknoten in seiner Nähe zu " +"verbinden. Weitere Informationen zur " +"Entenhausener Freifunk-Community findest du auf " +"unserer Webseite.

" +"

Viel Spaß mit deinem Knoten und der Erkundung von Freifunk!

" diff --git a/docs/site-example/i18n/en.po b/docs/site-example/i18n/en.po new file mode 100644 index 00000000..bfbbc882 --- /dev/null +++ b/docs/site-example/i18n/en.po @@ -0,0 +1,33 @@ +msgid "" +msgstr "" +"Content-Type: text/plain; charset=UTF-8\n" +"Project-Id-Version: PACKAGE VERSION\n" +"PO-Revision-Date: 2015-03-19 20:28+0100\n" +"Last-Translator: Matthias Schiffer \n" +"Language-Team: English\n" +"Language: en\n" +"MIME-Version: 1.0\n" +"Content-Transfer-Encoding: 8bit\n" +"Plural-Forms: nplurals=2; plural=(n != 1);\n" + +msgid "gluon-config-mode:welcome" +msgstr "" +"Welcome the the setup wizard of your new Freifunk Duckburg node. " +"Please fill out the following form and transmit it." + +msgid "gluon-config-mode:pubkey" +msgstr "" +"This is your Freifunk node's public key. The node won't be able to " +"connect to the mesh VPN until the key has been registered on the Freifunk " +"Duckburg servers. " +"To register the key send it together with your node's name (<%=hostname%>) to " +"keys@entenhausen.freifunk.net." + + +msgid "gluon-config-mode:reboot" +msgstr "" +"

The node is currently rebooting and will try to connect to other " +"nearby Freifunk nodes after that. " +"Your can find lots of information on the Freifunk Duckburg community on " +"our homepage.

" +"

Have fun with your node and exploring the Freifunk network!

" diff --git a/docs/site-example/site.conf b/docs/site-example/site.conf index b6f3246d..ca691342 100644 --- a/docs/site-example/site.conf +++ b/docs/site-example/site.conf @@ -166,42 +166,4 @@ -- setup_mode = { -- skip = true, -- }, - - -- These strings are shown in config mode. Some HTML is permissible. - -- - -- msg_welcome: shown at startup - -- msg_pubkey: shown when VPN is enabled - -- msg_reboot: shown during reboot (after finishing configuration) - -- - -- You may use some variables, e.g.: - -- - -- <%=hostname%> - the node's hostname - -- <%=pubkey%> - the fastd public key - -- <%=sysconfig.primary_mac%> - the node's primary MAC - config_mode = { - msg_welcome = [[ -Willkommen zum Einrichtungsassistenten für deinen neuen Entenhausener -Freifunk-Knoten. Fülle das folgende Formular deinen Vorstellungen -entsprechend aus und sende es ab. -]], - msg_pubkey = [[ -Dies ist der öffentliche Schlüssel deines Freifunk-Knotens. Erst nachdem -er auf den Servern des Entenhausener Freifunk-Projektes eingetragen wurde, -kann sich dein Knoten mit dem Entenhausener Mesh-VPN verbinden. Bitte -schicke dazu diesen Schlüssel und den Namen deines Knotens -(<%=hostname%>) an -keys@entenhausen.freifunk.net. -]], - msg_reboot = [[ -

-Dein Knoten startet gerade neu und wird anschließend versuchen, -sich mit anderen Freifunk-Knoten in seiner Nähe zu verbinden. -Weitere Informationen zur Entenhausener Freifunk-Community -findest du auf unserer Webseite. -

-

-Viel Spaß mit deinem Knoten und der Erkundung von Freifunk! -

-]], - }, } diff --git a/docs/site-example/site.mk b/docs/site-example/site.mk index e9dfb543..e03be578 100644 --- a/docs/site-example/site.mk +++ b/docs/site-example/site.mk @@ -48,3 +48,6 @@ GLUON_RELEASE ?= $(DEFAULT_GLUON_RELEASE) # Default priority for updates. GLUON_PRIORITY ?= 0 + +# Languages to include +GLUON_LANGS ?= en de From 2538b1b1083793266755f16595acbe277df1436b Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Thu, 19 Mar 2015 22:59:51 +0100 Subject: [PATCH 13/32] docs: add POT file to site example --- docs/site-example/i18n/gluon-site.pot | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 docs/site-example/i18n/gluon-site.pot diff --git a/docs/site-example/i18n/gluon-site.pot b/docs/site-example/i18n/gluon-site.pot new file mode 100644 index 00000000..670de410 --- /dev/null +++ b/docs/site-example/i18n/gluon-site.pot @@ -0,0 +1,11 @@ +msgid "" +msgstr "Content-Type: text/plain; charset=UTF-8" + +msgid "gluon-config-mode:welcome" +msgstr "" + +msgid "gluon-config-mode:pubkey" +msgstr "" + +msgid "gluon-config-mode:reboot" +msgstr "" From a2e88140c0315f2eb3f30605e6b2692ac497f128 Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Thu, 19 Mar 2015 23:09:40 +0100 Subject: [PATCH 14/32] docs: update site documentation for new i18n support --- docs/user/getting_started.rst | 8 +++---- docs/user/site.rst | 39 ++++++++++++++++++++++++++++++++--- 2 files changed, 39 insertions(+), 8 deletions(-) diff --git a/docs/user/getting_started.rst b/docs/user/getting_started.rst index 14848af6..1f18186e 100644 --- a/docs/user/getting_started.rst +++ b/docs/user/getting_started.rst @@ -47,17 +47,15 @@ So let's create the directory *site/*: mkdir site cd site -Copy *site.conf* and *site.mk* from *docs/site-example*: +Copy *site.conf*, *site.mk* and *i18n* from *docs/site-example*: :: cp ../docs/site-example/site.conf . cp ../docs/site-example/site.mk . + cp -r ../docs/site-example/i18n . -.. note:: On **v2014.3**, take both files from - https://github.com/freifunk-gluon/gluon/tree/2014.3.x/docs/site-example - -Edit both files to match your community, then go back to the top-level Gluon +Edit these files to match your community, then go back to the top-level Gluon directory and build Gluon: :: diff --git a/docs/user/site.rst b/docs/user/site.rst index b2ebbaa0..90b70bdd 100644 --- a/docs/user/site.rst +++ b/docs/user/site.rst @@ -180,9 +180,6 @@ setup_mode : package skip = true, }, -config_mode : package - Configuration Mode text blocks - legacy : package Configuration for the legacy upgrade path. This is only required in communities upgrading from Lübeck's LFF-0.3.x. @@ -215,6 +212,30 @@ GLUON_PRIORITY The default priority for the generated manifests (see the autoupdater documentation for more information). +GLUON_LANGS + List of languages (as two-letter-codes) to include for the web interface. Should always contain + ``en``. + +Config mode texts +----------------- + +The community-defined texts in the config mode are configured in PO files in the ``i18n`` subdirectory +of the site configuration. The message IDs currently defined are: + +gluon-config-mode:welcome + Welcome text on the top of the config wizard page. + +gluon-config-mode:pubkey + Information about the public VPN key on the reboot page. + +gluon-config-mode:reboot + General information about the reboot page. + +There is a POT file in the site example directory which can be used to create templates +for the language files. The command ``msginit -l en -i ../../docs/site-example/i18n/gluon-site.pot`` +can be used from the ``i18n`` directory to create an initial PO file called ``en.po`` if the ``gettext`` +utilities are installed. + Examples -------- @@ -230,6 +251,18 @@ site.conf .. literalinclude:: ../site-example/site.conf :language: lua +i18n/en.po +^^^^^^^^^^ + +.. literalinclude:: ../site-example/i18n/en.po + :language: po + +i18n/de.po +^^^^^^^^^^ + +.. literalinclude:: ../site-example/i18n/de.po + :language: po + modules ^^^^^^^ From c059c980744520c9febd98c527ab86954c65413a Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Fri, 20 Mar 2015 00:55:22 +0100 Subject: [PATCH 15/32] build: make manifest generation more robust --- Makefile | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index 09be32c5..ba07ae00 100644 --- a/Makefile +++ b/Makefile @@ -89,19 +89,20 @@ manifest: FORCE @echo '$(GLUON_PRIORITY)' | grep -qE '^([0-9]*\.)?[0-9]+$$' || (echo 'Please specify a numeric value for GLUON_PRIORITY to create a manifest.'; false) @$(CheckExternal) - mkdir -p $(GLUON_IMAGEDIR)/sysupgrade - ( \ echo 'BRANCH=$(GLUON_BRANCH)' && \ echo 'DATE=$(shell $(GLUON_ORIGOPENWRTDIR)/staging_dir/host/bin/lua $(GLUONDIR)/scripts/rfc3339date.lua)' && \ echo 'PRIORITY=$(GLUON_PRIORITY)' && \ echo \ - ) > $(GLUON_IMAGEDIR)/sysupgrade/$(GLUON_BRANCH).manifest + ) > $(GLUON_BUILDDIR)/$(GLUON_BRANCH).manifest.tmp +($(foreach GLUON_TARGET,$(GLUON_TARGETS), \ ( [ ! -e $(BOARD_BUILDDIR)/prepared ] || ( $(GLUONMAKE) manifest GLUON_TARGET='$(GLUON_TARGET)' V=s$(OPENWRT_VERBOSE) ) ) && \ ) :) + mkdir -p $(GLUON_IMAGEDIR)/sysupgrade + mv $(GLUON_BUILDDIR)/$(GLUON_BRANCH).manifest.tmp $(GLUON_IMAGEDIR)/sysupgrade/$(GLUON_BRANCH).manifest + dirclean : FORCE for dir in build_dir dl staging_dir tmp; do \ rm -rf $(GLUON_ORIGOPENWRTDIR)/$$dir; \ @@ -394,7 +395,7 @@ manifest: FORCE [ -e "$$file" ] && echo '$(model)' "$(PREPARED_RELEASE)" "$$($(SHA512SUM) "$$file")" "$$file"; \ ) \ ) : \ - ) >> $(GLUON_IMAGEDIR)/sysupgrade/$(GLUON_BRANCH).manifest + ) >> $(GLUON_BUILDDIR)/$(GLUON_BRANCH).manifest.tmp .PHONY: all images prepare clean gluon-tools manifest From c676934e88034d7ca523729713a0257c0c7b1930 Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Fri, 20 Mar 2015 01:34:02 +0100 Subject: [PATCH 16/32] build: don't enable all kernel modules in the general OpenWrt .config With this change, there are two OpenWrt config files: one for the packages actually used by Gluon, and one with all kernel modules enabled (like it was since we removed the static kernel configs). The config with all kernel modules is only used to generate the kernel configuration (so it is compatible with the upstream kernel). This should bring the build times back to what they were before the static configs were removed. --- Makefile | 19 +++++++++++++++---- include/Makefile.target | 15 ++++++++++++++- include/config | 2 -- include/gluon.mk | 2 ++ 4 files changed, 31 insertions(+), 7 deletions(-) diff --git a/Makefile b/Makefile index ba07ae00..4999ff1e 100644 --- a/Makefile +++ b/Makefile @@ -183,6 +183,9 @@ gluon-tools: FORCE +$(GLUONMAKE_EARLY) tools/sed/install +$(GLUONMAKE_EARLY) package/lua/host/install +scripts/config/conf: + @$(_SINGLE)$(SUBMAKE) -s -C scripts/config conf CC="$(HOSTCC_WRAPPER)" + prepare-tmpinfo: FORCE mkdir -p tmp/info $(_SINGLE)$(NO_TRACE_MAKE) -j1 -r -s -f include/scan.mk SCAN_TARGET="packageinfo" SCAN_DIR="package" SCAN_NAME="package" SCAN_DEPS="$(TOPDIR)/include/package*.mk $(TOPDIR)/overlay/*/*.mk" SCAN_EXTRA="" @@ -191,7 +194,9 @@ prepare-tmpinfo: FORCE f=tmp/.$${type}info; t=tmp/.config-$${type}.in; \ [ "$$t" -nt "$$f" ] || ./scripts/metadata.pl $${type}_config "$$f" > "$$t" || { rm -f "$$t"; echo "Failed to build $$t"; false; break; }; \ done + [ tmp/.config-feeds.in -nt tmp/.packagefeeds ] || ./scripts/feeds feed_config > tmp/.config-feeds.in ./scripts/metadata.pl package_mk tmp/.packageinfo > tmp/.packagedeps || { rm -f tmp/.packagedeps; false; } + ./scripts/metadata.pl package_feeds tmp/.packageinfo > tmp/.packagefeeds || { rm -f tmp/.packagefeeds; false; } touch $(TOPDIR)/tmp/.build feeds: FORCE @@ -201,7 +206,7 @@ feeds: FORCE . $(GLUONDIR)/modules && for feed in $$GLUON_FEEDS; do ln -s ../../../packages/$$feed $(TOPDIR)/package/feeds/$$feed; done +$(GLUONMAKE_EARLY) prepare-tmpinfo -config: FORCE +config: scripts/config/conf FORCE +$(GLUONMAKE) prepare-tmpinfo ( \ cat $(GLUONDIR)/include/config $(GLUONDIR)/targets/$(GLUON_TARGET)/config; \ @@ -209,8 +214,15 @@ config: FORCE | sed -e 's/ /\n/g'; \ echo '$(patsubst %,CONFIG_GLUON_LANG_%=y,$(GLUON_LANGS))' \ | sed -e 's/ /\n/g'; \ - ) > .config - +$(NO_TRACE_MAKE) defconfig OPENWRT_BUILD=0 + ) > $(BOARD_BUILDDIR)/config.tmp + scripts/config/conf --defconfig=$(BOARD_BUILDDIR)/config.tmp Config.in + mv .config $(BOARD_BUILDDIR)/config + + echo 'CONFIG_ALL_KMODS=y' >> $(BOARD_BUILDDIR)/config.tmp + scripts/config/conf --defconfig=$(BOARD_BUILDDIR)/config.tmp Config.in + mv .config $(BOARD_BUILDDIR)/config-allmods + + cp $(BOARD_BUILDDIR)/config .config prepare-target: FORCE rm $(GLUON_OPENWRTDIR)/tmp || true @@ -299,7 +311,6 @@ PROFILE_BUILDDIR = $(BOARD_BUILDDIR)/$(PROFILE) PROFILE_KDIR = $(PROFILE_BUILDDIR)/kernel BIN_DIR = $(PROFILE_BUILDDIR)/images -TMP_DIR = $(PROFILE_BUILDDIR)/tmp TARGET_DIR = $(PROFILE_BUILDDIR)/root PREPARED_RELEASE = $$(cat $(gluon_prepared_stamp)) diff --git a/include/Makefile.target b/include/Makefile.target index f2b898da..19370e52 100644 --- a/include/Makefile.target +++ b/include/Makefile.target @@ -1,5 +1,18 @@ +# code adjusted from openwrt/include/kernel-defaults.mk + override define Kernel/Configure - $(call Kernel/Configure/Default) + $(LINUX_CONF_CMD) > $(LINUX_DIR)/.config.target +# copy CONFIG_KERNEL_* settings over to .config.target + awk '/^(#[[:space:]]+)?CONFIG_KERNEL/{sub("CONFIG_KERNEL_","CONFIG_");print}' $(BOARD_BUILDDIR)/config-allmods >> $(LINUX_DIR)/.config.target + echo "# CONFIG_KALLSYMS_EXTRA_PASS is not set" >> $(LINUX_DIR)/.config.target + echo "# CONFIG_KALLSYMS_ALL is not set" >> $(LINUX_DIR)/.config.target + echo "# CONFIG_KALLSYMS_UNCOMPRESSED is not set" >> $(LINUX_DIR)/.config.target + echo "# CONFIG_KPROBES is not set" >> $(LINUX_DIR)/.config.target + $(SCRIPT_DIR)/metadata.pl kconfig $(TMP_DIR)/.packageinfo $(BOARD_BUILDDIR)/config-allmods > $(LINUX_DIR)/.config.override + $(SCRIPT_DIR)/kconfig.pl 'm+' '+' $(LINUX_DIR)/.config.target /dev/null $(LINUX_DIR)/.config.override > $(LINUX_DIR)/.config + $(call Kernel/SetNoInitramfs) + rm -rf $(KERNEL_BUILD_DIR)/modules + $(_SINGLE) [ -d $(LINUX_DIR)/user_headers ] || $(MAKE) $(KERNEL_MAKEOPTS) INSTALL_HDR_PATH=$(LINUX_DIR)/user_headers headers_install cp $(GLUONDIR)/targets/$(GLUON_TARGET)/vermagic $(LINUX_DIR)/.vermagic endef diff --git a/include/config b/include/config index 8a74d047..ac754391 100644 --- a/include/config +++ b/include/config @@ -1,5 +1,3 @@ -CONFIG_ALL_KMODS=y - CONFIG_IMAGEOPT=y # CONFIG_PER_FEED_REPO is not set diff --git a/include/gluon.mk b/include/gluon.mk index e0c6b49b..88db6f42 100644 --- a/include/gluon.mk +++ b/include/gluon.mk @@ -14,6 +14,8 @@ export GLUONDIR GLUON_SITEDIR GLUON_SITE_CONFIG GLUON_IMAGEDIR GLUON_BUILDDIR BOARD_BUILDDIR = $(GLUON_BUILDDIR)/$(GLUON_TARGET) BOARD_KDIR = $(BOARD_BUILDDIR)/kernel +export BOARD_BUILDDIR + GLUON_OPENWRTDIR = $(BOARD_BUILDDIR)/openwrt From 5faca867c4eb7c1e4cec930d8a922115a13fd7ce Mon Sep 17 00:00:00 2001 From: Jan-Philipp Litza Date: Sat, 21 Mar 2015 13:53:05 +0100 Subject: [PATCH 17/32] Document changes to hostname_prefix field of site.conf --- docs/releases/v2015.1.rst | 30 ++++++++++++++++++++++++++++++ docs/site-example/site.conf | 4 ++-- 2 files changed, 32 insertions(+), 2 deletions(-) create mode 100644 docs/releases/v2015.1.rst diff --git a/docs/releases/v2015.1.rst b/docs/releases/v2015.1.rst new file mode 100644 index 00000000..8ce3db0f --- /dev/null +++ b/docs/releases/v2015.1.rst @@ -0,0 +1,30 @@ +Gluon 2015.1 (in development) +============================= + +Added (and removed) hardware support +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + + +New features +~~~~~~~~~~~~ + + +Bugfixes +~~~~~~~~ + + +Site changes +~~~~~~~~~~~~ +* ``site.conf`` + + - ``hostname_prefix`` is now optional, and is concatenated directly with the + generated node ID, in particular no hyphen is inserted anymore. If you want + to keep the old behaviour, you have to append the hyphen to the + ``hostname_prefix`` field of your ``site.conf``. + +Internals +~~~~~~~~~ + + +Known Issues +~~~~~~~~~~~~ diff --git a/docs/site-example/site.conf b/docs/site-example/site.conf index ca691342..48e651e9 100644 --- a/docs/site-example/site.conf +++ b/docs/site-example/site.conf @@ -6,8 +6,8 @@ -- This configuration will not work as it. You're required to make -- community specific changes to it! { - -- Used for generated hostnames, e.g. freifunk-abcdef123456. - hostname_prefix = 'freifunk', + -- Used for generated hostnames, e.g. freifunk-abcdef123456. (optional) + -- hostname_prefix = 'freifunk-', -- Name of the community. site_name = 'Freifunk Entenhausen', From a320ef7d5f8b9335e849630466214fcc40721da6 Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Sat, 21 Mar 2015 14:49:55 +0100 Subject: [PATCH 18/32] Delegate scripts/config/conf build to OpenWrt makefile Otherwise some dependencies aren't respected. --- Makefile | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index 4999ff1e..c0c369ff 100644 --- a/Makefile +++ b/Makefile @@ -183,9 +183,6 @@ gluon-tools: FORCE +$(GLUONMAKE_EARLY) tools/sed/install +$(GLUONMAKE_EARLY) package/lua/host/install -scripts/config/conf: - @$(_SINGLE)$(SUBMAKE) -s -C scripts/config conf CC="$(HOSTCC_WRAPPER)" - prepare-tmpinfo: FORCE mkdir -p tmp/info $(_SINGLE)$(NO_TRACE_MAKE) -j1 -r -s -f include/scan.mk SCAN_TARGET="packageinfo" SCAN_DIR="package" SCAN_NAME="package" SCAN_DEPS="$(TOPDIR)/include/package*.mk $(TOPDIR)/overlay/*/*.mk" SCAN_EXTRA="" @@ -206,7 +203,8 @@ feeds: FORCE . $(GLUONDIR)/modules && for feed in $$GLUON_FEEDS; do ln -s ../../../packages/$$feed $(TOPDIR)/package/feeds/$$feed; done +$(GLUONMAKE_EARLY) prepare-tmpinfo -config: scripts/config/conf FORCE +config: FORCE + +$(NO_TRACE_MAKE) scripts/config/conf +$(GLUONMAKE) prepare-tmpinfo ( \ cat $(GLUONDIR)/include/config $(GLUONDIR)/targets/$(GLUON_TARGET)/config; \ From f5736274621bdb8fc41c277d474dc293bda077e4 Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Sat, 21 Mar 2015 16:41:37 +0100 Subject: [PATCH 19/32] base-files: disable reset button handling This conflicts with our reset button usage. --- ...-files-disable-reset-button-handling.patch | 30 +++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 patches/openwrt/0031-base-files-disable-reset-button-handling.patch diff --git a/patches/openwrt/0031-base-files-disable-reset-button-handling.patch b/patches/openwrt/0031-base-files-disable-reset-button-handling.patch new file mode 100644 index 00000000..4a601eda --- /dev/null +++ b/patches/openwrt/0031-base-files-disable-reset-button-handling.patch @@ -0,0 +1,30 @@ +From: Matthias Schiffer +Date: Sat, 21 Mar 2015 16:40:52 +0100 +Subject: base-files: disable reset button handling + +This conflicts with our reset button usage. + +diff --git a/package/base-files/files/etc/rc.button/reset b/package/base-files/files/etc/rc.button/reset +deleted file mode 100755 +index 229b503..0000000 +--- a/package/base-files/files/etc/rc.button/reset ++++ /dev/null +@@ -1,18 +0,0 @@ +-#!/bin/sh +- +-[ "${ACTION}" = "released" ] || exit 0 +- +-. /lib/functions.sh +- +-logger "$BUTTON pressed for $SEEN seconds" +- +-if [ "$SEEN" -lt 1 ] +-then +- echo "REBOOT" > /dev/console +- sync +- reboot +-elif [ "$SEEN" -gt 5 ] +-then +- echo "FACTORY RESET" > /dev/console +- jffs2reset -y && reboot & +-fi From 352212b323cac28a10b9be1c5377cfc6725a9548 Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Sat, 21 Mar 2015 17:08:22 +0100 Subject: [PATCH 20/32] Update gluon packages --- modules | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules b/modules index 69ed0902..6c36abcf 100644 --- a/modules +++ b/modules @@ -8,7 +8,7 @@ PACKAGES_OPENWRT_COMMIT=01fcd1f29174a56d6ddb59901ed8c67ea42c3a8f PACKAGES_OPENWRT_BRANCH=for-14.07 PACKAGES_GLUON_REPO=git://github.com/freifunk-gluon/packages.git -PACKAGES_GLUON_COMMIT=c882f286af701efc8ec7c8cb35c0b88366681f86 +PACKAGES_GLUON_COMMIT=ecdaf09b3b1cbd114d3e16dd95689819aa954f00 PACKAGES_ROUTING_REPO=git://github.com/openwrt-routing/packages.git PACKAGES_ROUTING_COMMIT=5d4ad63897b435d5df0f39a49bd58962c22c33b8 From 8aca9222efa2774c8e124554bd2792c747c6e746 Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Sat, 21 Mar 2015 18:42:24 +0100 Subject: [PATCH 21/32] build: fix scripts/config/conf build --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index c0c369ff..067b5733 100644 --- a/Makefile +++ b/Makefile @@ -204,7 +204,7 @@ feeds: FORCE +$(GLUONMAKE_EARLY) prepare-tmpinfo config: FORCE - +$(NO_TRACE_MAKE) scripts/config/conf + +$(NO_TRACE_MAKE) scripts/config/conf OPENWRT_BUILD=0 +$(GLUONMAKE) prepare-tmpinfo ( \ cat $(GLUONDIR)/include/config $(GLUONDIR)/targets/$(GLUON_TARGET)/config; \ From ff05a1f3ca61a3d60e3a3fcce7824427ab6de2b4 Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Sat, 21 Mar 2015 18:46:46 +0100 Subject: [PATCH 22/32] build: don't delete TMP_DIR during image generation --- Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 067b5733..7a137977 100644 --- a/Makefile +++ b/Makefile @@ -365,8 +365,8 @@ opkg_config: FORCE image: FORCE - rm -rf $(TARGET_DIR) $(BIN_DIR) $(TMP_DIR) $(PROFILE_KDIR) - mkdir -p $(TARGET_DIR) $(BIN_DIR) $(TMP_DIR) $(TARGET_DIR)/tmp $(GLUON_IMAGEDIR)/factory $(GLUON_IMAGEDIR)/sysupgrade + rm -rf $(TARGET_DIR) $(BIN_DIR) $(PROFILE_KDIR) + mkdir -p $(TARGET_DIR) $(BIN_DIR) $(TARGET_DIR)/tmp $(GLUON_IMAGEDIR)/factory $(GLUON_IMAGEDIR)/sysupgrade cp -r $(BOARD_KDIR) $(PROFILE_KDIR) +$(GLUONMAKE) package_install From 8fc4a037ffdf439090557d0d8d8fb9a1e6eb9030 Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Sat, 21 Mar 2015 18:47:57 +0100 Subject: [PATCH 23/32] Update gluon packages --- modules | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules b/modules index 6c36abcf..04b9b5b2 100644 --- a/modules +++ b/modules @@ -8,7 +8,7 @@ PACKAGES_OPENWRT_COMMIT=01fcd1f29174a56d6ddb59901ed8c67ea42c3a8f PACKAGES_OPENWRT_BRANCH=for-14.07 PACKAGES_GLUON_REPO=git://github.com/freifunk-gluon/packages.git -PACKAGES_GLUON_COMMIT=ecdaf09b3b1cbd114d3e16dd95689819aa954f00 +PACKAGES_GLUON_COMMIT=f5c0865d5025a7e6ad3ff6c21ca5206ac972ba75 PACKAGES_ROUTING_REPO=git://github.com/openwrt-routing/packages.git PACKAGES_ROUTING_COMMIT=5d4ad63897b435d5df0f39a49bd58962c22c33b8 From e719df04bf04bd40a0344e13c2ee277714a843bf Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Sat, 21 Mar 2015 19:04:51 +0100 Subject: [PATCH 24/32] build: move profile build directories to a new subdir --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 7a137977..39f58781 100644 --- a/Makefile +++ b/Makefile @@ -305,7 +305,7 @@ include $(INCLUDE_DIR)/package-ipkg.mk # override variables from rules.mk PACKAGE_DIR = $(GLUON_OPENWRTDIR)/bin/$(BOARD)/packages -PROFILE_BUILDDIR = $(BOARD_BUILDDIR)/$(PROFILE) +PROFILE_BUILDDIR = $(BOARD_BUILDDIR)/profiles/$(PROFILE) PROFILE_KDIR = $(PROFILE_BUILDDIR)/kernel BIN_DIR = $(PROFILE_BUILDDIR)/images From a11d4a56b0e06987e15bde72b13185634fffce18 Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Sat, 21 Mar 2015 21:33:42 +0100 Subject: [PATCH 25/32] Use different BUILD_DIRs and STAGING_DIRs for different targets --- Makefile | 1 + include/config | 2 ++ 2 files changed, 3 insertions(+) diff --git a/Makefile b/Makefile index 39f58781..b5f4305b 100644 --- a/Makefile +++ b/Makefile @@ -208,6 +208,7 @@ config: FORCE +$(GLUONMAKE) prepare-tmpinfo ( \ cat $(GLUONDIR)/include/config $(GLUONDIR)/targets/$(GLUON_TARGET)/config; \ + echo 'CONFIG_BUILD_SUFFIX="gluon-$(GLUON_TARGET)"'; \ echo '$(patsubst %,CONFIG_PACKAGE_%=m,$(sort $(filter-out -%,$(GLUON_DEFAULT_PACKAGES) $(GLUON_SITE_PACKAGES) $(PROFILE_PACKAGES))))' \ | sed -e 's/ /\n/g'; \ echo '$(patsubst %,CONFIG_GLUON_LANG_%=y,$(GLUON_LANGS))' \ diff --git a/include/config b/include/config index ac754391..faab30c8 100644 --- a/include/config +++ b/include/config @@ -1,6 +1,8 @@ CONFIG_IMAGEOPT=y # CONFIG_PER_FEED_REPO is not set +CONFIG_DEVEL=y + CONFIG_BUSYBOX_CUSTOM=y CONFIG_BUSYBOX_CONFIG_SHA512SUM=y # CONFIG_BUSYBOX_CONFIG_FEATURE_PREFER_IPV4_ADDRESS is not set From a6cd3a387e8557142c6636f4d360ad7819613f00 Mon Sep 17 00:00:00 2001 From: hexa- Date: Mon, 23 Mar 2015 20:49:21 +0100 Subject: [PATCH 26/32] site.rst: document ingress/egress unit in simple_tc --- docs/user/site.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/user/site.rst b/docs/user/site.rst index 5c8679bb..e0ec5aa3 100644 --- a/docs/user/site.rst +++ b/docs/user/site.rst @@ -138,7 +138,7 @@ autoupdater : package } simple_tc : package - Uplink traffic control + Uplink traffic control, ingress and egress values are specified in kbit/s. :: simple_tc = { From 5415806f334a019480935db2fc105a4772984ac4 Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Mon, 23 Mar 2015 21:33:43 +0100 Subject: [PATCH 27/32] x86: update PARTUUID patch to work with leading zeros --- ...nstead-explicitly-specifying-the-device-by-default.patch | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/patches/openwrt/0026-x86-use-PARTUUID-instead-explicitly-specifying-the-device-by-default.patch b/patches/openwrt/0026-x86-use-PARTUUID-instead-explicitly-specifying-the-device-by-default.patch index bc9e0431..a2e7e7d9 100644 --- a/patches/openwrt/0026-x86-use-PARTUUID-instead-explicitly-specifying-the-device-by-default.patch +++ b/patches/openwrt/0026-x86-use-PARTUUID-instead-explicitly-specifying-the-device-by-default.patch @@ -1,5 +1,5 @@ From: Matthias Schiffer -Date: Sun, 15 Mar 2015 17:01:32 +0100 +Date: Mon, 23 Mar 2015 21:11:41 +0100 Subject: x86: use PARTUUID instead explicitly specifying the device by default This changes the x86 image generation to match x86_64, using the PARTUUID for @@ -143,14 +143,14 @@ index a2dd20a..73ab5ef 100644 + fi } diff --git a/target/linux/x86/image/Makefile b/target/linux/x86/image/Makefile -index 5983718..a0045a7 100644 +index 5983718..1f91b9f 100644 --- a/target/linux/x86/image/Makefile +++ b/target/linux/x86/image/Makefile @@ -40,7 +40,9 @@ ifneq ($(GRUB_TERMINALS),) GRUB_TERMINAL_CONFIG := terminal_input $(GRUB_TERMINALS); terminal_output $(GRUB_TERMINALS) endif -+SIGNATURE:=$(shell dd if=/dev/urandom bs=4 count=1 2>/dev/null | hexdump -v -e '"%02x"') ++SIGNATURE:=$(shell dd if=/dev/urandom bs=4 count=1 2>/dev/null | hexdump -v -e '"%08x"') ROOTPART:=$(call qstrip,$(CONFIG_TARGET_ROOTFS_PARTNAME)) +ROOTPART:=$(if $(ROOTPART),$(ROOTPART),PARTUUID=$(SIGNATURE)-02) From 013a1500ff1549c4e4002a846ce068e9af91cf5a Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Wed, 25 Mar 2015 18:53:46 +0100 Subject: [PATCH 28/32] docs: update version number to 2014.4+ --- docs/conf.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/conf.py b/docs/conf.py index d77832bf..4cf0a96e 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -54,9 +54,9 @@ copyright = '2014, Project Gluon' # built documents. # # The short X.Y version. -version = '2014.3' +version = '2014.4+' # The full version, including alpha/beta/rc tags. -release = '2014.3' +release = '2014.4+' # The language for content autogenerated by Sphinx. Refer to documentation # for a list of supported languages. From b7d256b69d272b051801f981151d5bd446b6d063 Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Wed, 25 Mar 2015 18:54:52 +0100 Subject: [PATCH 29/32] docs: add releases/v2015.1 to TOC tree --- docs/index.rst | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/index.rst b/docs/index.rst index c7e60ee8..a53c0a8d 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -98,6 +98,7 @@ Releases .. toctree:: :maxdepth: 1 + releases/v2015.1 releases/v2014.4 releases/v2014.3.1 releases/v2014.3 From 6bad3e385a371e22a6b3617e4de4a64b0b495dc9 Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Wed, 25 Mar 2015 19:14:18 +0100 Subject: [PATCH 30/32] docs: updates to "Getting Started" --- docs/user/getting_started.rst | 25 ++++++++++++++++++------- 1 file changed, 18 insertions(+), 7 deletions(-) diff --git a/docs/user/getting_started.rst b/docs/user/getting_started.rst index 1f18186e..adbec026 100644 --- a/docs/user/getting_started.rst +++ b/docs/user/getting_started.rst @@ -20,11 +20,25 @@ configuration located in *docs/site-example/*. .. _Git tags: http://git-scm.com/book/en/Git-Basics-Tagging .. _list of gluon releases: https://github.com/freifunk-gluon/gluon/releases -Building the image ------------------- +Dependencies +------------ +To build Gluon, several packages need to be installed on the system. On a +freshly installed Debian Wheezy system the following packages are required: + +* `git` (to get Gluon and other dependencies) +* `subversion` +* `build-essential` +* `gawk` +* `unzip` +* `libncurses-dev` (actually `libncurses5-dev`) +* `libz-dev` (actually `zlib1g-dev`) + + +Building the images +------------------- To build Gluon, first check out the repository. Replace *RELEASE* with the -version you'd like to checkout, e.g. *v2014.3*. +version you'd like to checkout, e.g. *v2014.4*. :: @@ -75,10 +89,7 @@ images are to be used when flashing from the original firmware a device came wit and sysupgrade is to upgrade from other versions of Gluon or any other OpenWRT-based system. -For the build reserve 6GB of disk space. The build requires packages -for `subversion`, ncurses headers (`libncurses-dev`) and zlib headers -(`libz-dev`). - +You should reserve about 10GB of disk space for each `GLUON_TARGET`. There are two levels of `make clean`: From 9449f0f5d8b76a832638183ba08096bb163f9230 Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Sun, 29 Mar 2015 14:06:56 +0200 Subject: [PATCH 31/32] Update NETGEAR WNDR3700/3800 model string detection patch --- ...ion-on-NETGEAR-WNDR3700-3800-WNDRMAC.patch | 65 +++++++++++-------- 1 file changed, 39 insertions(+), 26 deletions(-) diff --git a/patches/openwrt/0027-ar71xx-fix-model-string-detection-on-NETGEAR-WNDR3700-3800-WNDRMAC.patch b/patches/openwrt/0027-ar71xx-fix-model-string-detection-on-NETGEAR-WNDR3700-3800-WNDRMAC.patch index a6868085..f4051a2d 100644 --- a/patches/openwrt/0027-ar71xx-fix-model-string-detection-on-NETGEAR-WNDR3700-3800-WNDRMAC.patch +++ b/patches/openwrt/0027-ar71xx-fix-model-string-detection-on-NETGEAR-WNDR3700-3800-WNDRMAC.patch @@ -1,51 +1,64 @@ From: Matthias Schiffer -Date: Sun, 15 Mar 2015 19:51:15 +0100 +Date: Sun, 29 Mar 2015 13:23:26 +0200 Subject: ar71xx: fix model string detection on NETGEAR WNDR3700/3800/WNDRMAC There were a few issues with the existing code to detect the model string: * Always using the string starting with byte 56 would cut off the W of WNDR when - the ID starts with 29763654+16+128 instead of 29763654+16+64 + the ID starts with 29763654+16+64 instead of 29763654+16+128 * The string contained garbage after the zero byte instead of cutting it off after the zero (which wasn't always visible using busybox tools, but could confuse other scripts) +Tested on a WNDR3700v1 and a WNDR3700v2 using the new 29763654+16+64 ID in the +ART. Furthermore, tested against ART dumps of a WNDR3700v2 using the old +$'\xff...' value and a WNDR3800. + +The [ -z "$model" ] check was dropped as there is no way to actually hit this +unless no ART partition is found at all. + +The awk command was carefully crafted to work both with gawk and the (horribly +broken) busybox awk. + +Fixes #18992. + +Signed-off-by: Matthias Schiffer + diff --git a/target/linux/ar71xx/base-files/lib/ar71xx.sh b/target/linux/ar71xx/base-files/lib/ar71xx.sh -index a698ce5..0f9be69 100755 +index a698ce5..1838cb4 100755 --- a/target/linux/ar71xx/base-files/lib/ar71xx.sh +++ b/target/linux/ar71xx/base-files/lib/ar71xx.sh -@@ -37,16 +37,28 @@ wndr3700_board_detect() { +@@ -37,16 +37,26 @@ wndr3700_board_detect() { machine="NETGEAR WNDR3700" ;; "33373031") - local model - model=$(ar71xx_get_mtd_offset_size_format art 56 10 %c) - if [ -z "$model" ] || [ "$model" = $'\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff' ]; then -+ case "$(ar71xx_get_mtd_offset_size_format art 56 10 %c)" in -+ $'\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff') - machine="NETGEAR WNDR3700v2" +- machine="NETGEAR WNDR3700v2" - elif [ -z "$model" ] || [ "$model" = $'\xff\xff\xff\xff\xff\xff\xff\xff\xffN' ]; then -+ ;; -+ $'\xff\xff\xff\xff\xff\xff\xff\xff\xffN') - machine="NETGEAR WNDRMAC" +- machine="NETGEAR WNDRMAC" - else -- machine="NETGEAR $model" -- fi -- ;; ++ # Use awk to remove everything after the first zero byte ++ model="$(ar71xx_get_mtd_offset_size_format art 41 32 %c | awk 'BEGIN{FS="[[:cntrl:]]"} {print $1; exit}')" ++ case $model in ++ $'\xff'*) ++ if [ "${model:24:1}" = 'N' ]; then ++ machine="NETGEAR WNDRMAC" ++ else ++ machine="NETGEAR WNDR3700v2" ++ fi ++ ;; ++ '29763654+16+64'*) ++ machine="NETGEAR ${model:14}" ++ ;; ++ '29763654+16+128'*) ++ machine="NETGEAR ${model:15}" + ;; + *) -+ # Use awk to remove everything after the first zero byte -+ model="$(ar71xx_get_mtd_offset_size_format art 41 32 %c | awk 'BEGIN{FS="[[:cntrl:]]"} {print $1; exit}')" -+ case $model in -+ '29763654+16+64'*) -+ machine="NETGEAR ${model:14}" -+ ;; -+ '29763654+16+128'*) -+ machine="NETGEAR ${model:15}" -+ ;; -+ *) -+ # Unknown ID -+ machine="NETGEAR $model" -+ esac ++ # Unknown ID + machine="NETGEAR $model" +- fi +- ;; + esac esac From a3559a4d322eaf1c48d9ec47775c1b8b4bd9afcf Mon Sep 17 00:00:00 2001 From: Benny Baumann Date: Thu, 26 Mar 2015 20:59:27 +0100 Subject: [PATCH 32/32] contrib/sign.sh: fix handling of filenames with spaces --- contrib/sign.sh | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/contrib/sign.sh b/contrib/sign.sh index a88c52df..082e967e 100755 --- a/contrib/sign.sh +++ b/contrib/sign.sh @@ -18,23 +18,23 @@ See also EOHELP exit 1 fi - -SECRET=$1 - -manifest=$2 -upper=$(mktemp) -lower=$(mktemp) - + +SECRET="$1" + +manifest="$2" +upper="$(mktemp)" +lower="$(mktemp)" + awk "BEGIN { sep=0 } /^---\$/ { sep=1; next } { if(sep==0) print > \"$upper\"; else print > \"$lower\"}" \ - $manifest - -ecdsasign $upper < $SECRET >> $lower - -cat $upper > $manifest -echo --- >> $manifest -cat $lower >> $manifest - -rm -f $upper $lower + "$manifest" + +ecdsasign "$upper" < "$SECRET" >> "$lower" + +cat "$upper" > "$manifest" +echo --- >> "$manifest" +cat "$lower" >> "$manifest" + +rm -f "$upper" "$lower"