From a0fae1f827c948183f099e9b51972fed67c29855 Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Fri, 31 Dec 2021 14:36:30 +0100 Subject: [PATCH 1/2] scripts: target_lib: remove obsolete non-device image handlers All our targets use the OpenWrt device abstraction. Since commit 6ba58c9b17c90e41b521d796ab76e5723ee017170 ("generic: force per-device RootFS") building non-device targets is not possible anymore, so we can remove these obsolete handlers. --- scripts/target_lib.lua | 41 ----------------------------------------- 1 file changed, 41 deletions(-) diff --git a/scripts/target_lib.lua b/scripts/target_lib.lua index 36a6ee91..1c2395e6 100644 --- a/scripts/target_lib.lua +++ b/scripts/target_lib.lua @@ -267,47 +267,6 @@ function F.device(image, name, options) end end -function F.factory_image(image, name, ext, options) - options = merge(default_options, options) - - if not want_device(image, options) then - return - end - - if options.deprecated and not full_deprecated then - return - end - - add_image { - image = image, - name = name, - subdir = 'factory', - in_suffix = '', - out_suffix = '', - extension = ext, - aliases = options.aliases, - } -end - -function F.sysupgrade_image(image, name, ext, options) - options = merge(default_options, options) - - if not want_device(image, options) then - return - end - - add_image { - image = image, - name = name, - subdir = 'sysupgrade', - in_suffix = '', - out_suffix = '-sysupgrade', - extension = ext, - aliases = options.aliases, - manifest_aliases = options.manifest_aliases, - } -end - function F.defaults(options) default_options = merge(default_options, options) end From adda31717660ef0acbe51f6bc79b7635bc6f7ec0 Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Fri, 31 Dec 2021 14:44:47 +0100 Subject: [PATCH 2/2] build: set GLUON_DEPRECATED = 0 by default We currently don't have any deprecated devices, so it doesn't make much sense to force every site to specify this variable. Make it default to 0 instead. --- Makefile | 2 +- docs/multidomain-site-example/site.mk | 3 --- docs/site-example/site.mk | 3 --- docs/user/getting_started.rst | 2 +- docs/user/site.rst | 2 +- 5 files changed, 3 insertions(+), 9 deletions(-) diff --git a/Makefile b/Makefile index c25f82f5..e3aa596f 100644 --- a/Makefile +++ b/Makefile @@ -27,7 +27,7 @@ include $(GLUON_SITEDIR)/site.mk GLUON_RELEASE ?= $(error GLUON_RELEASE not set. GLUON_RELEASE can be set in site.mk or on the command line) -GLUON_DEPRECATED ?= $(error GLUON_DEPRECATED not set. Please consult the documentation) +GLUON_DEPRECATED ?= 0 ifneq ($(GLUON_BRANCH),) $(warning *** Warning: GLUON_BRANCH has been deprecated, please set GLUON_AUTOUPDATER_BRANCH and GLUON_AUTOUPDATER_ENABLED instead.) diff --git a/docs/multidomain-site-example/site.mk b/docs/multidomain-site-example/site.mk index df282a53..64ce6fa1 100644 --- a/docs/multidomain-site-example/site.mk +++ b/docs/multidomain-site-example/site.mk @@ -58,6 +58,3 @@ GLUON_REGION ?= eu # Languages to include GLUON_LANGS ?= en de - -# Do not build images for deprecated devices -GLUON_DEPRECATED ?= 0 diff --git a/docs/site-example/site.mk b/docs/site-example/site.mk index cff17523..30671b18 100644 --- a/docs/site-example/site.mk +++ b/docs/site-example/site.mk @@ -55,6 +55,3 @@ GLUON_REGION ?= eu # Languages to include GLUON_LANGS ?= en de - -# Do not build images for deprecated devices -GLUON_DEPRECATED ?= 0 diff --git a/docs/user/getting_started.rst b/docs/user/getting_started.rst index 01e01b54..57ffe83b 100644 --- a/docs/user/getting_started.rst +++ b/docs/user/getting_started.rst @@ -213,7 +213,7 @@ GLUON_DEPRECATED Usually, devices are deprecated because their flash size is insufficient to support future Gluon versions. The recommended setting is ``0`` for new sites, and ``upgrade`` for existing configurations (where upgrades for existing - deployments of low-flash devices are required). + deployments of low-flash devices are required). Defaults to ``0``. GLUON_LANGS Space-separated list of languages to include for the config mode/advanced settings. Defaults to ``en``. diff --git a/docs/user/site.rst b/docs/user/site.rst index bd2f9c3c..28297e38 100644 --- a/docs/user/site.rst +++ b/docs/user/site.rst @@ -562,7 +562,7 @@ GLUON_DEPRECATED Usually, devices are deprecated because their flash size is insufficient to support future Gluon versions. The recommended setting is ``0`` for new sites, and ``upgrade`` for existing configurations (where upgrades for existing - deployments of low-flash devices are required). + deployments of low-flash devices are required). Defaults to ``0``. GLUON_FEATURES Defines a list of features to include. Depending on the device, the feature list