From 16b17aa5354050958e4fb960ce42635318e46fdf Mon Sep 17 00:00:00 2001 From: Dany LE Date: Sat, 29 Jan 2022 16:31:50 +0100 Subject: [PATCH] update layer to be compatible with rpi zero 64 bits --- conf/layer.conf | 6 +++--- recipes-core/images/core-image-minimal.bbappend | 1 + recipes-diya/diya-overlay/files/confd | 3 +++ .../opensmalltalk-cog-vm/opensmalltalk-cog-vm.bb | 12 ++++++++---- recipes-example/example/files/sdl_test.cpp | 1 + recipes-kernel/linux/files/goodix.cfg | 1 + recipes-kernel/linux/linux-raspberrypi_%.bbappend | 6 ++++++ 7 files changed, 23 insertions(+), 7 deletions(-) create mode 100644 recipes-kernel/linux/files/goodix.cfg create mode 100644 recipes-kernel/linux/linux-raspberrypi_%.bbappend diff --git a/conf/layer.conf b/conf/layer.conf index 599d021..f397b54 100644 --- a/conf/layer.conf +++ b/conf/layer.conf @@ -27,8 +27,8 @@ ROOT_HOME = "/root" #MACHINE = "raspberrypi3-64" #MACHINE = "raspberrypi2" -RPI_USE_U_BOOT:raspberrypi = "0" -RPI_USE_U_BOOT ?= "1" +#RPI_USE_U_BOOT:raspberrypi = "0" +RPI_USE_U_BOOT = "0" RPI_USE_wS_28_DPI_LCD = "1" # enable usb boot in uboot ENABLE_USB_U_BOOT = "0" @@ -40,7 +40,7 @@ ENABLE_SPI_BUS = "0" ENABLE_I2C = "0" KERNEL_MODULE_AUTOLOAD:rpi += " i2c-dev " -VC4DTBO:raspberrypi = "vc4-kms-v3d,nocomposite,noaudio" +VC4DTBO = "vc4-kms-v3d,nocomposite,noaudio" KERNEL_DEVICETREE:append = " overlays/vc4-kms-dpi-generic.dtbo " diff --git a/recipes-core/images/core-image-minimal.bbappend b/recipes-core/images/core-image-minimal.bbappend index 4f37dd9..445f793 100644 --- a/recipes-core/images/core-image-minimal.bbappend +++ b/recipes-core/images/core-image-minimal.bbappend @@ -24,6 +24,7 @@ IMAGE_INSTALL:append = "mpg123 \ libgl-mesa \ libglapi \ glew \ + freetype \ freeglut \ mesa \ libsdl2 \ diff --git a/recipes-diya/diya-overlay/files/confd b/recipes-diya/diya-overlay/files/confd index 51e806b..847559e 100644 --- a/recipes-diya/diya-overlay/files/confd +++ b/recipes-diya/diya-overlay/files/confd @@ -28,6 +28,9 @@ case "$1" in reboot fi # display information + # disable wifi power save + /usr/sbin/iw wlan0 set power_save off + /sbin/ip a ;; *) N=/etc/init.d/$NAME diff --git a/recipes-diya/opensmalltalk-cog-vm/opensmalltalk-cog-vm.bb b/recipes-diya/opensmalltalk-cog-vm/opensmalltalk-cog-vm.bb index e0588e5..6bda647 100644 --- a/recipes-diya/opensmalltalk-cog-vm/opensmalltalk-cog-vm.bb +++ b/recipes-diya/opensmalltalk-cog-vm/opensmalltalk-cog-vm.bb @@ -5,7 +5,7 @@ LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda #FILESEXTRAPATHS_prepend := "${THISDIR}/files:" -DEPENDS = "libsdl2 " +DEPENDS = "libsdl2 mesa freetype" # pharo 9.0 # SRCREV = "${AUTOREV}" @@ -18,11 +18,15 @@ S="${WORKDIR}/git/platforms/unix/config" B="${WORKDIR}/build" inherit autotools -TARGET_CFLAGS += " -D__ARM_ARCH_6__ -DDEBUGVM=0 " +TARGET_CFLAGS:raspberrypi += " -D__ARM_ARCH_6__ " +TARGET_CF_GLAGS += " -DDEBUGVM=0 " -EXTRA_OECONF:append=" --with-src=src/spur32.cog \ - --with-sysroot=${STAGING_DIR_TARGET} \ +EXTRA_OECONF:append=" --with-sysroot=${STAGING_DIR_TARGET} \ --without-npsqueak" +EXTRA_OECONF:raspberrypi:append = " --with-src=src/spur32.cog " +EXTRA_OECONF:raspberrypi0-2w-64:append = " --with-src=src/spur64.cog " + + INSANE_SKIP += " configure-unsafe " do_configure() { diff --git a/recipes-example/example/files/sdl_test.cpp b/recipes-example/example/files/sdl_test.cpp index ddcd92a..b200fec 100644 --- a/recipes-example/example/files/sdl_test.cpp +++ b/recipes-example/example/files/sdl_test.cpp @@ -102,6 +102,7 @@ int main( int argc, char** argv ) SDL_SetRenderDrawColor( renderer, rand() % 256, rand() % 256, rand() % 256, SDL_ALPHA_OPAQUE ); SDL_RenderClear( renderer ); SDL_RenderPresent( renderer ); + SDL_Delay(50); } SDL_DestroyRenderer( renderer ); diff --git a/recipes-kernel/linux/files/goodix.cfg b/recipes-kernel/linux/files/goodix.cfg new file mode 100644 index 0000000..ad45d68 --- /dev/null +++ b/recipes-kernel/linux/files/goodix.cfg @@ -0,0 +1 @@ +CONFIG_TOUCHSCREEN_GOODIX=m diff --git a/recipes-kernel/linux/linux-raspberrypi_%.bbappend b/recipes-kernel/linux/linux-raspberrypi_%.bbappend new file mode 100644 index 0000000..c391fd7 --- /dev/null +++ b/recipes-kernel/linux/linux-raspberrypi_%.bbappend @@ -0,0 +1,6 @@ +FILESEXTRAPATHS:prepend := "${THISDIR}/files:" + +# inherit kernel +SRC_URI += " \ + file://goodix.cfg \ +" \ No newline at end of file