GNUmakefile.in 2.02 KB
Newer Older
Leigh Stoller's avatar
Leigh Stoller committed
1 2
#
# EMULAB-COPYRIGHT
3
# Copyright (c) 2000-2006 University of Utah and the Flux Group.
Leigh Stoller's avatar
Leigh Stoller committed
4 5 6
# All rights reserved.
#

Leigh Stoller's avatar
Leigh Stoller committed
7 8 9
#
# Insert Copyright Here.
#
10 11 12 13
SRCDIR		= @srcdir@
TESTBED_SRCDIR	= @top_srcdir@
OBJDIR		= ../..
SUBDIR		= tbsetup/ns2ir
14

15
include $(OBJDIR)/Makeconf
16

17
LIB_STUFF    = lanlink.tcl node.tcl sim.tcl tb_compat.tcl null.tcl \
18
		  nsobject.tcl traffic.tcl vtype.tcl parse.tcl program.tcl \
19
		  nsenode.tcl nstb_compat.tcl event.tcl firewall.tcl \
20 21
		  elabinelab.ns elabinelab-withfsnode.ns \
		  fw.ns timeline.tcl sequence.tcl \
22
		  topography.tcl console.tcl
23 24
BOSSLIBEXEC  = parse-ns
USERLIBEXEC  = parse.proxy
Leigh Stoller's avatar
Leigh Stoller committed
25

26 27 28 29 30
# These scripts installed setuid, with sudo. 
SETUID_BIN_SCRIPTS   = 
SETUID_SBIN_SCRIPTS  = 
SETUID_LIBX_SCRIPTS  = parse-ns

Leigh Stoller's avatar
Leigh Stoller committed
31
#
32 33
# Force dependencies on the scripts so that they will be rerun through
# configure if the .in file is changed.
Leigh Stoller's avatar
Leigh Stoller committed
34
# 
35
all: $(LIB_STUFF) $(BOSSLIBEXEC) $(USERLIBEXEC)
Leigh Stoller's avatar
Leigh Stoller committed
36

37
include $(TESTBED_SRCDIR)/GNUmakerules
Leigh Stoller's avatar
Leigh Stoller committed
38

39 40 41 42 43 44 45 46 47 48 49
install:	control-install \
	$(addprefix $(INSTALL_LIBEXECDIR)/, $(BOSSLIBEXEC)) \
	$(addprefix $(INSTALL_DIR)/opsdir/lib/ns2ir/, $(LIB_STUFF)) \
	$(addprefix $(INSTALL_DIR)/opsdir/libexec/ns2ir/, $(USERLIBEXEC))

control-install: $(addprefix $(INSTALL_LIBDIR)/ns2ir/, $(LIB_STUFF)) \
	$(addprefix $(INSTALL_LIBEXECDIR)/ns2ir/, $(USERLIBEXEC))

post-install: 
	chmod 775 $(INSTALL_LIBEXECDIR)
	chown root $(INSTALL_LIBEXECDIR)/parse-ns
50
	chmod 775 $(INSTALL_LIBEXECDIR)/ns2ir
51
	chmod u+s $(INSTALL_LIBEXECDIR)/parse-ns
52 53 54
	chmod 775 $(INSTALL_LIBDIR)/ns2ir
	chmod 775 $(INSTALL_DIR)/opsdir/lib/ns2ir
	chmod 775 $(INSTALL_DIR)/opsdir/libexec/ns2ir
Leigh Stoller's avatar
Leigh Stoller committed
55

56 57 58 59 60 61
$(INSTALL_LIBDIR)/ns2ir/%: %
	@echo "Installing $<"
	-mkdir -p $(INSTALL_LIBDIR)/ns2ir
	$(INSTALL) $< $@

$(INSTALL_LIBEXECDIR)/ns2ir/%: %
Leigh Stoller's avatar
Leigh Stoller committed
62
	@echo "Installing $<"
63
	-mkdir -p $(INSTALL_LIBEXECDIR)/ns2ir
Leigh Stoller's avatar
Leigh Stoller committed
64 65
	$(INSTALL) $< $@

66 67 68 69 70 71 72 73 74 75
$(INSTALL_DIR)/opsdir/lib/ns2ir/%: %
	@echo "Installing $<"
	-mkdir -p $(INSTALL_DIR)/opsdir/lib/ns2ir
	$(INSTALL) $< $@

$(INSTALL_DIR)/opsdir/libexec/ns2ir/%: %
	@echo "Installing $<"
	-mkdir -p $(INSTALL_DIR)/opsdir/libexec/ns2ir
	$(INSTALL) $< $@

Leigh Stoller's avatar
Leigh Stoller committed
76
clean: