add first working meta-layer

This commit is contained in:
DanyLE 2024-03-08 10:41:41 +01:00
parent 7a1ce5b08a
commit bdfbfc9669
64 changed files with 96512 additions and 0 deletions

44
conf/layer.conf Normal file
View File

@ -0,0 +1,44 @@
# We have a conf and classes directory, add to BBPATH
BBPATH .= ":${LAYERDIR}"
# We have recipes-* directories, add to BBFILES
BBFILES += "${LAYERDIR}/recipes-*/*/*.bb \
${LAYERDIR}/recipes-*/*/*.bbappend"
BBFILE_COLLECTIONS += "meta-opi-diya"
BBFILE_PATTERN_meta-opi-diya = "^${LAYERDIR}/"
BBFILE_PRIORITY_meta-opi-diya = "11"
LAYERDEPENDS_meta-opi-diya = " core "
LAYERSERIES_COMPAT_meta-opi-diya = "kirkstone"
PACKAGE_CLASSES = "package_ipk"
INITRAMFS_IMAGE="core-image-recovery"
INITRAMFS_IMAGE_BUNDLE="0"
INITRAMFS_MAXSIZE="200000"
INHERIT += "rm_work"
EXTRA_IMAGE_FEATURES ?= " ssh-server-dropbear read-only-rootfs "
# ssh-server-dropbear
DISTRO_FEATURES:append := " opengl wayland "
DISTRO_FEATURES:remove = " x11 vulkan "
TOOLCHAIN_TARGET_TASK:append = " libgles3-mesa-dev "
# DISTRO_FEATURES:append := " vc4-gfx opengl directfb "
MACHINE ?= "orange-pi-zero2w"
WKS_FILE="opi.wks.in"
ROOT_HOME = "/root"
PREFERRED_PROVIDER_virtual/kernel = "linux-xunlong"
PREFERRED_VERSION_linux-xunlong = "6.1.31"
PREFERRED_PROVIDER_virtual/bootloader = "u-boot-xunlong"
PREFERRED_PROVIDER_u-boot = "u-boot-xunlong"
#
# extra kernel CMDLINE_RNDIS option
# CMDLINE_RNDIS += " video=DPI-1:480x640,rotate=90 "
# accept license for wifi and bluetooth firmware
LICENSE_FLAGS_ACCEPTED = "synaptics-killswitch"

View File

@ -0,0 +1,9 @@
require conf/machine/include/sunxi64.inc
DEFAULTTUNE ?= "cortexa53-crypto"
require conf/machine/include/arm/armv8a/tune-cortexa53.inc
MACHINEOVERRIDES =. "sun50i:"
SOC_FAMILY = "sun50i-h616"

View File

@ -0,0 +1,15 @@
PREFERRED_PROVIDER_virtual/mesa ?= "mesa-gl"
PREFERRED_PROVIDER_virtual/libgl ?= "mesa-gl"
PREFERRED_PROVIDER_virtual/libgles1 ?= "sunxi-mali"
PREFERRED_PROVIDER_virtual/libgles2 ?= "sunxi-mali"
PREFERRED_PROVIDER_virtual/egl ?= "sunxi-mali"
PACKAGECONFIG:remove:pn-xserver-xorg = "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'glamor', '', d)}"
XSERVER += "sunxi-mali \
sunxi-mali-dev"
MACHINE_ESSENTIAL_EXTRA_RRECOMMENDS += "\
kernel-module-mali \
kernel-module-mali-drm \
"

View File

@ -0,0 +1,27 @@
SOC_FAMILY ??= ""
include conf/machine/include/soc-family.inc
MACHINEOVERRIDES =. "sunxi:sunxi64:"
PREFERRED_PROVIDER_virtual/kernel ?= "linux-mainline"
PREFERRED_PROVIDER_u-boot ?= "u-boot"
PREFERRED_PROVIDER_virtual/bootloader ?= "u-boot"
KERNEL_IMAGETYPE ?= "Image"
# IMAGE_CLASSES += "sdcard_image-sunxi"
IMAGE_FSTYPES += "ext4 tar.gz wic.bz2 wic.bmap"
# sunxi-sdimg
MACHINE_EXTRA_RRECOMMENDS = "kernel-modules"
UBOOT_LOCALVERSION = "-g${@d.getVar('SRCPV', True).partition('+')[2][0:7]}"
UBOOT_ENTRYPOINT ?= "0x40008000"
UBOOT_LOADADDRESS ?= "0x400080OB00"
#UBOOT_BINARY ?= "u-boot.itb"
SPL_BINARY ?= "spl/sunxi-spl.bin"
SERIAL_CONSOLE ?= "115200 ttyS0"
MACHINE_FEATURES ?= "alsa apm keyboard rtc serial screen usbgadget usbhost vfat"

View File

@ -0,0 +1,45 @@
#@TYPE: Machine
#@NAME: orange-pi-zero-2
#@DESCRIPTION: Machine configuration for the orange-pi-zero-2, based on Allwinner H616 CPU
require conf/machine/include/sun50i-h616.inc
KERNEL_DEVICETREE = "allwinner/sun50i-h616-orangepi-zero2w.dtb \
allwinner/overlay/sun50i-h616-disable-leds.dtbo \
allwinner/overlay/sun50i-h616-disable-uart0.dtbo \
allwinner/overlay/sun50i-h616-gpu.dtbo \
allwinner/overlay/sun50i-h616-ir.dtbo \
allwinner/overlay/sun50i-h616-ph-i2c1.dtbo \
allwinner/overlay/sun50i-h616-ph-i2c2.dtbo \
allwinner/overlay/sun50i-h616-ph-i2c3.dtbo \
allwinner/overlay/sun50i-h616-ph-i2c4.dtbo \
allwinner/overlay/sun50i-h616-ph-pwm12.dtbo \
allwinner/overlay/sun50i-h616-ph-pwm34.dtbo \
allwinner/overlay/sun50i-h616-ph-uart2.dtbo \
allwinner/overlay/sun50i-h616-ph-uart5.dtbo \
allwinner/overlay/sun50i-h616-pi-i2c0.dtbo \
allwinner/overlay/sun50i-h616-pi-i2c1.dtbo \
allwinner/overlay/sun50i-h616-pi-i2c2.dtbo \
allwinner/overlay/sun50i-h616-pi-pwm1.dtbo \
allwinner/overlay/sun50i-h616-pi-pwm2.dtbo \
allwinner/overlay/sun50i-h616-pi-pwm3.dtbo \
allwinner/overlay/sun50i-h616-pi-pwm4.dtbo \
allwinner/overlay/sun50i-h616-pi-uart2.dtbo \
allwinner/overlay/sun50i-h616-pi-uart3.dtbo \
allwinner/overlay/sun50i-h616-pi-uart4.dtbo \
allwinner/overlay/sun50i-h616-spi0-spidev.dtbo \
allwinner/overlay/sun50i-h616-spi1-cs0-cs1-spidev.dtbo \
allwinner/overlay/sun50i-h616-spi1-cs0-spidev.dtbo \
allwinner/overlay/sun50i-h616-spi1-cs1-spidev.dtbo \
allwinner/overlay/sun50i-h616-usb0-host.dtbo \
allwinner/overlay/sun50i-h616-zero2w-disable-led.dtbo \
"
UBOOT_MACHINE = "orangepi_zero2w_defconfig"
SPL_BINARY = "u-boot-sunxi-with-spl.bin"
# as for now neither graphics nor audio is supported
MACHINE_FEATURES:remove = "alsa x11"
MACHINE_FEATURES:append = "bluetooth wifi"
MACHINE_EXTRA_RRECOMMENDS = "uwe5622-firmware"

View File

@ -0,0 +1,30 @@
DESCRIPTION = "ARM Trusted Firmware Allwinner"
LICENSE = "BSD-3-Clause"
LIC_FILES_CHKSUM = "file://docs/license.rst;md5=b2c740efedc159745b9b31f88ff03dde"
SRC_URI = "git://github.com/ARM-software/arm-trusted-firmware;branch=master;protocol=https"
SRCREV = "d3e71ead6ea5bc3555ac90a446efec84ef6c6122"
# v2.9
S = "${WORKDIR}/git"
B = "${WORKDIR}/build"
COMPATIBLE_MACHINE = "(sun50i|sun50i-h616)"
PLATFORM = "sun50i_h616"
LDFLAGS[unexport] = "1"
do_compile() {
oe_runmake -C ${S} BUILD_BASE=${B} \
CROSS_COMPILE=${TARGET_PREFIX} \
PLAT=${PLATFORM} \
bl31 \
all
}
do_install() {
install -D -p -m 0644 ${B}/${PLATFORM}/release/bl31.bin ${DEPLOY_DIR_IMAGE}/bl31.bin
}

View File

@ -0,0 +1,108 @@
diff --git a/arch/arm/dts/sun50i-h616-orangepi-zero2w.dts b/arch/arm/dts/sun50i-h616-orangepi-zero2w.dts
index 2e6e740dc..971891901 100644
--- a/arch/arm/dts/sun50i-h616-orangepi-zero2w.dts
+++ b/arch/arm/dts/sun50i-h616-orangepi-zero2w.dts
@@ -17,10 +17,11 @@
aliases {
ethernet0 = &emac0;
serial0 = &uart0;
+ serial5 = &uart5;
};
chosen {
- stdout-path = "serial0:115200n8";
+ stdout-path = "serial5:115200n8";
};
leds {
@@ -170,6 +171,12 @@
status = "okay";
};
+&uart5 {
+ pinctrl-names = "default";
+ pinctrl-0 = <&uart5_ph_pins>;
+ status = "okay";
+};
+
&usbotg {
dr_mode = "peripheral";
status = "okay";
diff --git a/arch/arm/dts/sun50i-h616.dtsi b/arch/arm/dts/sun50i-h616.dtsi
index dd4d2f311..1cc260298 100644
--- a/arch/arm/dts/sun50i-h616.dtsi
+++ b/arch/arm/dts/sun50i-h616.dtsi
@@ -211,7 +211,10 @@
pins = "PH0", "PH1";
function = "uart0";
};
-
+ uart5_ph_pins: uart5-ph-pins {
+ pins = "PH2", "PH3";
+ function = "uart5";
+ };
uart1_pins: uart1-pins {
pins = "PG6", "PG7";
function = "uart1";
diff --git a/arch/arm/include/asm/arch-sunxi/gpio.h b/arch/arm/include/asm/arch-sunxi/gpio.h
index 2969a530a..bcb792a09 100644
--- a/arch/arm/include/asm/arch-sunxi/gpio.h
+++ b/arch/arm/include/asm/arch-sunxi/gpio.h
@@ -208,6 +208,7 @@ enum sunxi_gpio_number {
#define SUN9I_GPH_UART0 2
#define SUN50I_H6_GPH_UART0 2
#define SUN50I_H616_GPH_UART0 2
+#define SUN50I_H616_GPH_UART5 2
#define SUNXI_GPI_SDC3 2
#define SUN7I_GPI_TWI3 3
diff --git a/arch/arm/mach-sunxi/board.c b/arch/arm/mach-sunxi/board.c
index 0537c29b2..650bb928a 100644
--- a/arch/arm/mach-sunxi/board.c
+++ b/arch/arm/mach-sunxi/board.c
@@ -135,6 +135,10 @@ static int gpio_init(void)
sunxi_gpio_set_cfgpin(SUNXI_GPH(0), SUN50I_H616_GPH_UART0);
sunxi_gpio_set_cfgpin(SUNXI_GPH(1), SUN50I_H616_GPH_UART0);
sunxi_gpio_set_pull(SUNXI_GPH(1), SUNXI_GPIO_PULL_UP);
+#elif CONFIG_CONS_INDEX == 6 && defined(CONFIG_MACH_SUN50I_H616)
+ sunxi_gpio_set_cfgpin(SUNXI_GPH(2), SUN50I_H616_GPH_UART5);
+ sunxi_gpio_set_cfgpin(SUNXI_GPH(3), SUN50I_H616_GPH_UART5);
+ sunxi_gpio_set_pull(SUNXI_GPH(3), SUNXI_GPIO_PULL_UP);
#elif CONFIG_CONS_INDEX == 1 && defined(CONFIG_MACH_SUN8I_A83T)
sunxi_gpio_set_cfgpin(SUNXI_GPB(9), SUN8I_A83T_GPB_UART0);
sunxi_gpio_set_cfgpin(SUNXI_GPB(10), SUN8I_A83T_GPB_UART0);
diff --git a/configs/orangepi_zero2w_defconfig b/configs/orangepi_zero2w_defconfig
index 7bec5462d..267a708e8 100644
--- a/configs/orangepi_zero2w_defconfig
+++ b/configs/orangepi_zero2w_defconfig
@@ -16,3 +16,4 @@ CONFIG_AXP_DCDC3_VOLT=1100
CONFIG_SPL_I2C_SUPPORT=y
CONFIG_AXP313A_POWER=y
CONFIG_SPL_SPI_SUNXI=y
+CONFIG_CONS_INDEX=6
diff --git a/include/configs/sunxi-common.h b/include/configs/sunxi-common.h
index eb9ccf47c..2d93713a4 100644
--- a/include/configs/sunxi-common.h
+++ b/include/configs/sunxi-common.h
@@ -46,6 +46,9 @@
# define CONFIG_SYS_NS16550_COM3 SUNXI_UART2_BASE
# define CONFIG_SYS_NS16550_COM4 SUNXI_UART3_BASE
# define CONFIG_SYS_NS16550_COM5 SUNXI_R_UART_BASE
+#ifdef CONFIG_MACH_SUN50I_H616
+# define CONFIG_SYS_NS16550_COM6 0x05001400
+#endif
#endif
/* CPU */
@@ -470,7 +473,7 @@ extern int soft_i2c_gpio_scl;
MEM_LAYOUT_ENV_EXTRA_SETTINGS \
DFU_ALT_INFO_RAM \
"fdtfile=" FDTFILE "\0" \
- "console=ttyS0,115200\0" \
+ "console=ttyS5,115200\0" \
SUNXI_MTDIDS_DEFAULT \
SUNXI_MTDPARTS_DEFAULT \
"uuid_gpt_esp=" UUID_GPT_ESP "\0" \

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,83 @@
# default values
setenv load_addr "0x45000000"
setenv overlay_error "false"
setenv rootdev "/dev/mmcblk1p2"
setenv verbosity "1"
setenv rootfstype "ext4"
setenv console "both"
setenv bootlogo "false"
setenv overlay_prefix "sun50i-h616"
setenv disp_mode "1920x1080p60"
setenv recovery "false"
setenv recovery_image "recovery.initramfs"
# Print boot source
itest.b *0x10028 == 0x00 && echo "U-boot loaded from SD"
itest.b *0x10028 == 0x02 && echo "U-boot loaded from eMMC or secondary SD"
itest.b *0x10028 == 0x03 && echo "U-boot loaded from SPI"
echo "Boot script loaded from ${devtype}"
if test -e ${devtype} ${devnum} config.txt; then
load ${devtype} ${devnum} ${load_addr} config.txt
env import -t ${load_addr} ${filesize}
fi
if test "${console}" = "display" || test "${console}" = "both"; then setenv consoleargs "console=ttyS0,115200 console=tty1"; fi
if test "${console}" = "serial"; then setenv consoleargs "console=ttyS0,115200"; fi
if test "${bootlogo}" = "true"; then
setenv consoleargs "splash plymouth.ignore-serial-consoles ${consoleargs}"
else
setenv consoleargs "splash=verbose ${consoleargs}"
fi
# get PARTUUID of first partition on SD/eMMC it was loaded from
# mmc 0 is always mapped to device u-boot (2016.09+) was loaded from
if test "${devtype}" = "mmc"; then part uuid mmc 0:1 partuuid; fi
# consoleblank=0 loglevel=${verbosity}
setenv bootargs "root=${rootdev} rootwait rootfstype=${rootfstype} ${consoleargs} ubootpart=${partuuid} usb-storage.quirks=${usbstoragequirks} ${extraargs} ${extraboardargs}"
# if test "${docker_optimizations}" = "on"; then setenv bootargs "${bootargs} cgroup_enable=memory swapaccount=1"; fi
load ${devtype} ${devnum} ${fdt_addr_r} ${fdtfile}
fdt addr ${fdt_addr_r}
fdt resize 65536
for overlay_file in ${overlays}; do
if load ${devtype} ${devnum} ${load_addr} allwinner/overlay/${overlay_prefix}-${overlay_file}.dtbo; then
echo "Applying kernel provided DT overlay ${overlay_prefix}-${overlay_file}.dtbo"
fdt apply ${load_addr} || setenv overlay_error "true"
fi
done
if test "${overlay_error}" = "true"; then
echo "Error applying DT overlays, restoring original DT"
load ${devtype} ${devnum} ${fdt_addr_r} ${fdtfile}
else
if load ${devtype} ${devnum} ${load_addr} allwinner/overlay/${overlay_prefix}-fixup.scr; then
echo "Applying kernel provided DT fixup script (${overlay_prefix}-fixup.scr)"
source ${load_addr}
fi
fi
if test "${ethernet_phy}" = "rtl8211f"; then
fdt set /soc/ethernet@5020000 allwinner,rx-delay-ps <3100>
fdt set /soc/ethernet@5020000 allwinner,tx-delay-ps <700>
fi
if test "${ethernet_phy}" = "yt8531c"; then
fdt set /soc/ethernet@5020000 allwinner,rx-delay-ps <0>
fdt set /soc/ethernet@5020000 allwinner,tx-delay-ps <600>
fi
load ${devtype} ${devnum} ${kernel_addr_r} Image
if test "${recovery}" = "true"; then
load ${devtype} ${devnum} ${ramdisk_addr_r} ${recovery_image}
booti ${kernel_addr_r} ${ramdisk_addr_r} ${fdt_addr_r}
else
booti ${kernel_addr_r} - ${fdt_addr_r}
fi
# Recompile with:
# mkimage -C none -A arm -T script -d /boot/boot.cmd /boot/boot.scr

Binary file not shown.

View File

@ -0,0 +1,62 @@
DESCRIPTION = "U-Boot port for orange pi zero 2w"
require recipes-bsp/u-boot/u-boot.inc
LICENSE = "GPL-2.0-only"
LIC_FILES_CHKSUM = "file://Licenses/gpl-2.0.txt;md5=b234ee4d69f5fce4486a80fdaf4a4263"
FILESEXTRAPATHS:prepend := "${THISDIR}/files:"
DEPENDS:append = " bc-native dtc-native swig-native python3-native flex-native bison-native python3-setuptools-native "
DEPENDS:append = " atf-50i-h616 "
# No patches for other machines yet
# PROVIDES = "virtual/bootloader"
# COMPATIBLE_MACHINE = "orange-pi-zero2w"
# DEFAULT_PREFERENCE_orange-pi-zero2w="1"
COMPATIBLE_MACHINE = "(sun4i|sun5i|sun7i|sun8i|sun50i)"
DEFAULT_PREFERENCE:sun4i = "1"
DEFAULT_PREFERENCE:sun5i = "1"
DEFAULT_PREFERENCE:sun7i = "1"
DEFAULT_PREFERENCE:sun8i = "1"
DEFAULT_PREFERENCE:sun50i = "1"
SRC_URI = " \
git://github.com/orangepi-xunlong/u-boot-orangepi.git;protocol=https;branch=v2021.07-sunxi \
file://boot.cmd \
"
PE = "1"
PV = "v2021.07+git${SRCPV}"
SRCREV = "6fe17fac388aad17490cf386578b7532975e567f"
S = "${WORKDIR}/git"
PACKAGE_ARCH = "${MACHINE_ARCH}"
SPL_BINARY="u-boot-sunxi-with-spl.bin"
UBOOT_ENV_SUFFIX = "scr"
UBOOT_ENV = "boot"
EXTRA_OEMAKE:append = ' HOSTLDSHARED="${BUILD_CC} -shared ${BUILD_LDFLAGS} ${BUILD_CFLAGS}" '
EXTRA_OEMAKE:append = " BL31=${DEPLOY_DIR_IMAGE}/bl31.bin SCP=/dev/null"
do_compile[depends] += "atf-50i-h616:do_install"
do_configure() {
oe_runmake ${UBOOT_MACHINE}
# oe_runmake -C ${S} O=${B} ${UBOOT_MACHINE} mrproper
}
do_compile() {
oe_runmake
oe_runmake u-boot-initial-env
${B}/tools/mkimage -C none -A arm -T script -d ${WORKDIR}/boot.cmd ${WORKDIR}/${UBOOT_ENV_BINARY}
}

View File

@ -0,0 +1,28 @@
hostname = "diya"
do_install:append () {
cat << 'EOF' >> "${D}${sysconfdir}/profile"
export GDK_BACKEND=wayland
export XDG_RUNTIME_DIR=/home/$USER/.xdg
export XDG_CONFIG_HOME=/home/$USER/.config
export PATH=$PATH:/home/$USER/bin:/home/$USER/.local/bin
export LD_LIBRARY_PATH=/home/$USER/lib:/home/$USER/.local/lib
if [ ! -e "$XDG_RUNTIME_DIR" ]; then
mkdir -p "$XDG_RUNTIME_DIR"
fi
export TERM=xterm-256color
EOF
cat << EOF >> "${D}${sysconfdir}/profile"
export MACHINE=${MACHINE}
EOF
cat << EOF >> "${D}${sysconfdir}/modules"
uwe5622_bsp_sdio
sprdwl_ng
sprdbt_tty
bluetooth
hci_uart
rfcomm
EOF
}

View File

@ -0,0 +1,7 @@
FILESEXTRAPATHS:prepend := "${THISDIR}/files:"
SRC_URI += "file://default"
do_install:append () {
rm -rf ${D}/etc/dropbear
install -m 0644 ${WORKDIR}/default ${D}${sysconfdir}/default/dropbear
}

View File

@ -0,0 +1,2 @@
DROPBEAR_EXTRA_ARGS="-w"
DROPBEAR_RSAKEY_DIR=/etc/dropbear

View File

@ -0,0 +1,40 @@
#webrtc-audio-processing \
pulseaudio \
pulseaudio-server \
alsa-utils \
pulseaudio-module-alsa-card \
pulseaudio-module-alsa-source \
pulseaudio-module-alsa-sink \
pulseaudio-module-cli \
pulseaudio-module-echo-cancel \
pulseaudio-misc \
i2c-tools \
mpg123
libsdl2-mixer \
#tslib
#tslib-tests
#tslib-calibrate
#tslib-uinput
libsdl2 \
libsdl2-ttf \
libsdl2-image \
libsdl2-mixer \
libsdl2-net \
# v4l-utils
evtest
# openvt -v -c 5 -- /usr/bin/weston --tty=/dev/tty5
mesa \
mesa-demos \
libgbm \
dtdebug=1
dtoverlay=vc4-kms-v3d
dtoverlay=vc4-kms-dpi-generic,hactive=480,hfp=26,hsync=16,hbp=10
dtparam=vactive=640,vfp=25,vsync=10,vbp=16
dtparam=clock-frequency=32000000,rgb666-padhi
Diyas symbolise goodness and purity, and lighting them denotes dispelling darkness and going into light.

View File

@ -0,0 +1 @@
core-image-minimal.bbappend

View File

@ -0,0 +1,63 @@
inherit extrausers
# usermod -p BJpK8ADNDLsGg root;
EXTRA_USERS_PARAMS = "usermod -p 2Pe/4xyFxsokE diya; \
usermod -a -G video diya; \
usermod -a -G tty diya; \
usermod -a -G input diya; \
usermod -a -G dialout diya; \
usermod -a -G audio diya; \
usermod -a -G avahi diya; \
usermod -a -G sudo diya \
"
IMAGE_BOOT_FILES:append = "fs_resize config.txt recovery-${MACHINE}.cpio.gz Image boot.scr ${KERNEL_DEVICETREE} allwinner/overlay/sun50i-h616-fixup.scr "
IMAGE_INSTALL:append = "kernel-modules \
libcurl \
libdrm \
libgbm \
libgles2 \
libegl-mesa \
libglapi \
libudev \
libinput \
pango \
libxkbcommon \
xkeyboard-config \
diya-overlay \
seatd \
pixman \
cairo \
glib-2.0 \
udev \
glew \
freetype \
fontconfig \
librsvg librsvg-gtk \
gdk-pixbuf \
gtk-layer-shell \
gobject-introspection \
l3afpad \
mesa \
sudo \
htop \
i2c-tools \
bash \
nano \
wpa-supplicant \
evtest \
rsync \
coreutils \
wayland wayland-protocols \
foot swaybg swayidle swaylock wlopm sfwbar tofi wtype \
mc \
gdbserver \
"
IMAGE_PREPROCESS_COMMAND += "image_patch;"
image_patch () {
# delete unused kernel image
rm -rf ${IMAGE_ROOTFS}/boot/*
}
# labwc wlr-randr

View File

@ -0,0 +1,53 @@
DESCRIPTION = "Recovery initramfs image."
PACKAGE_INSTALL = "recovery-boot \
dosfstools \
e2fsprogs \
util-linux-fsck \
kernel-modules \
busybox \
sysvinit \
sysvinit-inittab \
${VIRTUAL-RUNTIME_base-utils} \
udev \
initscripts \
base-passwd \
${ROOTFS_BOOTSTRAP_INSTALL}"
# Do not pollute the initrd image with rootfs features
IMAGE_FEATURES = ""
export IMAGE_BASENAME = "${MLPREFIX}recovery"
IMAGE_NAME_SUFFIX ?= ""
IMAGE_LINGUAS = ""
LICENSE = "MIT"
IMAGE_FSTYPES = "${INITRAMFS_FSTYPES}"
inherit core-image extrausers
IMAGE_ROOTFS_SIZE = "8192"
IMAGE_ROOTFS_EXTRA_SPACE = "0"
EXTRA_USERS_PARAMS = "usermod -p 2Pe/4xyFxsokE root "
# Use the same restriction as initramfs-module-install
COMPATIBLE_HOST = '(x86_64.*|i.86.*|arm.*|aarch64.*)-(linux.*|freebsd.*)'
IMAGE_PREPROCESS_COMMAND += "image_patch;"
image_patch () {
# delete unused image
rm -rf ${IMAGE_ROOTFS}/boot/*
# create /etc/fstab
cat << EOF > ${IMAGE_ROOTFS}/etc/fstab
/dev/mmcblk1p1 /boot auto defaults 0 0
/dev/mmcblk1p4 /home auto defaults 0 0
EOF
cat << EOF > ${IMAGE_ROOTFS}/etc/hostname
diya-recovery
EOF
}

View File

@ -0,0 +1,24 @@
# /etc/network/interfaces -- configuration file for ifup(8), ifdown(8)
# The loopback interface
auto lo
iface lo inet loopback
# Wireless interfaces
auto wlan0
iface wlan0 inet dhcp
# wireless_mode managed
# wireless_essid any
# wpa-driver wext
wpa-conf /etc/network/wpa_supplicant.conf
# Ethernet/RNDIS gadget (g_ether)
# ... or on host side, usbnet and random hwaddr
iface usb0 inet static
address 192.168.7.2
netmask 255.255.255.0
network 192.168.7.0
gateway 192.168.7.1
# Bluetooth networking
# iface bnep0 inet dhcp

View File

@ -0,0 +1,7 @@
FILESEXTRAPATHS:prepend := "${THISDIR}/files:"
SRC_URI += " file://itf_diya "
do_install:append () {
rm ${D}/etc/network/interfaces
install -m 0644 ${WORKDIR}/itf_diya ${D}/etc/network/interfaces
}

View File

@ -0,0 +1,44 @@
DESCRIPTION = "Auto configuration deployment from media"
DEPENDS = ""
LICENSE = "MIT"
LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302"
SRC_URI += "file://confd \
file://expandfs.sh \
file://80_diya \
file://fs_resize \
file://boot-to-recovery"
inherit update-rc.d useradd
USERADD_PACKAGES = "${PN}"
GROUPADD_PACKAGES = "${PN}"
USERADD_PARAM:${PN} = "-u 1000 -d /home/diya -r -s /bin/sh diya"
INITSCRIPT_NAME = "confd"
INITSCRIPT_PARAMS = "start 30 S ."
do_install() {
install -d ${D}/${sysconfdir}/init.d/
install -d ${DEPLOY_DIR_IMAGE}
install -m 0755 ${WORKDIR}/confd ${D}/${sysconfdir}/init.d/confd
install -d ${D}/sbin/
install -d ${D}/etc/default/volatiles
# install -m 0644 ${WORKDIR}/80_diya ${D}${sysconfdir}/default/volatiles
install -m 0755 ${WORKDIR}/expandfs.sh ${D}/sbin/expandfs.sh
install -m 0755 ${WORKDIR}/boot-to-recovery ${D}/sbin/boot-to-recovery
install -m 0755 ${WORKDIR}/fs_resize ${DEPLOY_DIR_IMAGE}/
cat << EOF >> ${DEPLOY_DIR_IMAGE}/config.txt
recovery=false
recovery_image=recovery-${MACHINE}.cpio.gz
console=both
bootlogo=false
EOF
install -d ${D}/var/etc
install -d ${D}/var/etc/upper
install -d ${D}/var/etc/work
}

View File

@ -0,0 +1,3 @@
# d root root 0755 /var/etc/upper none
# d root root 0755 /var/etc/work none
# l root root 0644 /etc/dropbear /var/etc/dropbear

View File

@ -0,0 +1,21 @@
#! /bin/sh
if [[ $(/usr/bin/id -u) -ne 0 ]]; then
echo "$0 shall be run as root"
exit 1
fi
. /etc/profile
if [ ! -e /boot/config.txt ]; then
# prepare env for recovery boot
cat << EOF > /boot/config.txt
recovery=true
recovery_image=recovery-${MACHINE}.cpio.gz
EOF
else
sed -i 's/^.*recovery.*/recovery=true/g' /boot/config.txt || \
echo "recovery=true" >> /boot/config.txt
fi
echo "Rebooting to recovery mode"
reboot

View File

@ -0,0 +1,44 @@
#!/bin/sh
PATH=/sbin:/bin:/usr/sbin:/usr/bin
DESC="Auto deployment configuration from media"
case "$1" in
start)
echo -n "Start $DESC: "
# mount the overlay which is not auto mount by fstab
# this make /etc editable
mount -t overlay -o lowerdir=/etc,upperdir=/var/etc/upper,workdir=/var/etc/work overlay /etc
# for some reason the LCD backlight is turned off
# need to turn it on manually
if [ -f "/boot/fs_resize" ]; then
/sbin/expandfs.sh
touch /boot/home_partition_should_be_formated
rm /boot/fs_resize
reboot
fi
if [ -f "/boot/home_partition_should_be_formated" ]; then
echo "Trying to format the home partition"
umount /dev/mmcblk1p4
yes | mkfs.ext4 /dev/mmcblk1p4
mount /dev/mmcblk1p4 /home
mkdir -p /home/diya
chown -R diya:diya /home/diya
rm /boot/home_partition_should_be_formated
fi
if [ -e "/boot/wpa_supplicant.conf" ];then
mv /boot/wpa_supplicant.conf /etc/network/
reboot
fi
# display information
# disable wifi power save
# /usr/sbin/iw wlan0 set power_save off
;;
*)
N=/etc/init.d/$NAME
echo "Usage: $N {start}" >&2
exit 1
;;
esac
exit 0

View File

@ -0,0 +1,37 @@
#! /bin/sh
if [[ $(/usr/bin/id -u) -ne 0 ]]; then
echo "$0 shall be run as root"
exit 1
fi
line=$(
sed -e 's/\s*\([\+0-9a-zA-Z]*\).*/\1/' << EOF | fdisk /dev/mmcblk1 | grep /dev/mmcblk1p4
p
q
EOF
)
echo "Partition: $line"
#start_sector=$(echo "$line" | cut -d' ' -f14)
start_sector=$(echo "$line" | cut -d' ' -f15)
echo "Start sector is: $start_sector"
if [ -z "$start_sector" ]; then
echo "Cannot find the start sector"
exit 1
fi
echo "Expanding the partition"
sed -e 's/\s*\([\+0-9a-zA-Z]*\).*/\1/' << EOF | fdisk /dev/mmcblk1p4
d # delete partition
4 # number 4
n # new partition
p # primary partition
4 # partition number 4
$start_sector
# default - end of disk
p # print the in-memory partition table
w # write the partition table
q # and we're done
EOF

View File

@ -0,0 +1 @@
resize the partition

View File

@ -0,0 +1,21 @@
#!/bin/sh
PATH=/sbin:/bin:/usr/sbin:/usr/bin
DESC="Custom configuration"
. /etc/profile
case "$1" in
start)
echo -n "Start $DESC: "
sed -i 's/^.*recovery.*/recovery=false/g' /boot/config.txt || \
echo "recovery=false" >> /boot/config.txt
;;
*)
N=/etc/init.d/$NAME
echo "Usage: $N {start}" >&2
exit 1
;;
esac
exit 0

View File

@ -0,0 +1,147 @@
#! /bin/sh
. /etc/profile
DEFAULT_ROOTFS_NAME="rootfs-$MACHINE.tar.bz2"
DEFAULT_KERNEL_NAME="Image-$MACHINE.bin"
DEFAULT_INITRAMFS_NAME="recovery-$MACHINE.cpio.gz"
UPDATE_SRC_PATH="/home/diya/.update"
ROOTFS_DEV="/dev/mmcblk1p2"
SUPPORTED_COMMAND="rootfs kernel initramfs all"
TMP_MOUNT="/tmp/rootfs"
rootfs()
{
filename=$1
if [ -z "$filename" ]; then
filename="$DEFAULT_ROOTFS_NAME"
fi
path="$UPDATE_SRC_PATH/$filename"
backup_file="$UPDATE_SRC_PATH/rootfs-backup.img"
echo "Checking rootfs at: $path"
if [ ! -e "$path" ]; then
echo "Error: rootfs file not found"
return 1
fi
# backup the rootfs file
echo "Backing up the current rootfs"
if ! dd if=$ROOTFS_DEV of=$backup_file; then
echo "Error: unable to backup current rootfs"
return 1
fi
echo "Format rootfs partition"
if ! mkfs.ext4 -F $ROOTFS_DEV; then
echo "Error: Unable to format rootfs partition. Restore and quit"
dd if=$backup_file of=$ROOTFS_DEV
return 1
fi
mkdir -p $TMP_MOUNT
echo "Mount rootfs partition to $TMP_MOUNT"
if ! mount $ROOTFS_DEV $TMP_MOUNT; then
echo "Error: Unable to mount rootfs partition. Restore and quit"
dd if=$backup_file of=$ROOTFS_DEV
return 1
fi
echo "Installing new rootfs"
if ! tar -xpvf "$path" -C $TMP_MOUNT; then
echo "Error: unable to install new rootfs. Restore and quit"
umount $TMP_MOUNT
dd if=$backup_file of=$ROOTFS_DEV
return 1
fi
echo "Patch /etc/fstab"
cat << EOF >> $TMP_MOUNT/etc/fstab
/dev/mmcblk1p1 /boot vfat defaults 0 0
/dev/mmcblk1p3 /var/etc ext4 defaults 0 0
/dev/mmcblk1p4 /home ext4 defaults 0 0
EOF
sync
echo "Unmount the rootfs partition"
umount $TMP_MOUNT
echo "Done"
return 0
}
kernel()
{
filename=$1
if [ -z "$filename" ]; then
filename="$DEFAULT_KERNEL_NAME"
fi
path="$UPDATE_SRC_PATH/$filename"
echo "Checking kernel at: $path"
if [ ! -e "$path" ]; then
echo "Error: kernel file not found"
return 1
fi
echo "Update kernel"
cp -v "$path" /boot/kernel8.img
cd /boot
sync
echo "Done"
return 0
}
initramfs()
{
filename=$1
if [ -z "$filename" ]; then
filename="$DEFAULT_INITRAMFS_NAME"
fi
path="$UPDATE_SRC_PATH/$filename"
echo "Checking initramfs at: $path"
if [ ! -e "$path" ]; then
echo "Error: initramfs file not found"
return 1
fi
echo "Update recovery intramfs"
cp -v "$path" /boot/$DEFAULT_INITRAMFS_NAME
cd /boot
sync
echo "Done"
return 0
}
command_valid() {
VALUE=$1
echo $SUPPORTED_COMMAND | tr " " '\n' | grep -F -q -x "$VALUE"
}
name=$(basename $0)
cmd=${name#diya-update-}
file="$1"
if ! command_valid "$cmd"; then
cmd="$1"
file="$2"
fi
case "$cmd" in
rootfs)
rootfs $file
;;
kernel)
kernel $file
;;
initramfs)
initramfs $file
;;
all)
rootfs && kernel && initramfs
;;
*)
cat << EOF
Usage: $name <command> [file]
commands:
- rootfs: update rootfs
- kernel: update kernel image
- initramfs: update recovery initramfs
EOF
exit 1
;;
esac

107
recipes-diya/initramfs/files/init Executable file
View File

@ -0,0 +1,107 @@
#!/bin/sh
# Copyright (C) 2011 O.S. Systems Software LTDA.
# Licensed on MIT
#
# Provides the API to be used by the initramfs modules
#
# Modules need to provide the following functions:
#
# <module>_enabled : check if the module ought to run (return 1 to skip)
# <module>_run : do what is need
#
# Boot parameters are available on environment in the as:
#
# 'foo=value' as 'bootparam_foo=value'
# 'foo' as 'bootparam_foo=true'
# 'foo.bar[=value] as 'foo_bar=[value|true]'
# Load kernel module
load_kernel_module() {
if modprobe $1 >/dev/null 2>&1; then
info "Loaded module $1"
else
debug "Failed to load module $1"
fi
}
# Prints information
msg() {
echo "$@" >/dev/console
}
# Prints information if verbose bootparam is used
info() {
[ -n "$bootparam_verbose" ] && echo "$@" >/dev/console
}
# Prints information if debug bootparam is used
debug() {
[ -n "$bootparam_debug" ] && echo "DEBUG: $@" >/dev/console
}
# Prints a message and start a endless loop
fatal() {
echo $1 >/dev/console
echo >/dev/console
if [ -n "$bootparam_init_fatal_sh" ]; then
sh
else
while [ "true" ]; do
sleep 3600
done
fi
}
# Variables shared amoung modules
EFI_DIR=/sys/firmware/efi # place to store device firmware information
# initialize /proc, /sys, /run/lock and /var/lock
mkdir -p /proc /sys /run/lock /var/lock /var/run /home
mount -t proc proc /proc
mount -t sysfs sysfs /sys
if [ -d $EFI_DIR ];then
mount -t efivarfs none /sys/firmware/efi/efivars
fi
# populate bootparam environment
for p in `cat /proc/cmdline`; do
if [ -n "$quoted" ]; then
value="$value $p"
if [ "`echo $p | sed -e 's/\"$//'`" != "$p" ]; then
eval "bootparam_${quoted}=${value}"
unset quoted
fi
continue
fi
opt=`echo $p | cut -d'=' -f1`
opt=`echo $opt | sed -e 'y/.-/__/'`
if [ "`echo $p | cut -d'=' -f1`" = "$p" ]; then
eval "bootparam_${opt}=true"
else
value="`echo $p | cut -d'=' -f2-`"
if [ "`echo $value | sed -e 's/^\"//'`" != "$value" ]; then
quoted=${opt}
continue
fi
eval "bootparam_${opt}=\"${value}\""
fi
done
# use /dev with devtmpfs
if grep -q devtmpfs /proc/filesystems; then
mkdir -p /dev
mount -t devtmpfs devtmpfs /dev
else
if [ ! -d /dev ]; then
fatal "ERROR: /dev doesn't exist and kernel doesn't has devtmpfs enabled."
fi
fi
# run init
exec /sbin/init
# Catch all
fatal "ERROR: Initramfs failed to initialize the system."

View File

@ -0,0 +1,47 @@
SUMMARY = "Modular initramfs system"
LICENSE = "MIT"
LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
RDEPENDS:${PN} += "${VIRTUAL-RUNTIME_base-utils} sysvinit"
RRECOMMENDS:${PN} = "${VIRTUAL-RUNTIME_base-utils-syslog}"
FILESEXTRAPATHS:prepend := "${THISDIR}/files:"
PR = "r4"
inherit allarch update-rc.d
SRC_URI = "file://init \
file://confd \
file://diya-update \
"
S = "${WORKDIR}"
INITSCRIPT_NAME = "confd"
INITSCRIPT_PARAMS = "start 30 S ."
do_install() {
install -d ${D}/etc/init.d
install -d ${D}/sbin
# base
install -m 0755 ${WORKDIR}/init ${D}/init
install -m 0755 ${WORKDIR}/confd ${D}/etc/init.d/confd
cat << EOF >> ${D}/etc/profile
export MACHINE=${MACHINE}
EOF
install -m 0755 ${WORKDIR}/diya-update ${D}/sbin/
# create symlink
ln -sf /sbin/diya-update ${D}/sbin/diya-update-rootfs
ln -sf /sbin/diya-update ${D}/sbin/diya-update-kernel
ln -sf /sbin/diya-update ${D}/sbin/diya-update-initramfs
ln -sf /sbin/diya-update ${D}/sbin/diya-update-all
# Create device nodes expected by some kernels in initramfs
# before even executing /init.
install -d ${D}/dev
mknod -m 622 ${D}/dev/console c 5 1
}
FILES:${PN} = "/etc /init /dev /sbin"

View File

@ -0,0 +1,9 @@
do_install:append() {
# grant all permission to sudo group
sed -i 's/^#\s*\(%sudo\s*ALL=(ALL:ALL)\s*ALL\)/\1/' ${D}/${sysconfdir}/sudoers
# allow sudo group to power off/reboot system without password
cat << EOF >> ${D}/${sysconfdir}/sudoers
## sudo user group is allowed to execute halt and reboot
%sudo ALL=NOPASSWD: /sbin/halt, /sbin/reboot, /sbin/poweroff, /usr/bin/swaylock
EOF
}

View File

@ -0,0 +1,4 @@
DEPENS += " mesa libdrm alsa virtual/libgbm virtual/libgles2 virtual/libgl udev libudev "
PACKAGECONFIG = " kmsdrm opengl gles2 alsa libusb "
# PACKAGECONFIG:remove = "x11 wayland"

View File

@ -0,0 +1,7 @@
# change default weston user to diya
do_install:append() {
if [ -e ${D}/${sysconfdir}/init.d/weston ]; then
sed -i 's#WESTON_USER=weston#WESTON_USER=diya WESTON_GROUP=weston#' ${D}/${sysconfdir}/init.d/weston
fi
}

View File

@ -0,0 +1,28 @@
From 82fa50eadf11f01e6315f5e2c2a29845e2a516b8 Mon Sep 17 00:00:00 2001
From: Ondrej Jirman <megous@megous.com>
Date: Mon, 8 Apr 2019 03:49:26 +0200
Subject: [PATCH] Fix reset issue on H6 by using R_WDOG
Inspired by froezuses patch here:
https://forum.armbian.com/topic/9833-h6-famous-reboot-problem/?page=3
Signed-off-by: Ondrej Jirman <megous@megous.com>
---
plat/allwinner/sun50i_h6/include/sunxi_mmap.h | 3 +++
1 file changed, 3 insertions(+)
diff --git a/plat/allwinner/sun50i_h6/include/sunxi_mmap.h b/plat/allwinner/sun50i_h6/include/sunxi_mmap.h
index f36491a8..f01745a4 100644
--- a/plat/allwinner/sun50i_h6/include/sunxi_mmap.h
+++ b/plat/allwinner/sun50i_h6/include/sunxi_mmap.h
@@ -58,4 +58,7 @@
#define SUNXI_R_UART_BASE 0x07080000
#define SUNXI_R_PIO_BASE 0x07022000
+#undef SUNXI_WDOG_BASE
+#define SUNXI_WDOG_BASE SUNXI_R_WDOG_BASE
+
#endif /* SUNXI_MMAP_H */
--
2.21.0

View File

@ -0,0 +1,13 @@
diff --git a/drivers/net/wireless/rtl88x2cs/Makefile b/drivers/net/wireless/rtl88x2cs/Makefile
index 814cf1e1ba5f..fe0c5cbe991a 100755
--- a/drivers/net/wireless/rtl88x2cs/Makefile
+++ b/drivers/net/wireless/rtl88x2cs/Makefile
@@ -2316,7 +2316,7 @@ endif
########### HAL_RTL8822C #################################
ifeq ($(CONFIG_RTL8822C), y)
-include $(TopDIR)/drivers/net/wireless/rtl88x2cs/rtl8822c.mk
+include $(src)/rtl8822c.mk
EXTRA_CFLAGS += -DCONFIG_RTW_IOCTL_SET_COUNTRY
endif

View File

@ -0,0 +1,13 @@
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-h616-orangepi-zero2w.dts b/arch/arm64/boot/dts/allwinner/sun50i-h616-orangepi-zero2w.dts
index 27e817b379a4..01d2d6682c67 100755
--- a/arch/arm64/boot/dts/allwinner/sun50i-h616-orangepi-zero2w.dts
+++ b/arch/arm64/boot/dts/allwinner/sun50i-h616-orangepi-zero2w.dts
@@ -134,7 +134,7 @@ hdmi_out_con: endpoint {
&gpu {
mali-supply = <&reg_dcdc1>;
- status = "disabled";
+ status = "okay";
};
&mmc0 {

View File

@ -0,0 +1,33 @@
diff --git a/drivers/net/wireless/uwe5622/Makefile b/drivers/net/wireless/uwe5622/Makefile
index 313ea512340c..8a68354a186a 100644
--- a/drivers/net/wireless/uwe5622/Makefile
+++ b/drivers/net/wireless/uwe5622/Makefile
@@ -2,7 +2,10 @@ obj-$(CONFIG_AW_WIFI_DEVICE_UWE5622) += unisocwcn/
obj-$(CONFIG_WLAN_UWE5622) += unisocwifi/
obj-$(CONFIG_TTY_OVERY_SDIO) += tty-sdio/
-UNISOCWCN_DIR := $(shell cd $(src)/unisocwcn/ && /bin/pwd)
+# UNISOCWCN_DIR := $(shell cd $(src)/unisocwcn/ && /bin/pwd)
+mkfile_path := $(abspath $(lastword $(MAKEFILE_LIST)))
+UNISOCWCN_DIR := $(dir $(mkfile_path))/unisocwcn/
+
UNISOC_BSP_INCLUDE := $(UNISOCWCN_DIR)/include
export UNISOC_BSP_INCLUDE
diff --git a/drivers/net/wireless/uwe5622/unisocwcn/Makefile b/drivers/net/wireless/uwe5622/unisocwcn/Makefile
index f9c595747547..1ad490594cf2 100644
--- a/drivers/net/wireless/uwe5622/unisocwcn/Makefile
+++ b/drivers/net/wireless/uwe5622/unisocwcn/Makefile
@@ -129,9 +129,9 @@ ccflags-y += -DCONFIG_WCN_BOOT
ccflags-y += -DCONFIG_WCN_UTILS
#### include path ######
-ccflags-y += -I$(src)/include/
-ccflags-y += -I$(src)/platform/
-ccflags-y += -I$(src)/platform/rf/
+ccflags-y += -I$(srctree)/$(src)/include/
+ccflags-y += -I$(srctree)/$(src)/platform/
+ccflags-y += -I$(srctree)/$(src)/platform/rf/
#### add cflag for Customer ######
### ---------- Hisilicon start ---------- ###

View File

@ -0,0 +1,271 @@
diff --git a/drivers/net/wireless/rtl8189es/Makefile b/drivers/net/wireless/rtl8189es/Makefile
index faa4c0cb66d5..1a99826eee1d 100644
--- a/drivers/net/wireless/rtl8189es/Makefile
+++ b/drivers/net/wireless/rtl8189es/Makefile
@@ -19,7 +19,7 @@ ifeq ($(GCC_VER_49),1)
EXTRA_CFLAGS += -Wno-date-time # Fix compile error && warning on gcc 4.9 and later
endif
-EXTRA_CFLAGS += -I$(src)/include
+EXTRA_CFLAGS += -I$(srctree)/$(src)/include
EXTRA_LDFLAGS += --strip-debug
@@ -249,10 +249,10 @@ _HAL_INTFS_FILES := hal/hal_intf.o \
hal/led/hal_$(HCI_NAME)_led.o
-EXTRA_CFLAGS += -I$(src)/platform
+EXTRA_CFLAGS += -I$(srctree)/$(src)/platform
_PLATFORM_FILES := platform/platform_ops.o
-EXTRA_CFLAGS += -I$(src)/hal/btc
+EXTRA_CFLAGS += -I$(srctree)/$(src)/hal/btc
+EXTRA_CFLAGS += -I$(srctree)/$(src)/hal/phydm
########### HAL_RTL8188E #################################
ifeq ($(CONFIG_RTL8188E), y)
diff --git a/drivers/net/wireless/rtl8189fs/Makefile b/drivers/net/wireless/rtl8189fs/Makefile
index fd5fb4350def..06653cc3d697 100644
--- a/drivers/net/wireless/rtl8189fs/Makefile
+++ b/drivers/net/wireless/rtl8189fs/Makefile
@@ -20,7 +20,7 @@ ifeq ($(GCC_VER_49),1)
EXTRA_CFLAGS += -Wno-date-time # Fix compile error && warning on gcc 4.9 and later
endif
-EXTRA_CFLAGS += -I$(src)/include
+EXTRA_CFLAGS += -I$(srctree)/$(src)/include
EXTRA_CFLAGS += -DCONFIG_LITTLE_ENDIAN
EXTRA_CFLAGS += -DCONFIG_IOCTL_CFG80211 -DRTW_USE_CFG80211_STA_EVENT
@@ -250,10 +250,10 @@ _HAL_INTFS_FILES := hal/hal_intf.o \
hal/led/hal_$(HCI_NAME)_led.o
-EXTRA_CFLAGS += -I$(src)/platform
+EXTRA_CFLAGS += -I$(srctree)/$(src)/platform
_PLATFORM_FILES := platform/platform_ops.o
-EXTRA_CFLAGS += -I$(src)/hal/btc
+EXTRA_CFLAGS += -I$(srctree)/$(src)/hal/btc
+EXTRA_CFLAGS += -I$(srctree)/$(src)/hal/phydm
########### HAL_RTL8188E #################################
ifeq ($(CONFIG_RTL8188E), y)
diff --git a/drivers/net/wireless/rtl8192eu/Makefile b/drivers/net/wireless/rtl8192eu/Makefile
index 8ecdb72d6e0f..1372c5140e0f 100644
--- a/drivers/net/wireless/rtl8192eu/Makefile
+++ b/drivers/net/wireless/rtl8192eu/Makefile
@@ -11,7 +11,7 @@ GCC_VER_49 := $(shell echo `$(CC) -dumpversion | cut -f1-2 -d.` \>= 4.9 | bc )
ifeq ($(GCC_VER_49),1)
endif
-EXTRA_CFLAGS += -I$(src)/include
+EXTRA_CFLAGS += -I$(srctree)/$(src)/include
EXTRA_LDFLAGS += --strip-debug
@@ -251,10 +251,10 @@ _HAL_INTFS_FILES := hal/hal_intf.o \
hal/led/hal_$(HCI_NAME)_led.o
-EXTRA_CFLAGS += -I$(src)/platform
+EXTRA_CFLAGS += -I$(srctree)/$(src)/platform
_PLATFORM_FILES := platform/platform_ops.o
-EXTRA_CFLAGS += -I$(src)/hal/btc
+EXTRA_CFLAGS += -I$(srctree)/$(src)/hal/btc
+EXTRA_CFLAGS += -I$(srctree)/$(src)/hal/phydm
########### HAL_RTL8188E #################################
ifeq ($(CONFIG_RTL8188E), y)
diff --git a/drivers/net/wireless/rtl8723ds/Makefile b/drivers/net/wireless/rtl8723ds/Makefile
index ddd45612e06f..3748a4d288a3 100644
--- a/drivers/net/wireless/rtl8723ds/Makefile
+++ b/drivers/net/wireless/rtl8723ds/Makefile
@@ -19,8 +19,8 @@ ifeq ($(GCC_VER_49),1)
EXTRA_CFLAGS += -Wno-date-time # Fix compile error && warning on gcc 4.9 and later
endif
-EXTRA_CFLAGS += -I$(src)/include
-EXTRA_CFLAGS += -I$(src)/hal/phydm
+EXTRA_CFLAGS += -I$(srctree)/$(src)/include
+EXTRA_CFLAGS += -I$(srctree)/$(src)/hal/phydm
EXTRA_LDFLAGS += --strip-debug
@@ -232,11 +232,11 @@ _OUTSRC_FILES := hal/phydm/phydm_debug.o \
hal/phydm/phydm_ccx.o
-EXTRA_CFLAGS += -I$(src)/platform
+EXTRA_CFLAGS += -I$(srctree)/$(src)/platform
_PLATFORM_FILES := platform/platform_ops.o
ifeq ($(CONFIG_BT_COEXIST), y)
-EXTRA_CFLAGS += -I$(src)/hal/btc
+EXTRA_CFLAGS += -I$(srctree)/$(src)/hal/btc
_OUTSRC_FILES += hal/btc/HalBtc8192e1Ant.o \
hal/btc/HalBtc8192e2Ant.o \
hal/btc/HalBtc8723b1Ant.o \
diff --git a/drivers/net/wireless/rtl8723du/Makefile b/drivers/net/wireless/rtl8723du/Makefile
index 1b39e2722942..d5f978817e51 100644
--- a/drivers/net/wireless/rtl8723du/Makefile
+++ b/drivers/net/wireless/rtl8723du/Makefile
@@ -6,7 +6,7 @@ ifeq ($(GCC_VER_49),1)
EXTRA_CFLAGS += -Wno-date-time # Fix compile error && warning on gcc 4.9 and later
endif
-EXTRA_CFLAGS += -I$(src)/include
+EXTRA_CFLAGS += -I$(srctree)/$(src)/include
#EXTRA_LDFLAGS += --strip-debug
@@ -59,10 +59,10 @@ _HAL_INTFS_FILES := hal/hal_intf.o \
hal/hal_usb_led.o
-EXTRA_CFLAGS += -I$(src)/platform
+EXTRA_CFLAGS += -I$(srctree)/$(src)/platform
_PLATFORM_FILES := platform/platform_ops.o
-EXTRA_CFLAGS += -I$(src)/hal
+EXTRA_CFLAGS += -I$(srctree)/$(src)/hal
include $(TopDIR)/hal/phydm/phydm.mk
########### HAL_RTL8723D #################################
diff --git a/drivers/net/wireless/rtl8811cu/Makefile b/drivers/net/wireless/rtl8811cu/Makefile
index 1051a18a3cf0..fd455e266d89 100644
--- a/drivers/net/wireless/rtl8811cu/Makefile
+++ b/drivers/net/wireless/rtl8811cu/Makefile
@@ -28,7 +28,7 @@ ifeq ($(GCC_VER_49),1)
EXTRA_CFLAGS += -Wno-date-time # Fix compile error && warning on gcc 4.9 and later
endif
-EXTRA_CFLAGS += -I$(src)/include
+EXTRA_CFLAGS += -I$(srctree)/$(src)/include
EXTRA_LDFLAGS += --strip-debug
@@ -282,10 +282,10 @@ _HAL_INTFS_FILES := hal/hal_intf.o \
hal/led/hal_$(HCI_NAME)_led.o
-EXTRA_CFLAGS += -I$(src)/platform
+EXTRA_CFLAGS += -I$(srctree)/$(src)/platform
_PLATFORM_FILES := platform/platform_ops.o
-EXTRA_CFLAGS += -I$(src)/hal/btc
+EXTRA_CFLAGS += -I$(srctree)/$(src)/hal/btc
+EXTRA_CFLAGS += -I$(srctree)/$(src)/hal/phydm
########### HAL_RTL8188E #################################
ifeq ($(CONFIG_RTL8188E), y)
@@ -2459,7 +2459,7 @@ ifeq ($(CONFIG_SDIO_HCI), y)
rtk_core += core/rtw_sdio.o
endif
-EXTRA_CFLAGS += -I$(src)/core/crypto
+EXTRA_CFLAGS += -I$(srctree)/$(src)/core/crypto
rtk_core += \
core/crypto/aes-internal.o \
core/crypto/aes-internal-enc.o \
diff --git a/drivers/net/wireless/rtl8812au/Makefile b/drivers/net/wireless/rtl8812au/Makefile
index 69585ae65f9e..bd18f9dca1c1 100755
--- a/drivers/net/wireless/rtl8812au/Makefile
+++ b/drivers/net/wireless/rtl8812au/Makefile
@@ -20,7 +20,7 @@ EXTRA_CFLAGS += -Wno-vla -g
#EXTRA_CFLAGS += -Wno-date-time # Fix compile error && warning on gcc 4.9 and later
#endif
-EXTRA_CFLAGS += -I$(src)/include
+EXTRA_CFLAGS += -I$(srctree)/$(src)/include
EXTRA_LDFLAGS += --strip-all -O3
########################## WIFI IC ############################
@@ -230,10 +230,10 @@ _HAL_INTFS_FILES := hal/hal_intf.o \
hal/led/hal_$(HCI_NAME)_led.o
-EXTRA_CFLAGS += -I$(src)/platform
+EXTRA_CFLAGS += -I$(srctree)/$(src)/platform
_PLATFORM_FILES := platform/platform_ops.o
-EXTRA_CFLAGS += -I$(src)/hal/btc
+EXTRA_CFLAGS += -I$(srctree)/$(src)/hal/btc
+EXTRA_CFLAGS += -I$(srctree)/$(src)/hal/phydm
########### HAL_RTL8188E #################################
ifeq ($(CONFIG_RTL8188E), y)
diff --git a/drivers/net/wireless/rtl88x2cs/Makefile b/drivers/net/wireless/rtl88x2cs/Makefile
index fe0c5cbe991a..82e09b258edb 100755
--- a/drivers/net/wireless/rtl88x2cs/Makefile
+++ b/drivers/net/wireless/rtl88x2cs/Makefile
@@ -20,7 +20,7 @@ ifeq ($(GCC_VER_49),1)
EXTRA_CFLAGS += -Wno-date-time # Fix compile error && warning on gcc 4.9 and later
endif
-EXTRA_CFLAGS += -I$(src)/include
+EXTRA_CFLAGS += -I$(srctree)/$(src)/include
EXTRA_LDFLAGS += --strip-debug
@@ -268,10 +268,10 @@ _HAL_INTFS_FILES := hal/hal_intf.o \
hal/led/hal_$(HCI_NAME)_led.o
-EXTRA_CFLAGS += -I$(src)/platform
+EXTRA_CFLAGS += -I$(srctree)/$(src)/platform
_PLATFORM_FILES := platform/platform_ops.o
-EXTRA_CFLAGS += -I$(src)/hal/btc
+EXTRA_CFLAGS += -I$(srctree)/$(src)/hal/btc
+EXTRA_CFLAGS += -I$(srctree)/$(src)/hal/phydm
########### HAL_RTL8188E #################################
ifeq ($(CONFIG_RTL8188E), y)
@@ -2370,7 +2370,7 @@ ifeq ($(CONFIG_SDIO_HCI), y)
rtk_core += core/rtw_sdio.o
endif
-EXTRA_CFLAGS += -I$(src)/core/crypto
+EXTRA_CFLAGS += -I$(srctree)/$(src)/core/crypto
rtk_core += \
core/crypto/aes-internal.o \
core/crypto/aes-internal-enc.o \
diff --git a/drivers/net/wireless/rtl88x2bu/Makefile b/drivers/net/wireless/rtl88x2bu/Makefile
index 1cd1c6a7043b..1c6dbb64bc8c 100644
--- a/drivers/net/wireless/rtl88x2bu/Makefile
+++ b/drivers/net/wireless/rtl88x2bu/Makefile
@@ -28,7 +28,7 @@ ifeq ($(GCC_VER_49),1)
EXTRA_CFLAGS += -Wno-date-time # Fix compile error && warning on gcc 4.9 and later
endif
-EXTRA_CFLAGS += -I$(src)/include
+EXTRA_CFLAGS += -I$(srctree)/$(src)/include
EXTRA_LDFLAGS += --strip-debug
@@ -285,10 +285,10 @@ _HAL_INTFS_FILES := hal/hal_intf.o \
hal/led/hal_$(HCI_NAME)_led.o
-EXTRA_CFLAGS += -I$(src)/platform
+EXTRA_CFLAGS += -I$(srctree)/$(src)/platform
_PLATFORM_FILES := platform/platform_ops.o
-EXTRA_CFLAGS += -I$(src)/hal/btc
+EXTRA_CFLAGS += -I$(srctree)/$(src)/hal/btc
+EXTRA_CFLAGS += -I$(srctree)/$(src)/hal/phydm
########### HAL_RTL8188E #################################
ifeq ($(CONFIG_RTL8188E), y)
@@ -2457,7 +2457,7 @@ ifeq ($(CONFIG_SDIO_HCI), y)
rtk_core += core/rtw_sdio.o
endif
-EXTRA_CFLAGS += -I$(src)/core/crypto
+EXTRA_CFLAGS += -I$(srctree)/$(src)/core/crypto
rtk_core += \
core/crypto/aes-internal.o \
core/crypto/aes-internal-enc.o \

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,56 @@
DESCRIPTION = "Linux Kernel for Raspberry Pi"
SECTION = "kernel"
LICENSE = "GPL-2.0-only"
LIC_FILES_CHKSUM = "file://COPYING;md5=6bc538ed5bd9a7fc9398086aedcd7e46"
FILESEXTRAPATHS:prepend := "${THISDIR}/files:"
SRCREV_machine = "3495b5ee0594566c9fed930b96b1cae90600412e"
# SRCREV_meta = "1a97a82e62ebf4ef3787768a1f5937e2d2f280ce"
# COMPATIBLE_MACHINE ?= "^orange-pi-zero2w$"
COMPATIBLE_MACHINE = "(sun4i|sun5i|sun7i|sun8i|sun50i)"
LINUX_OPI_BRANCH ?= "orange-pi-6.1-sun50iw9"
SRC_URI = " \
git://github.com/orangepi-xunlong/linux-orangepi.git;name=machine;branch=${LINUX_OPI_BRANCH};protocol=https \
file://defconfig \
file://0003-enable-mali-gpu.patch \
file://0004-fix-unisocwcn-include-path.patch \
"
# file://0002-fix-rtl8822c-compi-error.patch
# file://0005-fix-rtl8xxx-include-path.patch
# Pull in the devicetree files into the rootfs
RDEPENDS_${KERNEL_PACKAGE_NAME}-base += "kernel-devicetree"
KERNEL_EXTRA_ARGS += "LOADADDR=${UBOOT_ENTRYPOINT}"
inherit kernel
require linux.inc
LINUX_VERSION ?= "${PV}"
S = "${WORKDIR}/linux-${PV}"
do_deploy:append() {
install -d ${DEPLOY_DIR_IMAGE}
install -d ${DEPLOY_DIR_IMAGE}/allwinner
install -d ${DEPLOY_DIR_IMAGE}/allwinner/overlay
for file in ${KERNEL_DEVICETREE}; do
name=$(basename $file)
ext="${name##*.}"
if [ "$ext" = "dtb" ]; then
ln -sf ${DEPLOY_DIR_IMAGE}/${name} ${DEPLOY_DIR_IMAGE}/allwinner/${name}
else
ln -sf ${DEPLOY_DIR_IMAGE}/${name} ${DEPLOY_DIR_IMAGE}/allwinner/overlay/${name}
fi
done
install -m 0755 ${S}/arch/arm64/boot/dts/allwinner/overlay/sun50i-h616-fixup.scr ${DEPLOY_DIR_IMAGE}/allwinner/overlay/
}
# allwinner/overlay/sun50i-h616-fixup.scr
FILES_${KERNEL_PACKAGE_NAME}-base:append = " ${nonarch_base_libdir}/modules/${KERNEL_VERSION}/modules.builtin.modinfo"

View File

@ -0,0 +1,126 @@
DESCRIPTION = "Linux Kernel"
SECTION = "kernel"
LICENSE = "GPLv2"
INC_PR = "r0"
inherit kernel kernel-yocto siteinfo
# Enable OABI compat for people stuck with obsolete userspace
ARM_KEEP_OABI ?= "0"
# Set the verbosity of kernel messages during runtime
# You can define CMDLINE_DEBUG in your local.conf or distro.conf to override this behaviour
CMDLINE_DEBUG ?= "loglevel=3"
# Kernel bootlogo is distro-specific (default is OE logo).
# Logo resolution (qvga, vga, ...) is machine-specific.
LOGO_SIZE ?= '${@oe.utils.conditional("MACHINE_GUI_CLASS", "bigscreen", "vga", "qvga", d)}'
# To use this, add file://${LOGO_SIZE}/logo_linux_clut224.ppm.bz2 or similar
# to your kernel recipe, and then structure your logos for each resolution
# accordingly.
LOCALVERSION ?= ""
KCONFIG_MODE ?= "alldefconfig"
KMACHINE ?= "${MACHINE}"
#kernel_conf_variable CMDLINE "\"${CMDLINE} ${CMDLINE_DEBUG}\""
kernel_conf_variable() {
CONF_SED_SCRIPT="$CONF_SED_SCRIPT /CONFIG_$1[ =]/d;"
if test "$2" = "n"
then
echo "# CONFIG_$1 is not set" >> ${B}/.config
else
echo "CONFIG_$1=$2" >> ${B}/.config
fi
}
do_kernel_configme[depends] += "virtual/${TARGET_PREFIX}binutils:do_populate_sysroot"
do_kernel_configme[depends] += "virtual/${TARGET_PREFIX}gcc:do_populate_sysroot"
do_kernel_configme[depends] += "bc-native:do_populate_sysroot bison-native:do_populate_sysroot"
do_configure:prepend() {
CONF_SED_SCRIPT=""
#
# logo support, if you supply logo_linux_clut224.ppm in SRC_URI, then it's going to be used
#
if [ -e ${WORKDIR}/logo_linux_clut224.ppm ]; then
install -m 0644 ${WORKDIR}/logo_linux_clut224.ppm drivers/video/logo/logo_linux_clut224.ppm
kernel_conf_variable LOGO y
kernel_conf_variable LOGO_LINUX_CLUT224 y
fi
#
# oabi / eabi support
#
kernel_conf_variable AEABI y
if [ "${ARM_KEEP_OABI}" = "1" ] ; then
kernel_conf_variable OABI_COMPAT y
else
kernel_conf_variable OABI_COMPAT n
fi
# When enabling thumb for userspace we also need thumb support in the kernel
if [ "${ARM_INSTRUCTION_SET}" = "thumb" ] ; then
kernel_conf_variable ARM_THUMB y
fi
kernel_conf_variable CMDLINE "\"${CMDLINE} ${CMDLINE_DEBUG}\""
kernel_conf_variable LOCALVERSION "\"${LOCALVERSION}\""
kernel_conf_variable LOCALVERSION_AUTO n
kernel_conf_variable SYSFS_DEPRECATED n
kernel_conf_variable SYSFS_DEPRECATED_V2 n
kernel_conf_variable HOTPLUG y
kernel_conf_variable UEVENT_HELPER_PATH \"\"
kernel_conf_variable UNIX y
kernel_conf_variable SYSFS y
kernel_conf_variable PROC_FS y
kernel_conf_variable TMPFS y
kernel_conf_variable INOTIFY_USER y
kernel_conf_variable SIGNALFD y
kernel_conf_variable TMPFS_POSIX_ACL y
kernel_conf_variable BLK_DEV_BSG y
kernel_conf_variable DEVTMPFS y
kernel_conf_variable DEVTMPFS_MOUNT y
# Newer inits like systemd need cgroup support
if [ "${KERNEL_ENABLE_CGROUPS}" = "1" ] ; then
kernel_conf_variable CGROUP_SCHED y
kernel_conf_variable CGROUPS y
kernel_conf_variable CGROUP_NS y
kernel_conf_variable CGROUP_FREEZER y
kernel_conf_variable CGROUP_DEVICE y
kernel_conf_variable CPUSETS y
kernel_conf_variable PROC_PID_CPUSET y
kernel_conf_variable CGROUP_CPUACCT y
kernel_conf_variable RESOURCE_COUNTERS y
fi
#
# root-over-nfs-over-usb-eth support. Limited, but should cover some cases.
# Enable this by setting a proper CMDLINE_NFSROOT_USB.
#
if [ ! -z "${CMDLINE_NFSROOT_USB}" ]; then
bbnote "Configuring the kernel for root-over-nfs-over-usb-eth with CMDLINE ${CMDLINE_NFSROOT_USB}"
kernel_conf_variable INET y
kernel_conf_variable IP_PNP y
kernel_conf_variable USB_GADGET y
kernel_conf_variable USB_GADGET_SELECTED y
kernel_conf_variable USB_ETH y
kernel_conf_variable NFS_FS y
kernel_conf_variable ROOT_NFS y
kernel_conf_variable CMDLINE \"${CMDLINE_NFSROOT_USB} ${CMDLINE_DEBUG}\"
fi
yes '' | oe_runmake -C ${S} O=${B} oldconfig
}
do_configure:append() {
if test -e scripts/Makefile.fwinst ; then
sed -i -e "s:-m0644:-m 0644:g" scripts/Makefile.fwinst
fi
}

Binary file not shown.

View File

@ -0,0 +1,177 @@
[Section 1: Version]
Major = 2
Minor = 2
[Section 2: Board Config]
Calib_Bypass = 11758
TxChain_Mask = 2
RxChain_Mask = 2
[Section 3: Board Config TPC]
DPD_LUT_idx = 0x33,0x33,0x0,0x11,0x22,0x33,0x33,0x33
TPC_Goal_Chain0 = 0,0,0,0,0,0,0,0
TPC_Goal_Chain1 = 159,167,162,152,159,167,162,152
[Section 4: TPC-LUT]
Chain0_LUT_0 = 6,0,40,0
Chain0_LUT_1 = 6,1,24,0
Chain0_LUT_2 = 6,2,8,0
Chain0_LUT_3 = 10,2,0,0
Chain0_LUT_4 = 14,2,0,0
Chain0_LUT_5 = 18,2,0,0
Chain0_LUT_6 = 22,2,0,0
Chain0_LUT_7 = 26,2,0,0
Chain1_LUT_0 = 6,0,40,0
Chain1_LUT_1 = 6,1,24,0
Chain1_LUT_2 = 6,2,8,0
Chain1_LUT_3 = 10,2,0,0
Chain1_LUT_4 = 14,2,0,0
Chain1_LUT_5 = 18,2,0,0
Chain1_LUT_6 = 22,2,0,0
Chain1_LUT_7 = 26,2,0,0
[Section 5: Board Config Frequency Compensation]
2G_Channel_Chain0 = 6,6,6,6,7,7,7,7,7,7,7,7,7,7
2G_Channel_Chain1 = 6,6,6,6,7,7,7,7,7,7,7,7,7,7
5G_Channel_Chain0 = 11,11,11,11,9,9,9,9,10,10,10,10,10,10,10,10,10,10,10,10,9,9,9,9,9
5G_Channel_Chain1 = 11,11,11,11,9,9,9,9,10,10,10,10,10,10,10,10,10,10,10,10,9,9,9,9,9
[Section 6: Rate To Power with BW 20M]
11b_Power = 20,20,20,20
11ag_Power = 28,32,36,44,28,32,36,48
11n_Power = 34,38,38,40,40,44,44,48,32,36,36,40,40,44,44,54,48
11ac_Power = 32,36,36,40,40,44,44,48,50,66,32,36,36,40,40,44,44,48,50,66
[Section 7: Power Backoff]
Green_WIFI_offset = 0
HT40_Power_offset = 0
VHT40_Power_offset = 0
VHT80_Power_offset = 0
SAR_Power_offset = 0
Mean_Power_offset = 36
[Section 8: Reg Domain]
reg_domain1 = 0x00000001
reg_domain2 = 0x00000002
[Section 9: Band Edge Power offset (MKK, FCC, ETSI)]
BW20M = 3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41
BW40M = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21
BW80M = 6,5,4,3,2,1
[Section 10: TX Scale]
Chain0_1 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16
Chain1_1 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16
Chain0_2 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,17
Chain1_2 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,17
Chain0_3 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,18
Chain1_3 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,18
Chain0_4 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,19
Chain1_4 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,19
Chain0_5 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,20
Chain1_5 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,20
Chain0_6 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,21
Chain1_6 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,21
Chain0_7 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,22
Chain1_7 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,22
Chain0_8 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,23
Chain1_8 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,23
Chain0_9 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,24
Chain1_9 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,24
Chain0_10 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,25
Chain1_10 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,25
Chain0_11 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,26
Chain1_11 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,26
Chain0_12 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,27
Chain1_12 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,27
Chain0_13 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,28
Chain1_13 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,28
Chain0_14 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,29
Chain1_14 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,29
Chain0_36 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,30
Chain1_36 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,30
Chain0_40 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,31
Chain1_40 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,31
Chain0_44 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,32
Chain1_44 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,32
Chain0_48 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,33
Chain1_48 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,33
Chain0_52 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,34
Chain1_52 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,34
Chain0_56 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,35
Chain1_56 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,35
Chain0_60 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,36
Chain1_60 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,36
Chain0_64 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,37
Chain1_64 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,37
Chain0_100 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,38
Chain1_100 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,38
Chain0_104 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,39
Chain1_104 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,39
Chain0_108 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,40
Chain1_108 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,40
Chain0_112 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,41
Chain1_112 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,41
Chain0_116 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,42
Chain1_116 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,42
Chain0_120 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,43
Chain1_120 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,43
Chain0_124 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,44
Chain1_124 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,44
Chain0_128 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,45
Chain1_128 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,45
Chain0_132 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,46
Chain1_132 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,46
Chain0_136 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,47
Chain1_136 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,47
Chain0_140 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,48
Chain1_140 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,48
Chain0_144 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,49
Chain1_144 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,49
Chain0_149 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,50
Chain1_149 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,50
Chain0_153 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,51
Chain1_153 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,51
Chain0_157 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,52
Chain1_157 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,52
Chain0_161 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,53
Chain1_161 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,53
Chain0_165 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,54
Chain1_165 = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,54
[Section 11: misc]
DFS_switch = 1
power_save_switch = 2
ex-Fem_and_ex-LNA_param_setup = 3
rssi_report_diff = 4
[Section 12: debug reg]
address = 0x1,0x2,0x3,0x4,0x5,0x6,0x7,0x8,0x9,0x10,0x11,0x12,0x13,0x14,0x15,0x16
value = 0x16,0x17,0x18,0x19,0x20,0x21,0x22,0x23,0x24,0x25,0x26,0x27,0x28,0x29,0x30,0x31
[Section 13: coex_config]
bt_performance_cfg0 = 0x01010101
bt_performance_cfg1 = 0x01000000
wifi_performance_cfg0 = 0x01050A01
wifi_performance_cfg2 = 0x00000000
strategy_cfg0 = 0x01010100
strategy_cfg1 = 0x03000000
strategy_cfg2 = 0x08020000
compatibility_cfg0 = 0x04040000
compatibility_cfg1 = 0x0
ant_cfg0 = 0x0
ant_cfg1 = 0x0
isolation_cfg0 = 0x0505
isolation_cfg1 = 0x0
reserved_cfg0 = 0x0
reserved_cfg1 = 0x0
reserved_cfg2 = 0x0
reserved_cfg3 = 0x0
reserved_cfg4 = 0x0
reserved_cfg5 = 0x0
reserved_cfg6 = 0x0
reserved_cfg7 = 0x0
[Section 14: rf_tlv_config]
rf_config = 0xAA,0x55,0x00,0xFF,0x8,0xA,0x0,0x5,0x0,0x0,0x0,0x0,0x0,0x0

View File

@ -0,0 +1,22 @@
DESCRIPTION = "UWE5622 Wifi firmware"
LICENSE = "CC0-1.0"
LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/${LICENSE};md5=0ceb3372c9595f0a8067e55da801e4a1"
S = "${WORKDIR}"
COMPATIBLE_MACHINE = "orange-pi-zero2"
SRC_URI:append = " \
file://wcnmodem.bin \
file://wifi_2355b001_1ant.ini \
"
do_install() {
install -d ${D}${base_libdir}/firmware
install -m 0644 ${S}/wcnmodem.bin ${D}${base_libdir}/firmware/wcnmodem.bin
install -m 0644 ${S}/wifi_2355b001_1ant.ini ${D}${base_libdir}/firmware/wifi_2355b001_1ant.ini
}
FILES:${PN} = "${base_libdir}/*"
PACKAGES = "${PN}"

View File

@ -0,0 +1,30 @@
DESCRIPTION = "leafpad for GTK3"
LICENSE = "GPL-3.0-only"
LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/GPL-3.0-only;md5=c79ff39f19dfec6d293b95dea7b07891"
FILESEXTRAPATHS:prepend := "${THISDIR}/files:"
S="${WORKDIR}"
DEPENDS = "gtk+3 pango cairo harfbuzz gdk-pixbuf intltool-native"
inherit pkgconfig
SRC_URI = "file://l3afpad-0.8.18.1.11.tar.gz"
SRC_URI[sha256sum] = "005457fa35a7e37024e403852a21a5c7362a0314a8de9b7fff73b1e7802d8959"
do_configure () {
./configure --host=x86_64-unknown-linux --target=aarch64-poky-linux
}
do_compile () {
make
}
do_install () {
DESTDIR=${D} make install
}
FILES:${PN} += "/usr/local/*"

View File

@ -0,0 +1,334 @@
Set Term = "foot"
# Task Switcher
switcher {
interval = 700
icons = true
labels = false
cols = 5
}
function("SfwbarInit") {
SetBarId "bar-0"
SetLayer "bottom"
}
function("ToggleMinimize") {
[!Minimized] Minimize
[Minimized] UnMinimize
}
function("ToggleMaximize") {
[!Maximized] Maximize
[Maximized] UnMaximize
}
function("ShowDesktopSaveFocus") {
[Focused] UserState "2:on"
[!Focused] UserState "2:off"
}
function("ShowdesktopMinimize") {
[!Minimized] UserState "on"
[Minimized] UserState "off"
[!Minimized] Minimize
}
function("ShowDesktopRestore") {
[UserState] UnMinimize
}
function("ShowDesktopRestoreFocus") {
[UserState2] Focus
}
function("ShowDesktopCheckWindow") {
[!Minimized] UserState "target","2:on"
}
function("ShowDesktopReminimize")
{
[!Minimized] UserState "on"
[!Minimized] Minimize
}
function("ShowDesktopUnminimized") {
[UserState2 | Children] Function "ShowDesktopSaveFocus"
[UserState2 | Children] Function "ShowDesktopReminimize"
[!UserState2 | Children] Function "ShowDesktopRestore"
[!UserState2 | Children] Function "ShowDesktopRestoreFocus"
[!UserState2] UserState "off"
[UserState2] UserState "on"
}
function("ShowDesktop") {
[!UserState | Children] Function "ShowDesktopSaveFocus"
[!UserState | Children] Function "ShowDesktopMinimize"
[UserState] UserState "2:off"
[UserState| Children ] Function "ShowDesktopCheckWindow"
[UserState] Function "target","ShowDesktopUnminimized"
[!UserState] UserState "on"
}
menu("winops") {
item("Focus", Focus );
item("Close", Close );
item("Toggle minimize", Function "ToggleMinimize" );
item("Toggle maximize", Function "ToggleMaximize" );
}
# Panel layout
layout {
button {
style = "launcher"
value = "/usr/share/icons/Adwaita/scalable/actions/view-app-grid-symbolic.svg"
action = Exec "wtype -M alt ' ' -m alt"
}
button {
style = "launcher"
value = "/usr/share/icons/Adwaita/scalable/actions/system-run-symbolic.svg"
tooltip = "Quick run"
action = Exec "bash -c \"`drun`\""
}
button {
value = "/usr/share/icons/Adwaita/scalable/devices/tv-symbolic.svg"
style = "launcher"
tooltip = "Show Desktop"
action = Function "target", "ShowDesktop"
}
button {
style = "launcher"
value = $Term
tooltip = "Terminal"
action = Exec $Term
}
taskbar "target" {
rows = 1
css = "* { -GtkWidget-hexpand:false; }" # stretch horizontally
icons = true
group = false
sort = false
labels = true
action[3] = Menu "winops"
action[2] = Close
}
label {
css = "* { -GtkWidget-hexpand: true; }"
}
tray {
rows = 1
}
include("network-module.widget")
include("cpu.widget")
include("memory.widget")
}
#CSS
button#launcher, button#module{
padding: 0px 2px 0px 2px;
/*background: none;
background-color: #5F548E;*/
border-style:none;
box-shadow: none;
border-radius: 0;
}
window {
-GtkWidget-direction: top;
/*background-color: rgba(0,0,0,0.6);*/
border-color: rgba(0,0,0,0.3);
}
#hidden {
-GtkWidget-visible: false;
}
button#taskbar_normal grid {
-GtkWidget-hexpand: false;
padding-right: 0px;
margin-right: 0px;
}
button#launcher image, button#taskbar_normal image, button#taskbar_active image, button#taskbar_normal:hover image {
-GtkWidget-vexpand: true;
box-shadow: none;
border: none;
border-image: none;
background-image: none;
background: none;
min-width: 24px;
min-height: 24px;
-gtk-icon-shadow: none;
}
button#taskbar_normal label, button#taskbar_active label, button#taskbar_normal:hover label {
-GtkWidget-vexpand: true;
-GtkWidget-hexpand: false;
padding-left: 0.75mm;
padding-top: 0px;
padding-bottom: 0px;
font: 0.3cm Sans;
}
button#taskbar_normal , button#taskbar_active , button#taskbar_normal:hover {
padding-left: 0.75mm;
padding-top: 0.5mm;
padding-bottom: 0.5mm;
background-image: none;
border-radius: 0;
border-image: none;
-GtkWidget-hexpand: false;
-GtkWidget-vexpand: true;
background-color: rgba(119,119,119,0.2);
border: none;
/*border-color: rgba(119,119,119,0.3);*/
box-shadow: none;
}
button#taskbar_normal label {
color: black;
}
button#taskbar_active {
/* background-color: rgba(255,255,255,0.2);
border-color: rgba(255,255,255,0.4); */
border-bottom:3px solid #5F548E;
}
button#taskbar_active label, button#taskbar_normal:hover label {
color: #5F548E;
}
/* button#taskbar_active:hover*/
button#taskbar_normal:hover {
background-color: #d2d2d2;
border-color: rgba(234,234,234,0.44);
}
grid#switcher_active image,
grid#switcher_active {
min-width: 1.25cm;
min-height: 1.25cm;
border-image: none;
padding: 1.25mm;
background-color: #777777;
border: 0px;
box-shadow: none;
border-radius: 1.25mm;
-GtkWidget-hexpand: true;
}
grid#switcher_normal image,
grid#switcher_normal {
min-width: 1.25cm;
min-height: 1.25cm;
border-image: none;
padding: 1.25mm;
-GtkWidget-direction: right;
-GtkWidget-hexpand: true;
}
window#switcher {
border-style: solid;
border-width: 0.25mm;
border-color: #000000;
border-radius: 1.25mm;
padding: 1.25mm;
-GtkWidget-hexpand: true;
}
grid#switcher {
border-radius: 1.25mm;
padding: 1.25mm;
background-color: rgba(0,0,0,0.8);
border-color: rgba(119,119,119,0.8);
box-shadow: none;
-GtkWidget-hexpand: true;
}
button#tray_active,
button#tray_passive,
button#tray_attention {
background-image: none;
border: 0px;
padding: 0px 1px;
margin: 0px;
border-image: none;
border-radius: 0px;
outline-style: none;
box-shadow: none;
-GtkWidget-hexpand: true;
-GtkWidget-vexpand: true;
}
button#tray_active image,
button#tray_passive image,
button#tray_attention image {
min-width: 26px;
}
grid#layout {
padding: 0.25mm;
-GtkWidget-direction: right;
min-height: 30px;
}
menu {
background-color: rgba(0,0,0,0.8);
border-color: rgba(119,119,119,0.3);
box-shadow: none;
}
menuitem {
color: #ffffff;
}
menu image {
min-width: 24px;
min-height: 24px;
padding-right: 5px;
}
chart#cpu_chart {
background: rgba(127,127,127,0.3);
min-width: 9px;
-GtkWidget-vexpand: true;
margin: 2px;
border: 1px solid @theme_fg_color;
color: red;
}
progressbar#memory {
-GtkWidget-direction: top;
-GtkWidget-vexpand: true;
min-width: 9px;
border: 1px solid @theme_fg_color;
margin: 2px;
}
progressbar#memory trough {
min-height: 2px;
min-width: 9px;
border: none;
border-radius: 0px;
background: rgba(127,127,127,0.3);
}
progressbar#memory progress {
-GtkWidget-hexpand: true;
min-width: 9px;
border-radius: 0px;
border: none;
margin: 0px;
background-color: alpha(green,0.9);
}
label {
font: 0.27cm Sans;
color: #ffffff;
text-shadow: none;
}
* {
-GtkWidget-vexpand: true;
}

View File

@ -0,0 +1,27 @@
DESCRIPTION = "sfwbar pannel for wayland"
LICENSE = "GPL-3.0-only"
LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/GPL-3.0-only;md5=c79ff39f19dfec6d293b95dea7b07891"
FILESEXTRAPATHS:prepend := "${THISDIR}/files:"
DEPENDS = "gtk+3 gtk-layer-shell json-c wayland-native"
SRCREV = "${AUTOREV}"
SRC_URI = "git://github.com/LBCrion/sfwbar.git;protocol=https;branch=main"
SRC_URI += " file://sfwbar.config "
S="${WORKDIR}/git"
inherit meson pkgconfig
EXTRA_OEMESON += "--buildtype release"
do_install:append () {
install -d ${D}/${sysconfdir}/xdg/
install -d ${D}/${sysconfdir}/xdg/sfwbar/
install -m 0755 ${WORKDIR}/sfwbar.config ${D}/${sysconfdir}/xdg/sfwbar/
}
FILES:${PN} += "/usr/share/icons/*"

View File

@ -0,0 +1 @@
PACKAGECONFIG:remove = " systemd sysvinit man-pages "

View File

@ -0,0 +1 @@
PACKAGECONFIG:remove = " man-pages pam "

View File

@ -0,0 +1,320 @@
# Default config for tofi
#
# Copy this file to ~/.config/tofi/config and get customising!
#
# A complete reference of available options can be found in `man 5 tofi`.
#
### Fonts
#
# Font to use, either a path to a font file or a name.
#
# If a path is given, tofi will startup much quicker, but any
# characters not in the chosen font will fail to render.
#
# Otherwise, fonts are interpreted in Pango format.
font = "Sans"
# Point size of text.
font-size = 24
# Comma separated list of OpenType font feature settings to apply,
# if supported by the chosen font. The format is similar to the CSS
# "font-feature-settings" property.
#
# Examples:
#
# font-features = "smcp, c2sc" (all small caps)
# font-features = "liga 0" (disable ligatures)
font-features = ""
# Comma separated list of OpenType font variation settings to apply
# to variable fonts. The format is similar to the CSS
# "font-variation-settings" property.
#
# Examples:
#
# font-variations = "wght 900" (Extra bold)
# font-variations = "wdth 25, slnt -10" (Narrow and slanted)
font-variations = ""
# Perform font hinting. Only applies when a path to a font has been
# specified via `font`. Disabling font hinting speeds up text
# rendering appreciably, but will likely look poor at small font pixel
# sizes.
hint-font = true
#
### Text theming
#
# Default text color
#
# All text defaults to this color if not otherwise specified.
text-color = #FFFFFF
# All pieces of text have the same theming attributes available:
#
# *-color
# Foreground color
#
# *-background
# Background color
#
# *-background-padding
# Background padding in pixels (comma-delimited, CSS-style list).
# See "DIRECTIONAL VALUES" under `man 5 tofi` for more info.
#
# *-background-corner-radius
# Radius of background box corners in pixels
# Prompt text theme
# prompt-color = #FFFFFF
prompt-background = #00000000
prompt-background-padding = 0
prompt-background-corner-radius = 0
# Placeholder text theme
placeholder-color = #FFFFFFA8
placeholder-background = #00000000
placeholder-background-padding = 0
placeholder-background-corner-radius = 0
# Input text theme
# input-color = #FFFFFF
input-background = #00000000
input-background-padding = 0
input-background-corner-radius = 0
# Default result text theme
# default-result-color = #FFFFFF
default-result-background = #00000000
default-result-background-padding = 0
default-result-background-corner-radius = 0
# Alternate (even-numbered) result text theme
#
# If unspecified, these all default to the corresponding
# default-result-* attribute.
#
# alternate-result-color = #FFFFFF
# alternate-result-background = #00000000
# alternate-result-background-padding = 0
# alternate-result-background-corner-radius = 0
# Selection text
selection-color = #F92672
selection-background = #00000000
selection-background-padding = 0
selection-background-corner-radius = 0
# Matching portion of selection text
selection-match-color = #00000000
#
### Text cursor theme
#
# Style of the optional text cursor.
#
# Supported values: bar, block, underscore
text-cursor-style = bar
# Color of the text cursor
#
# If unspecified, defaults to the same as input-color
# text-cursor-color = #FFFFFF
# Color of text behind the text cursor when text-cursor-style = block
#
# If unspecified, defaults to the same as background-color
# text-cursor-background = #000000
# Corner radius of the text cursor
text-cursor-corner-radius = 0
# Thickness of the bar and underscore text cursors.
#
# If unspecified, defaults to a font-dependent value when
# text-cursor-style = underscore, or to 2 otherwise.
# text-cursor-thickness = 2
#
### Text layout
#
# Prompt to display.
prompt-text = "run: "
# Extra horizontal padding between prompt and input.
prompt-padding = 0
# Placeholder input text.
placeholder-text = ""
# Maximum number of results to display.
# If 0, tofi will draw as many results as it can fit in the window.
num-results = 0
# Spacing between results in pixels. Can be negative.
result-spacing = 0
# List results horizontally.
horizontal = false
# Minimum width of input in horizontal mode.
min-input-width = 0
#
### Window theming
#
# Width and height of the window. Can be pixels or a percentage.
width = 640
height = 480
# Window background color
background-color = #1B1D1E
# Width of the border outlines in pixels.
outline-width = 4
# Border outline color
outline-color = #080800
# Width of the border in pixels.
border-width = 12
# Border color
border-color = #F92672
# Radius of window corners in pixels.
corner-radius = 0
# Padding between borders and text. Can be pixels or a percentage.
padding-top = 8
padding-bottom = 8
padding-left = 8
padding-right = 8
# Whether to clip text drawing to be within the specified padding. This
# is mostly important for allowing text to be inset from the border,
# while still allowing text backgrounds to reach right to the edge.
clip-to-padding = true
# Whether to scale the window by the output's scale factor.
scale = true
#
### Window positioning
#
# The name of the output to appear on. An empty string will use the
# default output chosen by the compositor.
output = ""
# Location on screen to anchor the window to.
#
# Supported values: top-left, top, top-right, right, bottom-right,
# bottom, bottom-left, left, center.
anchor = center
# Set the size of the exclusive zone.
#
# A value of -1 means ignore exclusive zones completely.
# A value of 0 will move tofi out of the way of other windows' zones.
# A value greater than 0 will set that much space as an exclusive zone.
#
# Values greater than 0 are only meaningful when tofi is anchored to a
# single edge.
exclusive-zone = -1
# Window offset from edge of screen. Only has an effect when anchored
# to the relevant edge. Can be pixels or a percentage.
margin-top = 0
margin-bottom = 0
margin-left = 0
margin-right = 0
#
### Behaviour
#
# Hide the mouse cursor.
hide-cursor = true
# Show a text cursor in the input field.
text-cursor = true
# Sort results by number of usages in run and drun modes.
history = true
# Specify an alternate file to read and store history information
# from / to. This shouldn't normally be needed, and is intended to
# facilitate the creation of custom modes.
# history-file = /path/to/histfile
# Select the matching algorithm used. If normal, substring matching is
# used, weighted to favour matches closer to the beginning of the
# string. If prefix, only substrings at the beginning of the string are
# matched. If fuzzy, searching is performed via a simple fuzzy matching
# algorithm.
#
# Supported values: normal, prefix, fuzzy
matching-algorithm = normal
# If true, require a match to allow a selection to be made. If false,
# making a selection with no matches will print input to stdout.
# In drun mode, this is always true.
require-match = true
# If true, automatically accept a result if it is the only one
# remaining. If there's only one result on startup, window creation is
# skipped altogether.
auto-accept-single = false
# If true, typed input will be hidden, and what is displayed (if
# anything) is determined by the hidden-character option.
hide-input = false
# Replace displayed input characters with a character. If the empty
# string is given, input will be completely hidden.
# This option only has an effect when hide-input is set to true.
hidden-character = "*"
# If true, use physical keys for shortcuts, regardless of the current
# keyboard layout. If false, use the current layout's keys.
physical-keybindings = true
# Instead of printing the selected entry, print the 1-based index of
# the selection. This option has no effect in run or drun mode. If
# require-match is set to false, non-matching input will still result
# in the input being printed.
print-index = false
# If true, directly launch applications on selection when in drun mode.
# Otherwise, just print the command line to stdout.
drun-launch = false
# The terminal to run terminal programs in when in drun mode.
# This option has no effect if drun-launch is set to true.
# Defaults to the value of the TERMINAL environment variable.
terminal = foot
# Delay keyboard initialisation until after the first draw to screen.
# This option is experimental, and will cause tofi to miss keypresses
# for a short time after launch. The only reason to use this option is
# performance on slow systems.
late-keyboard-init = false
# If true, allow multiple simultaneous processes.
# If false, create a lock file on startup to prevent multiple instances
# from running simultaneously.
multi-instance = false
# Assume input is plain ASCII, and disable some Unicode handling
# functions. This is faster, but means e.g. a search for "e" will not
# match "é".
ascii-input = false
#
### Inclusion
#
# Configs can be split between multiple files, and then included
# within each other.
# include = /path/to/config

View File

@ -0,0 +1,9 @@
#! /bin/sh
config="/etc/xdg/tofi/config"
if [ -e "$HOME/.config/tofi/config" ]; then
config="$HOME/.config/tofi/config"
fi
tofi-drun -c "$config"

View File

@ -0,0 +1,27 @@
DESCRIPTION = "tofi menu for wayland"
LICENSE = "MIT"
LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302"
FILESEXTRAPATHS:prepend := "${THISDIR}/files:"
DEPENDS = "wayland freetype wayland-native wayland-protocols-native wayland-protocols harfbuzz pango libxkbcommon"
SRCREV = "${AUTOREV}"
SRC_URI = "git://github.com/philj56/tofi.git;protocol=https;branch=master"
SRC_URI += " file://config file://drun "
S="${WORKDIR}/git"
inherit meson pkgconfig
EXTRA_OEMESON += "--buildtype release"
do_install:append () {
# replace the default config
install -m 0755 ${WORKDIR}/drun ${D}/usr/bin/
install -m 0755 ${WORKDIR}/config ${D}/${sysconfdir}/xdg/tofi/
}
FILES:${PN} += "/usr/share/*"

View File

@ -0,0 +1,23 @@
DESCRIPTION = "wlopm"
LICENSE = "GPL-3.0-only"
LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/GPL-3.0-only;md5=c79ff39f19dfec6d293b95dea7b07891"
DEPENDS = "wayland wayland-native wayland-protocols"
SRCREV = "${AUTOREV}"
SRC_URI = "git://git.iohub.dev/dany/wlopm.git;protocol=https;branch=master"
S="${WORKDIR}/git"
do_compile () {
oe_runmake
}
do_install() {
oe_runmake install DESTDIR='${D}'
}
FILES:${PN} += "/usr/local/*"

View File

@ -0,0 +1,17 @@
DESCRIPTION = "virtual key event for wayland"
LICENSE = "MIT"
LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302"
DEPENDS = "wayland wayland-native wayland-protocols-native wayland-protocols libxkbcommon"
SRCREV = "${AUTOREV}"
SRC_URI = "git://github.com/atx/wtype.git;protocol=https;branch=master"
S="${WORKDIR}/git"
inherit meson pkgconfig
EXTRA_OEMESON += "--buildtype release"

View File

@ -0,0 +1,38 @@
# Example autostart file
# Set background color
swaybg -i /etc/xdg/labwc/wpp.jpg >/dev/null 2>&1 &
wlr-randr --output DPI-1 --transform 90
# Configure output directives such as mode, position, scale and transform.
# Use wlr-randr to get your output names
# Example ~/.config/kanshi/config below:
# profile {
# output HDMI-A-1 position 1366,0
# output eDP-1 position 0,0
# }
# kanshi >/dev/null 2>&1 &
# Launch a panel such as yambar or waybar.
# waybar >/dev/null 2>&1 &
# Enable notifications. Typically GNOME/KDE application notifications go
# through the org.freedesktop.Notifications D-Bus API and require a client such
# as mako to function correctly. Thunderbird is an example of this.
# mako >/dev/null 2>&1 &
# Lock screen after 1 minute; turn off display after another 5 minutes.
#
# Note that in the context of idle system power management, it is *NOT* a good
# idea to turn off displays by 'disabling outputs' for example by
# `wlr-randr --output <whatever> --off` because this re-arranges views
# (since a837fef). Instead use a wlr-output-power-management client such as
# https://git.sr.ht/~leon_plickat/wlopm
swayidle -w timeout 60 'wlopm --off DPI-1' resume 'wlopm --on DPI-1' &
SFWBAR_CNF="/etc/xdg/sfwbar/sfwbar.config"
if [ -e "$HOME/.config/sfwbar/sfwbar.config" ]; then
SFWBAR_CNF="$HOME/.config/sfwbar/sfwbar.config"
fi
sfwbar -f "$SFWBAR_CNF"

View File

@ -0,0 +1,28 @@
# Example environment file
# This allows xdg-desktop-portal-wlr to function (e.g. for screen-recording)
XDG_CURRENT_DESKTOP=wlroots
# Set keyboard layout to Swedish
# XKB_DEFAULT_LAYOUT=se
# Set two keyboard layouts and toggle between them using alt+shift
# XKB_DEFAULT_LAYOUT=se,de
XKB_DEFAULT_OPTIONS=grp:alt_shift_toggle
# Force firefox to use wayland backend
# MOZ_ENABLE_WAYLAND=1
# Set cursor theme.
# Find icons themes with the command below or similar:
# find /usr/share/icons/ -type d -name "cursors"
XCURSOR_THEME=breeze_cursors
# Disable hardware cursors. Most users wouldn't want to do this, but if you
# are experiencing issues with disappearing cursors, this might fix it.
# WLR_NO_HARDWARE_CURSORS=1
# For Java applications such as JetBrains/Intellij Idea, set this variable
# to avoid menus with incorrect offset and blank windows
# See https://github.com/swaywm/sway/issues/595
# _JAVA_AWT_WM_NONREPARENTING=1

View File

@ -0,0 +1,53 @@
#!/bin/sh
#
### BEGIN INIT INFO
# Provides: labwc
# Required-Start: $local_fs $remote_fs
# Required-Stop: $local_fs $remote_fs
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
### END INIT INFO
LABWC_USER=diya
LABWC_CONFDIR="/etc/xdg/labwc"
if test -e "/home/$LABWC_USER/.config/labwc" ; then
LABWC_CONFDIR="/home/$LABWC_USER/.config/labwc"
fi
killproc() {
pid=`/bin/pidof $1`
[ "$pid" != "" ] && kill $pid
}
read CMDLINE < /proc/cmdline
for x in $CMDLINE; do
case $x in
labwc=false)
echo "labwc disabled"
exit 0;
;;
esac
done
case "$1" in
start)
. /etc/profile
su - $LABWC_USER -c "labwc -C $LABWC_CONFDIR" &
;;
stop)
echo "Stopping labwc"
killproc labwc
;;
restart)
$0 stop
sleep 1
$0 start
;;
*)
echo "usage: $0 { start | stop | restart }"
;;
esac
exit 0

View File

@ -0,0 +1,49 @@
<?xml version="1.0" encoding="UTF-8"?>
<openbox_menu>
<menu id="client-menu">
<item label="Minimize">
<action name="Iconify" />
</item>
<item label="Maximize">
<action name="ToggleMaximize" />
</item>
<item label="Fullscreen">
<action name="ToggleFullscreen" />
</item>
<item label="Always on top">
<action name="ToggleAlwaysOnTop" />
</item>
<item label="Close">
<action name="Close"/>
</item>
</menu>
<menu id="root-menu">
<item label="Terminal">
<action name="Execute" command="foot -t xterm-256color" />
</item>
<item label="Reconfigure">
<action name="Reconfigure" />
</item>
<item label="Exit">
<action name="Exit" />
</item>
<item label="Reboot">
<action name="Execute" command="sudo /sbin/reboot" />
</item>
<item label="Power off">
<action name="Execute" command="sudo /sbin/halt" />
</item>
</menu>
<menu id="some-custom-menu">
<item label="Reconfigure">
<action name="Reconfigure" />
</item>
<item label="Exit">
<action name="Exit" />
</item>
</menu>
</openbox_menu>

View File

@ -0,0 +1,71 @@
<?xml version="1.0"?>
<!--
This is a very simple config file with many options missing. For a complete
set of options with comments, see docs/rc.xml.all
-->
<labwc_config>
<core>
<gap>10</gap>
</core>
<theme>
<name>Adwaita</name>
<cornerRadius>0</cornerRadius>
<font name="sans" size="12" />
</theme>
<keyboard>
<default />
<keybind key="W-F">
<action name="ToggleFullscreen" />
</keybind>
<keybind key="W-L">
<action name="NextWindow" />
</keybind>
<keybind key="W-M">
<action name="ShowMenu">
<menu>root-menu</menu>
</action>
</keybind>
<keybind key="A-Space">
<action name="ShowMenu">
<menu>root-menu</menu>
</action>
</keybind>
<!-- Use a different terminal emulator -->
<keybind key="W-Return">
<action name="Execute" command="foot" />
</keybind>
<keybind key="W-Space">
<action name="Execute">
<command>bash -c "bash -c \"`drun`\""</command>
</action>
</keybind>
<!--
Remove a previously defined keybind
A shorter alternative is <keybind key="W-F4" />
-->
<keybind key="W-F4">
<action name="None" />
</keybind>
</keyboard>
<mouse>
<default />
<!-- Show a custom menu on desktop right click -->
<context name="Root">
<mousebind button="Right" action="Press">
<action name="ShowMenu" menu="some-custom-menu" />
</mousebind>
</context>
</mouse>
<windowRules>
<windowRule identifier="*">
<action name="Maximize"/>
</windowRule>
</windowRules>
</labwc_config>

Binary file not shown.

After

Width:  |  Height:  |  Size: 161 KiB

View File

@ -0,0 +1,27 @@
PACKAGECONFIG:remove = " man-pages xwayland "
FILESEXTRAPATHS:prepend := "${THISDIR}/files:"
SRC_URI += " file://autostart \
file://init \
file://environment \
file://menu.xml \
file://rc.xml \
file://wpp.jpg \
"
do_install:append () {
install -d ${D}/${sysconfdir}/xdg
install -d ${D}/${sysconfdir}/init.d
install -d ${D}/${sysconfdir}/xdg/labwc
install -m 0755 ${WORKDIR}/init ${D}/${sysconfdir}/init.d/labwc
install -m 0755 ${WORKDIR}/wpp.jpg ${D}/${sysconfdir}/xdg/labwc/
install -m 0755 ${WORKDIR}/autostart ${D}/${sysconfdir}/xdg/labwc/
install -m 0755 ${WORKDIR}/environment ${D}/${sysconfdir}/xdg/labwc/
install -m 0755 ${WORKDIR}/menu.xml ${D}/${sysconfdir}/xdg/labwc/
install -m 0755 ${WORKDIR}/rc.xml ${D}/${sysconfdir}/xdg/labwc/
}
inherit update-rc.d
INITSCRIPT_NAME = "labwc"
INITSCRIPT_PARAMS = "start 9 5 2 . stop 20 0 1 6 ."

View File

@ -0,0 +1,2 @@
PACKAGECONFIG += " opengl gbm libinput "
PACKAGECONFIG:remove = " sysvinit systemd x11 xwayland "

12
wic/opi.wks.in Normal file
View File

@ -0,0 +1,12 @@
# short-description: Create Raspberry Pi SD card image
# long-description: Creates a partitioned SD card image for use with
part u-boot --source rawcopy --sourceparams="file=${SPL_BINARY}" --ondisk mmcblk1 --no-table --align 8
part /boot --source bootimg-partition --ondisk mmcblk1 --fstype=vfat --label boot --active --align 4096 --size 32
# read only roofs
part / --source rootfs --ondisk mmcblk1 --fstype=ext4 --label root --align 4096 --size 150 --exclude-path home/ --exclude-path var/etc/ --exclude-path boot/
# modifiable configurations stored in /var/etc
part /var/etc --source rootfs --rootfs-dir=${IMAGE_ROOTFS}/var/etc --ondisk mmcblk1 --fstype=ext4 --label diya --align 1024 --size 32
# home partition
part /home --source rootfs --rootfs-dir=${IMAGE_ROOTFS}/home --ondisk mmcblk1 --fstype=ext4 --label home --align 1024 --size 16
# part /home --ondisk mmcblk1 --fstype=vfat --label music --active --align 1024 --size 16