Commit Graph

582 Commits

Author SHA1 Message Date
Tianling Shen
2352d1bfa9
kernel: bump to 4.9.288, 4.14.253, 4.19.214
Refreshed all patches.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-10-28 11:15:06 +08:00
Rosen Penev
6df9589d31 uclibc++: remove
No package here depends on it. Furthermore, uClibc++ is a fairly buggy
C++ library and seems to be relatively inactive upstream.

It also lacks proper support for modern C++11 features.

The main benefit of it is size: 66.6 KB	vs 287.3 KB on mips24kc. Static
linking and LTO can help bring the size down of packages that need it.

Added warning message to uclibc++.mk

Signed-off-by: Rosen Penev <rosenp@gmail.com>
Acked-by: Hauke Mehrtens <hauke@hauke-m.de>
2021-10-26 23:50:42 +08:00
Felix Fietkau
573f489f8b include/cmake.mk: fix host builds with CMAKE_BINARY_SUBDIR
Use it in the same way as for target builds

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2021-10-24 00:08:12 +08:00
Tianling Shen
9e56c46a39
kernel: bump to 4.9.287, 4.14.251, 4.19.212
Manually rebased:
- generic/backport-4.9/024-7-net-reorganize-struct-sock-for-better-data-locality.patch

Refreshed all patches.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-10-17 21:52:46 +08:00
Rosen Penev
d544c1b0d7 tools/meson: fix usage with SDK
The python path cannot be embedded in the meson binary as it changes
with the SDK.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-10-12 23:40:34 +08:00
Rosen Penev
b082f04ae3 tools/meson: update to 0.59.2
Update install procedure based on upstream feedback. Normally, meson is
to be installed with pip. But as pip is not mandated by the build
system, it cannot be used. Upstream provides a nice script to pack meson
automatically.

Moved src/ to files/. No need to copy to BUILD_DIR.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-10-08 23:39:42 +08:00
Tianling Shen
10a0ee06ee
kernel: bump to 4.9.285, 4.14.249, 4.19.209
Manually rebased:
- generic/pending-4.19/800-bcma-get-SoC-device-struct-copy-its-DMA-params-to-th.patch

Refreshed all patches.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-10-07 14:56:30 +08:00
Paul Spooren
8af77773f4 build: fix which detection on Fedora & MacOS
Fix Fedora 34/35 issue where 'which' detection of 'which' wasn't working
because Fedora use alias and proc

Fixup of fca5ad55d2 prereq-build: fix `which` detection on Fedora

Reported-by: Jani Partanen <rtfm@iki.fi>
Suggest-by: Etienne Champetier <champetier.etienne@gmail.com>
Tested-by: Georgi Valkov <gvalkov@abv.bg>
Signed-off-by: Paul Spooren <mail@aparcar.org>
2021-10-03 23:50:40 +08:00
Marcin Juszkiewicz
22290dc38d prereq-build: recognize Python 3.10
Fedora 35 contains Python 3.10 as default version. Make use of it.

Signed-off-by: Marcin Juszkiewicz <marcin@juszkiewicz.com.pl>
[fix commit subject]
Signed-off-by: Paul Spooren <mail@aparcar.org>
2021-09-29 23:37:36 +08:00
Rosen Penev
e06ab0c6b3 tools: add meson
meson is a next generation build system designed to have good defaults,
simpler build files, and fast compilation.

It is built upon python and uses ninja for compilation. The latter
provides fast by default (parallel) and problem free compilation.

There are over 40 packages already successfully using meson. The next
commit will convert pkgconf to use meson compilation.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-09-18 23:53:55 +08:00
Paul Spooren
e9cb0a7753
build: store artifacts in JSON
Multiple profiles create artifacts, these should be stored in the JSON
file as well, allowing downstream tooling to show those files, too.

Artifacts don't have specific filesystems so only the fields `name`,
`type` and `sha256` are available.

Rename env variable names from IMAGE_ to FILE_ prefixes to reflect that
images, kernels and artifacts are added with the same command.

Signed-off-by: Paul Spooren <mail@aparcar.org>
(cherry picked from commit 5ef4608c02)
2021-09-17 04:49:04 +08:00
Adrian Schmutzler
7984a95946
treewide: rename IMAGE_PREFIX/IMAGE_NAME to DEVICE_IMG_*
We so far had two variables IMG_PREFIX and IMAGE_PREFIX with
different content. Since these names are obviously quite
confusing, this patch renames the latter to DEVICE_IMG_PREFIX,
as it's a device-dependent variable, while IMG_PREFIX is only
(sub)target-dependent.

For consistency, also rename IMAGE_NAME to DEVICE_IMG_NAME, as
that's a device-dependent variable as well.

Cc: Paul Spooren <mail@aparcar.org>
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
(cherry picked from commit ef2cb8572b)
2021-09-17 04:48:26 +08:00
Tianling Shen
1ebbbbfec6
target: drop some default packages
Let users to decide build them or not.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-09-11 05:01:06 +08:00
Tianling Shen
0c22299647
kernel: bump to 4.9.282, 4.14.246, 4.19.206
Resolve conflicted:
- generic/backport-4.19/370-netfilter-nf_flow_table-fix-offloaded-connection-tim.patch

Refreshed all patches.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-09-06 06:39:19 +08:00
klever1988
36184296ba
target.mk: remove unexists packages 2021-09-05 07:40:45 +08:00
Andre Heider
a5e9b97611 prereq-build: require python3-distutils
Debian and Ubuntu ship a python3-minimal package which does not include
the distutils module. This is not supported by upstream and can be
considered a broken python distribution.

In practice, many scripts depend on said module, and this is a reoccuring
pain point for building various OpenWrt packages.

Require and check for said module, enough time has been wasted on this.

Signed-off-by: Andre Heider <a.heider@gmail.com>
2021-08-22 12:16:26 +08:00
Daniel Golle
cdea9c5d9d image: fix build with SELinux
The option '-xattr' for mksquashfs4 should be '-xattrs' which lead to
build failure with SELinux enabled. Add the missing 's'.

Fixes: 4baf47b9a8 ("images: squashfs: xattrs should not depend on buld host")
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2021-08-19 12:10:37 +08:00
Tianling Shen
9bfc21a8d3
kernel: bump to 4.9.280, 4.14.244, 4.19.204
Refreshed all patches.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-08-17 19:38:52 +08:00
Tianling Shen
54c0966bb1
kernel: bump to 4.9.278, 4.14.242, 4.19.201
Resolve conflicted:
- generic/pending-4.14/690-net-add-support-for-threaded-NAPI-polling.patch
- generic/pending-4.19/690-net-add-support-for-threaded-NAPI-polling.patch

Refreshed all patches.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-08-06 22:23:34 +08:00
Daniel Golle
b3437ac7a3 images: squashfs: xattrs should not depend on buld host
Enable xattr for the generated squashfs only if needed for SELinux.
This eliminates warnings during boot on target when building
(non-SELinux) OpenWrt on SELinux-enabled hosts like Fedora.

Reported-by: fda77 <fda77@users.noreply.github.com>
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2021-08-04 12:05:38 +08:00
Tianling Shen
1ac8417985
kernel: bump to 4.9.275, 4.14.239, 4.19.197
Refreshed all patches.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-07-17 00:05:32 +08:00
Tianling Shen
16dee56503
target: tweak default packages
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-06-22 13:16:25 +08:00
李国
9eddf65670
x86: generate EFI platform bootable images
Add EFI platform bootable images for x86 platforms. These images can
also boot from legacy BIOS platform.

EFI System Partition need to be fat12/fat16/fat32 (not need to load
filesystem drivers), so the first partition of EFI images are not ext4
filesystem any more.

GPT partition table has an alternate partition table, we did not
generate it. This may cause problems when use these images as qemu disk
(kernel can not find rootfs), we pad enough sectors will be ok.

Signed-off-by: 李国 <uxgood.org@gmail.com>
[part_magic_* refactoring, removed genisoimage checks]
Signed-off-by: Petr Štetiar <ynezz@true.cz>
(cherry picked from commit a6b7c3e672)
2021-06-17 20:13:41 +08:00
Paul Spooren
47bbca5ee3
x86: use qemu-image command from image-commands.mk
The `qemu-image` command converts images to the specified type and
reduces redundant code.

Adaption from Alexander Couzens <lynxis@fe80.eu> work[0].

[0]: https://git.openwrt.org/?p=openwrt/staging/lynxis.git;a=blob;f=target/linux/x86/image/Makefile;h=83b8140b7aefbe708fd09c9c61827e7e39bda8b4;hb=416cccf398e9589e3de386e05b61b1c46cace20d#l51

Signed-off-by: Paul Spooren <mail@aparcar.org>
(cherry picked from commit 33cc7e763b)
2021-06-17 19:48:43 +08:00
Paul Spooren
a1dc0bafa9
x86: switch image generation to new code
This commit introduces few related changes which need to be done in
single commit to keep images buildable between git revisions. In result
it retains all previous image creation possibilities with slight name
change of generated images. Brief summary of the commit:

* Split up image generation recipe to smaller chunks to make it more
  generic and reusable.

* Make iso images x86 specific and drop their definition as root
  filesystem.

* Convert image creation process to generic code specified in image.mk.

* Make geode subtarget inherit features from the main target instead of
  redefining them.

* For subtargets create device definitions with basic packages set.

Signed-off-by: Tomasz Maciej Nowak <tomek_n@o2.pl>
[rebased]
Signed-off-by: Paul Spooren <mail@aparcar.org>
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-06-17 19:38:52 +08:00
Jo-Philipp Wich
9f80b7d5be build: ensure that dash isn't prepended twice to abi version suffix
The ABIV_$(pkgname) variable already is formatted so return it as-is from
the GetABISuffix macro and only filter through FormatABISuffix if we read
the raw ABI version value from a version stamp file.

This ensures that binary intra-package dependencies on ABI versioned
libraries are properly formatted.

Fixes: f6a03bff5b ("build: prepend ABI suffixes with a dash if package name ends with digit")
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2021-06-15 23:13:36 +08:00
Jo-Philipp Wich
48307357af build: prepend ABI suffixes with a dash if package name ends with digit
Ensure that ABI suffixes are separated with a dash from the package name if
the name happens to end with a digit. This implementation detail got lost
during the recent refactoring of the ABI_VERSION handling in buildroot.

Fixes: c921650382 ("build: drop ABI version from metadata")
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2021-06-15 23:13:08 +08:00
Rosen Penev
00cd20c4b2 prereq-build: diff requirement to GNU
tools/quilt requires GNU diffutils to compile. Failure can be simulated
by installing Alpine Linux without diffutils.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-06-13 12:02:48 +08:00
Felix Fietkau
f17acc7689 build: do not override DESTDIR for cmake ninja host builds
The full prefix is already passed to cmake

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2021-06-13 12:02:01 +08:00
Felix Fietkau
345cbe4ce2 build: use ninja for cmake packages by default
Speed goes from:

Executed in     178.08 secs     fish            external
usr time        20.16 mins      509.00 micros   20.16 mins
sys time        2.88 mins       39.00 micros    2.88 mins

To:

Executed in     175.90 secs     fish            external
usr time        20.19 mins      0.00 micros     20.19 mins
sys time        2.85 mins       497.00 micros   2.85 mins

Tested with "time make -j 12" on AMD Ryzen 3600

When building individual packages, the build time difference is often
significantly bigger than that.

Signed-off-by: Felix Fietkau <nbd@nbd.name>
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-06-13 12:01:44 +08:00
Felix Fietkau
056b026135 build: add ninja build tool and make it available for cmake
ninja is faster at building cmake packages than make, and according to reports
also more reliable at handling parallel builds
This commit includes a patch that adds GNU make jobserver support, in order to
allow more precise control over the number of parallel tasks

Enable parallel build by default for packages using ninja

Signed-off-by: Felix Fietkau <nbd@nbd.name>
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-06-13 11:59:14 +08:00
Felix Fietkau
301c9ea4ed u-boot: support verbose build
Signed-off-by: Felix Fietkau <nbd@nbd.name>
2021-06-13 11:57:51 +08:00
Tianling Shen
afd4f84321
kernel: bump to 4.9.272, 4.14.236, 4.19.194
Refreshed all patches.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-06-11 00:48:28 +08:00
Paul Spooren
f86e21f3ea build/json: fix DEVICE_PACKAGES
The variable was missing in the definition of DEFAULT_DEVICE_VARS which
caused it to contain wrong values, messing up the resulting JSON files.

This patch adds the variable DEVICE_PACKAGES to DEFAULT_DEVICE_VARS.

Suggested-by: Baptiste Jonglez <git@bitsofnetworks.org>
Signed-off-by: Paul Spooren <mail@aparcar.org>
2021-06-03 12:08:07 +08:00
Tianling Shen
8b3da8c24d
kernel: bump to 4.9.270, 4.14.234, 4.19.192
Backported latest BBR fixes for kernel 4.14 and 4.19.

No patch needs to be refreshed.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-05-28 20:06:13 +08:00
Tianling Shen
4c7cf87e6b
kernel: bump to 4.9.269, 4.14.233, 4.19.191
Refreshed all patches.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-05-25 01:20:11 +08:00
Karl Palsson
323e1ecdb9 prereq-build: g++ formatting and consistency fixes
Remove \n that mangles output, and fix inconsistent version name check.

Example before:

Build dependency: Please install the GNU C++ Compiler (g++) 6 or later
Build dependency: \nPlease reinstall the GNU C++ Compiler (4.8 or later) - it appears to be broken
Build dependency: Please install ncurses. (Missing libncurses.so or ncurses.h)

Signed-off-by: Karl Palsson <karlp@tweak.net.au>
2021-05-23 23:22:56 +08:00
Andre Heider
a5a2740d7c
build: prereq: drop support for Python 3.5
The final Python 3.5 release was 3.5.10 in September 2020 [0].
This release series is now End-of-Life (EOL).

The only LTS distribution that still only ships Python 3.5 is Ubuntu 16.04,
which will be EOL in April 2021 [1].

The meson build system bumped their python requirement to 3.6 for the 0.57.0
release. This patch ensures that OpenWrt can update meson while still
relying on the host python.

[0] https://www.python.org/dev/peps/pep-0478/#id4
[1] https://ubuntu.com/about/release-cycle
[2] https://mesonbuild.com/Release-notes-for-0-57-0.html#minimum-required-python-version-updated-to-36

Signed-off-by: Andre Heider <a.heider@gmail.com>
[python3.6+ in README.md]
Signed-off-by: Petr Štetiar <ynezz@true.cz>
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-05-13 22:51:22 +08:00
Leonardo Mörlein
2a821d862c
build: introduce $(MKHASH)
Before this commit, it was assumed that mkhash is in the PATH. While
this was fine for the normal build workflow, this led to some issues if

    make TOPDIR="$(pwd)" -C "$pkgdir" compile

was called manually. In most of the cases, I just saw warnings like this:

    make: Entering directory '/home/.../package/gluon-status-page'
    bash: line 1: mkhash: command not found
    bash: line 1: mkhash: command not found
    bash: line 1: mkhash: command not found
    bash: line 1: mkhash: command not found
    bash: line 1: mkhash: command not found
    bash: line 1: mkhash: command not found
    bash: line 1: mkhash: command not found
    bash: line 1: mkhash: command not found
    [...]

While these were only warnings and the package still compiled sucessfully,
I also observed that some package even fail to build because of this.

After applying this commit, the variable $(MKHASH) is introduced. This
variable points to $(STAGING_DIR_HOST)/bin/mkhash, which is always the
correct path.

Signed-off-by: Leonardo Mörlein <me@irrelefant.net>
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-05-13 22:49:42 +08:00
François Chavant
8e196a6299 build: kernel2minor: work around path length limit
When building for MikroTik devices the kernel2minor tool will sometimes
fail with:

  Can't get lstat from kernel file!: No such file or directory.

This is because kernel2minor expects paths no longer than 250 chars.
To work around this the include/image-commands.mk has been modified
to copy the kernel to a temporary file (/tmp/tmp.XXXXXXXXXX) before
calling kernel2minor.

Signed-off-by: François Chavant <francois@chavant.info>
2021-05-12 23:28:46 +08:00
Bas Mevissen
0c2eccb0b2 Extend checks on build prerequisites for building OpenWRT core
OpenWRT requires a number of Perl modules to be installed. It wasn't checking on all of them.
This patch adds checks for Perl FindBin, File::Copy, File::Compare and Thread::Queue modules.

Failing to install these, will have the build break at some point. By adding these to the
prereq-build.mk script, they are checked on forehand.

Tested on a Fedora 33 and 34 (beta) that was freshly installed. Fedora appears to
break up Perl modules into small packages that need to be installed for the build to succeed.

Signed-off-by: Bas Mevissen <abuse@basmevissen.nl>
2021-05-09 00:38:09 +08:00
Tianling Shen
5f0f4cb2b0
target: update wget pkg name
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-05-07 17:24:17 +08:00
Tianling Shen
339d6fc2e8
kernel: bump to 4.9.267, 4.14.231, 4.19.188
Remove upstreamed:
- generic/pending-4.14/840-can-flexcan-flexcan_chip_freeze-fix-chip-freeze-for-.patch

Refreshed all patches.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-04-26 21:31:32 +08:00
Tianling Shen
a5e28e4678
kernel: bump to 4.9.265, 4.14.229, 4.19.185
Refreshed all patches.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-04-10 17:30:47 +08:00
Tianling Shen
0c6e721a78
kernel: bump to 4.9.264, 4.14.228, 4.19.184
Resolve conflicted:
- generic/pending-4.19/611-netfilter_match_bypass_default_table.patch

Refreshed all patches.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-04-04 20:08:14 +08:00
Tianling Shen
4a24bd4db0
kernel: bump to 4.9.262, 4.14.227, 4.19.183
Resolve conflicted:
- layerscape/patches-4.14/809-flexcan-support-layerscape.patch

Refreshed all patches.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-03-27 01:15:23 +08:00
Kevin Darbyshire-Bryant
ee6fbafecf build: add GNU install to prerequisites
The recent removal of usbutils from core and replacement by hwdata in
packages has exposed hwdata's requirement for certain GNU options on
'install' (-T)  Other packages (sqm-scripts) have openwrt specific
makefile sections to avoid GNU options but I suspect this is going to
get harder in the future.

Add GNU install as a prerequisite and link into
$STAGING_DIR/host/etc/bin as per similar GNU utils

This resolves an issue building under MacOS which would otherwise use a
non-GNU options aware version of 'install'

Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
2021-03-25 23:38:59 +08:00
Tianling Shen
49e3204f02
Revert "treewide: add mirrors for GitHub Codeload"
This reverts commit 9796619efc.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-03-23 16:58:11 +08:00
Tianling Shen
66a13ba4b4
Revert "treewide: add mirrors for GitHub Archives"
This reverts commit 19980fd5b9.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-03-23 16:58:11 +08:00
Tianling Shen
fa4d6e9e0b
Revert "Package ctcgfw: use package-immortalwrt.mk"
This reverts commit 36c9fc3bda.

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
2021-03-23 09:26:08 +08:00