--- a/Makefile +++ b/Makefile @@ -26,6 +26,10 @@ LIBS=-L$(OSSLLIB) +PREFIX=/usr/local +INSTALL=install + + all: chntpw cpnt reged samusrgrp sampasswd samunlock chntpw: chntpw.o ntreg.o edlib.o libsam.o @@ -70,6 +74,10 @@ .c.o: $(CC) -c $(CFLAGS) $< +install: all + $(INSTALL) -d -m 0755 $(DESTDIR)$(PREFIX)/bin + $(INSTALL) -m 0755 chntpw reged samusrgrp sampasswd samunlock $(DESTDIR)$(PREFIX)/bin + clean: rm -f *.o chntpw cpnt reged samusrgrp sampasswd samunlock *~