Commit 7bb03240 authored by Leigh Stoller's avatar Leigh Stoller

Checkpoint clientside branch.

parent 54d318a8
......@@ -6,12 +6,12 @@
SRCDIR = @srcdir@
TESTBED_SRCDIR = @top_srcdir@
OBJDIR = @top_builddir@
SUBDIR = clientside
SUBDIR = $(subst $(TESTBED_SRCDIR)/,,$(SRCDIR))
SYSTEM := $(shell uname -s)
include $(OBJDIR)/Makeconf
SUBDIRS = event
SUBDIRS = lib event
all: all-subdirs
......@@ -19,13 +19,8 @@ include $(TESTBED_SRCDIR)/GNUmakerules
client: client-subdirs
client-install: client client-install-subdirs
control-install:
@$(MAKE) -C event control-install
post-install:
@$(MAKE) -C event post-install
control-install: control-install-subdirs
post-install: post-install-subdirs
clean: clean-subdirs
distclean: distclean-subdirs
......
#
# EMULAB-COPYRIGHT
# Copyright (c) 2000-2009 University of Utah and the Flux Group.
# Copyright (c) 2000-2011 University of Utah and the Flux Group.
# All rights reserved.
# Get rid of a bunch of nasty built-in implicit rules,
......@@ -118,24 +118,3 @@ check: $(TESTS)
done
endif
ifeq ($(MERGE_BUILD),1)
.PRECIOUS: ${SRCDIR}/*
#
# I really want to say something like:
# ${TESTBED_SRCDIR}/.merged: $(wildcard ${OBJDIR}/${MERGE_BUILD_SANDBOX}/${SUBDIR}/*)
# but that causes problems if one the prereq. has a rule for it (such
# as when both GNUmakefile and GNUmakefile.in exist in the source tree),
# thus I do the equivalent manually
#
newest=$(shell ls -rtd "${OBJDIR}/${MERGE_BUILD_SANDBOX}/${SUBDIR}/"* "${TESTBED_SRCDIR}/.merged" | tail -n 1)
ifneq ($(newest),${TESTBED_SRCDIR}/.merged)
${TESTBED_SRCDIR}/.merged:
cd ${TESTBED_SRCDIR} && utils/merge-build sync
.PHONY: ${TESTBED_SRCDIR}/.merged
else
${TESTBED_SRCDIR}/.merged:
endif
${SRCDIR}/*: ${TESTBED_SRCDIR}/.merged
endif
#
# EMULAB-COPYRIGHT
# Copyright (c) 2000-2009 University of Utah and the Flux Group.
# Copyright (c) 2000-2011 University of Utah and the Flux Group.
# All rights reserved.
#
# Most of the configure-substitution magic is done here.
......@@ -21,37 +21,11 @@ export AR = @AR@
export ELVIN_CONFIG = @ELVIN_CONFIG@
export JAVAC = @JAVAC@
export JAR = @JAR@
prefix = @prefix@
exec_prefix = @exec_prefix@
host_cpu = @host_cpu@
TBROOT = @prefix@
TBDEFS = @TBDEFS@
TBDBNAME = @TBDBNAME@
TBADMINGROUP = @TBADMINGROUP@
TBOPSEMAIL = @TBOPSEMAIL@
TBROBOCOPSEMAIL = @TBROBOCOPSEMAIL@
TBLOGSEMAIL = @TBLOGSEMAIL@
TBAUDITEMAIL = @TBAUDITEMAIL@
TBACTIVEARCHIVE = @TBACTIVEARCHIVE@
TBUSERSARCHIVE = @TBUSERSARCHIVE@
TBERRORSEMAIL = @TBERRORSEMAIL@
TBAPPROVALEMAIL = @TBAPPROVALEMAIL@
BOSSNODE = @BOSSNODE@
USERNODE = @USERNODE@
FSNODE = @FSNODE@
WWW = @WWW@
OURDOMAIN = @OURDOMAIN@
FSDIR_PROJ = @FSDIR_PROJ@
FSDIR_GROUPS = @FSDIR_GROUPS@
FSDIR_USERS = @FSDIR_USERS@
CPPFLAGS = @CPPFLAGS@
CFLAGS += @CFLAGS@
CXXFLAGS += @CXXFLAGS@
LDFLAGS = @LDFLAGS@
OPT_CFLAGS = @OPT_CFLAGS@
INSTALL_TOPDIR = @exec_prefix@
INSTALL_DIR = @exec_prefix@
......@@ -63,7 +37,6 @@ INSTALL_ETCDIR = @sysconfdir@
INSTALL_INCDIR = @includedir@
INSTALL_WWWDIR = @exec_prefix@/www
INSTALL_RCDIR = @INSTALL_RCDIR@
INSTALL_APACHE_CONFIG = @INSTALL_APACHE_CONFIG@
INSTALL = @INSTALL@
INSTALL_PROGRAM = @INSTALL@ -m 755
......@@ -80,18 +53,5 @@ LOG_TESTBED = @LOG_TESTBED@
EVENTSYS = @EVENTSYS@
ELVIN_COMPAT = @ELVIN_COMPAT@
HAVE_MEZZANINE = @HAVE_MEZZANINE@
GTK_CONFIG = @GTK_CONFIG@
BRAINSTEM_DIR = @BRAINSTEM_DIR@
host_cpu = @host_cpu@
HAVE_ULXMLRPCPP = @HAVE_ULXMLRPCPP@
STANDALONE_CLEARINGHOUSE = @STANDALONE_CLEARINGHOUSE@
NODE_USAGE_SUPPORT = @NODE_USAGE_SUPPORT@
MERGE_BUILD = @MERGE_BUILD@
MERGE_BUILD_SANDBOX = @MERGE_BUILD_SANDBOX@
EMULAB_CLIENTSIDE = @EMULAB_CLIENTSIDE@
EXP_VIS_SUPPORT = @EXP_VIS_SUPPORT@
This diff is collapsed.
This diff is collapsed.
......@@ -5,4 +5,5 @@
#undef VERSION
#undef ELVIN_COMPAT
#undef EMULAB_CLIENTSIDE
\ No newline at end of file
#undef EMULAB_CLIENTSIDE
#undef LOG_TESTBED
This diff is collapsed.
......@@ -3,7 +3,12 @@
# Copyright (c) 2000-2011 University of Utah and the Flux Group.
# All rights reserved.
#
AC_INIT(Makefile.in)
AC_PREREQ(2.62)
AC_INIT(Makeconf.in)
AC_CONFIG_AUX_DIR(${srcdir}/autoconf)
AC_CONFIG_HEADER(config.h)
AC_PROG_CPP
AC_PROG_CXX
AC_PROG_LN_S
......@@ -14,6 +19,10 @@ AC_PATH_PROG(AR, ar)
if test -z "$AR" ; then
AC_MSG_ERROR([no acceptable ar found in \$PATH])
fi
AC_PATH_PROG(STRIP, strip)
if test -z "$STRIP" ; then
AC_MSG_ERROR([no acceptable strip found in \$PATH])
fi
AC_PATH_PROG(RM, rm)
if test -z "$RM" ; then
AC_MSG_ERROR([no acceptable rm found in \$PATH])
......@@ -30,15 +39,18 @@ AC_PATH_PROG(TAR, tar)
if test -z "$TAR" ; then
AC_MSG_ERROR([no tar found in \$PATH])
fi
AC_PATH_PROG(LIBTOOL, libtool)
if test -z "$LIBTOOL" ; then
AC_MSG_ERROR([no libtool found in \$PATH])
fi
AC_PATH_PROG(RPM, rpm, rpm)
if test -z "$RPM" ; then
AC_MSG_ERROR([no rpm found in \$PATH])
fi
# Need this for Makeconf.
AC_SUBST(PATH)
# Tell build it is the clientside.
AC_SUBST(EMULAB_CLIENTSIDE)
EMULAB_CLIENTSIDE=1
#
# The only option is if we build in elvin compat support.
#
......@@ -51,5 +63,38 @@ AC_ARG_ENABLE(elvin_compat,
if test "$enable_elvin_compat" = "yes"; then
ELVIN_COMPAT=1
fi
if test $ELVIN_COMPAT -eq 1; then
AC_DEFINE_UNQUOTED(ELVIN_COMPAT, 1)
fi
AC_SUBST(CLIENT_ETCDIR)
AC_SUBST(CLIENT_BINDIR)
AC_SUBST(CLIENT_VARDIR)
AC_SUBST(CLIENT_MANDIR)
CLIENT_ETCDIR="/etc/emulab"
CLIENT_BINDIR="/usr/local/etc/emulab"
CLIENT_VARDIR="/var/emulab"
CLIENT_MANDIR="/usr/local/man"
TBLOGFACIL="local5"
LOG_TESTBED=`echo "LOG_$TBLOGFACIL" | tr a-z A-Z`
AC_DEFINE_UNQUOTED(LOG_TESTBED, $LOG_TESTBED)
AC_SUBST(LOG_TESTBED)
AC_SUBST(TBLOGFACIL)
outfiles="Makeconf GNUmakefile \
lib/GNUmakefile \
lib/libtb/GNUmakefile \
lib/event/GNUmakefile \
event/GNUmakefile \
event/program-agent/GNUmakefile"
#
# Do this for easy distclean.
#
DISTCLEAN_FILES="$outfiles"
AC_SUBST(DISTCLEAN_FILES)
AC_OUTPUT($outfiles)
AC_OUTPUT(Makefile 2.pubsubd.sh linux-pubsubd.sh)
......@@ -6,8 +6,7 @@
SRCDIR = @srcdir@
TESTBED_SRCDIR = @top_srcdir@
OBJDIR = @top_builddir@
SUBDIR = clientside/event
SYSTEM := $(shell uname -s)
SUBDIR = $(subst $(TESTBED_SRCDIR)/,,$(SRCDIR))
include $(OBJDIR)/Makeconf
......@@ -19,13 +18,8 @@ include $(TESTBED_SRCDIR)/GNUmakerules
client: client-subdirs
client-install: client client-install-subdirs
control-install:
@$(MAKE) -C event control-install
post-install:
@$(MAKE) -C event post-install
control-install: control-install-subdirs
post-install: post-install-subdirs
clean: clean-subdirs
distclean: distclean-subdirs
......
......@@ -6,7 +6,7 @@
SRCDIR = @srcdir@
TESTBED_SRCDIR = @top_srcdir@
OBJDIR = @top_builddir@
SUBDIR = clientside/event/program-agent
SUBDIR = $(subst $(TESTBED_SRCDIR)/,,$(SRCDIR))
SYSTEM := $(shell uname -s)
PROGRAMS = program-agent
......@@ -62,6 +62,8 @@ install: $(INSTALL_DIR)/opsdir/sbin/program-agent
control-install: $(INSTALL_SBINDIR)/program-agent
post-install:
client: $(PROGRAMS)
client-install: client
$(INSTALL_PROGRAM) program-agent$(EXE) $(DESTDIR)$(CLIENT_BINDIR)/program-agent$(EXE)
......
/*
* EMULAB-COPYRIGHT
* Copyright (c) 2000-2010 University of Utah and the Flux Group.
* Copyright (c) 2000-2011 University of Utah and the Flux Group.
* All rights reserved.
*/
......@@ -735,6 +735,7 @@ main(int argc, char **argv)
setenv("NODECNETIP", inet_ntoa(ia), 1);
}
#ifdef EMULAB_CLIENTSIDE
/*
* XXX for planetlab, hostname is the official hostname as opposed
* to the per-experiment Emulab alias. To be consistent, we want
......@@ -757,7 +758,7 @@ main(int argc, char **argv)
}
} else
setenv("NODECNET", buf, 1);
#endif
/*
* Now find "the default" experimental network interface by stripping
* the domain qualifier and looking that up. If the short name fails
......
......@@ -5529,7 +5529,6 @@ else
event/nsetrafgen/nseinput.tcl \
event/nsetrafgen/nse-makepatch \
event/delay-agent/GNUmakefile \
clientside/event/program-agent/GNUmakefile \
event/link-agent/GNUmakefile \
event/stated/waitForState \
event/stated/GNUmakefile event/stated/stated \
......@@ -7124,7 +7123,10 @@ outfiles="$outfiles Makeconf GNUmakefile \
node_usage/analy2 node_usage/refresh \
node_usage/from_ptop node_usage/sanity \
node_usage/gather node_usage/mk-php-pages \
node_usage/get-start-date"
node_usage/get-start-date \
clientside/GNUmakefile \
clientside/event/GNUmakefile \
clientside/event/program-agent/GNUmakefile"
#
# Do this for easy distclean.
......
......@@ -712,7 +712,6 @@ else
event/nsetrafgen/nseinput.tcl \
event/nsetrafgen/nse-makepatch \
event/delay-agent/GNUmakefile \
clientside/event/program-agent/GNUmakefile \
event/link-agent/GNUmakefile \
event/stated/waitForState \
event/stated/GNUmakefile event/stated/stated \
......@@ -1083,7 +1082,10 @@ outfiles="$outfiles Makeconf GNUmakefile \
node_usage/analy2 node_usage/refresh \
node_usage/from_ptop node_usage/sanity \
node_usage/gather node_usage/mk-php-pages \
node_usage/get-start-date"
node_usage/get-start-date \
clientside/GNUmakefile \
clientside/event/GNUmakefile \
clientside/event/program-agent/GNUmakefile"
#
# Do this for easy distclean.
......
......@@ -3,11 +3,10 @@
# Copyright (c) 2000-2011 University of Utah and the Flux Group.
# All rights reserved.
#
SRCDIR = @srcdir@
TESTBED_SRCDIR = @top_srcdir@
OBJDIR = ..
SUBDIR = lib
OBJDIR = @top_builddir@
SUBDIR = $(subst $(TESTBED_SRCDIR)/,,$(SRCDIR))
include $(OBJDIR)/Makeconf
......
......@@ -3,11 +3,10 @@
# Copyright (c) 2000-2011 University of Utah and the Flux Group.
# All rights reserved.
#
SRCDIR = @srcdir@
TESTBED_SRCDIR = @top_srcdir@
OBJDIR = ../..
SUBDIR = lib/event
OBJDIR = @top_builddir@
SUBDIR = $(subst $(TESTBED_SRCDIR)/,,$(SRCDIR))
include $(OBJDIR)/Makeconf
......@@ -26,7 +25,10 @@ SWIGLIBS =
# Re-entrant, multi-threaded version on FreeBSD and Linux, not on Windows.
ifneq ($(SYSTEM),CYGWIN_NT-5.1)
LIBS += libevent_r.a
SWIGLIBS += event.so _tbevent.so
SWIGLIBS += event.so
ifneq ($(EMULAB_CLIENTSIDE),1)
SWIGLIBS += _tbevent.so
endif
endif
PROGRAMS = $(LIBS) $(SWIGLIBS)
......
......@@ -3,19 +3,17 @@
# Copyright (c) 2000-2011 University of Utah and the Flux Group.
# All rights reserved.
#
SRCDIR = @srcdir@
TESTBED_SRCDIR = @top_srcdir@
OBJDIR = ../..
SUBDIR = lib/libtb
OBJDIR = @top_builddir@
SUBDIR = $(subst $(TESTBED_SRCDIR)/,,$(SRCDIR))
include $(OBJDIR)/Makeconf
all: libtb.a
client: libtb-nodb.a
cmp -s libtb-nodb.a libtb.a || cp -pf libtb-nodb.a libtb.a
client-install: client
client: all
client-install: all
# The point of this is to make sure a nodb version of the library is
# built during the ops-install target when installing a new emulab.
......@@ -25,13 +23,12 @@ control-install: client
include $(TESTBED_SRCDIR)/GNUmakerules
OBJS = log.o tbdefs.o popenf.o systemf.o be_user.o tmcc.o
ifneq ($(EMULAB_CLIENTSIDE),1)
OBJS += tbdb.o
endif
CFLAGS += -O -g -Wall -I${OBJDIR} -I/usr/local/include
libtb.a: $(OBJS) tbdb.o
$(AR) crv $@ $(OBJS) tbdb.o
$(RANLIB) $@
libtb-nodb.a: $(OBJS)
libtb.a: $(OBJS)
$(AR) crv $@ $(OBJS)
$(RANLIB) $@
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment