#! /bin/sh
-# From configure.ac Revision: 4915 .
+# From configure.ac Revision: 4930 .
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.61 for simgrid 3.3-cvs.
+# Generated by GNU Autoconf 2.61 for simgrid 3.3-svn.
#
# Report bugs to <simgrid-devel@lists.gforge.inria.fr>.
#
# Identity of this package.
PACKAGE_NAME='simgrid'
PACKAGE_TARNAME='simgrid'
-PACKAGE_VERSION='3.3-cvs'
-PACKAGE_STRING='simgrid 3.3-cvs'
+PACKAGE_VERSION='3.3-svn'
+PACKAGE_STRING='simgrid 3.3-svn'
PACKAGE_BUGREPORT='simgrid-devel@lists.gforge.inria.fr'
ac_unique_file="include/gras.h"
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
-\`configure' configures simgrid 3.3-cvs to adapt to many kinds of systems.
+\`configure' configures simgrid 3.3-svn to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
if test -n "$ac_init_help"; then
case $ac_init_help in
- short | recursive ) echo "Configuration of simgrid 3.3-cvs:";;
+ short | recursive ) echo "Configuration of simgrid 3.3-svn:";;
esac
cat <<\_ACEOF
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
-simgrid configure 3.3-cvs
+simgrid configure 3.3-svn
generated by GNU Autoconf 2.61
Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
-It was created by simgrid $as_me 3.3-cvs, which was
+It was created by simgrid $as_me 3.3-svn, which was
generated by GNU Autoconf 2.61. Invocation command line was
$ $0 $@
# Define the identity of the package.
PACKAGE='simgrid'
- VERSION='3.3-cvs'
+ VERSION='3.3-svn'
cat >>confdefs.h <<_ACEOF
+
+###############
+## SVN version check
+##
+if test -e .svn ; then
+ VERSION="$VERSION-r`svnversion`"
+ PACKAGE_VERSION="$PACKAGE_VERSION-r`svnversion`"
+ PACKAGE_STRING="PACKAGE_STRING r`svnversion`"
+fi
###############
## System checks
if test x$MD5SUM != xno ; then
- build_version=`find -name '*.ch' |grep -v src/ucontext_stack.h | grep -v src/gras_config.h |\
+ build_version=`find . -name '*.ch' |grep -v src/ucontext_stack.h | grep -v src/gras_config.h |\
xargs cat| $MD5SUM | sed 's/ .*$//'`
else
build_version="no_md5sum_binary"
ac_config_files="$ac_config_files examples/java/Makefile examples/java/basic/Makefile examples/java/comm_time/Makefile examples/java/suspend/Makefile examples/java/ping_pong/Makefile"
-ac_config_files="$ac_config_files examples/Makefile examples/msg/Makefile examples/simdag/Makefile examples/gras/Makefile examples/gras/ping/Makefile examples/gras/rpc/Makefile examples/gras/spawn/Makefile examples/gras/synchro/Makefile examples/gras/timer/Makefile examples/gras/chrono/Makefile examples/gras/mutual_exclusion/simple_token/Makefile examples/gras/mmrpc/Makefile examples/gras/pmm/Makefile examples/gras/all2all/Makefile examples/amok/Makefile"
+ac_config_files="$ac_config_files examples/Makefile examples/msg/Makefile examples/simdag/Makefile examples/gras/Makefile examples/gras/ping/Makefile examples/gras/rpc/Makefile examples/gras/spawn/Makefile examples/gras/synchro/Makefile examples/gras/timer/Makefile examples/gras/properties/Makefile examples/gras/chrono/Makefile examples/gras/mutual_exclusion/simple_token/Makefile examples/gras/mmrpc/Makefile examples/gras/pmm/Makefile examples/gras/all2all/Makefile examples/amok/Makefile"
ac_config_files="$ac_config_files src/smpi/smpicc src/smpi/smpirun"
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
-This file was extended by simgrid $as_me 3.3-cvs, which was
+This file was extended by simgrid $as_me 3.3-svn, which was
generated by GNU Autoconf 2.61. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
_ACEOF
cat >>$CONFIG_STATUS <<_ACEOF
ac_cs_version="\\
-simgrid config.status 3.3-cvs
+simgrid config.status 3.3-svn
configured by $0, generated by GNU Autoconf 2.61,
with options \\"`echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
"examples/gras/spawn/Makefile") CONFIG_FILES="$CONFIG_FILES examples/gras/spawn/Makefile" ;;
"examples/gras/synchro/Makefile") CONFIG_FILES="$CONFIG_FILES examples/gras/synchro/Makefile" ;;
"examples/gras/timer/Makefile") CONFIG_FILES="$CONFIG_FILES examples/gras/timer/Makefile" ;;
+ "examples/gras/properties/Makefile") CONFIG_FILES="$CONFIG_FILES examples/gras/properties/Makefile" ;;
"examples/gras/chrono/Makefile") CONFIG_FILES="$CONFIG_FILES examples/gras/chrono/Makefile" ;;
"examples/gras/mutual_exclusion/simple_token/Makefile") CONFIG_FILES="$CONFIG_FILES examples/gras/mutual_exclusion/simple_token/Makefile" ;;
"examples/gras/mmrpc/Makefile") CONFIG_FILES="$CONFIG_FILES examples/gras/mmrpc/Makefile" ;;
examples/gras/spawn/Makefile
examples/gras/synchro/Makefile
examples/gras/timer/Makefile
+ examples/gras/properties/Makefile
examples/gras/chrono/Makefile
examples/gras/mutual_exclusion/simple_token/Makefile
examples/gras/mmrpc/Makefile
# GNU LGPL (v2.1) licence.
-SUBDIRS= ping rpc spawn timer chrono mutual_exclusion/simple_token mmrpc all2all pmm synchro
+SUBDIRS= ping rpc spawn timer chrono mutual_exclusion/simple_token mmrpc all2all pmm synchro properties
# p2p
include $(top_srcdir)/acmacro/dist-files.mk
target_vendor = @target_vendor@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
-SUBDIRS = ping rpc spawn timer chrono mutual_exclusion/simple_token mmrpc all2all pmm synchro
+SUBDIRS = ping rpc spawn timer chrono mutual_exclusion/simple_token mmrpc all2all pmm synchro properties
all: all-recursive
.SUFFIXES:
--- /dev/null
+# Copyright (c) 2004-2007. The SimGrid team. All right reserved.
+
+# This file is part of the SimGrid project. This is free software:
+# You can redistribute and/or modify it under the terms of the
+# GNU LGPL (v2.1) licence.
+
+
+INCLUDES= -I$(top_srcdir)/include
+
+EXTRA_DIST=properties.xml properties.h
+include $(top_srcdir)/examples/gras/tests.mk
+
+# AUTOMAKE variable definition
+noinst_PROGRAMS=properties_slave properties_master properties_simulator
+
+properties_simulator_SOURCES= _properties_simulator.c properties.c
+properties_simulator_LDADD= $(top_builddir)/src/libsimgrid.la
+
+properties_slave_SOURCES= _properties_slave.c properties.c
+properties_slave_LDADD= $(top_builddir)/src/libgras.la
+
+properties_master_SOURCES= _properties_master.c properties.c
+properties_master_LDADD= $(top_builddir)/src/libgras.la
+
+# Take care of generatated sources
+NAME=properties
+PROCESSES= slave master
+include $(top_srcdir)/examples/temps-gras-stub.mk
+
+# Cruft
+include $(top_srcdir)/acmacro/dist-files.mk
+++ /dev/null
-<?xml version='1.0'?>
-<!DOCTYPE platform SYSTEM "surfxml.dtd">
-<platform version="2">
- <process host="C1-01" function="server">
- <prop id="someprop" value="somevalue"/>
- </process>
- <process host="C1-00" function="client">
- <prop id="otherprop" value="othervalue"/>
- </process>
-</platform>
XBT_LOG_NEW_DEFAULT_CATEGORY(test,"Simple Property example");
+int master(int argc, char *argv[]);
+int slave(int argc, char *argv[]);
-int client(int argc, char *argv[]) {
+
+int slave(int argc, char *argv[]) {
gras_init(&argc,argv);
/* Get the properties */
}
/* Try to get a property that does not exist */
- char noexist[]="Nonexisent";
+ const char *noexist="Nonexisting";
const char *value = gras_process_property_value(noexist);
if ( value == NULL)
INFO1("Process property: %s is undefined", noexist);
else
INFO2("Process property: %s has value: %s", noexist, value);
- /* Modify an existing property. First check it exists */\
+ /* Modify an existing property. First check it exists */
INFO0("Trying to modify a process property");
- char exist[]="otherprop";
+ const char *exist="otherprop";
value = gras_process_property_value(exist);
- if ( value == NULL)
+ if (value == NULL)
INFO1("\tProperty: %s is undefined", exist);
else {
INFO2("\tProperty: %s old value: %s", exist, value);
- xbt_dict_set(props, exist, strdup("newValue"), free);
+ xbt_dict_set(props, exist, xbt_strdup("newValue"), free);
}
/* Test if we have changed the value */
value = gras_process_property_value(exist);
- if ( value == NULL)
+ if (value == NULL)
INFO1("\tProperty: %s is undefined", exist);
else
INFO2("\tProperty: %s new value: %s", exist, value);
-
+
+ gras_os_sleep(1);
gras_exit();
return 0;
}
-int server(int argc, char *argv[]) {
+int master(int argc, char *argv[]) {
gras_init(&argc,argv);
/* Get the properties */
}
/* Try to get a property that does not exist */
- char noexist[]="Nonexisent";
+ const char *noexist="Nonexisting";
const char *value = gras_os_host_property_value(noexist);
- if ( value == NULL)
- INFO1("Host property: %s is undefined", noexist);
- else
- INFO2("Host property: %s has value: %s", noexist, value);
+ xbt_assert2(value == NULL, "Host property: %s has value: %s", noexist, value);
+ gras_os_sleep(1);
gras_exit();
return 0;
}
--- /dev/null
+<?xml version='1.0'?>
+<!DOCTYPE platform SYSTEM "surfxml.dtd">
+<platform version="2">
+ <!-- The master process (with some arguments) -->
+ <process host="C1-01" function="master">
+ <argument value="1"/> <!-- Number of tasks -->
+ <argument value="50000000"/> <!-- Computation size of tasks -->
+ <argument value="1000000"/> <!-- Communication size of tasks -->
+ <argument value="C1-00"/> <!-- First slave -->
+ </process>
+ <!-- The slave process (with no argument) -->
+ <process host="C1-00" function="slave">
+ <prop id="SomeProp" value="SomeValue"/>
+ </process>
+</platform>
--- /dev/null
+
+! timeout 20
+& $SG_TEST_ENV ./properties_master$EXEEXT 4002 --log=root.fmt=%P:%t%e%m%n $ARGS
+
+! timeout 20
+& $SG_TEST_ENV ./properties_slave$EXEEXT 127.0.0.1 4002 --log=root.fmt=%P:%t%e%m%n $ARGS
--- /dev/null
+p Runs the 'properties' test within the simulator (simulation times valid for 32bits architectures)
+
+$ $SG_TEST_EXENV ./properties_simulator${EXEEXT:=} ${srcdir:=.}/../../platforms/prop.xml ${srcdir:=.}/properties.xml
+> [C1-01:master:(1) 0.000000] [test/INFO] Host property: mem has value: 4
+> [C1-01:master:(1) 0.000000] [test/INFO] Host property: Hdd has value: 180
+> [C1-00:slave:(2) 0.000000] [test/INFO] Process property: SomeProp has value: SomeValue
+> [C1-00:slave:(2) 0.000000] [test/INFO] Process property: Nonexisting is undefined
+> [C1-00:slave:(2) 0.000000] [test/INFO] Trying to modify a process property
+> [C1-00:slave:(2) 0.000000] [test/INFO] Property: otherprop is undefined
+> [C1-00:slave:(2) 0.000000] [test/INFO] Property: otherprop is undefined
+> [C1-01:master:(1) 1.000000] [gras/INFO] Exiting GRAS
+> [C1-00:slave:(2) 1.000000] [gras/INFO] Exiting GRAS
--- /dev/null
+p Runs the 'properties' test within the simulator (simulation times valid for 32bits architectures)
+
+$ $SG_TEST_EXENV ./properties_simulator${EXEEXT:=} ${srcdir:=.}/../../platforms/prop.xml ${srcdir:=.}/properties.xml
+> [C1-01:master:(1) 0.000000] [test/INFO] Host property: mem has value: 4
+> [C1-01:master:(1) 0.000000] [test/INFO] Host property: Hdd has value: 180
+> [C1-00:slave:(2) 0.000000] [test/INFO] Process property: SomeProp has value: SomeValue
+> [C1-00:slave:(2) 0.000000] [test/INFO] Process property: Nonexisting is undefined
+> [C1-00:slave:(2) 0.000000] [test/INFO] Trying to modify a process property
+> [C1-00:slave:(2) 0.000000] [test/INFO] Property: otherprop is undefined
+> [C1-00:slave:(2) 0.000000] [test/INFO] Property: otherprop is undefined
+> [C1-01:master:(1) 1.000000] [gras/INFO] Exiting GRAS
+> [C1-00:slave:(2) 1.000000] [gras/INFO] Exiting GRAS