summaryrefslogtreecommitdiff
path: root/Makefile
blob: e9ce1b411f5ac47f8346040806755050408eb74a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27

all: mactelnet mactelnetd mndp

clean: dist-clean

dist-clean:
	rm -f mactelnet mactelnetd mndp

install: all
	cp mndp $(DESTDIR)/usr/bin/
	cp mactelnet $(DESTDIR)/usr/bin/
	cp mactelnetd $(DESTDIR)/usr/sbin/
	mkdir -p $(DESTDIR)/etc
	cp mactelnetd.users $(DESTDIR)/etc/
	chown root $(DESTDIR)/etc/mactelnetd.users
	chmod 600 $(DESTDIR)/etc/mactelnetd.users

install-debian:

mactelnet: config.h udp.h udp.c mactelnet.c mactelnet.h protocol.c protocol.h console.c console.h devices.c devices.h md5.c md5.h
	gcc -Wall -g -DUSERSFILE='"/etc/mactelnetd.users"' -o mactelnet mactelnet.c udp.c protocol.c console.c devices.c md5.c

mactelnetd: config.h mactelnetd.c udp.h udp.c protocol.c protocol.h console.c console.h users.c users.h md5.c md5.h
	gcc -Wall -g -DUSERSFILE='"/etc/mactelnetd.users"' -o mactelnetd mactelnetd.c udp.c protocol.c console.c users.c md5.c

mndp: config.h mndp.c protocol.c protocol.h
	gcc -Wall -g -o mndp mndp.c protocol.c