X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=Makefile;h=4141b1c1ab07e8ccd9b5012536a8178fda5079e4;hb=a50ac263773294c16836189f55663ed7c861d5c0;hp=8a45be58ef580e453acbc54a84a728771486583c;hpb=82a1046663291b69499543c17bae9bccd21f6c53;p=deb_pkgs%2Fautorandr.git diff --git a/Makefile b/Makefile index 8a45be5..4141b1c 100644 --- a/Makefile +++ b/Makefile @@ -1,7 +1,18 @@ +all: + @echo "Call \"make install\" to install this program." + @echo "Call \"make hotplug\" to install matching hotplug events." +INSTALL_PATH=/usr/local/bin install: - install -m 774 autorandr /usr/bin/ - install -m 774 autorandr_monitor /usr/bin/ - install -m 644 bash_completion/autorandr /etc/bash_completion.d/ - ln -sf /usr/bin/autorandr /usr/bin/auto-disper - #install -m pm-utils/40autorandr /etc/pm/power.d/ + install -D -m 755 autorandr.py ${DESTDIR}${INSTALL_PATH}/autorandr + install -D -m 644 bash_completion/autorandr ${DESTDIR}/etc/bash_completion.d/autorandr + +hotplug: + install -D -m 755 pm-utils/40autorandr ${DESTDIR}/etc/pm/sleep.d/40autorandr + install -D -m 644 udev/40-monitor-hotplug.rules ${DESTDIR}/etc/udev/rules.d/40-monitor-hotplug.rules +ifeq (${USER},root) + udevadm control --reload-rules +else + @echo "Please run this command as root:" + @echo " udevadm control --reload-rules" +endif