#     TorTA: Perform traffic analysis experiments on Tor
#
#     Copyright (C) 2005 Steven J. Murdoch <http://www.cl.cam.ac.uk/users/sjm217/>
#
#     This program is free software; you can redistribute it and/or modify
#     it under the terms of the GNU General Public License as published by
#     the Free Software Foundation; either version 2 of the License, or
#     (at your option) any later version.
#
#     This program is distributed in the hope that it will be useful,
#     but WITHOUT ANY WARRANTY; without even the implied warranty of
#     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
#     GNU General Public License for more details.
#
#     You should have received a copy of the GNU General Public License
#     along with this program; if not, write to the Free Software
#     Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
#
#     $Id: Makefile 1403 2005-10-11 20:40:01Z sjm217 $

.PHONY: all clean release

VERSION=0.02
CC=gcc -g -Wall
TARGETS=victim evil-server receiver sender
RELEASE=victim.c evil-server.c receiver.c sender.c Makefile README COPYING

PACKAGE=torta-$(VERSION).tar.gz
PACKAGEDIR=torta-$(VERSION)

WEBSITE=$(HOME)/public_html/projects/anon

all: $(TARGETS)

clean:
	rm -f $(TARGETS) *~ $(PACKAGE)

release: $(PACKAGE)

publish: $(PACKAGE)
	cp $(PACKAGE) $(WEBSITE)
	ln -s $(WEBSITE)/$(PACKAGE) $(WEBSITE)/torta-latest.tar.gz
	chmod 644 $(WEBSITE)/$(PACKAGE)

$(PACKAGE): $(RELEASE)
	mkdir $(PACKAGEDIR)
	cp $(RELEASE) $(PACKAGEDIR)
	tar -czvf $@ $(PACKAGEDIR)
	rm -fr $(PACKAGEDIR)

victim: victim.c
	$(CC) -o $@ $<

evil-server: evil-server.c
	$(CC) -o $@ $<

receiver: receiver.c
	$(CC) -o $@ $<

sender: sender.c
	$(CC) -o $@ $<



