Bump buildroot to 2020.11-rc1 (#985)
* Update buildroot-patches for 2020.11-rc1 buildroot * Update buildroot to 2020.11-rc1 Signed-off-by: Stefan Agner <stefan@agner.ch> * Don't rely on sfdisk --list-free output The --list-free (-F) argument does not allow machine readable mode. And it seems that the output format changes over time (different spacing, using size postfixes instead of raw blocks). Use sfdisk json output and calculate free partition space ourselfs. This works for 2.35 and 2.36 and is more robust since we rely on output which is meant for scripts to parse. * Migrate defconfigs for Buildroot 2020.11-rc1 In particular, rename BR2_TARGET_UBOOT_BOOT_SCRIPT(_SOURCE) to BR2_PACKAGE_HOST_UBOOT_TOOLS_BOOT_SCRIPT(_SOURCE). * Rebase/remove systemd patches for systemd 246 * Drop apparmor/libapparmor from buildroot-external * hassos-persists: use /run as directory for lockfiles The U-Boot tools use /var/lock by default which is not created any more by systemd by default (it is under tmpfiles legacy.conf, which we no longer install). * Disable systemd-update-done.service The service is not suited for pure read-only systems. In particular the service needs to be able to write a file in /etc and /var. Remove the service. Note: This is a static service and cannot be removed using systemd-preset. * Disable apparmor.service for now The service loads all default profiles. Some might actually cause problems. E.g. the profile for ping seems not to match our setup for /etc/resolv.conf: [85503.634653] audit: type=1400 audit(1605286002.684:236): apparmor="DENIED" operation="open" profile="ping" name="/run/resolv.conf" pid=27585 comm="ping" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
This commit is contained in:
6
buildroot/package/environment-setup/Config.in.host
Normal file
6
buildroot/package/environment-setup/Config.in.host
Normal file
@@ -0,0 +1,6 @@
|
||||
config BR2_PACKAGE_HOST_ENVIRONMENT_SETUP
|
||||
bool "host environment-setup"
|
||||
help
|
||||
Install an helper script to setup a build environment
|
||||
based on Buildroot. It's useful when you export an sdk
|
||||
and want to use Buildroot to build an external project.
|
||||
18
buildroot/package/environment-setup/environment-setup
Normal file
18
buildroot/package/environment-setup/environment-setup
Normal file
@@ -0,0 +1,18 @@
|
||||
cat <<'EOF'
|
||||
_ _ _ _ _
|
||||
| |__ _ _(_) | __| |_ __ ___ ___ | |_
|
||||
| '_ \| | | | | |/ _` | '__/ _ \ / _ \| __|
|
||||
| |_) | |_| | | | (_| | | | (_) | (_) | |_
|
||||
|_.__/ \__,_|_|_|\__,_|_| \___/ \___/ \__|
|
||||
|
||||
Making embedded Linux easy!
|
||||
|
||||
Some tips:
|
||||
* PATH now contains the SDK utilities
|
||||
* Standard autotools variables (CC, LD, CFLAGS) are exported
|
||||
* To configure do "./configure $CONFIGURE_FLAGS" or use
|
||||
the "configure" alias
|
||||
* To build CMake-based projects, use the "cmake" alias
|
||||
|
||||
EOF
|
||||
SDK_PATH=$(dirname $(realpath "${BASH_SOURCE[0]}"))
|
||||
36
buildroot/package/environment-setup/environment-setup.mk
Normal file
36
buildroot/package/environment-setup/environment-setup.mk
Normal file
@@ -0,0 +1,36 @@
|
||||
################################################################################
|
||||
#
|
||||
# environment-setup
|
||||
#
|
||||
################################################################################
|
||||
|
||||
ENVIRONMENT_SETUP_FILE = $(HOST_DIR)/environment-setup
|
||||
|
||||
define HOST_ENVIRONMENT_SETUP_INSTALL_CMDS
|
||||
cp package/environment-setup/environment-setup $(ENVIRONMENT_SETUP_FILE)
|
||||
for var in $(TARGET_CONFIGURE_OPTS); do \
|
||||
printf "export \"$$var\"\n" >> $(ENVIRONMENT_SETUP_FILE); \
|
||||
done
|
||||
printf "export \"CROSS_COMPILE=$(TARGET_CROSS)\"\n" >> $(ENVIRONMENT_SETUP_FILE)
|
||||
printf "export \"CONFIGURE_FLAGS=--target=$(GNU_TARGET_NAME) \
|
||||
--host=$(GNU_TARGET_NAME) \
|
||||
--build=$(GNU_HOST_NAME) \
|
||||
--prefix=/usr \
|
||||
--exec-prefix=/usr \
|
||||
--sysconfdir=/etc \
|
||||
--localstatedir=/var \
|
||||
--program-prefix=\"\n" >> $(ENVIRONMENT_SETUP_FILE)
|
||||
printf "alias configure=\"./configure \$${CONFIGURE_FLAGS}\"\n" \
|
||||
>> $(ENVIRONMENT_SETUP_FILE)
|
||||
printf "alias cmake=\"cmake \
|
||||
-DCMAKE_TOOLCHAIN_FILE=$(HOST_DIR)/share/buildroot/toolchainfile.cmake \
|
||||
-DCMAKE_INSTALL_PREFIX=/usr\"\n" >> $(ENVIRONMENT_SETUP_FILE)
|
||||
$(SED) 's%$(HOST_DIR)%\$$SDK_PATH%g' \
|
||||
-e 's%$(HOST_DIR)/bin/%%g' \
|
||||
-e '/^export "PATH=/c\' \
|
||||
$(ENVIRONMENT_SETUP_FILE)
|
||||
printf "export \"PATH=\$$SDK_PATH/bin:\$$SDK_PATH/sbin:\$$PATH\"\n" \
|
||||
>> $(ENVIRONMENT_SETUP_FILE)
|
||||
endef
|
||||
|
||||
$(eval $(host-generic-package))
|
||||
Reference in New Issue
Block a user