Skip to content

Commit

Permalink
udev: Update installation of udev rules
Browse files Browse the repository at this point in the history
Related #2263
  • Loading branch information
MattHag committed Feb 11, 2024
1 parent 21a9e8f commit 6967114
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,23 +1,21 @@
# Makefile to copy Solaar udev rules to the appropriate directory

UDEV_RULE_FILE = 42-logitech-unify-permissions.rules
UDEV_RULES_SOURCE := rules.d/$(UDEV_RULE_FILE)
UDEV_RULES_SOURCE_UINPUT := rules.d-uinput/$(UDEV_RULE_FILE)
UDEV_RULES_DEST := /etc/udev/rules.d/

.PHONY: install install_uinput uninstall
.PHONY: install_udev install_udev_uinput uninstall_udev

install:
install_udev:
@echo "Copying Solaar udev rules to $(UDEV_RULES_DEST)"
sudo cp $(UDEV_RULES_SOURCE) $(UDEV_RULES_DEST)
sudo udevadm control --reload-rules

install_udev_uinput:
@echo "Copying Solaar udev rules to $(UDEV_RULES_DEST)"
@echo "Copying Solaar udev rules (uinput) to $(UDEV_RULES_DEST)"
sudo cp $(UDEV_RULES_SOURCE_UINPUT) $(UDEV_RULES_DEST)
sudo udevadm control --reload-rules

uninstall:
uninstall_udev:
@echo "Removing Solaar udev rules from $(UDEV_RULES_DEST)"
sudo rm -f $(UDEV_RULES_DEST)/$(UDEV_RULE_FILE)
sudo udevadm control --reload-rules

0 comments on commit 6967114

Please sign in to comment.