diff --git a/configure b/configure
index 40f07e42f2c5276c42e4deac008d960656d0f3ed..2c857b41dff85d5bbd11e62b07d24d49453210e1 100755
--- a/configure
+++ b/configure
@@ -854,6 +854,8 @@ CXXDEPMODE
 ac_ct_CXX
 CXXFLAGS
 CXX
+WITH_CYGWIN_FALSE
+WITH_CYGWIN_TRUE
 HAVE_AIX_PROCTRACK_FALSE
 HAVE_AIX_PROCTRACK_TRUE
 EGREP
@@ -5635,11 +5637,26 @@ $as_echo "#define USE_ALIAS 1" >>confdefs.h
  ;;
 esac
 
+ac_have_cygwin=no
 case "$host" in
+     	*cygwin)   LDFLAGS="$LDFLAGS -no-undefined"
+		   SO_LDFLAGS="$SO_LDFLAGS \$(top_builddir)/src/api/libslurmhelper.la"
+
+		   ac_have_cygwin=yes
+		   ;;
 	*solaris*) CC="/usr/sfw/bin/gcc"
 		   CFLAGS="$CFLAGS -D_POSIX_PTHREAD_SEMANTICS -I/usr/sfw/include"
 		   LDFLAGS="$LDFLAGS -L/usr/sfw/lib"
+		   ;;
 esac
+ if test x"$ac_have_cygwin" == x"yes"; then
+  WITH_CYGWIN_TRUE=
+  WITH_CYGWIN_FALSE='#'
+else
+  WITH_CYGWIN_TRUE='#'
+  WITH_CYGWIN_FALSE=
+fi
+
 
 ac_ext=c
 ac_cpp='$CPP $CPPFLAGS'
@@ -7202,13 +7219,13 @@ if test "${lt_cv_nm_interface+set}" = set; then :
 else
   lt_cv_nm_interface="BSD nm"
   echo "int some_variable = 0;" > conftest.$ac_ext
-  (eval echo "\"\$as_me:7205: $ac_compile\"" >&5)
+  (eval echo "\"\$as_me:7222: $ac_compile\"" >&5)
   (eval "$ac_compile" 2>conftest.err)
   cat conftest.err >&5
-  (eval echo "\"\$as_me:7208: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
+  (eval echo "\"\$as_me:7225: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
   (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
   cat conftest.err >&5
-  (eval echo "\"\$as_me:7211: output\"" >&5)
+  (eval echo "\"\$as_me:7228: output\"" >&5)
   cat conftest.out >&5
   if $GREP 'External.*some_variable' conftest.out > /dev/null; then
     lt_cv_nm_interface="MS dumpbin"
@@ -8413,7 +8430,7 @@ ia64-*-hpux*)
   ;;
 *-*-irix6*)
   # Find out which ABI we are using.
-  echo '#line 8416 "configure"' > conftest.$ac_ext
+  echo '#line 8433 "configure"' > conftest.$ac_ext
   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
   (eval $ac_compile) 2>&5
   ac_status=$?
@@ -10202,11 +10219,11 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:10205: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:10222: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>conftest.err)
    ac_status=$?
    cat conftest.err >&5
-   echo "$as_me:10209: \$? = $ac_status" >&5
+   echo "$as_me:10226: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s "$ac_outfile"; then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings other than the usual output.
@@ -10541,11 +10558,11 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:10544: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:10561: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>conftest.err)
    ac_status=$?
    cat conftest.err >&5
-   echo "$as_me:10548: \$? = $ac_status" >&5
+   echo "$as_me:10565: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s "$ac_outfile"; then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings other than the usual output.
@@ -10646,11 +10663,11 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:10649: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:10666: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>out/conftest.err)
    ac_status=$?
    cat out/conftest.err >&5
-   echo "$as_me:10653: \$? = $ac_status" >&5
+   echo "$as_me:10670: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s out/conftest2.$ac_objext
    then
      # The compiler can only warn and ignore the option if not recognized
@@ -10701,11 +10718,11 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:10704: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:10721: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>out/conftest.err)
    ac_status=$?
    cat out/conftest.err >&5
-   echo "$as_me:10708: \$? = $ac_status" >&5
+   echo "$as_me:10725: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s out/conftest2.$ac_objext
    then
      # The compiler can only warn and ignore the option if not recognized
@@ -13085,7 +13102,7 @@ else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<_LT_EOF
-#line 13088 "configure"
+#line 13105 "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
@@ -13181,7 +13198,7 @@ else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<_LT_EOF
-#line 13184 "configure"
+#line 13201 "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
@@ -15137,11 +15154,11 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:15140: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:15157: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>conftest.err)
    ac_status=$?
    cat conftest.err >&5
-   echo "$as_me:15144: \$? = $ac_status" >&5
+   echo "$as_me:15161: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s "$ac_outfile"; then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings other than the usual output.
@@ -15236,11 +15253,11 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:15239: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:15256: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>out/conftest.err)
    ac_status=$?
    cat out/conftest.err >&5
-   echo "$as_me:15243: \$? = $ac_status" >&5
+   echo "$as_me:15260: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s out/conftest2.$ac_objext
    then
      # The compiler can only warn and ignore the option if not recognized
@@ -15288,11 +15305,11 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:15291: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:15308: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>out/conftest.err)
    ac_status=$?
    cat out/conftest.err >&5
-   echo "$as_me:15295: \$? = $ac_status" >&5
+   echo "$as_me:15312: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s out/conftest2.$ac_objext
    then
      # The compiler can only warn and ignore the option if not recognized
@@ -20590,7 +20607,7 @@ fi
 
 
 
-ac_config_files="$ac_config_files Makefile config.xml auxdir/Makefile contribs/Makefile contribs/pam/Makefile contribs/perlapi/Makefile contribs/perlapi/libslurm/Makefile contribs/perlapi/libslurm/perl/Makefile.PL contribs/perlapi/libslurmdb/Makefile contribs/perlapi/libslurmdb/perl/Makefile.PL contribs/torque/Makefile contribs/phpext/Makefile contribs/phpext/slurm_php/config.m4 contribs/sjobexit/Makefile contribs/slurmdb-direct/Makefile src/Makefile src/api/Makefile src/common/Makefile src/db_api/Makefile src/database/Makefile src/sacct/Makefile src/sacctmgr/Makefile src/sreport/Makefile src/sstat/Makefile src/sshare/Makefile src/salloc/Makefile src/sbatch/Makefile src/sattach/Makefile src/sprio/Makefile src/srun/Makefile src/srun_cr/Makefile src/slurmd/Makefile src/slurmd/slurmd/Makefile src/slurmd/slurmstepd/Makefile src/slurmdbd/Makefile src/slurmctld/Makefile src/sbcast/Makefile src/scontrol/Makefile src/scancel/Makefile src/squeue/Makefile src/sinfo/Makefile src/smap/Makefile src/strigger/Makefile src/sview/Makefile src/plugins/Makefile src/plugins/accounting_storage/Makefile src/plugins/accounting_storage/common/Makefile src/plugins/accounting_storage/filetxt/Makefile src/plugins/accounting_storage/mysql/Makefile src/plugins/accounting_storage/pgsql/Makefile src/plugins/accounting_storage/none/Makefile src/plugins/accounting_storage/slurmdbd/Makefile src/plugins/auth/Makefile src/plugins/auth/authd/Makefile src/plugins/auth/munge/Makefile src/plugins/auth/none/Makefile src/plugins/checkpoint/Makefile src/plugins/checkpoint/aix/Makefile src/plugins/checkpoint/none/Makefile src/plugins/checkpoint/ompi/Makefile src/plugins/checkpoint/xlch/Makefile src/plugins/checkpoint/blcr/Makefile src/plugins/checkpoint/blcr/cr_checkpoint.sh src/plugins/checkpoint/blcr/cr_restart.sh src/plugins/crypto/Makefile src/plugins/crypto/munge/Makefile src/plugins/crypto/openssl/Makefile src/plugins/gres/Makefile src/plugins/gres/gpu/Makefile src/plugins/gres/nic/Makefile src/plugins/jobacct_gather/Makefile src/plugins/jobacct_gather/linux/Makefile src/plugins/jobacct_gather/aix/Makefile src/plugins/jobacct_gather/none/Makefile src/plugins/jobcomp/Makefile src/plugins/jobcomp/filetxt/Makefile src/plugins/jobcomp/none/Makefile src/plugins/jobcomp/script/Makefile src/plugins/jobcomp/mysql/Makefile src/plugins/jobcomp/pgsql/Makefile src/plugins/job_submit/Makefile src/plugins/job_submit/defaults/Makefile src/plugins/job_submit/logging/Makefile src/plugins/job_submit/lua/Makefile src/plugins/job_submit/partition/Makefile src/plugins/preempt/Makefile src/plugins/preempt/none/Makefile src/plugins/preempt/partition_prio/Makefile src/plugins/preempt/qos/Makefile src/plugins/priority/Makefile src/plugins/priority/basic/Makefile src/plugins/priority/multifactor/Makefile src/plugins/proctrack/Makefile src/plugins/proctrack/aix/Makefile src/plugins/proctrack/pgid/Makefile src/plugins/proctrack/linuxproc/Makefile src/plugins/proctrack/rms/Makefile src/plugins/proctrack/sgi_job/Makefile src/plugins/proctrack/cgroup/Makefile src/plugins/proctrack/lua/Makefile src/plugins/sched/Makefile src/plugins/sched/backfill/Makefile src/plugins/sched/builtin/Makefile src/plugins/sched/hold/Makefile src/plugins/sched/wiki/Makefile src/plugins/sched/wiki2/Makefile src/plugins/select/Makefile src/plugins/select/bgq/Makefile src/plugins/select/bluegene/Makefile src/plugins/select/bluegene/block_allocator/Makefile src/plugins/select/bluegene/plugin/Makefile src/plugins/select/cons_res/Makefile src/plugins/select/cray/Makefile src/plugins/select/linear/Makefile src/plugins/switch/Makefile src/plugins/switch/elan/Makefile src/plugins/switch/none/Makefile src/plugins/switch/federation/Makefile src/plugins/mpi/Makefile src/plugins/mpi/mpich1_p4/Makefile src/plugins/mpi/mpich1_shmem/Makefile src/plugins/mpi/mpichgm/Makefile src/plugins/mpi/mpichmx/Makefile src/plugins/mpi/mvapich/Makefile src/plugins/mpi/lam/Makefile src/plugins/mpi/none/Makefile src/plugins/mpi/openmpi/Makefile src/plugins/task/Makefile src/plugins/task/affinity/Makefile src/plugins/task/none/Makefile src/plugins/topology/Makefile src/plugins/topology/3d_torus/Makefile src/plugins/topology/node_rank/Makefile src/plugins/topology/none/Makefile src/plugins/topology/tree/Makefile doc/Makefile doc/man/Makefile doc/html/Makefile doc/html/configurator.html testsuite/Makefile testsuite/expect/Makefile testsuite/slurm_unit/Makefile testsuite/slurm_unit/api/Makefile testsuite/slurm_unit/api/manual/Makefile testsuite/slurm_unit/common/Makefile"
+ac_config_files="$ac_config_files Makefile config.xml auxdir/Makefile contribs/Makefile contribs/pam/Makefile contribs/perlapi/Makefile contribs/perlapi/libslurm/Makefile contribs/perlapi/libslurm/perl/Makefile.PL contribs/perlapi/libslurmdb/Makefile contribs/perlapi/libslurmdb/perl/Makefile.PL contribs/torque/Makefile contribs/phpext/Makefile contribs/phpext/slurm_php/config.m4 contribs/sjobexit/Makefile contribs/slurmdb-direct/Makefile src/Makefile src/api/Makefile src/common/Makefile src/db_api/Makefile src/database/Makefile src/sacct/Makefile src/sacctmgr/Makefile src/sreport/Makefile src/sstat/Makefile src/sshare/Makefile src/salloc/Makefile src/sbatch/Makefile src/sattach/Makefile src/sprio/Makefile src/srun/Makefile src/srun_cr/Makefile src/slurmd/Makefile src/slurmd/common/Makefile src/slurmd/slurmd/Makefile src/slurmd/slurmstepd/Makefile src/slurmdbd/Makefile src/slurmctld/Makefile src/sbcast/Makefile src/scontrol/Makefile src/scancel/Makefile src/squeue/Makefile src/sinfo/Makefile src/smap/Makefile src/strigger/Makefile src/sview/Makefile src/plugins/Makefile src/plugins/accounting_storage/Makefile src/plugins/accounting_storage/common/Makefile src/plugins/accounting_storage/filetxt/Makefile src/plugins/accounting_storage/mysql/Makefile src/plugins/accounting_storage/pgsql/Makefile src/plugins/accounting_storage/none/Makefile src/plugins/accounting_storage/slurmdbd/Makefile src/plugins/auth/Makefile src/plugins/auth/authd/Makefile src/plugins/auth/munge/Makefile src/plugins/auth/none/Makefile src/plugins/checkpoint/Makefile src/plugins/checkpoint/aix/Makefile src/plugins/checkpoint/none/Makefile src/plugins/checkpoint/ompi/Makefile src/plugins/checkpoint/xlch/Makefile src/plugins/checkpoint/blcr/Makefile src/plugins/checkpoint/blcr/cr_checkpoint.sh src/plugins/checkpoint/blcr/cr_restart.sh src/plugins/crypto/Makefile src/plugins/crypto/munge/Makefile src/plugins/crypto/openssl/Makefile src/plugins/gres/Makefile src/plugins/gres/gpu/Makefile src/plugins/gres/nic/Makefile src/plugins/jobacct_gather/Makefile src/plugins/jobacct_gather/linux/Makefile src/plugins/jobacct_gather/aix/Makefile src/plugins/jobacct_gather/none/Makefile src/plugins/jobcomp/Makefile src/plugins/jobcomp/filetxt/Makefile src/plugins/jobcomp/none/Makefile src/plugins/jobcomp/script/Makefile src/plugins/jobcomp/mysql/Makefile src/plugins/jobcomp/pgsql/Makefile src/plugins/job_submit/Makefile src/plugins/job_submit/defaults/Makefile src/plugins/job_submit/logging/Makefile src/plugins/job_submit/lua/Makefile src/plugins/job_submit/partition/Makefile src/plugins/preempt/Makefile src/plugins/preempt/none/Makefile src/plugins/preempt/partition_prio/Makefile src/plugins/preempt/qos/Makefile src/plugins/priority/Makefile src/plugins/priority/basic/Makefile src/plugins/priority/multifactor/Makefile src/plugins/proctrack/Makefile src/plugins/proctrack/aix/Makefile src/plugins/proctrack/pgid/Makefile src/plugins/proctrack/linuxproc/Makefile src/plugins/proctrack/rms/Makefile src/plugins/proctrack/sgi_job/Makefile src/plugins/proctrack/cgroup/Makefile src/plugins/proctrack/lua/Makefile src/plugins/sched/Makefile src/plugins/sched/backfill/Makefile src/plugins/sched/builtin/Makefile src/plugins/sched/hold/Makefile src/plugins/sched/wiki/Makefile src/plugins/sched/wiki2/Makefile src/plugins/select/Makefile src/plugins/select/bgq/Makefile src/plugins/select/bluegene/Makefile src/plugins/select/bluegene/block_allocator/Makefile src/plugins/select/bluegene/plugin/Makefile src/plugins/select/cons_res/Makefile src/plugins/select/cray/Makefile src/plugins/select/linear/Makefile src/plugins/switch/Makefile src/plugins/switch/elan/Makefile src/plugins/switch/none/Makefile src/plugins/switch/federation/Makefile src/plugins/mpi/Makefile src/plugins/mpi/mpich1_p4/Makefile src/plugins/mpi/mpich1_shmem/Makefile src/plugins/mpi/mpichgm/Makefile src/plugins/mpi/mpichmx/Makefile src/plugins/mpi/mvapich/Makefile src/plugins/mpi/lam/Makefile src/plugins/mpi/none/Makefile src/plugins/mpi/openmpi/Makefile src/plugins/task/Makefile src/plugins/task/affinity/Makefile src/plugins/task/none/Makefile src/plugins/topology/Makefile src/plugins/topology/3d_torus/Makefile src/plugins/topology/node_rank/Makefile src/plugins/topology/none/Makefile src/plugins/topology/tree/Makefile doc/Makefile doc/man/Makefile doc/html/Makefile doc/html/configurator.html testsuite/Makefile testsuite/expect/Makefile testsuite/slurm_unit/Makefile testsuite/slurm_unit/api/Makefile testsuite/slurm_unit/api/manual/Makefile testsuite/slurm_unit/common/Makefile"
 
 
 cat >confcache <<\_ACEOF
@@ -20727,6 +20744,10 @@ if test -z "${HAVE_AIX_PROCTRACK_TRUE}" && test -z "${HAVE_AIX_PROCTRACK_FALSE}"
   as_fn_error $? "conditional \"HAVE_AIX_PROCTRACK\" was never defined.
 Usually this means the macro was only invoked conditionally." "$LINENO" 5
 fi
+if test -z "${WITH_CYGWIN_TRUE}" && test -z "${WITH_CYGWIN_FALSE}"; then
+  as_fn_error $? "conditional \"WITH_CYGWIN\" was never defined.
+Usually this means the macro was only invoked conditionally." "$LINENO" 5
+fi
 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
   as_fn_error $? "conditional \"am__fastdepCC\" was never defined.
 Usually this means the macro was only invoked conditionally." "$LINENO" 5
@@ -21802,6 +21823,7 @@ do
     "src/srun/Makefile") CONFIG_FILES="$CONFIG_FILES src/srun/Makefile" ;;
     "src/srun_cr/Makefile") CONFIG_FILES="$CONFIG_FILES src/srun_cr/Makefile" ;;
     "src/slurmd/Makefile") CONFIG_FILES="$CONFIG_FILES src/slurmd/Makefile" ;;
+    "src/slurmd/common/Makefile") CONFIG_FILES="$CONFIG_FILES src/slurmd/common/Makefile" ;;
     "src/slurmd/slurmd/Makefile") CONFIG_FILES="$CONFIG_FILES src/slurmd/slurmd/Makefile" ;;
     "src/slurmd/slurmstepd/Makefile") CONFIG_FILES="$CONFIG_FILES src/slurmd/slurmstepd/Makefile" ;;
     "src/slurmdbd/Makefile") CONFIG_FILES="$CONFIG_FILES src/slurmdbd/Makefile" ;;
diff --git a/configure.ac b/configure.ac
index 619865c75dc893c68d823ac7c2c29a139140e8a1..d7ba1316d7ac03b90893c16a0ee31d5092023560 100644
--- a/configure.ac
+++ b/configure.ac
@@ -54,14 +54,22 @@ case "$host" in
 			[Define slurm_ prefix function aliases for plugins]) ;;
 esac
 
+ac_have_cygwin=no
 dnl
-dnl add some flags for Solaris
+dnl add some flags for Solaris and cygwin
 dnl
 case "$host" in
+     	*cygwin)   LDFLAGS="$LDFLAGS -no-undefined"
+		   SO_LDFLAGS="$SO_LDFLAGS \$(top_builddir)/src/api/libslurmhelper.la"
+		   AC_SUBST(SO_LDFLAGS)
+		   ac_have_cygwin=yes
+		   ;;
 	*solaris*) CC="/usr/sfw/bin/gcc"
 		   CFLAGS="$CFLAGS -D_POSIX_PTHREAD_SEMANTICS -I/usr/sfw/include"
 		   LDFLAGS="$LDFLAGS -L/usr/sfw/lib"
+		   ;;
 esac
+AM_CONDITIONAL(WITH_CYGWIN, test x"$ac_have_cygwin" == x"yes")
 
 dnl Checks for programs.
 dnl
@@ -370,6 +378,7 @@ AC_CONFIG_FILES([Makefile
 		 src/srun/Makefile
 		 src/srun_cr/Makefile
 		 src/slurmd/Makefile
+		 src/slurmd/common/Makefile
 		 src/slurmd/slurmd/Makefile
 		 src/slurmd/slurmstepd/Makefile
 		 src/slurmdbd/Makefile
diff --git a/doc/html/proctrack_plugins.shtml b/doc/html/proctrack_plugins.shtml
index a3c4a17e693b84a9029be4711f77cd82404a2d0b..23439fa47d21f857338fae09dada0ccd1d468ed9 100644
--- a/doc/html/proctrack_plugins.shtml
+++ b/doc/html/proctrack_plugins.shtml
@@ -70,10 +70,10 @@ Successful API calls are not required to reset errno to a known value.</p>
 <p>The following functions must appear. Functions which are not implemented should
 be stubbed.</p>
 
-<p class="commandline">int slurm_container_create (slurmd_job_t *job);</p>
+<p class="commandline">int slurm_container_plugin_create (slurmd_job_t *job);</p>
 <p style="margin-left:.2in"><b>Description</b>: Create a container.
 The container should be valid
-<span class="commandline">slurm_container_destroy()</span> is called.
+<span class="commandline">slurm_container_plugin_destroy()</span> is called.
 This function must put the container ID directory in the job structure's
 variable <i>cont_id</i>.</p>
 <p style="margin-left:.2in"><b>Argument</b>:
@@ -83,7 +83,7 @@ Pointer to a slurmd job structure.</p>
 the plugin should return SLURM_ERROR and set the errno to an appropriate value
 to indicate the reason for failure.</p>
 
-<p class="commandline">int slurm_container_add (slurmd_job_t *job, pid_t pid);</p>
+<p class="commandline">int slurm_container_plugin_add (slurmd_job_t *job, pid_t pid);</p>
 <p style="margin-left:.2in"><b>Description</b>: Add a specific process ID
 to a given job's container.</p>
 <p style="margin-left:.2in"><b>Arguments</b>:<br>
@@ -95,7 +95,7 @@ The ID of the process to add to this job's container.</p>
 the plugin should return SLURM_ERROR and set the errno to an appropriate value
 to indicate the reason for failure.</p>
 
-<p class="commandline">int slurm_container_signal (uint32_t id, int signal);</p>
+<p class="commandline">int slurm_container_plugin_signal (uint32_t id, int signal);</p>
 <p style="margin-left:.2in"><b>Description</b>: Signal all processes in a given
 job's container.</p>
 <p style="margin-left:.2in"><b>Arguments</b>:<br>
@@ -111,7 +111,7 @@ its errno to an appropriate value to indicate the reason for failure.</p>
 
 <p class="footer"><a href="#top">top</a></p>
 
-<p class="commandline">int slurm_container_destroy (uint32_t id);</p>
+<p class="commandline">int slurm_container_plugin_destroy (uint32_t id);</p>
 <p style="margin-left:.2in"><b>Description</b>: Destroy or  otherwise
 invalidate a job container.
 This does not imply the container is empty, just that it is no longer
@@ -123,7 +123,7 @@ Job container's ID.</p>
 the plugin should return SLURM_ERROR and set the errno to an appropriate value
 to indicate the reason for failure.</p>
 
-<p class="commandline">uint32_t slurm_container_find (pid_t pid);</p>
+<p class="commandline">uint32_t slurm_container_plugin_find (pid_t pid);</p>
 <p style="margin-left:.2in"><b>Description</b>:
 Given a process ID, return its job container ID.</p>
 <p style="margin-left:.2in"><b>Arguments</b>:
@@ -132,6 +132,19 @@ A process ID.</p>
 <p style="margin-left:.2in"><b>Returns</b>: The job container ID
 with this process or zero if none is found.</p>
 
+<p class="commandline">uint32_t slurm_container_plugin_get_pids (uint32_t cont_id, pid_t **pids, int *npids);</p>
+<p style="margin-left:.2in"><b>Description</b>:
+Given a process container ID, fill in all the process IDs in the container.</p>
+<p style="margin-left:.2in"><b>Arguments</b>:
+<span class="commandline"> cont_id</span>&nbsp; &nbsp;&nbsp;(input)
+A container ID.</p>
+<span class="commandline"> pids</span>&nbsp; &nbsp;&nbsp;(output)
+Array of process IDs in the container.</p>
+<span class="commandline"> npids</span>&nbsp; &nbsp;&nbsp;(output)
+Count of process IDs in the container.</p>
+<p style="margin-left:.2in"><b>Returns</b>: SLURM_SUCCESS if
+  successful, SLURM_ERROR else.</p>
+
 <h2>Versioning</h2>
 <p> This document describes version 0 of the SLURM Process Tracking API.
 Future releases of SLURM may revise this API. A process tracking plugin
@@ -140,6 +153,6 @@ mechanism outlined for SLURM plugins.</p>
 
 <p class="footer"><a href="#top">top</a></p>
 
-<p style="text-align:center;">Last modified 6 June 2006</p>
+<p style="text-align:center;">Last modified 22 Dec 2010</p>
 
 <!--#include virtual="footer.txt"-->
diff --git a/src/api/Makefile.am b/src/api/Makefile.am
index 12eac1e6fd60e0ccb0e003b526680f2834312bf6..926d29bdbfd8be8d1443ddef29cee52bf100ed0f 100644
--- a/src/api/Makefile.am
+++ b/src/api/Makefile.am
@@ -75,6 +75,8 @@ BUILT_SOURCES = $(VERSION_SCRIPT) $(PMI_VERSION_SCRIPT) libslurm.la
 # Also, libslurmhelper, libslurm.o are for convenience, they are not installed.
 noinst_LTLIBRARIES = libslurmhelper.la
 noinst_PROGRAMS = libslurm.o
+# This is needed if compiling on windows
+EXEEXT=
 
 slurmapi_src =           \
 	allocate.c       \
diff --git a/src/api/Makefile.in b/src/api/Makefile.in
index 13431030515bf1c8acec3d7db164579ed52a8f1e..eb4467e9dee4393d4c8dfa7c7777c5002b5d6311 100644
--- a/src/api/Makefile.in
+++ b/src/api/Makefile.in
@@ -193,7 +193,8 @@ ECHO_N = @ECHO_N@
 ECHO_T = @ECHO_T@
 EGREP = @EGREP@
 ELAN_LIBS = @ELAN_LIBS@
-EXEEXT = @EXEEXT@
+# This is needed if compiling on windows
+EXEEXT = 
 FEDERATION_LDFLAGS = @FEDERATION_LDFLAGS@
 FGREP = @FGREP@
 GREP = @GREP@
diff --git a/src/api/job_info.c b/src/api/job_info.c
index 73fcb69f772471a606159dbe940fe4a201d32d86..090ed75291c26c1ec4ed77e1ff4ec0a3ef2f4bae 100644
--- a/src/api/job_info.c
+++ b/src/api/job_info.c
@@ -209,7 +209,7 @@ slurm_sprint_job_info ( job_info_t * job_ptr, int one_liner )
 	if (job_ptr->state_desc) {
 		/* Replace white space with underscore for easier parsing */
 		for (j=0; job_ptr->state_desc[j]; j++) {
-			if (isspace(job_ptr->state_desc[j]))
+			if (isspace((int)job_ptr->state_desc[j]))
 				job_ptr->state_desc[j] = '_';
 		}
 		tmp6_ptr = job_ptr->state_desc;
diff --git a/src/common/Makefile.am b/src/common/Makefile.am
index 7225858e58e178da3297d0b05f4aafd1aa8b9c87..f8e67238809117d6f06bd0d79263c6124f27081d 100644
--- a/src/common/Makefile.am
+++ b/src/common/Makefile.am
@@ -22,6 +22,8 @@ endif
 INCLUDES     = -I$(top_srcdir) $(BG_INCLUDES)
 
 noinst_PROGRAMS = libcommon.o libeio.o libspank.o
+# This is needed if compiling on windows
+EXEEXT=
 
 noinst_LTLIBRARIES = 			\
 	libcommon.la 			\
@@ -40,7 +42,6 @@ libcommon_la_SOURCES = 			\
 	strlcpy.c strlcpy.h		\
 	list.c list.h 			\
 	net.c net.h                     \
-	fd.c fd.h			\
 	log.c log.h			\
 	cbuf.c cbuf.h			\
 	safeopen.c safeopen.h		\
@@ -55,6 +56,7 @@ libcommon_la_SOURCES = 			\
 	read_config.c read_config.h	\
 	node_select.c node_select.h	\
 	env.c env.h      		\
+	fd.c fd.h       		\
 	slurm_cred.h       		\
 	slurm_cred.c			\
 	slurm_errno.c			\
@@ -117,8 +119,7 @@ EXTRA_libcommon_la_SOURCES = 	\
 
 libdaemonize_la_SOURCES =  		\
 	daemonize.c       	 	\
-	daemonize.h        		\
-	fd.c fd.h
+	daemonize.h
 
 libeio_la_SOURCES = 	   		\
 	eio.c eio.h	   		\
diff --git a/src/common/Makefile.in b/src/common/Makefile.in
index 79f4eec0c8bfc9a467cd6c1357b9d9ba9bf64257..6b494787f596a69c07cda8b9e45e1c72c5b5e338 100644
--- a/src/common/Makefile.in
+++ b/src/common/Makefile.in
@@ -98,12 +98,12 @@ am__libcommon_la_SOURCES_DIST = assoc_mgr.c assoc_mgr.h \
 	basil_resv_conf.c basil_resv_conf.h xmalloc.c xmalloc.h \
 	xassert.c xassert.h xstring.c xstring.h xsignal.c xsignal.h \
 	forward.c forward.h strlcpy.c strlcpy.h list.c list.h net.c \
-	net.h fd.c fd.h log.c log.h cbuf.c cbuf.h safeopen.c \
-	safeopen.h bitstring.c bitstring.h mpi.c mpi.h pack.c pack.h \
+	net.h log.c log.h cbuf.c cbuf.h safeopen.c safeopen.h \
+	bitstring.c bitstring.h mpi.c mpi.h pack.c pack.h \
 	parse_config.c parse_config.h parse_spec.c parse_spec.h \
 	plugin.c plugin.h plugrack.c plugrack.h print_fields.c \
 	print_fields.h read_config.c read_config.h node_select.c \
-	node_select.h env.c env.h slurm_cred.h slurm_cred.c \
+	node_select.h env.c env.h fd.c fd.h slurm_cred.h slurm_cred.c \
 	slurm_errno.c slurm_priority.c slurm_priority.h \
 	slurm_protocol_api.c slurm_protocol_api.h \
 	slurm_protocol_pack.c slurm_protocol_pack.h \
@@ -133,9 +133,9 @@ am__libcommon_la_SOURCES_DIST = assoc_mgr.c assoc_mgr.h \
 @HAVE_UNSETENV_FALSE@am__objects_1 = unsetenv.lo
 am_libcommon_la_OBJECTS = assoc_mgr.lo basil_resv_conf.lo xmalloc.lo \
 	xassert.lo xstring.lo xsignal.lo forward.lo strlcpy.lo list.lo \
-	net.lo fd.lo log.lo cbuf.lo safeopen.lo bitstring.lo mpi.lo \
-	pack.lo parse_config.lo parse_spec.lo plugin.lo plugrack.lo \
-	print_fields.lo read_config.lo node_select.lo env.lo \
+	net.lo log.lo cbuf.lo safeopen.lo bitstring.lo mpi.lo pack.lo \
+	parse_config.lo parse_spec.lo plugin.lo plugrack.lo \
+	print_fields.lo read_config.lo node_select.lo env.lo fd.lo \
 	slurm_cred.lo slurm_errno.lo slurm_priority.lo \
 	slurm_protocol_api.lo slurm_protocol_pack.lo \
 	slurm_protocol_util.lo slurm_protocol_socket_implementation.lo \
@@ -156,7 +156,7 @@ libcommon_la_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) \
 	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
 	$(libcommon_la_LDFLAGS) $(LDFLAGS) -o $@
 libdaemonize_la_LIBADD =
-am_libdaemonize_la_OBJECTS = daemonize.lo fd.lo
+am_libdaemonize_la_OBJECTS = daemonize.lo
 libdaemonize_la_OBJECTS = $(am_libdaemonize_la_OBJECTS)
 libeio_la_LIBADD =
 am_libeio_la_OBJECTS = eio.lo io_hdr.lo
@@ -235,7 +235,8 @@ ECHO_N = @ECHO_N@
 ECHO_T = @ECHO_T@
 EGREP = @EGREP@
 ELAN_LIBS = @ELAN_LIBS@
-EXEEXT = @EXEEXT@
+# This is needed if compiling on windows
+EXEEXT = 
 FEDERATION_LDFLAGS = @FEDERATION_LDFLAGS@
 FGREP = @FGREP@
 GREP = @GREP@
@@ -413,7 +414,6 @@ libcommon_la_SOURCES = \
 	strlcpy.c strlcpy.h		\
 	list.c list.h 			\
 	net.c net.h                     \
-	fd.c fd.h			\
 	log.c log.h			\
 	cbuf.c cbuf.h			\
 	safeopen.c safeopen.h		\
@@ -428,6 +428,7 @@ libcommon_la_SOURCES = \
 	read_config.c read_config.h	\
 	node_select.c node_select.h	\
 	env.c env.h      		\
+	fd.c fd.h       		\
 	slurm_cred.h       		\
 	slurm_cred.c			\
 	slurm_errno.c			\
@@ -490,8 +491,7 @@ EXTRA_libcommon_la_SOURCES = \
 
 libdaemonize_la_SOURCES = \
 	daemonize.c       	 	\
-	daemonize.h        		\
-	fd.c fd.h
+	daemonize.h
 
 libeio_la_SOURCES = \
 	eio.c eio.h	   		\
diff --git a/src/common/bitstring.c b/src/common/bitstring.c
index 6363ddf9db1842b998dcd6bf605e762db95977b0..8fed9d4cd299bb0175617ba58ab009879fcd62db 100644
--- a/src/common/bitstring.c
+++ b/src/common/bitstring.c
@@ -1117,7 +1117,7 @@ int bit_unfmt_hexmask(bitstr_t * bitmap, const char* str)
 	int bit_index = 0, len = strlen(str);
 	int rc = 0;
 	const char *curpos = str + len - 1;
-	char current;
+	int current;
 	bitoff_t bitsize = bit_size(bitmap);
 
 	bit_nclear(bitmap, 0, bitsize - 1);
diff --git a/src/common/hostlist.c b/src/common/hostlist.c
index c624db7ee3f63f521ac9b6a1b3ef6405380c9803..cf2e74f79963b255132a7280ec524ac0b159aa47 100644
--- a/src/common/hostlist.c
+++ b/src/common/hostlist.c
@@ -618,7 +618,7 @@ static int host_prefix_end(const char *hostname)
 			return -1;
 		idx = len - 1;
 
-		while (idx >= 0 && isdigit((char) hostname[idx]))
+		while (idx >= 0 && isdigit((int)hostname[idx]))
 			idx--;
 	}
 
diff --git a/src/common/node_conf.c b/src/common/node_conf.c
index 4aff65daad0bd03d632b0eec5f5f629de6779060..9a485c5fb727b61841ae2536834144a69ea95772 100644
--- a/src/common/node_conf.c
+++ b/src/common/node_conf.c
@@ -543,7 +543,7 @@ extern void  build_config_feature_list(struct config_record *config_ptr)
 		tmp_str = xmalloc(i);
 		/* Remove white space from feature specification */
 		for (i=0, j=0; config_ptr->feature[i]; i++) {
-			if (!isspace(config_ptr->feature[i]))
+			if (!isspace((int)config_ptr->feature[i]))
 				tmp_str[j++] = config_ptr->feature[i];
 		}
 		if (i != j)
diff --git a/src/common/node_select.c b/src/common/node_select.c
index 13e2f8d769d73b0171a5fcdd25e72fb5f948fd49..bc2de083a0d1e2d2862f7eaf8ea97b2304ee0405 100644
--- a/src/common/node_select.c
+++ b/src/common/node_select.c
@@ -286,11 +286,21 @@ extern int slurm_select_init(bool only_default)
 			if (strncmp(e->d_name, "select_", 7))
 				continue;
 
-			len = strlen(e->d_name)-3;
+			len = strlen(e->d_name);
+#if defined(__CYGWIN__)
+			len -= 4;
+#else
+			len -= 3;
+#endif
 			/* Check only shared object files */
-			if (strcmp(e->d_name+len, ".so"))
+			if (strcmp(e->d_name+len,
+#if defined(__CYGWIN__)
+				   ".dll"
+#else
+				   ".so"
+#endif
+				    ))
 				continue;
-
 			/* add one for the / */
 			len++;
 			xassert(len<sizeof(full_name));
diff --git a/src/common/parse_config.c b/src/common/parse_config.c
index 51b026cc56ca4fb08cb6066ae800a637a25000da..b6cf948e66877657a246dbd5f519ea089885b318 100644
--- a/src/common/parse_config.c
+++ b/src/common/parse_config.c
@@ -99,7 +99,7 @@ static int _conf_hashtbl_index(const char *key)
 	for (i = 0; i < 10; i++) {
 		if (key[i] == '\0')
 			break;
-		idx += tolower(key[i]);
+		idx += tolower((int)key[i]);
 	}
 	return idx % CONF_HASH_LEN;
 }
@@ -266,7 +266,7 @@ static int _strip_continuation(char *buf, int len)
 	for (ptr = buf+len-1; ptr >= buf; ptr--) {
 		if (*ptr == '\\')
 			bs++;
-		else if (isspace(*ptr) && bs == 0)
+		else if (isspace((int)*ptr) && bs == 0)
 			continue;
 		else
 			break;
@@ -725,7 +725,7 @@ static int _line_is_space(const char *line)
 	}
 	len = strlen(line);
 	for (i = 0; i < len; i++) {
-		if (!isspace(line[i]))
+		if (!isspace((int)line[i]))
 			return 0;
 	}
 
@@ -812,12 +812,12 @@ static int _parse_include_directive(s_p_hashtbl_t *hashtbl, uint32_t *hash_val,
 	*leftover = NULL;
 	if (strncasecmp("include", line, strlen("include")) == 0) {
 		ptr = (char *)line + strlen("include");
-		if (!isspace(*ptr))
+		if (!isspace((int)*ptr))
 			return 0;
-		while (isspace(*ptr))
+		while (isspace((int)*ptr))
 			ptr++;
 		fn_start = ptr;
-		while (!isspace(*ptr))
+		while (!isspace((int)*ptr))
 			ptr++;
 		fn_stop = *leftover = ptr;
 		filename = xstrndup(fn_start, fn_stop-fn_start);
diff --git a/src/common/parse_time.c b/src/common/parse_time.c
index 5fecb9a42a43fd19d047bfd880f2b17dda17863c..9bbdd7f3831d776327c0a2c47eb8fb910dcaff50 100644
--- a/src/common/parse_time.c
+++ b/src/common/parse_time.c
@@ -92,7 +92,7 @@ static int _get_delta(char *time_str, int *pos, long *delta)
 	for (offset = (*pos) + 1;
 	     ((time_str[offset] != '\0') && (time_str[offset] != '\n'));
 	     offset++) {
-		if (isspace(time_str[offset]))
+		if (isspace((int)time_str[offset]))
 			continue;
 		for (i=0; un[i].name; i++) {
 			if (!strncasecmp((time_str + offset),
@@ -180,7 +180,7 @@ _get_time(char *time_str, int *pos, int *hour, int *minute, int * second)
 	} else
 		sec = 0;
 
-	while (isspace(time_str[offset])) {
+	while (isspace((int)time_str[offset])) {
 		offset++;
 	}
 	if (strncasecmp(time_str+offset, "pm", 2)== 0) {
@@ -357,7 +357,7 @@ extern time_t parse_time(char *time_str, int past)
 
 	for (pos=0; ((time_str[pos] != '\0') && (time_str[pos] != '\n'));
 	     pos++) {
-		if (isblank(time_str[pos]) ||
+		if (isblank((int)time_str[pos]) ||
 		    (time_str[pos] == '-') || (time_str[pos] == 'T'))
 			continue;
 		if (strncasecmp(time_str+pos, "today", 5) == 0) {
@@ -409,7 +409,7 @@ extern time_t parse_time(char *time_str, int past)
 						goto prob;
 					break;
 				}
-				if (isblank(time_str[i]))
+				if (isblank((int)time_str[i]))
 					continue;
 				if ((time_str[i] == '\0')
 				    || (time_str[i] == '\n')) {
diff --git a/src/common/plugin.c b/src/common/plugin.c
index c71469a7b077cb9e71d9ffab8c50f86597ccd2cc..3677337f75e5ab626f392015ad4de83e76ea1bdb 100644
--- a/src/common/plugin.c
+++ b/src/common/plugin.c
@@ -217,9 +217,11 @@ plugin_load_and_link(const char *type_name, int n_syms,
 
 	if (!type_name)
 		return plug;
-
+#if defined(__CYGWIN__)
+	so_name = xstrdup_printf("%s.dll", type_name);
+#else
 	so_name = xstrdup_printf("%s.so", type_name);
-
+#endif
 	while(so_name[i]) {
 		if(so_name[i] == '/')
 			so_name[i] = '_';
diff --git a/src/common/plugstack.c b/src/common/plugstack.c
index 98e66f232e04ea5aa59be7bc53bf4a8c70c6e0ed..e7717bcf9106c9e8925708b65c7c54046af8149f 100644
--- a/src/common/plugstack.c
+++ b/src/common/plugstack.c
@@ -1036,7 +1036,7 @@ _find_word_boundary(char *str, char *from, char **next)
 	 * Back up past any non-whitespace if we are pointing in
 	 *  the middle of a word.
 	 */
-	while ((p != str) && !isspace (*p))
+	while ((p != str) && !isspace ((int)*p))
 		--p;
 
 	/*
@@ -1047,7 +1047,7 @@ _find_word_boundary(char *str, char *from, char **next)
 	/*
 	 * Now move back to the end of the previous word
 	 */
-	while ((p != str) && isspace (*p))
+	while ((p != str) && isspace ((int)*p))
 		--p;
 
 	if (p == str) {
@@ -1182,7 +1182,7 @@ int spank_print_options(FILE * fp, int left_pad, int width)
 
 static char _canonical_char (char c)
 {
-	if (!isalnum (c))
+	if (!isalnum ((int)c))
 		return '_';
 	else
 		return c;
diff --git a/src/common/proc_args.c b/src/common/proc_args.c
index e48d430511eb4189587bbeccda187ef31e959c92..7901c784e7d9d16f2db544485523aa7b7ca5ec61 100644
--- a/src/common/proc_args.c
+++ b/src/common/proc_args.c
@@ -141,7 +141,7 @@ task_dist_states_t verify_dist_type(const char *arg, uint32_t *plane_size)
 		} else if (strncasecmp(arg, "block", len) == 0) {
 			result = SLURM_DIST_BLOCK;
 		} else if ((strncasecmp(arg, "arbitrary", len) == 0) ||
-		           (strncasecmp(arg, "hostfile", len) == 0)) {
+			   (strncasecmp(arg, "hostfile", len) == 0)) {
 			result = SLURM_DIST_ARBITRARY;
 		}
 	}
@@ -378,7 +378,7 @@ bool verify_node_list(char **node_list_pptr, enum task_dist_states dist,
 	   saying, lay it out this way! */
 	if(dist == SLURM_DIST_ARBITRARY)
 		nodelist = slurm_read_hostfile(*node_list_pptr, task_count);
-        else
+	else
 		nodelist = slurm_read_hostfile(*node_list_pptr, NO_VAL);
 
 	if (!nodelist)
@@ -417,7 +417,7 @@ bool get_resource_arg_range(const char *arg, const char *what, int* min,
 	}
 
 	result = strtol(arg, &p, 10);
-        if (*p == 'k' || *p == 'K') {
+	if (*p == 'k' || *p == 'K') {
 		result *= 1024;
 		p++;
 	} else if(*p == 'm' || *p == 'M') {
@@ -445,7 +445,7 @@ bool get_resource_arg_range(const char *arg, const char *what, int* min,
 		p++;
 
 	result = strtol(p, &p, 10);
-        if ((*p == 'k') || (*p == 'K')) {
+	if ((*p == 'k') || (*p == 'K')) {
 		result *= 1024;
 		p++;
 	} else if(*p == 'm' || *p == 'M') {
@@ -514,7 +514,7 @@ bool verify_socket_core_thread_count(const char *arg, int *min_sockets,
 		} else if (j == 2) {
 			*cpu_bind_type |= CPU_BIND_TO_THREADS;
 		}
-        }
+	}
 	buf[j][i] = '\0';
 
 	ret_val = true;
@@ -544,7 +544,7 @@ bool verify_socket_core_thread_count(const char *arg, int *min_sockets,
  * RET true if valid
  */
 bool verify_hint(const char *arg, int *min_sockets, int *min_cores,
-		 int *min_threads, int *ntasks_per_core, 
+		 int *min_threads, int *ntasks_per_core,
 		 cpu_bind_type_t *cpu_bind_type)
 {
 	char *buf, *p, *tok;
@@ -557,7 +557,7 @@ bool verify_hint(const char *arg, int *min_sockets, int *min_cores,
 	/* change all ',' delimiters not followed by a digit to ';'  */
 	/* simplifies parsing tokens while keeping map/mask together */
 	while (p[0] != '\0') {
-		if ((p[0] == ',') && (!isdigit(p[1])))
+		if ((p[0] == ',') && (!isdigit((int)p[1])))
 			p[0] = ';';
 		p++;
 	}
@@ -574,21 +574,21 @@ bool verify_hint(const char *arg, int *min_sockets, int *min_cores,
 "        help            show this help message\n");
 			return 1;
 		} else if (strcasecmp(tok, "compute_bound") == 0) {
-		        *min_sockets = NO_VAL;
-		        *min_cores   = NO_VAL;
-		        *min_threads = 1;
+			*min_sockets = NO_VAL;
+			*min_cores   = NO_VAL;
+			*min_threads = 1;
 			*cpu_bind_type |= CPU_BIND_TO_CORES;
 		} else if (strcasecmp(tok, "memory_bound") == 0) {
-		        *min_cores   = 1;
-		        *min_threads = 1;
+			*min_cores   = 1;
+			*min_threads = 1;
 			*cpu_bind_type |= CPU_BIND_TO_CORES;
 		} else if (strcasecmp(tok, "multithread") == 0) {
-		        *min_threads = NO_VAL;
+			*min_threads = NO_VAL;
 			*cpu_bind_type |= CPU_BIND_TO_THREADS;
 			if (*ntasks_per_core == NO_VAL)
 				*ntasks_per_core = INFINITE;
 		} else if (strcasecmp(tok, "nomultithread") == 0) {
-		        *min_threads = 1;
+			*min_threads = 1;
 			*cpu_bind_type |= CPU_BIND_TO_THREADS;
 		} else {
 			error("unrecognized --hint argument \"%s\", "
@@ -615,7 +615,7 @@ uint16_t parse_mail_type(const char *arg)
 	else if (strcasecmp(arg, "REQUEUE") == 0)
 		rc = MAIL_JOB_REQUEUE;
 	else if (strcasecmp(arg, "ALL") == 0)
-		rc = MAIL_JOB_BEGIN |  MAIL_JOB_END |  MAIL_JOB_FAIL | 
+		rc = MAIL_JOB_BEGIN |  MAIL_JOB_END |  MAIL_JOB_FAIL |
 		     MAIL_JOB_REQUEUE;
 	else
 		rc = 0;		/* failure */
@@ -690,7 +690,7 @@ search_path(char *cwd, char *cmd, bool check_current_dir, int access_mode)
 	char *path, *fullpath = NULL;
 
 	if (  (cmd[0] == '.' || cmd[0] == '/')
-           && (access(cmd, access_mode) == 0 ) ) {
+	   && (access(cmd, access_mode) == 0 ) ) {
 		if (cmd[0] == '.')
 			xstrfmtcat(fullpath, "%s/", cwd);
 		xstrcat(fullpath, cmd);
@@ -813,7 +813,7 @@ int sig_name2num(char *signal_name)
 			return 0;
 	} else {
 		ptr = (char *)signal_name;
-		while (isspace(*ptr))
+		while (isspace((int)*ptr))
 			ptr++;
 		if (strncasecmp(ptr, "SIG", 3) == 0)
 			ptr += 3;
@@ -823,7 +823,7 @@ int sig_name2num(char *signal_name)
 			if (strncasecmp(ptr, sig_name[i],
 					strlen(sig_name[i])) == 0) {
 				/* found the signal name */
-				if (!xstring_is_whitespace(ptr + 
+				if (!xstring_is_whitespace(ptr +
 							   strlen(sig_name[i])))
 					return 0;
 				sig = sig_num[i];
diff --git a/src/common/read_config.c b/src/common/read_config.c
index f37bb3e461a89fc28d692f1489e0b31b2c869875..dd4a7574dd4bb514bb46b80394d4a81dca3d38a2 100644
--- a/src/common/read_config.c
+++ b/src/common/read_config.c
@@ -731,7 +731,7 @@ static int _parse_partitionname(void **dest, slurm_parser_enum_t type,
 		else {
 			int i;
 			for (i=0; p->nodes[i]; i++) {
-				if (isspace(p->nodes[i]))
+				if (isspace((int)p->nodes[i]))
 					p->nodes[i] = ',';
 			}
 		}
@@ -1879,7 +1879,7 @@ _validate_and_set_defaults(slurm_ctl_conf_t *conf, s_p_hashtbl_t *hashtbl)
 		int i;
 		for (i = 0; conf->cluster_name[i] != '\0'; i++)
 			conf->cluster_name[i] =
-				(char)tolower(conf->cluster_name[i]);
+				(char)tolower((int)conf->cluster_name[i]);
 	}
 
 	if (!s_p_get_uint16(&conf->complete_wait, "CompleteWait", hashtbl))
diff --git a/src/common/slurm_resource_info.c b/src/common/slurm_resource_info.c
index 80dd2caec6782ae510358e382f2b2c0939d4c313..537ca7fdda596372374177804b3608712102eb4e 100644
--- a/src/common/slurm_resource_info.c
+++ b/src/common/slurm_resource_info.c
@@ -72,11 +72,11 @@ static void _clear_then_set(int *data, int clear_mask, int set_mask)
  * returns 1 is the argument appears to be a value, 0 otherwise
  */
 static int _isvalue(char *arg) {
-    	if (isdigit(*arg)) {	 /* decimal values and 0x... hex values */
+    	if (isdigit((int)*arg)) { /* decimal values and 0x... hex values */
 	    	return 1;
 	}
 
-	while (isxdigit(*arg)) { /* hex values not preceded by 0x */
+	while (isxdigit((int)*arg)) { /* hex values not preceded by 0x */
 		arg++;
 	}
 	if (*arg == ',' || *arg == '\0') { /* end of field or string */
diff --git a/src/common/stepd_api.c b/src/common/stepd_api.c
index a0bc4e8644240594f03cc72e6955b1682cf01629..7eea47b2595348e2f4ba64112f4397e1ccf9b725 100644
--- a/src/common/stepd_api.c
+++ b/src/common/stepd_api.c
@@ -108,7 +108,7 @@ _handle_stray_socket(const char *socket_name)
 
 	if ((uid = getuid()) != buf.st_uid) {
 		debug3("_handle_stray_socket: socket %s is not owned by uid %d",
-		       socket_name, uid);
+		       socket_name, (int)uid);
 		return;
 	}
 
diff --git a/src/common/xstring.c b/src/common/xstring.c
index ed937a06d0d6cd46264255643d3f5dec2b43d763..ba53f31ae5574d752337718c61f8810bcd7b2afb 100644
--- a/src/common/xstring.c
+++ b/src/common/xstring.c
@@ -57,6 +57,7 @@
 
 #include <stdarg.h>
 #include <ctype.h>
+#include <time.h>
 
 #include <slurm/slurm_errno.h>
 
@@ -469,7 +470,7 @@ bool xstring_is_whitespace(const char *str)
 
 	len = strlen(str);
 	for (i = 0; i < len; i++) {
-		if (!isspace(str[i])) {
+		if (!isspace((int)str[i])) {
 			return false;
 		}
 	}
@@ -485,7 +486,7 @@ char *xstrtolower(char *str)
 	if(str) {
 		int j = 0;
 		while(str[j]) {
-			str[j] = tolower(str[j]);
+			str[j] = tolower((int)str[j]);
 			j++;
 		}
 	}
diff --git a/src/db_api/Makefile.am b/src/db_api/Makefile.am
index 99b5958f12acf358e956ad9d7df609cfe1352432..4b392b53201c6ccff85d3585fb31c40ed894236f 100644
--- a/src/db_api/Makefile.am
+++ b/src/db_api/Makefile.am
@@ -51,7 +51,8 @@ BUILT_SOURCES = $(VERSION_SCRIPT) libslurmdb.la
 # and libslurmdb in the same program because of extra symbols this is needed.
 # libslurmdb.o are for convenience, and it is not installed.
 noinst_PROGRAMS = libslurmdb.o
-
+# This is needed if compiling on windows
+EXEEXT=
 
 libslurmdb_la_SOURCES =	\
 	account_functions.c \
diff --git a/src/db_api/Makefile.in b/src/db_api/Makefile.in
index 1e5ec642e9147e83472920c02e7ce44f1ce94269..460e05a4cfe2fbc8e7b92ca0f74bfe1c94f5cc68 100644
--- a/src/db_api/Makefile.in
+++ b/src/db_api/Makefile.in
@@ -178,7 +178,8 @@ ECHO_N = @ECHO_N@
 ECHO_T = @ECHO_T@
 EGREP = @EGREP@
 ELAN_LIBS = @ELAN_LIBS@
-EXEEXT = @EXEEXT@
+# This is needed if compiling on windows
+EXEEXT = 
 FEDERATION_LDFLAGS = @FEDERATION_LDFLAGS@
 FGREP = @FGREP@
 GREP = @GREP@
diff --git a/src/plugins/accounting_storage/filetxt/filetxt_jobacct_process.c b/src/plugins/accounting_storage/filetxt/filetxt_jobacct_process.c
index e9509603611c9147714eaa89b4d7ae20505cbcb9..ba35c156d3709c762ff3411efbdd6bad63d35314 100644
--- a/src/plugins/accounting_storage/filetxt/filetxt_jobacct_process.c
+++ b/src/plugins/accounting_storage/filetxt/filetxt_jobacct_process.c
@@ -46,6 +46,7 @@
 
 #include "src/common/xstring.h"
 #include "src/common/xmalloc.h"
+#include "src/common/list.h"
 #include "filetxt_jobacct_process.h"
 #include "src/slurmctld/slurmctld.h"
 #include "src/slurmdbd/read_config.h"
diff --git a/src/plugins/accounting_storage/slurmdbd/accounting_storage_slurmdbd.c b/src/plugins/accounting_storage/slurmdbd/accounting_storage_slurmdbd.c
index 60f467805643d8834ba5f0ae4933ba98978dd9f3..b97e9fac6611d2cdcc0705bfb12976fb53dcef72 100644
--- a/src/plugins/accounting_storage/slurmdbd/accounting_storage_slurmdbd.c
+++ b/src/plugins/accounting_storage/slurmdbd/accounting_storage_slurmdbd.c
@@ -67,8 +67,13 @@
  * the slurmctld we will have these symbols defined.  They will get
  * overwritten when linking with the slurmctld.
  */
+#if defined(__APPLE__)
+slurm_ctl_conf_t slurmctld_conf __attribute__((weak_import));
+List job_list __attribute__((weak_import)) = NULL;
+#else
 slurm_ctl_conf_t slurmctld_conf;
 List job_list = NULL;
+#endif
 
 /*
  * These variables are required by the generic plugin interface.  If they
diff --git a/src/plugins/auth/munge/auth_munge.c b/src/plugins/auth/munge/auth_munge.c
index f898067e8b7ae3d0621a5e8713ac54159828e5f0..36e934a864a8842382e3b5794a89318b4a14157e 100644
--- a/src/plugins/auth/munge/auth_munge.c
+++ b/src/plugins/auth/munge/auth_munge.c
@@ -69,8 +69,8 @@
 
 #include <munge.h>
 
-#include <slurm/slurm_errno.h>
 #include "src/common/slurm_xlator.h"
+#include <slurm/slurm_errno.h>
 
 #define MUNGE_ERRNO_OFFSET	1000
 
diff --git a/src/plugins/proctrack/aix/proctrack_aix.c b/src/plugins/proctrack/aix/proctrack_aix.c
index 8027b0a5f96840ca0cc2e44dd12925e795fe3503..c8907c319e057003c1858e5dc386fac1bbbd8e20 100644
--- a/src/plugins/proctrack/aix/proctrack_aix.c
+++ b/src/plugins/proctrack/aix/proctrack_aix.c
@@ -117,7 +117,7 @@ extern int fini ( void )
 	return SLURM_SUCCESS;
 }
 
-extern int slurm_container_create ( slurmd_job_t *job )
+extern int slurm_container_plugin_create ( slurmd_job_t *job )
 {
 	return SLURM_SUCCESS;
 }
@@ -126,7 +126,7 @@ extern int slurm_container_create ( slurmd_job_t *job )
  * Uses job step process group id as a unique identifier.  Job id
  * and step id are not unique by themselves.
  */
-extern int slurm_container_add ( slurmd_job_t *job, pid_t pid )
+extern int slurm_container_plugin_add ( slurmd_job_t *job, pid_t pid )
 {
 	int pgid = (int) job->pgid;
 
@@ -142,7 +142,7 @@ extern int slurm_container_add ( slurmd_job_t *job, pid_t pid )
 	return SLURM_SUCCESS;
 }
 
-extern int slurm_container_signal  ( uint32_t id, int signal )
+extern int slurm_container_plugin_signal  ( uint32_t id, int signal )
 {
 	int jobid = (int) id;
 	if (!id)	/* no container ID */
@@ -151,7 +151,7 @@ extern int slurm_container_signal  ( uint32_t id, int signal )
 	return proctrack_job_kill(&jobid, &signal);
 }
 
-extern int slurm_container_destroy ( uint32_t id )
+extern int slurm_container_plugin_destroy ( uint32_t id )
 {
 	int jobid = (int) id;
 
@@ -165,7 +165,7 @@ extern int slurm_container_destroy ( uint32_t id )
 }
 
 extern uint32_t
-slurm_container_find(pid_t pid)
+slurm_container_plugin_find(pid_t pid)
 {
 	int local_pid = (int) pid;
 	int cont_id = proctrack_get_job_id(&local_pid);
@@ -175,7 +175,7 @@ slurm_container_find(pid_t pid)
 }
 
 extern bool
-slurm_container_has_pid(uint32_t cont_id, pid_t pid)
+slurm_container_plugin_has_pid(uint32_t cont_id, pid_t pid)
 {
 	int local_pid = (int) pid;
 	int found_cont_id = proctrack_get_job_id(&local_pid);
@@ -187,7 +187,7 @@ slurm_container_has_pid(uint32_t cont_id, pid_t pid)
 }
 
 extern int
-slurm_container_get_pids(uint32_t cont_id, pid_t **pids, int *npids)
+slurm_container_plugin_get_pids(uint32_t cont_id, pid_t **pids, int *npids)
 {
 	int32_t *p;
 	int np;
@@ -210,7 +210,8 @@ slurm_container_get_pids(uint32_t cont_id, pid_t **pids, int *npids)
 	}
 
 	if (sizeof(uint32_t) == sizeof(pid_t)) {
-		debug3("slurm_container_get_pids: No need to copy pids array");
+		debug3("slurm_container_plugin_get_pids: No need to copy "
+		       "pids array");
 		*npids = np;
 		*pids = (pid_t *)p;
 	} else {
@@ -218,7 +219,7 @@ slurm_container_get_pids(uint32_t cont_id, pid_t **pids, int *npids)
 		pid_t *p_copy;
 		int i;
 
-		debug3("slurm_container_get_pids: Must copy pids array");
+		debug3("slurm_container_plugin_get_pids: Must copy pids array");
 		p_copy = (pid_t *)xmalloc(np * sizeof(pid_t));
 		for (i = 0; i < np; i++) {
 			p_copy[i] = (pid_t)p[i];
@@ -232,7 +233,7 @@ slurm_container_get_pids(uint32_t cont_id, pid_t **pids, int *npids)
 }
 
 extern int
-slurm_container_wait(uint32_t cont_id)
+slurm_container_plugin_wait(uint32_t cont_id)
 {
 	int jobid = (int) cont_id;
 	int delay = 1;
@@ -253,7 +254,7 @@ slurm_container_wait(uint32_t cont_id)
 			int npids = 0;
 			error("Container %u is still not empty", cont_id);
 
-			slurm_container_get_pids(cont_id, &pids, &npids);
+			slurm_container_plugin_get_pids(cont_id, &pids, &npids);
 			if (npids > 0) {
 				for (i = 0; i < npids; i++) {
 					verbose("  Container %u has pid %d",
@@ -266,4 +267,3 @@ slurm_container_wait(uint32_t cont_id)
 
 	return SLURM_SUCCESS;
 }
-
diff --git a/src/plugins/proctrack/cgroup/proctrack_cgroup.c b/src/plugins/proctrack/cgroup/proctrack_cgroup.c
index bb5dcbe5768154617850aae30ecbef41540f7d92..b0da92ea47ef9c2ec4309fbe4482b5568e61ff2e 100644
--- a/src/plugins/proctrack/cgroup/proctrack_cgroup.c
+++ b/src/plugins/proctrack/cgroup/proctrack_cgroup.c
@@ -3,32 +3,32 @@
  *****************************************************************************
  *  Copyright (C) 2009 CEA/DAM/DIF
  *  Written by Matthieu Hautreux <matthieu.hautreux@cea.fr>
- *  
+ *
  *  This file is part of SLURM, a resource management program.
  *  For details, see <https://computing.llnl.gov/linux/slurm/>.
  *  Please also read the included file: DISCLAIMER.
- *  
+ *
  *  SLURM 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.
  *
- *  In addition, as a special exception, the copyright holders give permission 
- *  to link the code of portions of this program with the OpenSSL library under 
- *  certain conditions as described in each individual source file, and 
- *  distribute linked combinations including the two. You must obey the GNU 
- *  General Public License in all respects for all of the code used other than 
- *  OpenSSL. If you modify file(s) with this exception, you may extend this 
- *  exception to your version of the file(s), but you are not obligated to do 
+ *  In addition, as a special exception, the copyright holders give permission
+ *  to link the code of portions of this program with the OpenSSL library under
+ *  certain conditions as described in each individual source file, and
+ *  distribute linked combinations including the two. You must obey the GNU
+ *  General Public License in all respects for all of the code used other than
+ *  OpenSSL. If you modify file(s) with this exception, you may extend this
+ *  exception to your version of the file(s), but you are not obligated to do
  *  so. If you do not wish to do so, delete this exception statement from your
- *  version.  If you delete this exception statement from all source files in 
+ *  version.  If you delete this exception statement from all source files in
  *  the program, then also delete it here.
- *  
+ *
  *  SLURM 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 SLURM; if not, write to the Free Software Foundation, Inc.,
  *  51 Franklin Street, Fifth Floor, Boston, MA 02110-1301  USA.
@@ -80,7 +80,7 @@
  * where <application> is a description of the intended application of
  * the plugin (e.g., "jobcomp" for SLURM job completion logging) and <method>
  * is a description of how this plugin satisfies that application.  SLURM will
- * only load job completion logging plugins if the plugin_type string has a 
+ * only load job completion logging plugins if the plugin_type string has a
  * prefix of "jobcomp/".
  *
  * plugin_version - an unsigned 32-bit integer giving the version number
@@ -159,7 +159,7 @@ int _slurm_cgroup_create(slurmd_job_t *job,uint32_t id,uid_t uid,gid_t gid)
 
 	/* build user cgroup path if no set (should not be) */
 	if ( *user_cgroup_path == '\0' ) {
-		if ( snprintf(user_cgroup_path,PATH_MAX,CGROUP_SLURMDIR 
+		if ( snprintf(user_cgroup_path,PATH_MAX,CGROUP_SLURMDIR
 			      "/uid_%u",uid) >= PATH_MAX ) {
 			error("unable to build uid %u cgroup filepath : %m",
 			      uid);
@@ -198,9 +198,9 @@ int _slurm_cgroup_create(slurmd_job_t *job,uint32_t id,uid_t uid,gid_t gid)
 	if ( slurm_cgroup_conf->user_cgroup_params )
 		xcgroup_set_params(user_cgroup_path,
 				   slurm_cgroup_conf->user_cgroup_params);
-	
+
 	/*
-	 * if memory constraints have to be added to uid cgroup 
+	 * if memory constraints have to be added to uid cgroup
 	 * use_hierachy=1 must be set here, but this would result
 	 * in impossibility to configure some job memory parameters
 	 * differently, so skip this stage for now
@@ -214,8 +214,8 @@ int _slurm_cgroup_create(slurmd_job_t *job,uint32_t id,uid_t uid,gid_t gid)
 	if ( xcgroup_create(job_cgroup_path,&opts)
 	     != SLURM_SUCCESS )
 		return SLURM_ERROR;
-	
-	/* job cgroup parameters must be set before any sub cgroups 
+
+	/* job cgroup parameters must be set before any sub cgroups
 	   are created */
 	xcgroup_set_mem_use_hierarchy(job_cgroup_path,1);
 	if ( slurm_cgroup_conf->job_cgroup_params )
@@ -228,15 +228,15 @@ int _slurm_cgroup_create(slurmd_job_t *job,uint32_t id,uid_t uid,gid_t gid)
 	 *  more memory than permitted
 	 *
 	 *  If an env value is already set for slurmstepd
-	 *  OOM killer behavior, keep it, otherwise set the 
+	 *  OOM killer behavior, keep it, otherwise set the
 	 *  -17 value, wich means do not let OOM killer kill it
-	 *  
-	 *  FYI, setting "export SLURMSTEPD_OOM_ADJ=-17" 
+	 *
+	 *  FYI, setting "export SLURMSTEPD_OOM_ADJ=-17"
 	 *  in /etc/sysconfig/slurm would be the same
 	 */
 	setenv("SLURMSTEPD_OOM_ADJ","-17",0);
 
-	/* 
+	/*
 	 * FIXME!
 	 * Warning, with slurm-2.1.0 job_mem more corresponds to the
 	 * missing field jobstep_mem and thus must not be
@@ -252,8 +252,8 @@ int _slurm_cgroup_create(slurmd_job_t *job,uint32_t id,uid_t uid,gid_t gid)
 	 * In the future, a jobstep_mem field should be added
 	 * to avoid this workaround and be more deterministic
 	 *
-	 * Unfortunately with this workaround comes a collateral problem ! 
-	 * As we propose to alter already fixed limits for both mem and 
+	 * Unfortunately with this workaround comes a collateral problem !
+	 * As we propose to alter already fixed limits for both mem and
 	 * mem+swap, we have to respect a certain order while doing the
 	 * modification to respect the kernel cgroup implementation
 	 * requirements : when sets, memory limit must be lower or equal
@@ -261,7 +261,7 @@ int _slurm_cgroup_create(slurmd_job_t *job,uint32_t id,uid_t uid,gid_t gid)
 	 *
 	 * Notes : a limit value of -1 means that the limit was not
 	 * previously set
-	 * Notes : this whole part should be much more simpler when 
+	 * Notes : this whole part should be much more simpler when
 	 * the jobstep_mem field will be added
 	 *
 	 */
@@ -272,7 +272,7 @@ int _slurm_cgroup_create(slurmd_job_t *job,uint32_t id,uid_t uid,gid_t gid)
 	xcgroup_get_memlimit(job_cgroup_path,&cur_memlimit);
 	xcgroup_get_memswlimit(job_cgroup_path,&cur_memswlimit);
 
-	/* 
+	/*
 	 * set memory constraints according to cgroup conf
 	 */
 	if ( slurm_cgroup_conf->constrain_ram_space &&
@@ -287,28 +287,28 @@ int _slurm_cgroup_create(slurmd_job_t *job,uint32_t id,uid_t uid,gid_t gid)
 		uint32_t limit,memlimit,swaplimit;
 		memlimit = (uint32_t) job->job_mem ;
 		swaplimit = memlimit ;
-		memlimit = (uint32_t) memlimit * 
+		memlimit = (uint32_t) memlimit *
 			( slurm_cgroup_conf->allowed_ram_space / 100.0 ) ;
-		swaplimit = (uint32_t) swaplimit * 
+		swaplimit = (uint32_t) swaplimit *
 			( slurm_cgroup_conf->allowed_swap_space / 100.0 ) ;
 		limit = memlimit + swaplimit ;
-		/* 
-		 * if memlimit was not set in the previous block, 
-		 * we have to set it here or it will not be possible 
+		/*
+		 * if memlimit was not set in the previous block,
+		 * we have to set it here or it will not be possible
 		 * to set mem+swap limit as the mem limit value could be
 		 * higher.
 		 * FIXME!
 		 * However, due to the restriction mentioned in the previous
 		 * block (job_mem...) if a step already set it, we will
 		 * have to skip this as if the new amount is bigger
-		 * we will not be allowed by the kernel to set it as 
-		 * the mem+swap value will certainly be lower. In such 
+		 * we will not be allowed by the kernel to set it as
+		 * the mem+swap value will certainly be lower. In such
 		 * scenario, we will have to set memlimit after mem+swap limit
 		 * to still be clean regarding to cgroup kernel implementation
 		 * ( memlimit must be lower or equal to mem+swap limit when
 		 * set ). See stage 2 below...
 		 */
-		if ( !slurm_cgroup_conf->constrain_ram_space && 
+		if ( !slurm_cgroup_conf->constrain_ram_space &&
 		     cur_memlimit == -1 )
 			xcgroup_set_memlimit(job_cgroup_path,limit);
 		/*
@@ -321,18 +321,18 @@ int _slurm_cgroup_create(slurmd_job_t *job,uint32_t id,uid_t uid,gid_t gid)
 		else
 			debug3("keeping previously set mem+swap limit of %uMB"
 			       " for '%s'",cur_memswlimit,job_cgroup_path);
-		/* 
+		/*
 		 * FIXME!
 		 * stage 2
 		 */
-		if ( !slurm_cgroup_conf->constrain_ram_space && 
+		if ( !slurm_cgroup_conf->constrain_ram_space &&
 		     cur_memlimit != -1 ) {
 			/*
 			 * FIXME!
-			 * for the reason why we do this, see the previous 
+			 * for the reason why we do this, see the previous
 			 * block
 			 */
-			if ( cur_memlimit == -1 || cur_memlimit < limit ) 
+			if ( cur_memlimit == -1 || cur_memlimit < limit )
 				xcgroup_set_memlimit(job_cgroup_path,limit);
 			else
 				debug3("keeping previously set mem limit of "
@@ -342,7 +342,7 @@ int _slurm_cgroup_create(slurmd_job_t *job,uint32_t id,uid_t uid,gid_t gid)
 	}
 	/*
 	 * FIXME!
-	 * yet an other stage 2 due to jobstep_mem lack... 
+	 * yet an other stage 2 due to jobstep_mem lack...
 	 * only used when ram_space constraint is enforced
 	 */
 	if ( slurm_cgroup_conf->constrain_ram_space &&
@@ -359,7 +359,7 @@ int _slurm_cgroup_create(slurmd_job_t *job,uint32_t id,uid_t uid,gid_t gid)
 	}
 
 	/* set cores constraints if required by conf */
-	if ( slurm_cgroup_conf->constrain_cores && 
+	if ( slurm_cgroup_conf->constrain_cores &&
 	     job->job_alloc_cores ) {
 		/*
 		 * abstract mapping of cores in slurm must
@@ -409,13 +409,13 @@ int _slurm_cgroup_destroy(void)
 {
 	if ( jobstep_cgroup_path[0] != '\0' )
 		xcgroup_destroy(jobstep_cgroup_path);
-	
+
 	if ( job_cgroup_path[0] != '\0' )
 		xcgroup_destroy(job_cgroup_path);
-	
+
 	if ( user_cgroup_path[0] != '\0' )
 		xcgroup_destroy(user_cgroup_path);
-	
+
 	return SLURM_SUCCESS;
 }
 
@@ -423,7 +423,7 @@ int _slurm_cgroup_add_pids(uint32_t id,pid_t* pids,int npids)
 {
 	if ( *jobstep_cgroup_path == '\0' )
 		return SLURM_ERROR;
-	
+
 	return xcgroup_add_pids(jobstep_cgroup_path,pids,npids);
 }
 
@@ -432,7 +432,7 @@ _slurm_cgroup_get_pids(uint32_t id, pid_t **pids, int *npids)
 {
 	if ( *jobstep_cgroup_path == '\0' )
 		return SLURM_ERROR;
-	
+
 	return xcgroup_get_pids(jobstep_cgroup_path,pids,npids);
 }
 
@@ -440,7 +440,7 @@ int _slurm_cgroup_set_memlimit(uint32_t id,uint32_t memlimit)
 {
 	if ( *jobstep_cgroup_path == '\0' )
 		return SLURM_ERROR;
-	
+
 	return xcgroup_set_memlimit(jobstep_cgroup_path,memlimit);
 }
 
@@ -448,7 +448,7 @@ int _slurm_cgroup_set_memswlimit(uint32_t id,uint32_t memlimit)
 {
 	if ( *jobstep_cgroup_path == '\0' )
 		return SLURM_ERROR;
-	
+
 	return xcgroup_set_memswlimit(jobstep_cgroup_path,memlimit);
 }
 
@@ -522,11 +522,11 @@ extern int fini ( void )
 /*
  * Uses slurmd job-step manager's pid as the unique container id.
  */
-extern int slurm_container_create ( slurmd_job_t *job )
+extern int slurm_container_plugin_create ( slurmd_job_t *job )
 {
 	int fstatus;
 
-	/* create a new cgroup for that container */ 
+	/* create a new cgroup for that container */
 	fstatus = _slurm_cgroup_create(job,(uint32_t)job->jmgr_pid,
 				       job->uid,job->gid);
 	if ( fstatus )
@@ -542,11 +542,11 @@ extern int slurm_container_create ( slurmd_job_t *job )
 	fstatus = _slurm_cgroup_add_pids((uint32_t)job->jmgr_pid,
 					 &(job->jmgr_pid),1);
 	if ( fstatus ) {
-		_slurm_cgroup_destroy();		
+		_slurm_cgroup_destroy();
 		return SLURM_ERROR;
 	}
 
-	/* we use slurmstepd pid as the identifier of the container 
+	/* we use slurmstepd pid as the identifier of the container
 	 * the corresponding cgroup could be found using
 	 * _slurm_cgroup_find_by_pid */
 	job->cont_id = (uint32_t)job->jmgr_pid;
@@ -554,12 +554,12 @@ extern int slurm_container_create ( slurmd_job_t *job )
 	return SLURM_SUCCESS;
 }
 
-extern int slurm_container_add ( slurmd_job_t *job, pid_t pid )
+extern int slurm_container_plugin_add ( slurmd_job_t *job, pid_t pid )
 {
 	return _slurm_cgroup_add_pids(job->cont_id,&pid,1);
 }
 
-extern int slurm_container_signal ( uint32_t id, int signal )
+extern int slurm_container_plugin_signal ( uint32_t id, int signal )
 {
 	pid_t* pids = NULL;
 	int npids;
@@ -570,7 +570,7 @@ extern int slurm_container_signal ( uint32_t id, int signal )
 		error("unable to get pids list for cont_id=%u",id);
 		return SLURM_ERROR;
 	}
-	
+
 	for ( i = 0 ; i<npids ; i++ ) {
 		/* do not kill slurmstepd */
 		if ( pids[i] != id ) {
@@ -579,26 +579,26 @@ extern int slurm_container_signal ( uint32_t id, int signal )
 			kill(pids[i],signal);
 		}
 	}
-	
+
 	xfree(pids);
-	
+
 	return SLURM_SUCCESS;
 }
 
-extern int slurm_container_destroy ( uint32_t id )
+extern int slurm_container_plugin_destroy ( uint32_t id )
 {
 	_slurm_cgroup_destroy();
 	return SLURM_SUCCESS;
 }
 
-extern uint32_t slurm_container_find(pid_t pid)
+extern uint32_t slurm_container_plugin_find(pid_t pid)
 {
 	uint32_t cont_id=-1;
 	_slurm_cgroup_find_by_pid(&cont_id,pid);
 	return cont_id;
 }
 
-extern bool slurm_container_has_pid(uint32_t cont_id, pid_t pid)
+extern bool slurm_container_plugin_has_pid(uint32_t cont_id, pid_t pid)
 {
 	int fstatus;
 	uint32_t lid;
@@ -614,7 +614,7 @@ extern bool slurm_container_has_pid(uint32_t cont_id, pid_t pid)
 
 }
 
-extern int slurm_container_wait(uint32_t cont_id)
+extern int slurm_container_plugin_wait(uint32_t cont_id)
 {
 	int delay = 1;
 
@@ -624,8 +624,8 @@ extern int slurm_container_wait(uint32_t cont_id)
 	}
 
 	/* Spin until the container is successfully destroyed */
-	while (slurm_container_destroy(cont_id) != SLURM_SUCCESS) {
-		slurm_container_signal(cont_id, SIGKILL);
+	while (slurm_container_plugin_destroy(cont_id) != SLURM_SUCCESS) {
+		slurm_container_plugin_signal(cont_id, SIGKILL);
 		sleep(delay);
 		if (delay < 120) {
 			delay *= 2;
@@ -637,7 +637,8 @@ extern int slurm_container_wait(uint32_t cont_id)
 	return SLURM_SUCCESS;
 }
 
-extern int slurm_container_get_pids(uint32_t cont_id, pid_t **pids, int *npids)
+extern int slurm_container_plugin_get_pids(
+	uint32_t cont_id, pid_t **pids, int *npids)
 {
 	return _slurm_cgroup_get_pids(cont_id,pids,npids);
 }
diff --git a/src/plugins/proctrack/linuxproc/proctrack_linuxproc.c b/src/plugins/proctrack/linuxproc/proctrack_linuxproc.c
index 7c68191b8418a0b47716eee656dcab80f6484a93..014589b633dc668d1d9bfdf6c29ccb654c08e2ca 100644
--- a/src/plugins/proctrack/linuxproc/proctrack_linuxproc.c
+++ b/src/plugins/proctrack/linuxproc/proctrack_linuxproc.c
@@ -105,33 +105,33 @@ extern int fini ( void )
 /*
  * Uses slurmd job-step manager's pid as the unique container id.
  */
-extern int slurm_container_create ( slurmd_job_t *job )
+extern int slurm_container_plugin_create ( slurmd_job_t *job )
 {
 	job->cont_id = (uint32_t)job->jmgr_pid;
 	return SLURM_SUCCESS;
 }
 
-extern int slurm_container_add ( slurmd_job_t *job, pid_t pid )
+extern int slurm_container_plugin_add ( slurmd_job_t *job, pid_t pid )
 {
 	return SLURM_SUCCESS;
 }
 
-extern int slurm_container_signal ( uint32_t id, int signal )
+extern int slurm_container_plugin_signal ( uint32_t id, int signal )
 {
 	return kill_proc_tree((pid_t)id, signal);
 }
 
-extern int slurm_container_destroy ( uint32_t id )
+extern int slurm_container_plugin_destroy ( uint32_t id )
 {
 	return SLURM_SUCCESS;
 }
 
-extern uint32_t slurm_container_find(pid_t pid)
+extern uint32_t slurm_container_plugin_find(pid_t pid)
 {
 	return (uint32_t) find_ancestor(pid, "slurmstepd");
 }
 
-extern bool slurm_container_has_pid(uint32_t cont_id, pid_t pid)
+extern bool slurm_container_plugin_has_pid(uint32_t cont_id, pid_t pid)
 {
 	uint32_t cont;
 
@@ -143,7 +143,7 @@ extern bool slurm_container_has_pid(uint32_t cont_id, pid_t pid)
 }
 
 extern int
-slurm_container_wait(uint32_t cont_id)
+slurm_container_plugin_wait(uint32_t cont_id)
 {
 	int delay = 1;
 
@@ -153,8 +153,8 @@ slurm_container_wait(uint32_t cont_id)
 	}
 
 	/* Spin until the container is successfully destroyed */
-	while (slurm_container_destroy(cont_id) != SLURM_SUCCESS) {
-		slurm_container_signal(cont_id, SIGKILL);
+	while (slurm_container_plugin_destroy(cont_id) != SLURM_SUCCESS) {
+		slurm_container_plugin_signal(cont_id, SIGKILL);
 		sleep(delay);
 		if (delay < 120) {
 			delay *= 2;
@@ -167,7 +167,7 @@ slurm_container_wait(uint32_t cont_id)
 }
 
 extern int
-slurm_container_get_pids(uint32_t cont_id, pid_t **pids, int *npids)
+slurm_container_plugin_get_pids(uint32_t cont_id, pid_t **pids, int *npids)
 {
 	return proctrack_linuxproc_get_pids((pid_t)cont_id, pids, npids);
 }
diff --git a/src/plugins/proctrack/lua/proctrack_lua.c b/src/plugins/proctrack/lua/proctrack_lua.c
index 7c32548c5ac055ae8fb2c197d603ebd23f531fce..716825746c63e8b2331044e69d5e6eb1ff366189 100644
--- a/src/plugins/proctrack/lua/proctrack_lua.c
+++ b/src/plugins/proctrack/lua/proctrack_lua.c
@@ -320,7 +320,7 @@ static int lua_job_table_create (slurmd_job_t *job)
 	return (0);
 }
 
-int slurm_container_create (slurmd_job_t *job)
+int slurm_container_plugin_create (slurmd_job_t *job)
 {
 	int rc = SLURM_ERROR;
 	double id;
@@ -337,8 +337,8 @@ int slurm_container_create (slurmd_job_t *job)
 
 	lua_job_table_create (job);
 	if (lua_pcall (L, 1, 1, 0) != 0) {
-		error ("proctrack/lua: %s: slurm_container_create: %s",
-				lua_script_path, lua_tostring (L, -1));
+		error ("proctrack/lua: %s: slurm_container_plugin_create: %s",
+		       lua_script_path, lua_tostring (L, -1));
 		goto out;
 	}
 
@@ -347,7 +347,7 @@ int slurm_container_create (slurmd_job_t *job)
 	 */
 	if (lua_isnil (L, -1)) {
 		error ("proctrack/lua: "
-		       "slurm_container_create did not return id");
+		       "slurm_container_plugin_create did not return id");
 		lua_pop (L, -1);
 		goto out;
 	}
@@ -363,7 +363,7 @@ out:
 	return rc;
 }
 
-int slurm_container_add (slurmd_job_t *job, pid_t pid)
+int slurm_container_plugin_add (slurmd_job_t *job, pid_t pid)
 {
 	int rc = SLURM_ERROR;
 
@@ -378,8 +378,9 @@ int slurm_container_add (slurmd_job_t *job, pid_t pid)
 	lua_pushnumber (L, pid);
 
 	if (lua_pcall (L, 3, 1, 0) != 0) {
-		error ("running lua function 'slurm_container_add': %s",
-				lua_tostring (L, -1));
+		error ("running lua function "
+		       "'slurm_container_plugin_add': %s",
+		       lua_tostring (L, -1));
 		goto out;
 	}
 
@@ -390,7 +391,7 @@ out:
 	return (rc);
 }
 
-int slurm_container_signal (uint32_t id, int sig)
+int slurm_container_plugin_signal (uint32_t id, int sig)
 {
 	int rc = SLURM_ERROR;
 
@@ -404,8 +405,9 @@ int slurm_container_signal (uint32_t id, int sig)
 	lua_pushnumber (L, sig);
 
 	if (lua_pcall (L, 2, 1, 0) != 0) {
-		error ("running lua function 'slurm_container_signal': %s",
-				lua_tostring (L, -1));
+		error ("running lua function "
+		       "'slurm_container_plugin_signal': %s",
+		       lua_tostring (L, -1));
 		goto out;
 	}
 
@@ -416,7 +418,7 @@ out:
 	return (rc);
 }
 
-int slurm_container_destroy (uint32_t id)
+int slurm_container_plugin_destroy (uint32_t id)
 {
 	int rc = SLURM_ERROR;
 
@@ -429,8 +431,9 @@ int slurm_container_destroy (uint32_t id)
 	lua_pushnumber (L, id);
 
 	if (lua_pcall (L, 1, 1, 0) != 0) {
-		error ("running lua function 'slurm_container_destroy': %s",
-				lua_tostring (L, -1));
+		error ("running lua function "
+		       "'slurm_container_plugin_destroy': %s",
+		       lua_tostring (L, -1));
 		goto out;
 	}
 
@@ -442,7 +445,7 @@ out:
 	return (rc);
 }
 
-uint32_t slurm_container_find (pid_t pid)
+uint32_t slurm_container_plugin_find (pid_t pid)
 {
 	uint32_t id = (uint32_t) SLURM_ERROR;
 
@@ -455,8 +458,8 @@ uint32_t slurm_container_find (pid_t pid)
 	lua_pushnumber (L, pid);
 
 	if (lua_pcall (L, 1, 1, 0) != 0) {
-		error ("running lua function 'slurm_container_find': %s",
-				lua_tostring (L, -1));
+		error ("running lua function 'slurm_container_plugin_find': %s",
+		       lua_tostring (L, -1));
 		goto out;
 	}
 
@@ -468,7 +471,7 @@ out:
 	return (id);
 }
 
-bool slurm_container_has_pid (uint32_t id, pid_t pid)
+bool slurm_container_plugin_has_pid (uint32_t id, pid_t pid)
 {
 	int rc = 0;
 
@@ -482,8 +485,9 @@ bool slurm_container_has_pid (uint32_t id, pid_t pid)
 	lua_pushnumber (L, pid);
 
 	if (lua_pcall (L, 2, 1, 0) != 0) {
-		error ("running lua function 'slurm_container_has_pid': %s",
-				lua_tostring (L, -1));
+		error ("running lua function "
+		       "'slurm_container_plugin_has_pid': %s",
+		       lua_tostring (L, -1));
 		goto out;
 	}
 
@@ -495,7 +499,7 @@ out:
 	return (rc == 1);
 }
 
-int slurm_container_wait (uint32_t id)
+int slurm_container_plugin_wait (uint32_t id)
 {
 	int rc = SLURM_ERROR;
 
@@ -508,8 +512,8 @@ int slurm_container_wait (uint32_t id)
 	lua_pushnumber (L, id);
 
 	if (lua_pcall (L, 1, 1, 0) != 0) {
-		error ("running lua function 'slurm_container_wait': %s",
-			lua_tostring (L, -1));
+		error ("running lua function 'slurm_container_plugin_wait': %s",
+		       lua_tostring (L, -1));
 		goto out;
 	}
 
@@ -520,7 +524,7 @@ out:
 	return (rc);
 }
 
-int slurm_container_get_pids (uint32_t cont_id, pid_t **pids, int *npids)
+int slurm_container_plugin_get_pids (uint32_t cont_id, pid_t **pids, int *npids)
 {
 	int rc = SLURM_ERROR;
 	int i = 0;
@@ -533,16 +537,16 @@ int slurm_container_get_pids (uint32_t cont_id, pid_t **pids, int *npids)
 
 	lua_getglobal (L, "slurm_container_get_pids");
 	if (lua_isnil (L, -1))
-	    goto out;
+		goto out;
 
 	lua_pushnumber (L, cont_id);
 
 	if (lua_pcall (L, 1, 1, 0) != 0) {
-	    error ("%s: %s: %s",
-		    "proctrack/lua",
-		    __func__,
-		    lua_tostring (L, -1));
-	    goto out;
+		error ("%s: %s: %s",
+		       "proctrack/lua",
+		       __func__,
+		       lua_tostring (L, -1));
+		goto out;
 	}
 
 	/*
@@ -551,8 +555,8 @@ int slurm_container_get_pids (uint32_t cont_id, pid_t **pids, int *npids)
 	 */
 	if (!lua_istable(L, -1)) {
 		error ("%s: %s: function should return a table",
-			"proctrack/lua",
-			__func__);
+		       "proctrack/lua",
+		       __func__);
 		goto out;
 	}
 
diff --git a/src/plugins/proctrack/pgid/proctrack_pgid.c b/src/plugins/proctrack/pgid/proctrack_pgid.c
index 4371c10db347dc723c086d7852aee5ab45fee4fc..04974f980a0e8b60f85adde0e5ae1f564f41a26f 100644
--- a/src/plugins/proctrack/pgid/proctrack_pgid.c
+++ b/src/plugins/proctrack/pgid/proctrack_pgid.c
@@ -107,7 +107,7 @@ extern int fini ( void )
 	return SLURM_SUCCESS;
 }
 
-extern int slurm_container_create ( slurmd_job_t *job )
+extern int slurm_container_plugin_create ( slurmd_job_t *job )
 {
 	return SLURM_SUCCESS;
 }
@@ -115,13 +115,13 @@ extern int slurm_container_create ( slurmd_job_t *job )
 /*
  * Uses job step process group id.
  */
-extern int slurm_container_add ( slurmd_job_t *job, pid_t pid )
+extern int slurm_container_plugin_add ( slurmd_job_t *job, pid_t pid )
 {
 	job->cont_id = (uint32_t)job->pgid;
 	return SLURM_SUCCESS;
 }
 
-extern int slurm_container_signal  ( uint32_t id, int signal )
+extern int slurm_container_plugin_signal  ( uint32_t id, int signal )
 {
 	pid_t pid = (pid_t) id;
 
@@ -136,12 +136,12 @@ extern int slurm_container_signal  ( uint32_t id, int signal )
 	return (int)killpg(pid, signal);
 }
 
-extern int slurm_container_destroy ( uint32_t id )
+extern int slurm_container_plugin_destroy ( uint32_t id )
 {
 	return SLURM_SUCCESS;
 }
 
-extern uint32_t slurm_container_find(pid_t pid)
+extern uint32_t slurm_container_plugin_find(pid_t pid)
 {
 	pid_t rc = getpgid(pid);
 
@@ -151,7 +151,7 @@ extern uint32_t slurm_container_find(pid_t pid)
 		return (uint32_t) rc;
 }
 
-extern bool slurm_container_has_pid(uint32_t cont_id, pid_t pid)
+extern bool slurm_container_plugin_has_pid(uint32_t cont_id, pid_t pid)
 {
 	pid_t pgid = getpgid(pid);
 
@@ -162,7 +162,7 @@ extern bool slurm_container_has_pid(uint32_t cont_id, pid_t pid)
 }
 
 extern int
-slurm_container_wait(uint32_t cont_id)
+slurm_container_plugin_wait(uint32_t cont_id)
 {
 	pid_t pgid = (pid_t)cont_id;
 	int delay = 1;
@@ -174,7 +174,7 @@ slurm_container_wait(uint32_t cont_id)
 
 	/* Spin until the process group is gone. */
 	while (killpg(pgid, 0) == 0) {
-		slurm_container_signal(cont_id, SIGKILL);
+		slurm_container_plugin_signal(cont_id, SIGKILL);
 		sleep(delay);
 		if (delay < 120) {
 			delay *= 2;
@@ -187,8 +187,9 @@ slurm_container_wait(uint32_t cont_id)
 }
 
 extern int
-slurm_container_get_pids(uint32_t cont_id, pid_t **pids, int *npids)
+slurm_container_plugin_get_pids(uint32_t cont_id, pid_t **pids, int *npids)
 {
-	error("proctrack/pgid does not implement slurm_container_get_pids");
+	error("proctrack/pgid does not implement "
+	      "slurm_container_plugin_get_pids");
 	return SLURM_ERROR;
 }
diff --git a/src/plugins/proctrack/rms/proctrack_rms.c b/src/plugins/proctrack/rms/proctrack_rms.c
index 9ff88e6ee0d224db02548d2f3f33d8ec67006d41..0d718b7e18b382fb10f78f4a22a2615828bc25eb 100644
--- a/src/plugins/proctrack/rms/proctrack_rms.c
+++ b/src/plugins/proctrack/rms/proctrack_rms.c
@@ -81,14 +81,14 @@ extern int fini (void)
 
 /*
  * When proctrack/rms is used in conjunction with switch/elan,
- * slurm_container_create will not normally create the program description.
- * It just retrieves the prgid created in switch/elan.
+ * slurm_container_plugin_create will not normally create the program
+ * description.  It just retrieves the prgid created in switch/elan.
  *
  * When the program description cannot be retrieved (switch/elan is not
  * being used, the job step is a batch script, etc.) then rms_prgcreate()
  * is called here.
  */
-extern int slurm_container_create (slurmd_job_t *job)
+extern int slurm_container_plugin_create (slurmd_job_t *job)
 {
 	int prgid;
 	/*
@@ -111,17 +111,17 @@ extern int slurm_container_create (slurmd_job_t *job)
 	return SLURM_SUCCESS;
 }
 
-extern int slurm_container_add (slurmd_job_t *job, pid_t pid)
+extern int slurm_container_plugin_add (slurmd_job_t *job, pid_t pid)
 {
 	return SLURM_SUCCESS;
 }
 
 /*
- * slurm_container_signal assumes that the slurmd jobstep manager
+ * slurm_container_plugin_signal assumes that the slurmd jobstep manager
  * is always the last process in the rms program description.
  * No signals are sent to the last process.
  */
-extern int slurm_container_signal  (uint32_t id, int signal)
+extern int slurm_container_plugin_signal  (uint32_t id, int signal)
 {
 	pid_t *pids;
 	int nids = 0;
@@ -165,20 +165,20 @@ extern int slurm_container_signal  (uint32_t id, int signal)
  * returns SLURM_SUCCESS when the program description contains one and
  * only one process, assumed to be the slurmd jobstep manager.
  */
-extern int slurm_container_destroy (uint32_t id)
+extern int slurm_container_plugin_destroy (uint32_t id)
 {
 	debug2("proctrack/rms: destroying container %u", id);
 	if (id == 0)
 		return SLURM_SUCCESS;
 
-	if (slurm_container_signal(id, 0) == -1)
+	if (slurm_container_plugin_signal(id, 0) == -1)
 		return SLURM_SUCCESS;
 
 	return SLURM_ERROR;
 }
 
 
-extern uint32_t slurm_container_find (pid_t pid)
+extern uint32_t slurm_container_plugin_find (pid_t pid)
 {
 	int prgid = 0;
 
@@ -187,7 +187,7 @@ extern uint32_t slurm_container_find (pid_t pid)
 	return (uint32_t) prgid;
 }
 
-extern bool slurm_container_has_pid (uint32_t cont_id, pid_t pid)
+extern bool slurm_container_plugin_has_pid (uint32_t cont_id, pid_t pid)
 {
 	int prgid = 0;
 
@@ -200,7 +200,7 @@ extern bool slurm_container_has_pid (uint32_t cont_id, pid_t pid)
 }
 
 extern int
-slurm_container_wait(uint32_t cont_id)
+slurm_container_plugin_wait(uint32_t cont_id)
 {
 	int delay = 1;
 
@@ -210,8 +210,8 @@ slurm_container_wait(uint32_t cont_id)
 	}
 
 	/* Spin until the container is empty */
-	while (slurm_container_signal(cont_id, 0) != -1) {
-		slurm_container_signal(cont_id, SIGKILL);
+	while (slurm_container_plugin_signal(cont_id, 0) != -1) {
+		slurm_container_plugin_signal(cont_id, SIGKILL);
 		sleep(delay);
 		if (delay < 120) {
 			delay *= 2;
@@ -229,7 +229,7 @@ slurm_container_wait(uint32_t cont_id)
  * the slurmstepd in the list of pids that we return.
  */
 extern int
-slurm_container_get_pids(uint32_t cont_id, pid_t **pids, int *npids)
+slurm_container_plugin_get_pids(uint32_t cont_id, pid_t **pids, int *npids)
 {
 	pid_t *p;
 	int np;
diff --git a/src/plugins/proctrack/sgi_job/proctrack_sgi_job.c b/src/plugins/proctrack/sgi_job/proctrack_sgi_job.c
index 2295503afac5a96886de475d16ec522c503fac7f..2f7ead07888caef6117f7d37989f1061a05fb3fc 100644
--- a/src/plugins/proctrack/sgi_job/proctrack_sgi_job.c
+++ b/src/plugins/proctrack/sgi_job/proctrack_sgi_job.c
@@ -192,7 +192,7 @@ int _job_getpidcnt (jid_t jid)
 	return ((*job_ops.getpidcnt) (jid));
 }
 
-int slurm_container_create (slurmd_job_t *job)
+int slurm_container_plugin_create (slurmd_job_t *job)
 {
 	jid_t jid;
 	job->cont_id = (uint32_t) -1;
@@ -209,7 +209,7 @@ int slurm_container_create (slurmd_job_t *job)
 	return SLURM_SUCCESS;
 }
 
-int slurm_container_add (slurmd_job_t *job, pid_t pid)
+int slurm_container_plugin_add (slurmd_job_t *job, pid_t pid)
 {
 	if (job->cont_id == (uint32_t) -1) {
 		job->cont_id = (uint32_t) _job_getjid (getpid());
@@ -225,7 +225,7 @@ int slurm_container_add (slurmd_job_t *job, pid_t pid)
 	return SLURM_SUCCESS;
 }
 
-int slurm_container_signal (uint32_t id, int sig)
+int slurm_container_plugin_signal (uint32_t id, int sig)
 {
 	if ( (_job_killjid ((jid_t) id, sig) < 0)
 	   && (errno != ENODATA) && (errno != EBADF) )
@@ -233,7 +233,7 @@ int slurm_container_signal (uint32_t id, int sig)
 	return (SLURM_SUCCESS);
 }
 
-int slurm_container_destroy (uint32_t id)
+int slurm_container_plugin_destroy (uint32_t id)
 {
 	int status;
 	_job_waitjid ((jid_t) id, &status, 0);
@@ -243,7 +243,7 @@ int slurm_container_destroy (uint32_t id)
 	return SLURM_SUCCESS;
 }
 
-uint32_t slurm_container_find (pid_t pid)
+uint32_t slurm_container_plugin_find (pid_t pid)
 {
 	jid_t jid;
 
@@ -253,7 +253,7 @@ uint32_t slurm_container_find (pid_t pid)
 	return ((uint32_t) jid);
 }
 
-bool slurm_container_has_pid (uint32_t cont_id, pid_t pid)
+bool slurm_container_plugin_has_pid (uint32_t cont_id, pid_t pid)
 {
 	jid_t jid;
 
@@ -265,7 +265,7 @@ bool slurm_container_has_pid (uint32_t cont_id, pid_t pid)
 	return true;
 }
 
-int slurm_container_wait (uint32_t id)
+int slurm_container_plugin_wait (uint32_t id)
 {
 	int status;
 	if (_job_waitjid ((jid_t) id, &status, 0) == (jid_t)-1)
@@ -274,7 +274,7 @@ int slurm_container_wait (uint32_t id)
 	return SLURM_SUCCESS;
 }
 
-int slurm_container_get_pids(uint32_t cont_id, pid_t **pids, int *npids)
+int slurm_container_plugin_get_pids(uint32_t cont_id, pid_t **pids, int *npids)
 {
 	int pidcnt, bufsize;
 	pid_t *p;
diff --git a/src/slurmctld/Makefile.am b/src/slurmctld/Makefile.am
index 79a6375eb4254098801c4a64c07c6995716ef595..2ee3f018d8d246d7cdf6ed8cc81339ca168c25b5 100644
--- a/src/slurmctld/Makefile.am
+++ b/src/slurmctld/Makefile.am
@@ -6,14 +6,10 @@ CLEANFILES = core.*
 
 INCLUDES = -I$(top_srcdir) $(BG_INCLUDES)
 
-sbin_PROGRAMS = slurmctld
-
-slurmctld_LDADD = 					\
-	$(top_builddir)/src/common/libdaemonize.la  \
-	$(top_builddir)/src/api/libslurm.o -ldl
-
-
-slurmctld_SOURCES = 	\
+# noinst_LTLIBRARIES = libslurmctld.la
+# libslurmctld_la_LDFLAGS  = $(LIB_LDFLAGS) -module --export-dynamic
+# libslurmctld_la_SOURCES =
+slurmctld_SOURCES =     \
 	acct_policy.c	\
 	acct_policy.h	\
 	agent.c  	\
@@ -63,8 +59,13 @@ slurmctld_SOURCES = 	\
 	trigger_mgr.c	\
 	trigger_mgr.h
 
-slurmctld_LDFLAGS = -export-dynamic $(CMD_LDFLAGS)
 
+sbin_PROGRAMS = slurmctld
+
+slurmctld_LDADD = 				    \
+	$(top_builddir)/src/common/libdaemonize.la  \
+	$(top_builddir)/src/api/libslurm.o -ldl
+slurmctld_LDFLAGS = -export-dynamic $(CMD_LDFLAGS)
 
 force:
 $(slurmctld_LDADD) : force
diff --git a/src/slurmctld/Makefile.in b/src/slurmctld/Makefile.in
index 75d9d02c7a41a328ed673ac51216d99cf161c912..3df91053c3d395bcbbdc254f66071e407024fae8 100644
--- a/src/slurmctld/Makefile.in
+++ b/src/slurmctld/Makefile.in
@@ -314,10 +314,10 @@ top_srcdir = @top_srcdir@
 AUTOMAKE_OPTIONS = foreign
 CLEANFILES = core.*
 INCLUDES = -I$(top_srcdir) $(BG_INCLUDES)
-slurmctld_LDADD = \
-	$(top_builddir)/src/common/libdaemonize.la  \
-	$(top_builddir)/src/api/libslurm.o -ldl
 
+# noinst_LTLIBRARIES = libslurmctld.la
+# libslurmctld_la_LDFLAGS  = $(LIB_LDFLAGS) -module --export-dynamic
+# libslurmctld_la_SOURCES =
 slurmctld_SOURCES = \
 	acct_policy.c	\
 	acct_policy.h	\
@@ -368,6 +368,10 @@ slurmctld_SOURCES = \
 	trigger_mgr.c	\
 	trigger_mgr.h
 
+slurmctld_LDADD = \
+	$(top_builddir)/src/common/libdaemonize.la  \
+	$(top_builddir)/src/api/libslurm.o -ldl
+
 slurmctld_LDFLAGS = -export-dynamic $(CMD_LDFLAGS)
 all: all-am
 
diff --git a/src/slurmctld/groups.c b/src/slurmctld/groups.c
index c0ad117d6653b0d7b46465b9636023131087e919..fdc831b47dc9d57600b52aa1dbaf90e0bdfafff2 100644
--- a/src/slurmctld/groups.c
+++ b/src/slurmctld/groups.c
@@ -93,7 +93,7 @@ extern uid_t *get_group_members(char *group_name)
 	int i, j, uid_cnt;
 #ifdef HAVE_AIX
 	FILE *fp = NULL;
-#elif defined (__APPLE__)
+#elif defined (__APPLE__) || defined (__CYGWIN__)
 #else
 	char pw_buffer[PW_BUF_SIZE];
 	struct passwd pw;
@@ -121,7 +121,7 @@ extern uid_t *get_group_members(char *group_name)
 	setgrent_r(&fp);
 	while (!getgrent_r(&grp, grp_buffer, PW_BUF_SIZE, &fp)) {
 		grp_result = &grp;
-#elif defined (__APPLE__)
+#elif defined (__APPLE__) || defined (__CYGWIN__)
 	setgrent();
 	while ((grp_result = getgrent()) != NULL) {
 #else
@@ -166,7 +166,7 @@ extern uid_t *get_group_members(char *group_name)
 	setpwent();
 #if defined (__sun)
 	while ((pwd_result = getpwent_r(&pw, pw_buffer, PW_BUF_SIZE)) != NULL) {
-#elif defined (__APPLE__)
+#elif defined (__APPLE__) || defined (__CYGWIN__)
 	while ((pwd_result = getpwent()) != NULL) {
 #else
 	while (!getpwent_r(&pw, pw_buffer, PW_BUF_SIZE, &pwd_result)) {
diff --git a/src/slurmd/Makefile.am b/src/slurmd/Makefile.am
index 89380c8715fba21c850a33cea61ad7a2ed6d1d38..ca7d43aa3b5f7cccf02494b170e0c60d21651a70 100644
--- a/src/slurmd/Makefile.am
+++ b/src/slurmd/Makefile.am
@@ -1,2 +1,2 @@
 
-SUBDIRS = slurmd slurmstepd
+SUBDIRS = common slurmd slurmstepd
diff --git a/src/slurmd/Makefile.in b/src/slurmd/Makefile.in
index 896b7dbb71bc7717eb00b80626f3bb6ad6fa61e6..32a8825c12d0468075ca4c596710ed7518d2995c 100644
--- a/src/slurmd/Makefile.in
+++ b/src/slurmd/Makefile.in
@@ -312,7 +312,7 @@ target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
-SUBDIRS = slurmd slurmstepd
+SUBDIRS = common slurmd slurmstepd
 all: all-recursive
 
 .SUFFIXES:
diff --git a/src/slurmd/common/Makefile.am b/src/slurmd/common/Makefile.am
new file mode 100644
index 0000000000000000000000000000000000000000..dda570360c7755a03957b8cd940c69f8ed1a56e1
--- /dev/null
+++ b/src/slurmd/common/Makefile.am
@@ -0,0 +1,18 @@
+# Makefile.am for slurmd/common
+
+AUTOMAKE_OPTIONS = foreign
+CLEANFILES = core.*
+
+INCLUDES = -I$(top_srcdir)
+
+# making a .la
+
+noinst_LTLIBRARIES = libslurmd_common.la
+libslurmd_common_la_SOURCES =    \
+	proctrack.c proctrack.h \
+	setproctitle.c setproctitle.h \
+	slurmstepd_init.c slurmstepd_init.h \
+	run_script.c run_script.h \
+	task_plugin.c task_plugin.h \
+	set_oomadj.c set_oomadj.h \
+	reverse_tree.h
diff --git a/src/slurmd/common/Makefile.in b/src/slurmd/common/Makefile.in
new file mode 100644
index 0000000000000000000000000000000000000000..756ddcfc6cae5268ac1bb4db14b3b8577480b079
--- /dev/null
+++ b/src/slurmd/common/Makefile.in
@@ -0,0 +1,600 @@
+# Makefile.in generated by automake 1.11.1 from Makefile.am.
+# @configure_input@
+
+# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
+# 2003, 2004, 2005, 2006, 2007, 2008, 2009  Free Software Foundation,
+# Inc.
+# This Makefile.in is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
+# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+# PARTICULAR PURPOSE.
+
+@SET_MAKE@
+
+# Makefile.am for slurmd/common
+
+VPATH = @srcdir@
+pkgdatadir = $(datadir)/@PACKAGE@
+pkgincludedir = $(includedir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkglibexecdir = $(libexecdir)/@PACKAGE@
+am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
+install_sh_DATA = $(install_sh) -c -m 644
+install_sh_PROGRAM = $(install_sh) -c
+install_sh_SCRIPT = $(install_sh) -c
+INSTALL_HEADER = $(INSTALL_DATA)
+transform = $(program_transform_name)
+NORMAL_INSTALL = :
+PRE_INSTALL = :
+POST_INSTALL = :
+NORMAL_UNINSTALL = :
+PRE_UNINSTALL = :
+POST_UNINSTALL = :
+build_triplet = @build@
+host_triplet = @host@
+target_triplet = @target@
+subdir = src/slurmd/common
+DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
+ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
+am__aclocal_m4_deps = $(top_srcdir)/auxdir/acx_pthread.m4 \
+	$(top_srcdir)/auxdir/libtool.m4 \
+	$(top_srcdir)/auxdir/ltoptions.m4 \
+	$(top_srcdir)/auxdir/ltsugar.m4 \
+	$(top_srcdir)/auxdir/ltversion.m4 \
+	$(top_srcdir)/auxdir/lt~obsolete.m4 \
+	$(top_srcdir)/auxdir/slurm.m4 \
+	$(top_srcdir)/auxdir/x_ac__system_configuration.m4 \
+	$(top_srcdir)/auxdir/x_ac_affinity.m4 \
+	$(top_srcdir)/auxdir/x_ac_aix.m4 \
+	$(top_srcdir)/auxdir/x_ac_blcr.m4 \
+	$(top_srcdir)/auxdir/x_ac_bluegene.m4 \
+	$(top_srcdir)/auxdir/x_ac_cflags.m4 \
+	$(top_srcdir)/auxdir/x_ac_cray.m4 \
+	$(top_srcdir)/auxdir/x_ac_databases.m4 \
+	$(top_srcdir)/auxdir/x_ac_debug.m4 \
+	$(top_srcdir)/auxdir/x_ac_elan.m4 \
+	$(top_srcdir)/auxdir/x_ac_env.m4 \
+	$(top_srcdir)/auxdir/x_ac_federation.m4 \
+	$(top_srcdir)/auxdir/x_ac_gpl_licensed.m4 \
+	$(top_srcdir)/auxdir/x_ac_hwloc.m4 \
+	$(top_srcdir)/auxdir/x_ac_iso.m4 \
+	$(top_srcdir)/auxdir/x_ac_lua.m4 \
+	$(top_srcdir)/auxdir/x_ac_munge.m4 \
+	$(top_srcdir)/auxdir/x_ac_ncurses.m4 \
+	$(top_srcdir)/auxdir/x_ac_pam.m4 \
+	$(top_srcdir)/auxdir/x_ac_printf_null.m4 \
+	$(top_srcdir)/auxdir/x_ac_ptrace.m4 \
+	$(top_srcdir)/auxdir/x_ac_readline.m4 \
+	$(top_srcdir)/auxdir/x_ac_setpgrp.m4 \
+	$(top_srcdir)/auxdir/x_ac_setproctitle.m4 \
+	$(top_srcdir)/auxdir/x_ac_sgi_job.m4 \
+	$(top_srcdir)/auxdir/x_ac_slurm_ssl.m4 \
+	$(top_srcdir)/auxdir/x_ac_sun_const.m4 \
+	$(top_srcdir)/auxdir/x_ac_xcpu.m4 $(top_srcdir)/configure.ac
+am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
+	$(ACLOCAL_M4)
+mkinstalldirs = $(install_sh) -d
+CONFIG_HEADER = $(top_builddir)/config.h $(top_builddir)/slurm/slurm.h
+CONFIG_CLEAN_FILES =
+CONFIG_CLEAN_VPATH_FILES =
+LTLIBRARIES = $(noinst_LTLIBRARIES)
+libslurmd_common_la_LIBADD =
+am_libslurmd_common_la_OBJECTS = proctrack.lo setproctitle.lo \
+	slurmstepd_init.lo run_script.lo task_plugin.lo set_oomadj.lo
+libslurmd_common_la_OBJECTS = $(am_libslurmd_common_la_OBJECTS)
+DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) -I$(top_builddir)/slurm
+depcomp = $(SHELL) $(top_srcdir)/auxdir/depcomp
+am__depfiles_maybe = depfiles
+am__mv = mv -f
+COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
+	$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
+	--mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
+	$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+CCLD = $(CC)
+LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
+	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
+	$(LDFLAGS) -o $@
+SOURCES = $(libslurmd_common_la_SOURCES)
+DIST_SOURCES = $(libslurmd_common_la_SOURCES)
+ETAGS = etags
+CTAGS = ctags
+DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
+ACLOCAL = @ACLOCAL@
+AMTAR = @AMTAR@
+AR = @AR@
+AUTHD_CFLAGS = @AUTHD_CFLAGS@
+AUTHD_LIBS = @AUTHD_LIBS@
+AUTOCONF = @AUTOCONF@
+AUTOHEADER = @AUTOHEADER@
+AUTOMAKE = @AUTOMAKE@
+AWK = @AWK@
+BGL_LOADED = @BGL_LOADED@
+BG_INCLUDES = @BG_INCLUDES@
+BLCR_CPPFLAGS = @BLCR_CPPFLAGS@
+BLCR_HOME = @BLCR_HOME@
+BLCR_LDFLAGS = @BLCR_LDFLAGS@
+BLCR_LIBS = @BLCR_LIBS@
+BLUEGENE_LOADED = @BLUEGENE_LOADED@
+CC = @CC@
+CCDEPMODE = @CCDEPMODE@
+CFLAGS = @CFLAGS@
+CMD_LDFLAGS = @CMD_LDFLAGS@
+CPP = @CPP@
+CPPFLAGS = @CPPFLAGS@
+CXX = @CXX@
+CXXCPP = @CXXCPP@
+CXXDEPMODE = @CXXDEPMODE@
+CXXFLAGS = @CXXFLAGS@
+CYGPATH_W = @CYGPATH_W@
+DEFS = @DEFS@
+DEPDIR = @DEPDIR@
+DSYMUTIL = @DSYMUTIL@
+DUMPBIN = @DUMPBIN@
+ECHO_C = @ECHO_C@
+ECHO_N = @ECHO_N@
+ECHO_T = @ECHO_T@
+EGREP = @EGREP@
+ELAN_LIBS = @ELAN_LIBS@
+EXEEXT = @EXEEXT@
+FEDERATION_LDFLAGS = @FEDERATION_LDFLAGS@
+FGREP = @FGREP@
+GREP = @GREP@
+GTK_CFLAGS = @GTK_CFLAGS@
+GTK_LIBS = @GTK_LIBS@
+HAVEMYSQLCONFIG = @HAVEMYSQLCONFIG@
+HAVEPGCONFIG = @HAVEPGCONFIG@
+HAVE_AIX = @HAVE_AIX@
+HAVE_ELAN = @HAVE_ELAN@
+HAVE_FEDERATION = @HAVE_FEDERATION@
+HAVE_OPENSSL = @HAVE_OPENSSL@
+HAVE_SOME_CURSES = @HAVE_SOME_CURSES@
+HWLOC_CPPFLAGS = @HWLOC_CPPFLAGS@
+HWLOC_LDFLAGS = @HWLOC_LDFLAGS@
+HWLOC_LIBS = @HWLOC_LIBS@
+INSTALL = @INSTALL@
+INSTALL_DATA = @INSTALL_DATA@
+INSTALL_PROGRAM = @INSTALL_PROGRAM@
+INSTALL_SCRIPT = @INSTALL_SCRIPT@
+INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
+LD = @LD@
+LDFLAGS = @LDFLAGS@
+LIBOBJS = @LIBOBJS@
+LIBS = @LIBS@
+LIBTOOL = @LIBTOOL@
+LIB_LDFLAGS = @LIB_LDFLAGS@
+LIPO = @LIPO@
+LN_S = @LN_S@
+LTLIBOBJS = @LTLIBOBJS@
+MAINT = @MAINT@
+MAKEINFO = @MAKEINFO@
+MKDIR_P = @MKDIR_P@
+MUNGE_CPPFLAGS = @MUNGE_CPPFLAGS@
+MUNGE_LDFLAGS = @MUNGE_LDFLAGS@
+MUNGE_LIBS = @MUNGE_LIBS@
+MYSQL_CFLAGS = @MYSQL_CFLAGS@
+MYSQL_LIBS = @MYSQL_LIBS@
+NCURSES = @NCURSES@
+NM = @NM@
+NMEDIT = @NMEDIT@
+NUMA_LIBS = @NUMA_LIBS@
+OBJDUMP = @OBJDUMP@
+OBJEXT = @OBJEXT@
+OTOOL = @OTOOL@
+OTOOL64 = @OTOOL64@
+PACKAGE = @PACKAGE@
+PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
+PACKAGE_NAME = @PACKAGE_NAME@
+PACKAGE_STRING = @PACKAGE_STRING@
+PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_URL = @PACKAGE_URL@
+PACKAGE_VERSION = @PACKAGE_VERSION@
+PAM_DIR = @PAM_DIR@
+PAM_LIBS = @PAM_LIBS@
+PATH_SEPARATOR = @PATH_SEPARATOR@
+PGSQL_CFLAGS = @PGSQL_CFLAGS@
+PGSQL_LIBS = @PGSQL_LIBS@
+PKG_CONFIG = @PKG_CONFIG@
+PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@
+PKG_CONFIG_PATH = @PKG_CONFIG_PATH@
+PROCTRACKDIR = @PROCTRACKDIR@
+PROJECT = @PROJECT@
+PTHREAD_CC = @PTHREAD_CC@
+PTHREAD_CFLAGS = @PTHREAD_CFLAGS@
+PTHREAD_LIBS = @PTHREAD_LIBS@
+RANLIB = @RANLIB@
+READLINE_LIBS = @READLINE_LIBS@
+RELEASE = @RELEASE@
+SED = @SED@
+SEMAPHORE_LIBS = @SEMAPHORE_LIBS@
+SEMAPHORE_SOURCES = @SEMAPHORE_SOURCES@
+SET_MAKE = @SET_MAKE@
+SHELL = @SHELL@
+SLURMCTLD_PORT = @SLURMCTLD_PORT@
+SLURMCTLD_PORT_COUNT = @SLURMCTLD_PORT_COUNT@
+SLURMDBD_PORT = @SLURMDBD_PORT@
+SLURMD_PORT = @SLURMD_PORT@
+SLURM_API_AGE = @SLURM_API_AGE@
+SLURM_API_CURRENT = @SLURM_API_CURRENT@
+SLURM_API_MAJOR = @SLURM_API_MAJOR@
+SLURM_API_REVISION = @SLURM_API_REVISION@
+SLURM_API_VERSION = @SLURM_API_VERSION@
+SLURM_MAJOR = @SLURM_MAJOR@
+SLURM_MICRO = @SLURM_MICRO@
+SLURM_MINOR = @SLURM_MINOR@
+SLURM_PREFIX = @SLURM_PREFIX@
+SLURM_VERSION_NUMBER = @SLURM_VERSION_NUMBER@
+SLURM_VERSION_STRING = @SLURM_VERSION_STRING@
+SO_LDFLAGS = @SO_LDFLAGS@
+SSL_CPPFLAGS = @SSL_CPPFLAGS@
+SSL_LDFLAGS = @SSL_LDFLAGS@
+SSL_LIBS = @SSL_LIBS@
+STRIP = @STRIP@
+UTIL_LIBS = @UTIL_LIBS@
+VERSION = @VERSION@
+abs_builddir = @abs_builddir@
+abs_srcdir = @abs_srcdir@
+abs_top_builddir = @abs_top_builddir@
+abs_top_srcdir = @abs_top_srcdir@
+ac_ct_CC = @ac_ct_CC@
+ac_ct_CXX = @ac_ct_CXX@
+ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
+am__include = @am__include@
+am__leading_dot = @am__leading_dot@
+am__quote = @am__quote@
+am__tar = @am__tar@
+am__untar = @am__untar@
+bindir = @bindir@
+build = @build@
+build_alias = @build_alias@
+build_cpu = @build_cpu@
+build_os = @build_os@
+build_vendor = @build_vendor@
+builddir = @builddir@
+datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
+exec_prefix = @exec_prefix@
+host = @host@
+host_alias = @host_alias@
+host_cpu = @host_cpu@
+host_os = @host_os@
+host_vendor = @host_vendor@
+htmldir = @htmldir@
+includedir = @includedir@
+infodir = @infodir@
+install_sh = @install_sh@
+libdir = @libdir@
+libexecdir = @libexecdir@
+localedir = @localedir@
+localstatedir = @localstatedir@
+lt_ECHO = @lt_ECHO@
+lua_CFLAGS = @lua_CFLAGS@
+lua_LIBS = @lua_LIBS@
+mandir = @mandir@
+mkdir_p = @mkdir_p@
+oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
+prefix = @prefix@
+program_transform_name = @program_transform_name@
+psdir = @psdir@
+sbindir = @sbindir@
+sharedstatedir = @sharedstatedir@
+srcdir = @srcdir@
+sysconfdir = @sysconfdir@
+target = @target@
+target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
+top_build_prefix = @top_build_prefix@
+top_builddir = @top_builddir@
+top_srcdir = @top_srcdir@
+AUTOMAKE_OPTIONS = foreign
+CLEANFILES = core.*
+INCLUDES = -I$(top_srcdir)
+
+# making a .la
+noinst_LTLIBRARIES = libslurmd_common.la
+libslurmd_common_la_SOURCES = \
+	proctrack.c proctrack.h \
+	setproctitle.c setproctitle.h \
+	slurmstepd_init.c slurmstepd_init.h \
+	run_script.c run_script.h \
+	task_plugin.c task_plugin.h \
+	set_oomadj.c set_oomadj.h \
+	reverse_tree.h
+
+all: all-am
+
+.SUFFIXES:
+.SUFFIXES: .c .lo .o .obj
+$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am  $(am__configure_deps)
+	@for dep in $?; do \
+	  case '$(am__configure_deps)' in \
+	    *$$dep*) \
+	      ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
+	        && { if test -f $@; then exit 0; else break; fi; }; \
+	      exit 1;; \
+	  esac; \
+	done; \
+	echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign src/slurmd/common/Makefile'; \
+	$(am__cd) $(top_srcdir) && \
+	  $(AUTOMAKE) --foreign src/slurmd/common/Makefile
+.PRECIOUS: Makefile
+Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
+	@case '$?' in \
+	  *config.status*) \
+	    cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
+	  *) \
+	    echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
+	    cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
+	esac;
+
+$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
+	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+
+$(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
+	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
+	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(am__aclocal_m4_deps):
+
+clean-noinstLTLIBRARIES:
+	-test -z "$(noinst_LTLIBRARIES)" || rm -f $(noinst_LTLIBRARIES)
+	@list='$(noinst_LTLIBRARIES)'; for p in $$list; do \
+	  dir="`echo $$p | sed -e 's|/[^/]*$$||'`"; \
+	  test "$$dir" != "$$p" || dir=.; \
+	  echo "rm -f \"$${dir}/so_locations\""; \
+	  rm -f "$${dir}/so_locations"; \
+	done
+libslurmd_common.la: $(libslurmd_common_la_OBJECTS) $(libslurmd_common_la_DEPENDENCIES) 
+	$(LINK)  $(libslurmd_common_la_OBJECTS) $(libslurmd_common_la_LIBADD) $(LIBS)
+
+mostlyclean-compile:
+	-rm -f *.$(OBJEXT)
+
+distclean-compile:
+	-rm -f *.tab.c
+
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/proctrack.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/run_script.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/set_oomadj.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/setproctitle.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/slurmstepd_init.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/task_plugin.Plo@am__quote@
+
+.c.o:
+@am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+@am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+@AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@	$(COMPILE) -c $<
+
+.c.obj:
+@am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
+@am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+@AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@	$(COMPILE) -c `$(CYGPATH_W) '$<'`
+
+.c.lo:
+@am__fastdepCC_TRUE@	$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+@am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+@AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@	$(LTCOMPILE) -c -o $@ $<
+
+mostlyclean-libtool:
+	-rm -f *.lo
+
+clean-libtool:
+	-rm -rf .libs _libs
+
+ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
+	list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
+	unique=`for i in $$list; do \
+	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+	  done | \
+	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
+	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+	mkid -fID $$unique
+tags: TAGS
+
+TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
+		$(TAGS_FILES) $(LISP)
+	set x; \
+	here=`pwd`; \
+	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
+	unique=`for i in $$list; do \
+	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+	  done | \
+	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
+	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+	shift; \
+	if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
+	  test -n "$$unique" || unique=$$empty_fix; \
+	  if test $$# -gt 0; then \
+	    $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+	      "$$@" $$unique; \
+	  else \
+	    $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+	      $$unique; \
+	  fi; \
+	fi
+ctags: CTAGS
+CTAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
+		$(TAGS_FILES) $(LISP)
+	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
+	unique=`for i in $$list; do \
+	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+	  done | \
+	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
+	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+	test -z "$(CTAGS_ARGS)$$unique" \
+	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
+	     $$unique
+
+GTAGS:
+	here=`$(am__cd) $(top_builddir) && pwd` \
+	  && $(am__cd) $(top_srcdir) \
+	  && gtags -i $(GTAGS_ARGS) "$$here"
+
+distclean-tags:
+	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
+
+distdir: $(DISTFILES)
+	@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+	topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+	list='$(DISTFILES)'; \
+	  dist_files=`for file in $$list; do echo $$file; done | \
+	  sed -e "s|^$$srcdirstrip/||;t" \
+	      -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
+	case $$dist_files in \
+	  */*) $(MKDIR_P) `echo "$$dist_files" | \
+			   sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
+			   sort -u` ;; \
+	esac; \
+	for file in $$dist_files; do \
+	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
+	  if test -d $$d/$$file; then \
+	    dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+	    if test -d "$(distdir)/$$file"; then \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+	    fi; \
+	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
+	      cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+	    fi; \
+	    cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
+	  else \
+	    test -f "$(distdir)/$$file" \
+	    || cp -p $$d/$$file "$(distdir)/$$file" \
+	    || exit 1; \
+	  fi; \
+	done
+check-am: all-am
+check: check-am
+all-am: Makefile $(LTLIBRARIES)
+installdirs:
+install: install-am
+install-exec: install-exec-am
+install-data: install-data-am
+uninstall: uninstall-am
+
+install-am: all-am
+	@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
+
+installcheck: installcheck-am
+install-strip:
+	$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+	  install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+	  `test -z '$(STRIP)' || \
+	    echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install
+mostlyclean-generic:
+
+clean-generic:
+	-test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
+
+distclean-generic:
+	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+	-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
+
+maintainer-clean-generic:
+	@echo "This command is intended for maintainers to use"
+	@echo "it deletes files that may require special tools to rebuild."
+clean: clean-am
+
+clean-am: clean-generic clean-libtool clean-noinstLTLIBRARIES \
+	mostlyclean-am
+
+distclean: distclean-am
+	-rm -rf ./$(DEPDIR)
+	-rm -f Makefile
+distclean-am: clean-am distclean-compile distclean-generic \
+	distclean-tags
+
+dvi: dvi-am
+
+dvi-am:
+
+html: html-am
+
+html-am:
+
+info: info-am
+
+info-am:
+
+install-data-am:
+
+install-dvi: install-dvi-am
+
+install-dvi-am:
+
+install-exec-am:
+
+install-html: install-html-am
+
+install-html-am:
+
+install-info: install-info-am
+
+install-info-am:
+
+install-man:
+
+install-pdf: install-pdf-am
+
+install-pdf-am:
+
+install-ps: install-ps-am
+
+install-ps-am:
+
+installcheck-am:
+
+maintainer-clean: maintainer-clean-am
+	-rm -rf ./$(DEPDIR)
+	-rm -f Makefile
+maintainer-clean-am: distclean-am maintainer-clean-generic
+
+mostlyclean: mostlyclean-am
+
+mostlyclean-am: mostlyclean-compile mostlyclean-generic \
+	mostlyclean-libtool
+
+pdf: pdf-am
+
+pdf-am:
+
+ps: ps-am
+
+ps-am:
+
+uninstall-am:
+
+.MAKE: install-am install-strip
+
+.PHONY: CTAGS GTAGS all all-am check check-am clean clean-generic \
+	clean-libtool clean-noinstLTLIBRARIES ctags distclean \
+	distclean-compile distclean-generic distclean-libtool \
+	distclean-tags distdir dvi dvi-am html html-am info info-am \
+	install install-am install-data install-data-am install-dvi \
+	install-dvi-am install-exec install-exec-am install-html \
+	install-html-am install-info install-info-am install-man \
+	install-pdf install-pdf-am install-ps install-ps-am \
+	install-strip installcheck installcheck-am installdirs \
+	maintainer-clean maintainer-clean-generic mostlyclean \
+	mostlyclean-compile mostlyclean-generic mostlyclean-libtool \
+	pdf pdf-am ps ps-am tags uninstall uninstall-am
+
+
+# Tell versions [3.59,3.63) of GNU make to not export all variables.
+# Otherwise a system limit (for SysV at least) may be exceeded.
+.NOEXPORT:
diff --git a/src/slurmd/common/proctrack.c b/src/slurmd/common/proctrack.c
index 4d3209b53e0b877a0f121fc3ee6d2c398a56667a..db64fceee7a3e4333c0ca8d56a112c666006f024 100644
--- a/src/slurmd/common/proctrack.c
+++ b/src/slurmd/common/proctrack.c
@@ -85,14 +85,14 @@ _proctrack_get_ops(slurm_proctrack_context_t * c)
 	 * Must be synchronized with slurm_proctrack_ops_t above.
 	 */
 	static const char *syms[] = {
-		"slurm_container_create",
-		"slurm_container_add",
-		"slurm_container_signal",
-		"slurm_container_destroy",
-		"slurm_container_find",
-		"slurm_container_has_pid",
-		"slurm_container_wait",
-		"slurm_container_get_pids"
+		"slurm_container_plugin_create",
+		"slurm_container_plugin_add",
+		"slurm_container_plugin_signal",
+		"slurm_container_plugin_destroy",
+		"slurm_container_plugin_find",
+		"slurm_container_plugin_has_pid",
+		"slurm_container_plugin_wait",
+		"slurm_container_plugin_get_pids"
 	};
 	int n_syms = sizeof(syms) / sizeof(char *);
 
diff --git a/src/slurmd/common/task_plugin.c b/src/slurmd/common/task_plugin.c
index d7f662a3a115d56ee1c7c6615b91447476ef1571..14319ebf10cafab3d075a3c59c3ad97eefedfbc2 100644
--- a/src/slurmd/common/task_plugin.c
+++ b/src/slurmd/common/task_plugin.c
@@ -48,21 +48,21 @@
 #include "src/slurmd/slurmstepd/slurmstepd_job.h"
 
 typedef struct slurmd_task_ops {
-	int	(*slurmd_batch_request)		(uint32_t job_id,
-						 batch_job_launch_msg_t *req);
-	int	(*slurmd_launch_request)	(uint32_t job_id,
-						 launch_tasks_request_msg_t *req,
-						 uint32_t node_id);
-	int	(*slurmd_reserve_resources)	(uint32_t job_id,
-						 launch_tasks_request_msg_t *req,
-						 uint32_t node_id);
-	int	(*slurmd_suspend_job)		(uint32_t job_id);
-	int	(*slurmd_resume_job)		(uint32_t job_id);
-	int	(*slurmd_release_resources)	(uint32_t job_id);
-
-	int	(*pre_setuid)			(slurmd_job_t *job);
-	int	(*pre_launch)			(slurmd_job_t *job);
-	int	(*post_term)			(slurmd_job_t *job);
+	int	(*slurmd_batch_request)	    (uint32_t job_id,
+					     batch_job_launch_msg_t *req);
+	int	(*slurmd_launch_request)    (uint32_t job_id,
+					     launch_tasks_request_msg_t *req,
+					     uint32_t node_id);
+	int	(*slurmd_reserve_resources) (uint32_t job_id,
+					     launch_tasks_request_msg_t *req,
+					     uint32_t node_id);
+	int	(*slurmd_suspend_job)	    (uint32_t job_id);
+	int	(*slurmd_resume_job)	    (uint32_t job_id);
+	int	(*slurmd_release_resources) (uint32_t job_id);
+
+	int	(*pre_setuid)		    (slurmd_job_t *job);
+	int	(*pre_launch)		    (slurmd_job_t *job);
+	int	(*post_term)		    (slurmd_job_t *job);
 } slurmd_task_ops_t;
 
 
diff --git a/src/slurmd/common/task_plugin.h b/src/slurmd/common/task_plugin.h
index 228fdf276a64cb13d338f0b610b99267c0973cbe..ee87917c64139b299e18a9d965f876af81896a88 100644
--- a/src/slurmd/common/task_plugin.h
+++ b/src/slurmd/common/task_plugin.h
@@ -6,32 +6,32 @@
  *  Produced at Lawrence Livermore National Laboratory (cf, DISCLAIMER).
  *  Written by Morris Jette <jette1@llnl.gov>
  *  CODE-OCEC-09-009. All rights reserved.
- *  
+ *
  *  This file is part of SLURM, a resource management program.
  *  For details, see <https://computing.llnl.gov/linux/slurm/>.
  *  Please also read the included file: DISCLAIMER.
- *  
+ *
  *  SLURM 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.
  *
- *  In addition, as a special exception, the copyright holders give permission 
- *  to link the code of portions of this program with the OpenSSL library under 
- *  certain conditions as described in each individual source file, and 
- *  distribute linked combinations including the two. You must obey the GNU 
- *  General Public License in all respects for all of the code used other than 
- *  OpenSSL. If you modify file(s) with this exception, you may extend this 
- *  exception to your version of the file(s), but you are not obligated to do 
+ *  In addition, as a special exception, the copyright holders give permission
+ *  to link the code of portions of this program with the OpenSSL library under
+ *  certain conditions as described in each individual source file, and
+ *  distribute linked combinations including the two. You must obey the GNU
+ *  General Public License in all respects for all of the code used other than
+ *  OpenSSL. If you modify file(s) with this exception, you may extend this
+ *  exception to your version of the file(s), but you are not obligated to do
  *  so. If you do not wish to do so, delete this exception statement from your
- *  version.  If you delete this exception statement from all source files in 
+ *  version.  If you delete this exception statement from all source files in
  *  the program, then also delete it here.
- *  
+ *
  *  SLURM 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 SLURM; if not, write to the Free Software Foundation, Inc.,
  *  51 Franklin Street, Fifth Floor, Boston, MA 02110-1301  USA.
@@ -51,7 +51,7 @@ extern int slurmd_task_init( void );
 
 /*
  * Terminate the task plugin, free memory.
- * 
+ *
  * RET - slurm error code
  */
 extern int slurmd_task_fini(void);
@@ -74,8 +74,8 @@ extern int slurmd_batch_request(uint32_t job_id, batch_job_launch_msg_t *req);
  *
  * RET - slurm error code
  */
-extern int slurmd_launch_request(uint32_t job_id, 
-				 launch_tasks_request_msg_t *req, 
+extern int slurmd_launch_request(uint32_t job_id,
+				 launch_tasks_request_msg_t *req,
 				 uint32_t node_id );
 
 /*
@@ -83,8 +83,8 @@ extern int slurmd_launch_request(uint32_t job_id,
  *
  * RET - slurm error code
  */
-extern int slurmd_reserve_resources(uint32_t job_id, 
-				    launch_tasks_request_msg_t *req, 
+extern int slurmd_reserve_resources(uint32_t job_id,
+				    launch_tasks_request_msg_t *req,
 				    uint32_t node_id );
 
 /*
@@ -131,4 +131,3 @@ extern int pre_launch(slurmd_job_t *job);
 extern int post_term(slurmd_job_t *job);
 
 #endif /* _SLURMD_TASK_PLUGIN_H_ */
-
diff --git a/src/slurmd/slurmd/Makefile.am b/src/slurmd/slurmd/Makefile.am
index 30afd9de102741828a72b1611392ed62a7da8daf..1cd8f85518c0242c73d98fc3606ac65bd7219d74 100644
--- a/src/slurmd/slurmd/Makefile.am
+++ b/src/slurmd/slurmd/Makefile.am
@@ -11,7 +11,8 @@ INCLUDES = -I$(top_srcdir)
 slurmd_LDADD = 					   \
 	$(top_builddir)/src/common/libdaemonize.la \
 	$(top_builddir)/src/api/libslurm.o -ldl	   \
-	$(PLPA_LIBS)
+	$(PLPA_LIBS) \
+	../common/libslurmd_common.la
 
 SLURMD_SOURCES = \
 	slurmd.c slurmd.h \
@@ -19,20 +20,7 @@ SLURMD_SOURCES = \
 	get_mach_stat.c get_mach_stat.h	\
 	read_proc.c 	        	\
 	reverse_tree_math.c reverse_tree_math.h \
-	xcpu.c xcpu.h			\
-	$(top_builddir)/src/slurmd/common/proctrack.c \
-	$(top_builddir)/src/slurmd/common/proctrack.h \
-	$(top_builddir)/src/slurmd/common/setproctitle.c \
-	$(top_builddir)/src/slurmd/common/setproctitle.h \
-	$(top_builddir)/src/slurmd/common/slurmstepd_init.c \
-	$(top_builddir)/src/slurmd/common/slurmstepd_init.h \
-	$(top_builddir)/src/slurmd/common/run_script.c \
-	$(top_builddir)/src/slurmd/common/run_script.h \
-	$(top_builddir)/src/slurmd/common/task_plugin.c \
-	$(top_builddir)/src/slurmd/common/task_plugin.h \
-	$(top_builddir)/src/slurmd/common/set_oomadj.c \
-	$(top_builddir)/src/slurmd/common/set_oomadj.h \
-	$(top_builddir)/src/slurmd/common/reverse_tree.h
+	xcpu.c xcpu.h
 
 slurmd_SOURCES = $(SLURMD_SOURCES)
 
diff --git a/src/slurmd/slurmd/Makefile.in b/src/slurmd/slurmd/Makefile.in
index 8b06bc3919e3e8f1234f5e2c52e436bcb461d21a..495b9ed498d6c78e46b1016084b312b97e36c0bd 100644
--- a/src/slurmd/slurmd/Makefile.in
+++ b/src/slurmd/slurmd/Makefile.in
@@ -86,14 +86,12 @@ CONFIG_CLEAN_VPATH_FILES =
 am__installdirs = "$(DESTDIR)$(sbindir)"
 PROGRAMS = $(sbin_PROGRAMS)
 am__objects_1 = slurmd.$(OBJEXT) req.$(OBJEXT) get_mach_stat.$(OBJEXT) \
-	read_proc.$(OBJEXT) reverse_tree_math.$(OBJEXT) xcpu.$(OBJEXT) \
-	proctrack.$(OBJEXT) setproctitle.$(OBJEXT) \
-	slurmstepd_init.$(OBJEXT) run_script.$(OBJEXT) \
-	task_plugin.$(OBJEXT) set_oomadj.$(OBJEXT)
+	read_proc.$(OBJEXT) reverse_tree_math.$(OBJEXT) xcpu.$(OBJEXT)
 am_slurmd_OBJECTS = $(am__objects_1)
 slurmd_OBJECTS = $(am_slurmd_OBJECTS)
 slurmd_DEPENDENCIES = $(top_builddir)/src/common/libdaemonize.la \
-	$(top_builddir)/src/api/libslurm.o
+	$(top_builddir)/src/api/libslurm.o \
+	../common/libslurmd_common.la
 slurmd_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
 	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(slurmd_LDFLAGS) \
 	$(LDFLAGS) -o $@
@@ -311,7 +309,8 @@ INCLUDES = -I$(top_srcdir)
 slurmd_LDADD = \
 	$(top_builddir)/src/common/libdaemonize.la \
 	$(top_builddir)/src/api/libslurm.o -ldl	   \
-	$(PLPA_LIBS)
+	$(PLPA_LIBS) \
+	../common/libslurmd_common.la
 
 SLURMD_SOURCES = \
 	slurmd.c slurmd.h \
@@ -319,20 +318,7 @@ SLURMD_SOURCES = \
 	get_mach_stat.c get_mach_stat.h	\
 	read_proc.c 	        	\
 	reverse_tree_math.c reverse_tree_math.h \
-	xcpu.c xcpu.h			\
-	$(top_builddir)/src/slurmd/common/proctrack.c \
-	$(top_builddir)/src/slurmd/common/proctrack.h \
-	$(top_builddir)/src/slurmd/common/setproctitle.c \
-	$(top_builddir)/src/slurmd/common/setproctitle.h \
-	$(top_builddir)/src/slurmd/common/slurmstepd_init.c \
-	$(top_builddir)/src/slurmd/common/slurmstepd_init.h \
-	$(top_builddir)/src/slurmd/common/run_script.c \
-	$(top_builddir)/src/slurmd/common/run_script.h \
-	$(top_builddir)/src/slurmd/common/task_plugin.c \
-	$(top_builddir)/src/slurmd/common/task_plugin.h \
-	$(top_builddir)/src/slurmd/common/set_oomadj.c \
-	$(top_builddir)/src/slurmd/common/set_oomadj.h \
-	$(top_builddir)/src/slurmd/common/reverse_tree.h
+	xcpu.c xcpu.h
 
 slurmd_SOURCES = $(SLURMD_SOURCES)
 @HAVE_AIX_FALSE@slurmd_LDFLAGS = -export-dynamic $(CMD_LDFLAGS)
@@ -428,16 +414,10 @@ distclean-compile:
 	-rm -f *.tab.c
 
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/get_mach_stat.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/proctrack.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/read_proc.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/req.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/reverse_tree_math.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/run_script.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/set_oomadj.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/setproctitle.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/slurmd.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/slurmstepd_init.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/task_plugin.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/xcpu.Po@am__quote@
 
 .c.o:
@@ -461,90 +441,6 @@ distclean-compile:
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @am__fastdepCC_FALSE@	$(LTCOMPILE) -c -o $@ $<
 
-proctrack.o: $(top_builddir)/src/slurmd/common/proctrack.c
-@am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT proctrack.o -MD -MP -MF $(DEPDIR)/proctrack.Tpo -c -o proctrack.o `test -f '$(top_builddir)/src/slurmd/common/proctrack.c' || echo '$(srcdir)/'`$(top_builddir)/src/slurmd/common/proctrack.c
-@am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/proctrack.Tpo $(DEPDIR)/proctrack.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_builddir)/src/slurmd/common/proctrack.c' object='proctrack.o' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o proctrack.o `test -f '$(top_builddir)/src/slurmd/common/proctrack.c' || echo '$(srcdir)/'`$(top_builddir)/src/slurmd/common/proctrack.c
-
-proctrack.obj: $(top_builddir)/src/slurmd/common/proctrack.c
-@am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT proctrack.obj -MD -MP -MF $(DEPDIR)/proctrack.Tpo -c -o proctrack.obj `if test -f '$(top_builddir)/src/slurmd/common/proctrack.c'; then $(CYGPATH_W) '$(top_builddir)/src/slurmd/common/proctrack.c'; else $(CYGPATH_W) '$(srcdir)/$(top_builddir)/src/slurmd/common/proctrack.c'; fi`
-@am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/proctrack.Tpo $(DEPDIR)/proctrack.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_builddir)/src/slurmd/common/proctrack.c' object='proctrack.obj' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o proctrack.obj `if test -f '$(top_builddir)/src/slurmd/common/proctrack.c'; then $(CYGPATH_W) '$(top_builddir)/src/slurmd/common/proctrack.c'; else $(CYGPATH_W) '$(srcdir)/$(top_builddir)/src/slurmd/common/proctrack.c'; fi`
-
-setproctitle.o: $(top_builddir)/src/slurmd/common/setproctitle.c
-@am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT setproctitle.o -MD -MP -MF $(DEPDIR)/setproctitle.Tpo -c -o setproctitle.o `test -f '$(top_builddir)/src/slurmd/common/setproctitle.c' || echo '$(srcdir)/'`$(top_builddir)/src/slurmd/common/setproctitle.c
-@am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/setproctitle.Tpo $(DEPDIR)/setproctitle.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_builddir)/src/slurmd/common/setproctitle.c' object='setproctitle.o' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o setproctitle.o `test -f '$(top_builddir)/src/slurmd/common/setproctitle.c' || echo '$(srcdir)/'`$(top_builddir)/src/slurmd/common/setproctitle.c
-
-setproctitle.obj: $(top_builddir)/src/slurmd/common/setproctitle.c
-@am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT setproctitle.obj -MD -MP -MF $(DEPDIR)/setproctitle.Tpo -c -o setproctitle.obj `if test -f '$(top_builddir)/src/slurmd/common/setproctitle.c'; then $(CYGPATH_W) '$(top_builddir)/src/slurmd/common/setproctitle.c'; else $(CYGPATH_W) '$(srcdir)/$(top_builddir)/src/slurmd/common/setproctitle.c'; fi`
-@am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/setproctitle.Tpo $(DEPDIR)/setproctitle.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_builddir)/src/slurmd/common/setproctitle.c' object='setproctitle.obj' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o setproctitle.obj `if test -f '$(top_builddir)/src/slurmd/common/setproctitle.c'; then $(CYGPATH_W) '$(top_builddir)/src/slurmd/common/setproctitle.c'; else $(CYGPATH_W) '$(srcdir)/$(top_builddir)/src/slurmd/common/setproctitle.c'; fi`
-
-slurmstepd_init.o: $(top_builddir)/src/slurmd/common/slurmstepd_init.c
-@am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT slurmstepd_init.o -MD -MP -MF $(DEPDIR)/slurmstepd_init.Tpo -c -o slurmstepd_init.o `test -f '$(top_builddir)/src/slurmd/common/slurmstepd_init.c' || echo '$(srcdir)/'`$(top_builddir)/src/slurmd/common/slurmstepd_init.c
-@am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/slurmstepd_init.Tpo $(DEPDIR)/slurmstepd_init.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_builddir)/src/slurmd/common/slurmstepd_init.c' object='slurmstepd_init.o' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o slurmstepd_init.o `test -f '$(top_builddir)/src/slurmd/common/slurmstepd_init.c' || echo '$(srcdir)/'`$(top_builddir)/src/slurmd/common/slurmstepd_init.c
-
-slurmstepd_init.obj: $(top_builddir)/src/slurmd/common/slurmstepd_init.c
-@am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT slurmstepd_init.obj -MD -MP -MF $(DEPDIR)/slurmstepd_init.Tpo -c -o slurmstepd_init.obj `if test -f '$(top_builddir)/src/slurmd/common/slurmstepd_init.c'; then $(CYGPATH_W) '$(top_builddir)/src/slurmd/common/slurmstepd_init.c'; else $(CYGPATH_W) '$(srcdir)/$(top_builddir)/src/slurmd/common/slurmstepd_init.c'; fi`
-@am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/slurmstepd_init.Tpo $(DEPDIR)/slurmstepd_init.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_builddir)/src/slurmd/common/slurmstepd_init.c' object='slurmstepd_init.obj' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o slurmstepd_init.obj `if test -f '$(top_builddir)/src/slurmd/common/slurmstepd_init.c'; then $(CYGPATH_W) '$(top_builddir)/src/slurmd/common/slurmstepd_init.c'; else $(CYGPATH_W) '$(srcdir)/$(top_builddir)/src/slurmd/common/slurmstepd_init.c'; fi`
-
-run_script.o: $(top_builddir)/src/slurmd/common/run_script.c
-@am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT run_script.o -MD -MP -MF $(DEPDIR)/run_script.Tpo -c -o run_script.o `test -f '$(top_builddir)/src/slurmd/common/run_script.c' || echo '$(srcdir)/'`$(top_builddir)/src/slurmd/common/run_script.c
-@am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/run_script.Tpo $(DEPDIR)/run_script.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_builddir)/src/slurmd/common/run_script.c' object='run_script.o' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o run_script.o `test -f '$(top_builddir)/src/slurmd/common/run_script.c' || echo '$(srcdir)/'`$(top_builddir)/src/slurmd/common/run_script.c
-
-run_script.obj: $(top_builddir)/src/slurmd/common/run_script.c
-@am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT run_script.obj -MD -MP -MF $(DEPDIR)/run_script.Tpo -c -o run_script.obj `if test -f '$(top_builddir)/src/slurmd/common/run_script.c'; then $(CYGPATH_W) '$(top_builddir)/src/slurmd/common/run_script.c'; else $(CYGPATH_W) '$(srcdir)/$(top_builddir)/src/slurmd/common/run_script.c'; fi`
-@am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/run_script.Tpo $(DEPDIR)/run_script.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_builddir)/src/slurmd/common/run_script.c' object='run_script.obj' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o run_script.obj `if test -f '$(top_builddir)/src/slurmd/common/run_script.c'; then $(CYGPATH_W) '$(top_builddir)/src/slurmd/common/run_script.c'; else $(CYGPATH_W) '$(srcdir)/$(top_builddir)/src/slurmd/common/run_script.c'; fi`
-
-task_plugin.o: $(top_builddir)/src/slurmd/common/task_plugin.c
-@am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT task_plugin.o -MD -MP -MF $(DEPDIR)/task_plugin.Tpo -c -o task_plugin.o `test -f '$(top_builddir)/src/slurmd/common/task_plugin.c' || echo '$(srcdir)/'`$(top_builddir)/src/slurmd/common/task_plugin.c
-@am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/task_plugin.Tpo $(DEPDIR)/task_plugin.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_builddir)/src/slurmd/common/task_plugin.c' object='task_plugin.o' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o task_plugin.o `test -f '$(top_builddir)/src/slurmd/common/task_plugin.c' || echo '$(srcdir)/'`$(top_builddir)/src/slurmd/common/task_plugin.c
-
-task_plugin.obj: $(top_builddir)/src/slurmd/common/task_plugin.c
-@am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT task_plugin.obj -MD -MP -MF $(DEPDIR)/task_plugin.Tpo -c -o task_plugin.obj `if test -f '$(top_builddir)/src/slurmd/common/task_plugin.c'; then $(CYGPATH_W) '$(top_builddir)/src/slurmd/common/task_plugin.c'; else $(CYGPATH_W) '$(srcdir)/$(top_builddir)/src/slurmd/common/task_plugin.c'; fi`
-@am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/task_plugin.Tpo $(DEPDIR)/task_plugin.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_builddir)/src/slurmd/common/task_plugin.c' object='task_plugin.obj' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o task_plugin.obj `if test -f '$(top_builddir)/src/slurmd/common/task_plugin.c'; then $(CYGPATH_W) '$(top_builddir)/src/slurmd/common/task_plugin.c'; else $(CYGPATH_W) '$(srcdir)/$(top_builddir)/src/slurmd/common/task_plugin.c'; fi`
-
-set_oomadj.o: $(top_builddir)/src/slurmd/common/set_oomadj.c
-@am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT set_oomadj.o -MD -MP -MF $(DEPDIR)/set_oomadj.Tpo -c -o set_oomadj.o `test -f '$(top_builddir)/src/slurmd/common/set_oomadj.c' || echo '$(srcdir)/'`$(top_builddir)/src/slurmd/common/set_oomadj.c
-@am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/set_oomadj.Tpo $(DEPDIR)/set_oomadj.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_builddir)/src/slurmd/common/set_oomadj.c' object='set_oomadj.o' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o set_oomadj.o `test -f '$(top_builddir)/src/slurmd/common/set_oomadj.c' || echo '$(srcdir)/'`$(top_builddir)/src/slurmd/common/set_oomadj.c
-
-set_oomadj.obj: $(top_builddir)/src/slurmd/common/set_oomadj.c
-@am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT set_oomadj.obj -MD -MP -MF $(DEPDIR)/set_oomadj.Tpo -c -o set_oomadj.obj `if test -f '$(top_builddir)/src/slurmd/common/set_oomadj.c'; then $(CYGPATH_W) '$(top_builddir)/src/slurmd/common/set_oomadj.c'; else $(CYGPATH_W) '$(srcdir)/$(top_builddir)/src/slurmd/common/set_oomadj.c'; fi`
-@am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/set_oomadj.Tpo $(DEPDIR)/set_oomadj.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_builddir)/src/slurmd/common/set_oomadj.c' object='set_oomadj.obj' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o set_oomadj.obj `if test -f '$(top_builddir)/src/slurmd/common/set_oomadj.c'; then $(CYGPATH_W) '$(top_builddir)/src/slurmd/common/set_oomadj.c'; else $(CYGPATH_W) '$(srcdir)/$(top_builddir)/src/slurmd/common/set_oomadj.c'; fi`
-
 mostlyclean-libtool:
 	-rm -f *.lo
 
diff --git a/src/slurmd/slurmd/get_mach_stat.c b/src/slurmd/slurmd/get_mach_stat.c
index ed3edefcb7130c74f91eea4eff1dd52b10bda200..13fc93e71e4be06b88740310fc67f7ccc1463ab4 100644
--- a/src/slurmd/slurmd/get_mach_stat.c
+++ b/src/slurmd/slurmd/get_mach_stat.c
@@ -1,9 +1,9 @@
 /*****************************************************************************\
- *  get_mach_stat.c - Get the status of the current machine 
+ *  get_mach_stat.c - Get the status of the current machine
  *
  *  NOTE: Some of these functions are system dependent. Built on RedHat2.4
  *  NOTE: While not currently used by SLURM, this code can also get a node's
- *       OS name and CPU speed. See code ifdef'ed out via USE_OS_NAME and 
+ *       OS name and CPU speed. See code ifdef'ed out via USE_OS_NAME and
  *       USE_CPU_SPEED
  *****************************************************************************
  *  Copyright (C) 2006 Hewlett-Packard Development Company, L.P.
@@ -11,32 +11,32 @@
  *  Produced at Lawrence Livermore National Laboratory (cf, DISCLAIMER).
  *  Written by Morris Jette <jette1@llnl.gov>.
  *  CODE-OCEC-09-009. All rights reserved.
- *  
+ *
  *  This file is part of SLURM, a resource management program.
  *  For details, see <https://computing.llnl.gov/linux/slurm/>.
  *  Please also read the included file: DISCLAIMER.
- *  
+ *
  *  SLURM 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.
  *
- *  In addition, as a special exception, the copyright holders give permission 
- *  to link the code of portions of this program with the OpenSSL library under 
- *  certain conditions as described in each individual source file, and 
- *  distribute linked combinations including the two. You must obey the GNU 
- *  General Public License in all respects for all of the code used other than 
- *  OpenSSL. If you modify file(s) with this exception, you may extend this 
- *  exception to your version of the file(s), but you are not obligated to do 
+ *  In addition, as a special exception, the copyright holders give permission
+ *  to link the code of portions of this program with the OpenSSL library under
+ *  certain conditions as described in each individual source file, and
+ *  distribute linked combinations including the two. You must obey the GNU
+ *  General Public License in all respects for all of the code used other than
+ *  OpenSSL. If you modify file(s) with this exception, you may extend this
+ *  exception to your version of the file(s), but you are not obligated to do
  *  so. If you do not wish to do so, delete this exception statement from your
- *  version.  If you delete this exception statement from all source files in 
+ *  version.  If you delete this exception statement from all source files in
  *  the program, then also delete it here.
- *  
+ *
  *  SLURM 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 SLURM; if not, write to the Free Software Foundation, Inc.,
  *  51 Franklin Street, Fifth Floor, Boston, MA 02110-1301  USA.
@@ -57,9 +57,9 @@
 #ifdef HAVE_SYS_SYSCTL_H
 # include <sys/sysctl.h>
 #endif
- 
+
 #include <errno.h>
-#include <fcntl.h> 
+#include <fcntl.h>
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
@@ -119,8 +119,8 @@ static int _chk_cpuinfo_uint32(char *buffer, char *keyword, uint32_t *val);
 #define xfree	free
 /* main is used here for testing purposes only:				*/
 /* % gcc -DDEBUG_MODULE get_mach_stat.c -I../../.. -g -DUSE_CPU_SPEED	*/
-int 
-main(int argc, char * argv[]) 
+int
+main(int argc, char * argv[])
 {
 	int error_code;
 	uint16_t sockets, cores, threads;
@@ -140,7 +140,7 @@ main(int argc, char * argv[])
 	debug3("%s:", _cpuinfo_path);
 
 	error_code = get_mach_name(node_name);
-	if (error_code != 0) 
+	if (error_code != 0)
 		exit(1);    /* The show is all over without a node name */
 
 	error_code += get_procs(&this_node.cpus);
@@ -171,15 +171,15 @@ main(int argc, char * argv[])
 	days  = (up_time / 86400);
 	debug3("\tUpTime=%u=%u-%2.2u:%2.2u:%2.2u",
 	       up_time, days, hours, mins, secs);
-	if (error_code != 0) 
+	if (error_code != 0)
 		debug3("get_mach_stat error_code=%d encountered", error_code);
 	exit (error_code);
 }
 
 
-/* gethostname_short - equivalent to gethostname, but return only the first 
- * component of the fully qualified name 
- * (e.g. "linux123.foo.bar" becomes "linux123") 
+/* gethostname_short - equivalent to gethostname, but return only the first
+ * component of the fully qualified name
+ * (e.g. "linux123.foo.bar" becomes "linux123")
  * OUT name
  */
 int
@@ -209,13 +209,13 @@ gethostname_short (char *name, size_t len)
 
 
 /*
- * get_procs - Return the count of procs on this system 
+ * get_procs - Return the count of procs on this system
  * Input: procs - buffer for the CPU count
  * Output: procs - filled in with CPU count, "1" if error
  *         return code - 0 if no error, otherwise errno
  */
-extern int 
-get_procs(uint16_t *procs) 
+extern int
+get_procs(uint16_t *procs)
 {
 #ifdef LPAR_INFO_FORMAT2
 	/* AIX 5.3 only */
@@ -226,7 +226,7 @@ get_procs(uint16_t *procs)
 		error("lpar_get_info() failed");
 		return EINVAL;
 	}
-	
+
 	*procs = (uint16_t) info.online_vcpus;
 #else /* !LPAR_INFO_FORMAT2 */
 
@@ -238,7 +238,7 @@ get_procs(uint16_t *procs)
 	if (my_proc_tally < 1) {
 		error ("get_procs: error running sysconf(_SC_NPROCESSORS_ONLN)");
 		return EINVAL;
-	} 
+	}
 
 	*procs = (uint16_t) my_proc_tally;
 #  else
@@ -263,13 +263,13 @@ get_procs(uint16_t *procs)
 
 #ifdef USE_OS_NAME
 /*
- * get_os_name - Return the operating system name and version 
+ * get_os_name - Return the operating system name and version
  * Input: os_name - buffer for the OS name, must be at least MAX_OS_LEN characters
  * Output: os_name - filled in with OS name, "UNKNOWN" if error
  *         return code - 0 if no error, otherwise errno
  */
-extern int 
-get_os_name(char *os_name) 
+extern int
+get_os_name(char *os_name)
 {
 	int error_code;
 	struct utsname sys_info;
@@ -279,13 +279,13 @@ get_os_name(char *os_name)
 	if (error_code != 0) {
 		error ("get_os_name: uname error %d", error_code);
 		return error_code;
-	} 
+	}
 
-	if ((strlen(sys_info.sysname) + strlen(sys_info.release) + 2) >= 
+	if ((strlen(sys_info.sysname) + strlen(sys_info.release) + 2) >=
 		MAX_OS_LEN) {
 		error ("get_os_name: OS name too long");
 		return error_code;
-	} 
+	}
 
 	strcpy(os_name, sys_info.sysname);
 	strcat(os_name, ".");
@@ -296,13 +296,13 @@ get_os_name(char *os_name)
 
 
 /*
- * get_mach_name - Return the name of this node 
+ * get_mach_name - Return the name of this node
  * Input: node_name - buffer for the node name, must be at least MAX_SLURM_NAME characters
  * Output: node_name - filled in with node name
  *         return code - 0 if no error, otherwise errno
  */
-extern int 
-get_mach_name(char *node_name) 
+extern int
+get_mach_name(char *node_name)
 {
     int error_code;
 
@@ -315,7 +315,7 @@ get_mach_name(char *node_name)
 
 
 /*
- * get_memory - Return the count of procs on this system 
+ * get_memory - Return the count of procs on this system
  * Input: real_memory - buffer for the Real Memory size
  * Output: real_memory - the Real Memory size in MB, "1" if error
  *         return code - 0 if no error, otherwise errno
@@ -334,8 +334,8 @@ get_memory(uint32_t *real_memory)
 	if (pages < 1) {
 		error ("get_memory: error running sysconf(_SC_PHYS_PAGES)");
 		return EINVAL;
-	} 
-	*real_memory = (uint32_t)((float)pages * (sysconf(_SC_PAGE_SIZE) / 
+	}
+	*real_memory = (uint32_t)((float)pages * (sysconf(_SC_PAGE_SIZE) /
 			1048576.0)); /* Megabytes of memory */
 #  else  /* !_SC_PHYS_PAGES */
 #    if HAVE_SYSCTLBYNAME
@@ -357,16 +357,16 @@ get_memory(uint32_t *real_memory)
 
 
 /*
- * get_tmp_disk - Return the total size of temporary file system on 
- *    this system 
+ * get_tmp_disk - Return the total size of temporary file system on
+ *    this system
  * Input: tmp_disk - buffer for the disk space size
- *        tmp_fs - pathname of the temporary file system to status, 
- *	           defaults to "/tmp"
+ *        tmp_fs - pathname of the temporary file system to status,
+ *		   defaults to "/tmp"
  * Output: tmp_disk - filled in with disk space size in MB, zero if error
  *         return code - 0 if no error, otherwise errno
  */
-extern int 
-get_tmp_disk(uint32_t *tmp_disk, char *tmp_fs) 
+extern int
+get_tmp_disk(uint32_t *tmp_disk, char *tmp_fs)
 {
 	int error_code = 0;
 #ifdef HAVE_SYS_VFS_H
@@ -390,7 +390,7 @@ get_tmp_disk(uint32_t *tmp_disk, char *tmp_fs)
 	}
 	else if (errno != ENOENT) {
 		error_code = errno;
-		error ("get_tmp_disk: error %d executing statfs on %s", 
+		error ("get_tmp_disk: error %d executing statfs on %s",
 			errno, tmp_fs_name);
 	}
 
@@ -403,7 +403,7 @@ get_tmp_disk(uint32_t *tmp_disk, char *tmp_fs)
 
 extern int get_up_time(uint32_t *up_time)
 {
-#if defined(HAVE_AIX) || defined(__sun) || defined(__APPLE__)
+#if defined(HAVE_AIX) || defined(__sun)	|| defined(__APPLE__)
 	clock_t tm;
 	struct tms buf;
 
@@ -414,10 +414,24 @@ extern int get_up_time(uint32_t *up_time)
 	}
 
 	*up_time = tm / sysconf(_SC_CLK_TCK);
+#elif defined(__CYGWIN__)
+	FILE *uptime_file;
+	char buffer[128];
+	char* _uptime_path = "/proc/uptime";
+
+	if (!(uptime_file = fopen(_uptime_path, "r"))) {
+		error("get_up_time: error %d opening %s", errno, _uptime_path);
+		return errno;
+	}
+
+	if (fgets(buffer, sizeof(buffer), uptime_file))
+		*up_time = atoi(buffer);
+
+	fclose(uptime_file);
 #else
-	/* NOTE for Linux: The return value of times() may overflow the 
-	 * possible range of type clock_t. There is also an offset of 
-	 * 429 million seconds on some implementations. We just use the 
+	/* NOTE for Linux: The return value of times() may overflow the
+	 * possible range of type clock_t. There is also an offset of
+	 * 429 million seconds on some implementations. We just use the
 	 * simpler sysinfo() function instead. */
 	struct sysinfo info;
 
@@ -446,7 +460,7 @@ static int _chk_cpuinfo_str(char *buffer, char *keyword, char **valptr)
 		return false;
 
 	ptr = strstr(buffer, ":");
-	if (ptr != NULL) 
+	if (ptr != NULL)
 		ptr++;
 	*valptr = ptr;
 	return true;
@@ -496,8 +510,8 @@ static int _chk_cpuinfo_float(char *buffer, char *keyword, float *val)
  * Output: procs - filled in with CPU speed, "1.0" if error
  *         return code - 0 if no error, otherwise errno
  */
-extern int 
-get_speed(float *speed) 
+extern int
+get_speed(float *speed)
 {
 #if defined (__sun)
 	kstat_ctl_t   *kc;
@@ -524,29 +538,29 @@ get_speed(float *speed)
 	if (cpu_info_file == NULL) {
 		error("get_speed: error %d opening %s", errno, _cpuinfo_path);
 		return errno;
-	} 
+	}
 
 	while (fgets(buffer, sizeof(buffer), cpu_info_file) != NULL) {
 		_chk_cpuinfo_float(buffer, "cpu MHz", speed);
-	} 
+	}
 
 	fclose(cpu_info_file);
 #endif
 	return 0;
-} 
+}
 
 #endif
 
 /*
- * get_cpuinfo - Return detailed cpuinfo on this system 
+ * get_cpuinfo - Return detailed cpuinfo on this system
  * Input:  numproc - number of processors on the system
  * Output: p_sockets - number of physical processor sockets
  *         p_cores - total number of physical CPU cores
  *         p_threads - total number of hardware execution threads
- *         block_map - asbtract->physical block distribution map 
+ *         block_map - asbtract->physical block distribution map
  *         block_map_inv - physical->abstract block distribution map (inverse)
  *         return code - 0 if no error, otherwise errno
- * NOTE: User must xfree block_map and block_map_inv  
+ * NOTE: User must xfree block_map and block_map_inv
  */
 typedef struct cpuinfo {
 	uint16_t seen;
@@ -616,7 +630,7 @@ get_cpuinfo(uint16_t numproc,
 #else
 	cpu_info_file = fopen(_cpuinfo_path, "r");
 	if (cpu_info_file == NULL) {
-		error ("get_cpuinfo: error %d opening %s", 
+		error ("get_cpuinfo: error %d opening %s",
 			errno, _cpuinfo_path);
 		return errno;
 	}
@@ -699,7 +713,7 @@ get_cpuinfo(uint16_t numproc,
 			numcpu++;
 			curcpu = val;
 		    	if (val >= numproc) {	/* out of bounds, ignore */
-				debug("cpuid is %u (> %d), ignored", 
+				debug("cpuid is %u (> %d), ignored",
 					val, numproc);
 				continue;
 			}
@@ -797,10 +811,10 @@ get_cpuinfo(uint16_t numproc,
 		}
 		if (sockets == 0)
 			sockets = 1;		/* guarantee non-zero */
-	
+
 		cores = numcores / sockets;	/* unique "core id" */
 		cores = MAX(maxcores, cores);	/* maximum "cpu cores" */
-	
+
 		if (cores == 0) {
 			cores = numcpu / sockets;	/* assume multi-core */
 			if (cores > 1) {
@@ -810,7 +824,7 @@ get_cpuinfo(uint16_t numproc,
 		}
 		if (cores == 0)
 			cores = 1;	/* guarantee non-zero */
-	
+
 		threads = numcpu / (sockets * cores); /* solve for threads */
 		if (threads == 0)
 			threads = 1;	/* guarantee non-zero */
@@ -871,7 +885,7 @@ get_cpuinfo(uint16_t numproc,
  *   actual machine processor ID ordering (which can be BIOS/OS dependendent)
  * Input:  numproc - number of processors on the system
  *	   cpu - array of cpuinfo (file static for qsort/_compare_cpus)
- * Output: block_map, block_map_inv - asbtract->physical block distribution map 
+ * Output: block_map, block_map_inv - asbtract->physical block distribution map
  *         return code - 0 if no error, otherwise errno
  * NOTE: User must free block_map and block_map_inv
  *
@@ -1024,5 +1038,3 @@ static int _compute_block_map(uint16_t numproc,
 #endif
 	return 0;
 }
-
-
diff --git a/src/slurmd/slurmd/req.c b/src/slurmd/slurmd/req.c
index c6d71e2c38ec63b0bc3cf6185e3bd9de88f75d0e..38bdc8f54297749b703a763aac5946ff55cec61c 100644
--- a/src/slurmd/slurmd/req.c
+++ b/src/slurmd/slurmd/req.c
@@ -3978,7 +3978,7 @@ init_gids_cache(int cache)
 	gids_t *gids;
 #ifdef HAVE_AIX
 	FILE *fp = NULL;
-#elif defined (__APPLE__)
+#elif defined (__APPLE__) || defined (__CYGWIN__)
 #else
 	struct passwd pw;
 	char buf[BUF_SIZE];
@@ -4008,7 +4008,7 @@ init_gids_cache(int cache)
 	setpwent();
 #if defined (__sun)
 	while ((pwd = getpwent_r(&pw, buf, BUF_SIZE)) != NULL) {
-#elif defined (__APPLE__)
+#elif defined (__APPLE__) || defined (__CYGWIN__)
 	while ((pwd = getpwent()) != NULL) {
 #else
 
diff --git a/src/slurmd/slurmstepd/Makefile.am b/src/slurmd/slurmstepd/Makefile.am
index 7d1061d39377cdce3bee76afc920d1ffc4211a48..96e7bb6398d6b89f783b763d9a5ea8788ec28d1c 100644
--- a/src/slurmd/slurmstepd/Makefile.am
+++ b/src/slurmd/slurmstepd/Makefile.am
@@ -9,8 +9,9 @@ INCLUDES = -I$(top_srcdir)
 
 slurmstepd_LDADD = 				   \
 	$(top_builddir)/src/common/libdaemonize.la \
-	$(top_builddir)/src/api/libslurm.o -ldl\
-	$(PLPA_LIBS) $(PAM_LIBS) $(UTIL_LIBS)
+	$(top_builddir)/src/api/libslurm.o -ldl \
+	$(PLPA_LIBS) $(PAM_LIBS) $(UTIL_LIBS) \
+	../common/libslurmd_common.la
 
 slurmstepd_SOURCES = 	        	\
 	slurmstepd.c slurmstepd.h	\
@@ -24,20 +25,7 @@ slurmstepd_SOURCES = 	        	\
 	pam_ses.c pam_ses.h		\
 	req.c req.h			\
 	multi_prog.c multi_prog.h	\
-	step_terminate_monitor.c step_terminate_monitor.h \
-	$(top_builddir)/src/slurmd/common/proctrack.c \
-	$(top_builddir)/src/slurmd/common/proctrack.h \
-	$(top_builddir)/src/slurmd/common/setproctitle.c \
-	$(top_builddir)/src/slurmd/common/setproctitle.h \
-	$(top_builddir)/src/slurmd/common/slurmstepd_init.c \
-	$(top_builddir)/src/slurmd/common/slurmstepd_init.h \
-	$(top_builddir)/src/slurmd/common/run_script.c \
-	$(top_builddir)/src/slurmd/common/run_script.h \
-	$(top_builddir)/src/slurmd/common/task_plugin.c \
-	$(top_builddir)/src/slurmd/common/task_plugin.h \
-	$(top_builddir)/src/slurmd/common/set_oomadj.c \
-	$(top_builddir)/src/slurmd/common/set_oomadj.h \
-	$(top_builddir)/src/slurmd/common/reverse_tree.h
+	step_terminate_monitor.c step_terminate_monitor.h
 
 if HAVE_AIX
 # We need to set maxdata back to 0 because this effects the "max memory size"
diff --git a/src/slurmd/slurmstepd/Makefile.in b/src/slurmd/slurmstepd/Makefile.in
index ebea1d39ebf031d1c5b112f3c5d2d0f0ed66b808..e85e5e7540d764dbf90b089133f19755385fdeb8 100644
--- a/src/slurmd/slurmstepd/Makefile.in
+++ b/src/slurmd/slurmstepd/Makefile.in
@@ -89,15 +89,12 @@ am_slurmstepd_OBJECTS = slurmstepd.$(OBJEXT) mgr.$(OBJEXT) \
 	task.$(OBJEXT) slurmstepd_job.$(OBJEXT) io.$(OBJEXT) \
 	fname.$(OBJEXT) ulimits.$(OBJEXT) pdebug.$(OBJEXT) \
 	pam_ses.$(OBJEXT) req.$(OBJEXT) multi_prog.$(OBJEXT) \
-	step_terminate_monitor.$(OBJEXT) proctrack.$(OBJEXT) \
-	setproctitle.$(OBJEXT) slurmstepd_init.$(OBJEXT) \
-	run_script.$(OBJEXT) task_plugin.$(OBJEXT) \
-	set_oomadj.$(OBJEXT)
+	step_terminate_monitor.$(OBJEXT)
 slurmstepd_OBJECTS = $(am_slurmstepd_OBJECTS)
 am__DEPENDENCIES_1 =
 slurmstepd_DEPENDENCIES = $(top_builddir)/src/common/libdaemonize.la \
 	$(top_builddir)/src/api/libslurm.o $(am__DEPENDENCIES_1) \
-	$(am__DEPENDENCIES_1)
+	$(am__DEPENDENCIES_1) ../common/libslurmd_common.la
 slurmstepd_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) \
 	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
 	$(slurmstepd_LDFLAGS) $(LDFLAGS) -o $@
@@ -314,8 +311,9 @@ AUTOMAKE_OPTIONS = foreign
 INCLUDES = -I$(top_srcdir)
 slurmstepd_LDADD = \
 	$(top_builddir)/src/common/libdaemonize.la \
-	$(top_builddir)/src/api/libslurm.o -ldl\
-	$(PLPA_LIBS) $(PAM_LIBS) $(UTIL_LIBS)
+	$(top_builddir)/src/api/libslurm.o -ldl \
+	$(PLPA_LIBS) $(PAM_LIBS) $(UTIL_LIBS) \
+	../common/libslurmd_common.la
 
 slurmstepd_SOURCES = \
 	slurmstepd.c slurmstepd.h	\
@@ -329,20 +327,7 @@ slurmstepd_SOURCES = \
 	pam_ses.c pam_ses.h		\
 	req.c req.h			\
 	multi_prog.c multi_prog.h	\
-	step_terminate_monitor.c step_terminate_monitor.h \
-	$(top_builddir)/src/slurmd/common/proctrack.c \
-	$(top_builddir)/src/slurmd/common/proctrack.h \
-	$(top_builddir)/src/slurmd/common/setproctitle.c \
-	$(top_builddir)/src/slurmd/common/setproctitle.h \
-	$(top_builddir)/src/slurmd/common/slurmstepd_init.c \
-	$(top_builddir)/src/slurmd/common/slurmstepd_init.h \
-	$(top_builddir)/src/slurmd/common/run_script.c \
-	$(top_builddir)/src/slurmd/common/run_script.h \
-	$(top_builddir)/src/slurmd/common/task_plugin.c \
-	$(top_builddir)/src/slurmd/common/task_plugin.h \
-	$(top_builddir)/src/slurmd/common/set_oomadj.c \
-	$(top_builddir)/src/slurmd/common/set_oomadj.h \
-	$(top_builddir)/src/slurmd/common/reverse_tree.h
+	step_terminate_monitor.c step_terminate_monitor.h
 
 @HAVE_AIX_FALSE@slurmstepd_LDFLAGS = -export-dynamic $(CMD_LDFLAGS)
 
@@ -442,17 +427,11 @@ distclean-compile:
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/multi_prog.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pam_ses.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pdebug.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/proctrack.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/req.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/run_script.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/set_oomadj.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/setproctitle.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/slurmstepd.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/slurmstepd_init.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/slurmstepd_job.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/step_terminate_monitor.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/task.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/task_plugin.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ulimits.Po@am__quote@
 
 .c.o:
@@ -476,90 +455,6 @@ distclean-compile:
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @am__fastdepCC_FALSE@	$(LTCOMPILE) -c -o $@ $<
 
-proctrack.o: $(top_builddir)/src/slurmd/common/proctrack.c
-@am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT proctrack.o -MD -MP -MF $(DEPDIR)/proctrack.Tpo -c -o proctrack.o `test -f '$(top_builddir)/src/slurmd/common/proctrack.c' || echo '$(srcdir)/'`$(top_builddir)/src/slurmd/common/proctrack.c
-@am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/proctrack.Tpo $(DEPDIR)/proctrack.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_builddir)/src/slurmd/common/proctrack.c' object='proctrack.o' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o proctrack.o `test -f '$(top_builddir)/src/slurmd/common/proctrack.c' || echo '$(srcdir)/'`$(top_builddir)/src/slurmd/common/proctrack.c
-
-proctrack.obj: $(top_builddir)/src/slurmd/common/proctrack.c
-@am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT proctrack.obj -MD -MP -MF $(DEPDIR)/proctrack.Tpo -c -o proctrack.obj `if test -f '$(top_builddir)/src/slurmd/common/proctrack.c'; then $(CYGPATH_W) '$(top_builddir)/src/slurmd/common/proctrack.c'; else $(CYGPATH_W) '$(srcdir)/$(top_builddir)/src/slurmd/common/proctrack.c'; fi`
-@am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/proctrack.Tpo $(DEPDIR)/proctrack.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_builddir)/src/slurmd/common/proctrack.c' object='proctrack.obj' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o proctrack.obj `if test -f '$(top_builddir)/src/slurmd/common/proctrack.c'; then $(CYGPATH_W) '$(top_builddir)/src/slurmd/common/proctrack.c'; else $(CYGPATH_W) '$(srcdir)/$(top_builddir)/src/slurmd/common/proctrack.c'; fi`
-
-setproctitle.o: $(top_builddir)/src/slurmd/common/setproctitle.c
-@am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT setproctitle.o -MD -MP -MF $(DEPDIR)/setproctitle.Tpo -c -o setproctitle.o `test -f '$(top_builddir)/src/slurmd/common/setproctitle.c' || echo '$(srcdir)/'`$(top_builddir)/src/slurmd/common/setproctitle.c
-@am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/setproctitle.Tpo $(DEPDIR)/setproctitle.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_builddir)/src/slurmd/common/setproctitle.c' object='setproctitle.o' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o setproctitle.o `test -f '$(top_builddir)/src/slurmd/common/setproctitle.c' || echo '$(srcdir)/'`$(top_builddir)/src/slurmd/common/setproctitle.c
-
-setproctitle.obj: $(top_builddir)/src/slurmd/common/setproctitle.c
-@am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT setproctitle.obj -MD -MP -MF $(DEPDIR)/setproctitle.Tpo -c -o setproctitle.obj `if test -f '$(top_builddir)/src/slurmd/common/setproctitle.c'; then $(CYGPATH_W) '$(top_builddir)/src/slurmd/common/setproctitle.c'; else $(CYGPATH_W) '$(srcdir)/$(top_builddir)/src/slurmd/common/setproctitle.c'; fi`
-@am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/setproctitle.Tpo $(DEPDIR)/setproctitle.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_builddir)/src/slurmd/common/setproctitle.c' object='setproctitle.obj' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o setproctitle.obj `if test -f '$(top_builddir)/src/slurmd/common/setproctitle.c'; then $(CYGPATH_W) '$(top_builddir)/src/slurmd/common/setproctitle.c'; else $(CYGPATH_W) '$(srcdir)/$(top_builddir)/src/slurmd/common/setproctitle.c'; fi`
-
-slurmstepd_init.o: $(top_builddir)/src/slurmd/common/slurmstepd_init.c
-@am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT slurmstepd_init.o -MD -MP -MF $(DEPDIR)/slurmstepd_init.Tpo -c -o slurmstepd_init.o `test -f '$(top_builddir)/src/slurmd/common/slurmstepd_init.c' || echo '$(srcdir)/'`$(top_builddir)/src/slurmd/common/slurmstepd_init.c
-@am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/slurmstepd_init.Tpo $(DEPDIR)/slurmstepd_init.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_builddir)/src/slurmd/common/slurmstepd_init.c' object='slurmstepd_init.o' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o slurmstepd_init.o `test -f '$(top_builddir)/src/slurmd/common/slurmstepd_init.c' || echo '$(srcdir)/'`$(top_builddir)/src/slurmd/common/slurmstepd_init.c
-
-slurmstepd_init.obj: $(top_builddir)/src/slurmd/common/slurmstepd_init.c
-@am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT slurmstepd_init.obj -MD -MP -MF $(DEPDIR)/slurmstepd_init.Tpo -c -o slurmstepd_init.obj `if test -f '$(top_builddir)/src/slurmd/common/slurmstepd_init.c'; then $(CYGPATH_W) '$(top_builddir)/src/slurmd/common/slurmstepd_init.c'; else $(CYGPATH_W) '$(srcdir)/$(top_builddir)/src/slurmd/common/slurmstepd_init.c'; fi`
-@am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/slurmstepd_init.Tpo $(DEPDIR)/slurmstepd_init.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_builddir)/src/slurmd/common/slurmstepd_init.c' object='slurmstepd_init.obj' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o slurmstepd_init.obj `if test -f '$(top_builddir)/src/slurmd/common/slurmstepd_init.c'; then $(CYGPATH_W) '$(top_builddir)/src/slurmd/common/slurmstepd_init.c'; else $(CYGPATH_W) '$(srcdir)/$(top_builddir)/src/slurmd/common/slurmstepd_init.c'; fi`
-
-run_script.o: $(top_builddir)/src/slurmd/common/run_script.c
-@am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT run_script.o -MD -MP -MF $(DEPDIR)/run_script.Tpo -c -o run_script.o `test -f '$(top_builddir)/src/slurmd/common/run_script.c' || echo '$(srcdir)/'`$(top_builddir)/src/slurmd/common/run_script.c
-@am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/run_script.Tpo $(DEPDIR)/run_script.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_builddir)/src/slurmd/common/run_script.c' object='run_script.o' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o run_script.o `test -f '$(top_builddir)/src/slurmd/common/run_script.c' || echo '$(srcdir)/'`$(top_builddir)/src/slurmd/common/run_script.c
-
-run_script.obj: $(top_builddir)/src/slurmd/common/run_script.c
-@am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT run_script.obj -MD -MP -MF $(DEPDIR)/run_script.Tpo -c -o run_script.obj `if test -f '$(top_builddir)/src/slurmd/common/run_script.c'; then $(CYGPATH_W) '$(top_builddir)/src/slurmd/common/run_script.c'; else $(CYGPATH_W) '$(srcdir)/$(top_builddir)/src/slurmd/common/run_script.c'; fi`
-@am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/run_script.Tpo $(DEPDIR)/run_script.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_builddir)/src/slurmd/common/run_script.c' object='run_script.obj' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o run_script.obj `if test -f '$(top_builddir)/src/slurmd/common/run_script.c'; then $(CYGPATH_W) '$(top_builddir)/src/slurmd/common/run_script.c'; else $(CYGPATH_W) '$(srcdir)/$(top_builddir)/src/slurmd/common/run_script.c'; fi`
-
-task_plugin.o: $(top_builddir)/src/slurmd/common/task_plugin.c
-@am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT task_plugin.o -MD -MP -MF $(DEPDIR)/task_plugin.Tpo -c -o task_plugin.o `test -f '$(top_builddir)/src/slurmd/common/task_plugin.c' || echo '$(srcdir)/'`$(top_builddir)/src/slurmd/common/task_plugin.c
-@am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/task_plugin.Tpo $(DEPDIR)/task_plugin.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_builddir)/src/slurmd/common/task_plugin.c' object='task_plugin.o' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o task_plugin.o `test -f '$(top_builddir)/src/slurmd/common/task_plugin.c' || echo '$(srcdir)/'`$(top_builddir)/src/slurmd/common/task_plugin.c
-
-task_plugin.obj: $(top_builddir)/src/slurmd/common/task_plugin.c
-@am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT task_plugin.obj -MD -MP -MF $(DEPDIR)/task_plugin.Tpo -c -o task_plugin.obj `if test -f '$(top_builddir)/src/slurmd/common/task_plugin.c'; then $(CYGPATH_W) '$(top_builddir)/src/slurmd/common/task_plugin.c'; else $(CYGPATH_W) '$(srcdir)/$(top_builddir)/src/slurmd/common/task_plugin.c'; fi`
-@am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/task_plugin.Tpo $(DEPDIR)/task_plugin.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_builddir)/src/slurmd/common/task_plugin.c' object='task_plugin.obj' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o task_plugin.obj `if test -f '$(top_builddir)/src/slurmd/common/task_plugin.c'; then $(CYGPATH_W) '$(top_builddir)/src/slurmd/common/task_plugin.c'; else $(CYGPATH_W) '$(srcdir)/$(top_builddir)/src/slurmd/common/task_plugin.c'; fi`
-
-set_oomadj.o: $(top_builddir)/src/slurmd/common/set_oomadj.c
-@am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT set_oomadj.o -MD -MP -MF $(DEPDIR)/set_oomadj.Tpo -c -o set_oomadj.o `test -f '$(top_builddir)/src/slurmd/common/set_oomadj.c' || echo '$(srcdir)/'`$(top_builddir)/src/slurmd/common/set_oomadj.c
-@am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/set_oomadj.Tpo $(DEPDIR)/set_oomadj.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_builddir)/src/slurmd/common/set_oomadj.c' object='set_oomadj.o' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o set_oomadj.o `test -f '$(top_builddir)/src/slurmd/common/set_oomadj.c' || echo '$(srcdir)/'`$(top_builddir)/src/slurmd/common/set_oomadj.c
-
-set_oomadj.obj: $(top_builddir)/src/slurmd/common/set_oomadj.c
-@am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT set_oomadj.obj -MD -MP -MF $(DEPDIR)/set_oomadj.Tpo -c -o set_oomadj.obj `if test -f '$(top_builddir)/src/slurmd/common/set_oomadj.c'; then $(CYGPATH_W) '$(top_builddir)/src/slurmd/common/set_oomadj.c'; else $(CYGPATH_W) '$(srcdir)/$(top_builddir)/src/slurmd/common/set_oomadj.c'; fi`
-@am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/set_oomadj.Tpo $(DEPDIR)/set_oomadj.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_builddir)/src/slurmd/common/set_oomadj.c' object='set_oomadj.obj' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o set_oomadj.obj `if test -f '$(top_builddir)/src/slurmd/common/set_oomadj.c'; then $(CYGPATH_W) '$(top_builddir)/src/slurmd/common/set_oomadj.c'; else $(CYGPATH_W) '$(srcdir)/$(top_builddir)/src/slurmd/common/set_oomadj.c'; fi`
-
 mostlyclean-libtool:
 	-rm -f *.lo
 
diff --git a/src/slurmd/slurmstepd/pdebug.c b/src/slurmd/slurmstepd/pdebug.c
index f5a48ef90927e9135683c6a6eff94f345363eb1f..3e2972dbb92fd7d25fe43a3ee20cf29a02647b9a 100644
--- a/src/slurmd/slurmstepd/pdebug.c
+++ b/src/slurmd/slurmstepd/pdebug.c
@@ -101,6 +101,10 @@ pdebug_trace_process(slurmd_job_t *job, pid_t pid)
 		if (_PTRACE(PT_DETACH, pid, NULL, 0)) {
 #elif defined(__sun)
 		if (_PTRACE(7, pid, NULL, 0)) {
+#elif defined(__CYGWIN__)
+		if (1) {
+			debug3("No ptrace for cygwin");
+		} else {
 #else
 		if (_PTRACE(PTRACE_DETACH, pid, NULL, 0)) {
 #endif
@@ -127,6 +131,8 @@ pdebug_stop_current(slurmd_job_t *job)
 	     && (_PTRACE(PT_TRACE_ME, 0, NULL, 0) < 0) )
 #elif defined(__sun)
 	     && (_PTRACE(0, 0, NULL, 0) < 0))
+#elif defined(__CYGWIN__)
+	     && 0)
 #else
 	     && (_PTRACE(PTRACE_TRACEME, 0, NULL, 0) < 0) )
 #endif