Improve rules installation script for Linux
Some checks failed
CD / ${{ matrix.platform.name }} ${{ matrix.config.name }} (map[flags:-DBUILD_SHARED_LIBS=FALSE name:Static], map[artifact_name:linux32 flags:32 name:Linux GCC 32 os:ubuntu-latest]) (push) Has been cancelled
CD / ${{ matrix.platform.name }} ${{ matrix.config.name }} (map[flags:-DBUILD_SHARED_LIBS=FALSE name:Static], map[artifact_name:linux64 flags:64 name:Linux GCC x64 os:ubuntu-latest]) (push) Has been cancelled
CD / ${{ matrix.platform.name }} ${{ matrix.config.name }} (map[flags:-DBUILD_SHARED_LIBS=FALSE name:Static], map[artifact_name:linuxarm32 flags:arm32 name:Linux GCC ARM 32 os:ubuntu-latest]) (push) Has been cancelled
CD / ${{ matrix.platform.name }} ${{ matrix.config.name }} (map[flags:-DBUILD_SHARED_LIBS=FALSE name:Static], map[artifact_name:linuxarm64 flags:arm64 name:Linux GCC ARM 64 os:ubuntu-latest]) (push) Has been cancelled
CD / ${{ matrix.platform.name }} ${{ matrix.config.name }} (map[flags:-DBUILD_SHARED_LIBS=FALSE name:Static], map[artifact_name:macos name:macOS Apple Silicon os:macos-14]) (push) Has been cancelled
CD / ${{ matrix.platform.name }} ${{ matrix.config.name }} (map[flags:-DBUILD_SHARED_LIBS=FALSE name:Static], map[artifact_name:win32 flags:-A Win32 -DCMAKE_PARALLEL_MSVC=TRUE -DCMAKE_PREPARE_WINDOWS_DRIVERS=TRUE name:Windows VS2022 Win32 os:windows-2022]) (push) Has been cancelled
CD / ${{ matrix.platform.name }} ${{ matrix.config.name }} (map[flags:-DBUILD_SHARED_LIBS=FALSE name:Static], map[artifact_name:win64 flags:-A x64 -DCMAKE_PARALLEL_MSVC=TRUE -DCMAKE_PREPARE_WINDOWS_DRIVERS=TRUE name:Windows VS2022 x64 os:windows-2022]) (push) Has been cancelled
CD / ${{ matrix.platform.name }} ${{ matrix.config.name }} (map[flags:-DBUILD_SHARED_LIBS=FALSE name:Static], map[artifact_name:winarm64 flags:-A ARM64 -DCMAKE_PARALLEL_MSVC=TRUE -DCMAKE_PREPARE_WINDOWS_DRIVERS=TRUE name:Windows VS2022 ARM os:windows-2022]) (push) Has been cancelled
CD / Create Pi Mono Setup (push) Has been cancelled
CD / Publishing (push) Has been cancelled

This commit is contained in:
Lorenzooone
2026-05-26 04:13:25 +02:00
parent fb79843870
commit 45a637034a
3 changed files with 36 additions and 12 deletions

View File

@@ -1,3 +1,27 @@
cp *.rules /etc/udev/rules.d/
#!/bin/sh
if [ "$(id -u)" -ne "0" ]; then
echo "This script shoud be run as root!";
exit 1;
fi
cd -P -- "$(dirname -- "$0")"
# Default...
RULES_DIR=.
if [ -d "usb_rules" ]; then
# Handle releases
RULES_DIR=usb_rules
elif [ -d "../usb_rules" ]; then
# Handle people self-compiling
RULES_DIR=../usb_rules
fi
REAL_PATH_RULES=$(realpath $RULES_DIR)
echo "Looking inside $REAL_PATH_RULES for *.rules files..."
cp -vf $RULES_DIR/*.rules /etc/udev/rules.d/
udevadm control --reload-rules
udevadm trigger

View File

@@ -10,7 +10,7 @@ mkdir -p ${RPI_SETUP_FOLDER}/files/usr/lib/udev/rules.d
cp ${EXTRACTION_FOLDER}32/cc3dsfs ${MAIN_FILES_RPI_SETUP}/cc3dsfs_versions/cc3dsfs_32
cp ${EXTRACTION_FOLDER}64/cc3dsfs ${MAIN_FILES_RPI_SETUP}/cc3dsfs_versions/cc3dsfs_64
cp -r "${EXTRACTION_FOLDER}32/other licenses" "${MAIN_FILES_RPI_SETUP}/other licenses"
cp ${EXTRACTION_FOLDER}32/*.rules ${RPI_SETUP_FOLDER}/files/usr/lib/udev/rules.d
cp ${EXTRACTION_FOLDER}32/usb_rules/*.rules ${RPI_SETUP_FOLDER}/files/usr/lib/udev/rules.d
cp ${EXTRACTION_FOLDER}32/LICENSE ${MAIN_FILES_RPI_SETUP}
cp ${EXTRACTION_FOLDER}32/README.md ${MAIN_FILES_RPI_SETUP}
$(cd ${RPI_SETUP_FOLDER} ; zip -qry ${BASE_LOCATION}/${RPI_FINAL_ZIP_NAME} ./*)