Commit Graph

48 Commits

Author SHA1 Message Date
Anton Kikin
694ed728b0 images: Empty /usr/lib/opkg/lists directory in rootfs
Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2019-06-19 00:32:51 +03:00
Anton Kikin
5d16699a74 openwrt-services.bbclass: Do not change service state on package upgrade
Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2019-06-18 06:09:36 +03:00
Anton Kikin
68575f5a71 layer: Adjust some version related variables
Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2019-06-18 02:23:06 +03:00
Anton Kikin
8b1bd717df kmod: Separate classes for kernel config dependencies and for kmod
This allows to use kernel-config-depends class in normal recipes, not
only in kmod recipes.

Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2019-05-21 16:14:19 +03:00
Anton Kikin
59126b0d51 kernel-config-depends.bbclass: Add kernel version checking support
Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2019-02-27 16:02:40 +03:00
Anton Kikin
889e1397df kernel-config.bbclass: Add a function to determine current kernel version
Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2019-02-27 16:02:40 +03:00
Anton Kikin
bb95deb714 treewide: Fix some issues with DISTRO_, MACHINE_ and COMBINED_FEATURES
Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2019-02-13 18:02:47 +03:00
Anton Kikin
bc39b28776 base-files: Remove openwrt-base-files class
Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2019-02-07 21:06:37 +03:00
Anton Kikin
3cf6b018e2 base-files: Update to the latest git head
Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2019-02-07 02:12:47 +03:00
Anton Kikin
85045701c9 layer: Add mirrors for repositories from git.openwrt.org
Added official and non-official mirrors for repositories from git.openwrt.org.

This may necessary because the Russian government has blocked the IP address
of the git.openwrt.org (46.101.214.210) and we may do not have access to it
with some ISP's.

Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2019-02-02 03:30:39 +03:00
Anton Kikin
78aa11ad7f base-files: Extract os-release package into a separate tano-version recipe
Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-12-13 01:39:17 +03:00
Anton Kikin
3f4c15ac52 luci-theme-*: Autogenerate hashes for the static files of LuCI themes
For all static files of the LuCI themes the hash is calculated. A parameter
with a hash of the file is added to the file loading location (in header.htm
and footer.htm) to avoid cache problems when theme is updated. Additionally
added hashes for cbi.js and xhr.js files loading.

Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-12-05 18:32:14 +03:00
Anton Kikin
54c4aceff8 treewide: Move luci.inc inclusion to openwrt-luci-pkg class
All LuCI modules requires inclusion for `recipes-extended/luci/luci.inc`.
Therefore, inclusion of this file is moved to the code openwrt-luci-pkg
class code.

Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-12-05 18:32:14 +03:00
Anton Kikin
9e425b4adf base-files: Update to the latest revision
Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-11-24 04:10:24 +03:00
Anton Kikin
f3fc26d94d classes/openwrt-version: Fix dependency on layer git revision
Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-11-16 01:11:10 +03:00
Anton Kikin
d54dd32d20 classes/openwrt-version: Set valid values for variables
Changed:
  * Added new OPENWRT_VERSION_HOME_URL variable
  * Set OPENWRT_VERSION_CODE by current git revision
  * Set valid OPENWRT_VERSION_REPO value
  * Set OPENWRT_VERSION_BUG_URL to github issues page
  * Empty OPENWRT_VERSION_SUPPORT_URL value

Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-11-15 20:08:21 +03:00
Anton Kikin
c57c3cd107 base-files: Update to latest revision from OpenWrt master branch
Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-11-07 22:29:40 +03:00
Anton Kikin
db21bb8a03 luasrcdiet: Fix luasrcdiet usage
Luasrcdiet compressor was not used due to incorrect
Lua modules search paths.

Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-11-03 03:40:25 +03:00
Anton Kikin
5ee7484d0b classes/rootfs-rm-boot-dir: Allow to completely disable /boot removal
Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-10-27 19:41:57 +03:00
Anton Kikin
559d3fccc8 kmod: Add kmod-* recipes for kernel modules
kmod-* recipes is a wrappers for kernel modules with kernel
configuration checks.

In addition, these recipes allows to customize the autoloading of the
kernel modules in case of that they builded as modules.

kmod-* recipes consists of the following directives:

    KERNEL_CONFIG_DEPENDS += "{\
        option              = CONFIG_OPTION_NAME, \
        required            = y|m, \
        m_rdepends          = kernel-module-mod1, \
        m_rdepends          = kernel-module-mod2, \
        m_autoload          = mod1, \
        m_autoload          = mod2 mod2_param=value, \
        m_autoload_early    = false, \
        m_autoload_priority = 30, \
        m_autoload_script   = modules \
    }"

Each directive refers to a single kernel configiration option, which
is specified in the `option` parameter.

Parameter `required` determines the possible values of the kernel
configuration option, separated by `|` symbol:
  * `y` — builtin;
  * `m` — module;
  * `n` — not set;
  * any other specific value.

All other parameters are optional and applied only if kernel configuration
option has been set to `m`.

Runtime dependencies (`RDEPENDS` variable) may be specified in `m_rdepends`
parameter. Parameter `m_rdepends` can be specified several times (one record
for each dependency).

Module name with module parameters for automatic loading must be specified
in the parameter `m_autoload`. Parameter `m_autoload` can also be specified
several times.

By default, a modprobe file is created in the `/etc/modules.d` folder with
the contents consisting of lines from `m_autoload` parameters.
If `m_autoload_early` set to `true` (default value is `false`) then modprobe
file is symlinked to `/etc/modules-boot.d` folder.

Parameter `m_autoload_script` sets the name for the modprobe file in the
`/etc/modules.d` or/and `/etc/modules-boot.d` folders.

If the parameter `m_autoload_priority` value is set, then the modprobe file
name will be preceded by a priority value using the format `%02d-name`.
The priority value must be between 0 and 99.

Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-10-20 20:24:29 +03:00
Anton Kikin
512330ccd3 luasrcdiet: Add recipe for LuaSrcDiet 1.0.0
Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-09-20 01:49:44 +03:00
Anton Kikin
c1cac3c2e8 layer: Add some variable dependencies (vardeps) for properly building
Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-09-15 02:43:02 +03:00
Anton Kikin
23cb7eb593 kernel-config-check.bbclass: Add additional checks
Added check for KERNEL_CONFIG_CHECK[option] empty value.

Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-09-14 01:56:02 +03:00
Anton Kikin
df28ed3dfc classes: Add class for kernel configuration check
Added kernel-config-check class that can be used for checking
kernel configuration options.

Basic usage syntax is:
  KERNEL_CONFIG_CHECK[<option>] = "<allowed>[=<rdepend>],..."

For example, if we need the option CONFIG_BRIDGE to be set to 'y',
we need to write in recipe:
  inherit kernel-config-check
  KERNEL_CONFIG_CHECK[BRIDGE] = "y"

If we also need to support CONFIG_BRIDGE=m, we need to write:
  KERNEL_CONFIG_CHECK[BRIDGE] = "y,m"

We can also add a runtime dependency for CONFIG_BRIDGE=m:
  KERNEL_CONFIG_CHECK[BRIDGE] = "y,m=kernel-module-bridge"

Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-09-14 01:15:06 +03:00
Anton Kikin
dcd745785a classes/rootfs-rm-boot-dir: Allow to keep DTB* files in /boot
Keep *.dtb* files in /boot when ROOTFS_RM_BOOT_DIR_KEEP_DTB enabled.

Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-09-13 23:11:29 +03:00
Anton Kikin
0eace91396 classes/rootfs-rm-boot-dir: Allow to keep DTB files in /boot
Add option ROOTFS_RM_BOOT_DIR_KEEP_DTB to rootfs-rm-boot-dir class that
allow to keep DTB files in /boot in root filesystem image.

Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-09-11 03:28:10 +03:00
Anton Kikin
0c2a04c89c base-files: Update to latest revision from OpenWrt 18.06.1
Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-08-31 12:12:00 +03:00
Anton Kikin
530937451b base-files: Update to latest revision from OpenWrt 18.06.0
Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-08-02 06:39:16 +03:00
Anton Kikin
bd443d8215 base-files: Add PR_append to openwrt-base-files.bbclass
Append ".owrtX" to all packages revisions which using OpenWrt base-files.

Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-07-23 15:45:24 +03:00
Anton Kikin
3803f52c56 base-files: Update OpenWrt base repository to latest revision
Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-07-23 05:12:31 +03:00
Anton Kikin
5a7b78312a luci: Add recipes for 3G, NCM, PPP and QMI protocols support
Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-07-18 04:40:39 +03:00
Anton Kikin
b3610dc9b8 openwrt-image: Link /var to /tmp
In original OpenWrt distribution /var is symlinked to /tmp .

Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-07-17 19:35:02 +03:00
Anton Kikin
94739bc9f5 base-files: Update to OpenWrt 18.06.0-rc2 revision
Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-07-17 19:29:56 +03:00
Anton Kikin
6587455ed1 classes/openwrt-luci-i18n: Skip hidden folders while scanning 'po' directories
Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-07-01 22:38:15 +03:00
Anton Kikin
be5dcf02a8 layer: Remove dependency on meta-arago layers
Now the layer does not depend directly on the Arago distribution layers.
But Arago support remained. For this, some configuration files were taken from
the meta-arago-distro and meta-arago-extras layers.

Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-06-30 16:24:25 +03:00
Anton Kikin
aeabb25134 openwrt-luci-pkg: Fix installation permissions
Install all files with 0644 permissions and make 0755 permissions
only for files specified in LUCI_PKG_EXECUTABLE variable.

Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-06-22 14:50:46 +03:00
Anton Kikin
9d98cd4d33 layer: Add image class with overlay support
When using this class, an additional empty UBIFS overlay image is created.

Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-06-22 06:17:10 +03:00
Anton Kikin
9b9d6d02d0 layer: Add support for squashfs root filesystem
Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-06-22 06:15:17 +03:00
Anton Kikin
81dfab56c4 layer: Single class for LuCI applications and themes
Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-06-06 01:14:34 +03:00
Anton Kikin
6245b42174 layer: Add variables for LuCI application, theme and i18n sources base
Add variables LUCI_APP_SRC, LUCI_THEME_SRC, LUCI_I18N_SRC in
appropriate classes.

This variables can be redefined in recipes if sources is not in the root
of source directory ${S}.

Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-06-05 21:11:12 +03:00
Anton Kikin
507f6c8879 luci: Made individual recipes for LuCI applications and LuCI themes
Remove applications and themes installation from main LuCI recipe.

Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-06-05 03:36:14 +03:00
Anton Kikin
0d796fa7bb layer: Add class for removing /boot directory from image
Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-05-31 18:40:32 +03:00
Anton Kikin
ace963e739 luci: i18n support and applications
Added initial support for LuCI 18n packages generation and customize
applications for building

Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-05-31 14:03:57 +03:00
Anton Kikin
84a48fd78d base-files: Add class for OpenWrt version info overriding
These options allow to override the version information embedded in
the /etc/openwrt_version, /etc/openwrt_release, /etc/issue and
/etc/os-release files.

Add processing by version script these files:
  - /etc/os-release -> /usr/lib/os-release
  - /etc/device_info
  - /etc/openwrt_release
  - /etc/openwrt_version

Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-05-31 05:25:18 +03:00
Anton Kikin
b444fa8efa layer: Improve OpenWrt service management class
Improved OpenWrt service management class allows to configure
multiple init scripts for one package and setup initial service
state (enabled or disabled) for each init script.

For example:
    ```
    inherit openwrt-services

    OPENWRT_SERVICE_PACKAGES = "pkgname"

    OPENWRT_SERVICE_SCRIPTS_pkgname = "init_script_1 init_script_2"
    OPENWRT_SERVICE_STATE_pkgname-init_script_1 = "enabled"
    OPENWRT_SERVICE_STATE_pkgname-init_script_2 = "disabled"
    ```

Package pkgname has two init scripts (init_script_1 and init_script_2)
that must be located at /etc/init.d directory. Initial state (first boot)
for init_script_1 is enabled, for init_script_2 - disabled.

Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-05-31 04:39:32 +03:00
Anton Kikin
809f82a5cc layer: Relocate some configuration variables to distribution config
Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-05-31 04:37:01 +03:00
Anton Kikin
92d3d79375 layer: Add class for fix configuration files for autoloadable modules
Move modules autoloading config files from /etc/modules-load.d
to /etc/modules.d as needed for OpenWrt kmodloader and remove
/etc/modules-load.d folder from root filesystem.

/etc/modules-load.d is used by sysvinit. OpenWrt's procd
uses /etc/modules.d directory.

Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-05-31 04:35:31 +03:00
Anton Kikin
4f8ddedf71 Added original sources from https://github.com/kraj/meta-openwrt
Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
2018-05-30 04:30:01 +03:00