File tree Expand file tree Collapse file tree 6 files changed +10
-8
lines changed
Expand file tree Collapse file tree 6 files changed +10
-8
lines changed Original file line number Diff line number Diff line change 11.PHONY : all systemd scripts configs
22
3- PREFIX := /usr/local
3+ PREFIX := /usr
44
55SCRIPTS_DIR := $(PREFIX ) /bin
66SYSTEMD_DIR := /etc/systemd/system
Original file line number Diff line number Diff line change @@ -17,7 +17,7 @@ make install
1717Available config options for ` make ` :
1818
1919- ` DESTDIR ` (default: unset, use this to have ` make install ` copy things to a build folder or something similar)
20- - ` PREFIX ` (default: ` /usr/local ` )
20+ - ` PREFIX ` (default: ` /usr ` )
2121- ` SCRIPTS_DIR ` (default: ` $(PREFIX)/bin ` )
2222- ` SYSTEMD_DIR ` (default: ` /etc/systemd/system ` )
2323- ` CONFIG_DIR ` (default: ` /etc/camera-streamer.conf.d ` )
Original file line number Diff line number Diff line change @@ -10,7 +10,7 @@ PORT=$2
1010DEVICE=$3
1111
1212CONFIG_DIR=/etc/camera-streamer.conf.d
13- CONTROL=/usr/local/ bin/camera-streamer-control
13+ CONTROL=/usr/bin/camera-streamer-control
1414
1515# # Name
1616
Original file line number Diff line number Diff line change 88action=$1
99single=$2
1010
11+ CONFIG_DIR=/etc/camera-streamer.conf.d
12+
1113run-action () {
1214 unit=$1
1315 echo " Running $action for $unit ..."
@@ -41,7 +43,7 @@ if [ -z "$single" ] || [[ "$single" == "libcamera" ]]; then
4143fi
4244
4345# iterate over all the camera confs in /boot/camera-streamer
44- for conf in /etc/camera-streamer.conf.d /usb-* .conf; do
46+ for conf in $CONFIG_DIR /usb-* .conf; do
4547 # get the name of the camera
4648 name=$( basename " $conf " .conf)
4749 name=${name# usb-}
Original file line number Diff line number Diff line change 88NAME=$1
99
1010CONFIG_DIR=/etc/camera-streamer.conf.d
11- CONTROL=/usr/local/ bin/camera-streamer-control
11+ CONTROL=/usr/bin/camera-streamer-control
1212
1313if [ -z " $NAME " ]; then
1414 echo " Usage: $0 <name>"
Original file line number Diff line number Diff line change @@ -4,9 +4,9 @@ After=network.target
44
55[Service]
66Type =oneshot
7- ExecStart =/usr/local/ bin/camera-streamer-control start
8- ExecStop =/usr/local/ bin/camera-streamer-control stop
9- ExecReload =/usr/local/ bin/camera-streamer-control restart
7+ ExecStart =/usr/bin/camera-streamer-control start
8+ ExecStop =/usr/bin/camera-streamer-control stop
9+ ExecReload =/usr/bin/camera-streamer-control restart
1010RemainAfterExit =yes
1111KillMode =mixed
1212TimeoutStopSec =10
You can’t perform that action at this time.
0 commit comments