rice/scripts/Makefile
2025-10-03 12:47:49 +02:00

17 lines
359 B
Makefile

SHELL := /bin/bash
DEST := /usr/local/bin
SRC := ./src/
install:
@if [ "$$(id -u)" -ne 0 ]; then \
echo "Error: You must be root to run 'make install'."; \
exit 1; \
fi
@find $(SRC) -type f | while IFS= read -r fpath; do \
filename="$${fpath##*/}"; \
echo "Installing $$filename ..."; \
install -m 755 "$$fpath" "$(DEST)/$$filename"; \
done