linuxOS_AP06/device/rockchip/common/scripts/post-udev.sh

16 lines
374 B
Bash
Raw Normal View History

2025-06-03 04:28:32 +00:00
#!/bin/bash -e
source "${RK_POST_HELPER:-$(dirname "$(realpath "$0")")/post-helper}"
[ -n "$RK_ROOTFS_UDEV_RULES" ] || exit 0
cd "$RK_SDK_DIR"
mkdir -p "$TARGET_DIR/lib/udev/rules.d"
for rule in external/rkscript/*.rules; do
echo $rule | grep -vq usbdevice || continue
message "Installing udev rule: $rule"
install -m 0644 $rule "$TARGET_DIR/lib/udev/rules.d/"
done