scripts: target_lib: remove profile override support (#2423)

No legacy OpenWrt targets exist anymore which require the .config profile
name to differ from the image name.
This commit is contained in:
Matthias Schiffer 2022-03-24 06:47:40 +01:00 committed by GitHub
parent 5e166d80d9
commit 7d75cfddfc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 5 deletions

View File

@ -155,8 +155,6 @@ if #lib.devices > 0 then
handle_target_pkgs(lib.target_packages) handle_target_pkgs(lib.target_packages)
for _, dev in ipairs(lib.devices) do for _, dev in ipairs(lib.devices) do
local profile = dev.options.profile or dev.name
local device_pkgs = {} local device_pkgs = {}
local function handle_pkgs(pkgs) local function handle_pkgs(pkgs)
for _, pkg in ipairs(pkgs) do for _, pkg in ipairs(pkgs) do
@ -172,10 +170,10 @@ if #lib.devices > 0 then
handle_pkgs(dev.options.packages or {}) handle_pkgs(dev.options.packages or {})
handle_pkgs(site_packages(dev.image)) handle_pkgs(site_packages(dev.image))
local profile_config = string.format('%s_DEVICE_%s', openwrt_config_target, profile) local profile_config = string.format('%s_DEVICE_%s', openwrt_config_target, dev.name)
lib.config( lib.config(
'TARGET_DEVICE_' .. profile_config, true, 'TARGET_DEVICE_' .. profile_config, true,
string.format("unable to enable device '%s'", profile) string.format("unable to enable device '%s'", dev.name)
) )
lib.config( lib.config(
'TARGET_DEVICE_PACKAGES_' .. profile_config, 'TARGET_DEVICE_PACKAGES_' .. profile_config,

View File

@ -31,7 +31,6 @@ M.images = {}
local default_options = { local default_options = {
profile = false,
factory = '-squashfs-factory', factory = '-squashfs-factory',
factory_ext = '.bin', factory_ext = '.bin',
sysupgrade = '-squashfs-sysupgrade', sysupgrade = '-squashfs-sysupgrade',