update: convert upserver and client from LWP to pthreads 54/12754/2
authorMichael Meffie <mmeffie@sinenomine.net>
Sat, 28 Oct 2017 03:25:10 +0000 (23:25 -0400)
committerBenjamin Kaduk <kaduk@mit.edu>
Fri, 21 Sep 2018 03:10:10 +0000 (23:10 -0400)
Build the upserver and the upclient with phreads instead of LWP
and convert the IOMRG sleeps in the client to regular sleeps.

Change-Id: I183765ef180f34d38b87a13ec49f16f4a60afcc8
Reviewed-on: https://gerrit.openafs.org/12754
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Mark Vitale <mvitale@sinenomine.net>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>

src/update/Makefile.in
src/update/client.c

index 917bf76..e8a0518 100644 (file)
@@ -7,20 +7,15 @@
 
 srcdir=@srcdir@
 include @TOP_OBJDIR@/src/config/Makefile.config
-include @TOP_OBJDIR@/src/config/Makefile.lwp
+include @TOP_OBJDIR@/src/config/Makefile.pthread
 
-
-LIBS=${TOP_LIBDIR}/libauth.a \
-       ${TOP_LIBDIR}/librxkad.a \
-       ${TOP_LIBDIR}/librx.a \
-       ${TOP_LIBDIR}/libsys.a \
-       ${TOP_LIBDIR}/librx.a \
-       ${TOP_LIBDIR}/liblwp.a \
-       ${TOP_LIBDIR}/libafscom_err.a \
-       ${TOP_LIBDIR}/util.a \
-       ${TOP_LIBDIR}/libopr.a \
-       ${TOP_LIBDIR}/libafsrfc3961.a \
-       ${TOP_LIBDIR}/libafshcrypto_lwp.a
+LIBS= \
+       $(top_builddir)/src/auth/liboafs_auth.la \
+       $(top_builddir)/src/rx/liboafs_rx.la \
+       $(top_builddir)/src/rxkad/liboafs_rxkad.la \
+       $(top_builddir)/src/cmd/liboafs_cmd.la \
+       $(top_builddir)/src/util/liboafs_util.la \
+       $(top_builddir)/src/opr/liboafs_opr.la
 
 all: upserver upclient
 
@@ -30,11 +25,11 @@ generated: update.cs.c update.ss.c update.xdr.c update.h
 # Build targets
 #
 upclient: client.o update.cs.o utils.o ${LIBS}
-       $(AFS_LDRULE) client.o update.cs.o utils.o \
+       $(LT_LDRULE_static) client.o update.cs.o utils.o \
                ${LIBS} $(LIB_roken) ${XLIBS}
 
 upserver: server.o utils.o update.ss.o ${LIBS}
-       $(AFS_LDRULE) server.o utils.o update.ss.o \
+       $(LT_LDRULE_static) server.o utils.o update.ss.o \
                ${LIBS} $(LIB_roken) ${XLIBS}
 
 utils.o: utils.c update.h global.h
index 742c7f9..5bc0ec0 100644 (file)
@@ -375,14 +375,14 @@ main(int argc, char **argv)
            free(curDir);
        }                       /* end for each dir loop */
        /*delete the file with info on files in directory df->name */
-       IOMGR_Sleep(interval);
+       sleep(interval);
        continue;
 
       fail_dirbuf:
        fclose(stream);
        unlink(dirbuf);
       fail:
-       IOMGR_Sleep(retrytime);
+       sleep(retrytime);
        if (cnt > 10) {
            rx_DestroyConnection(conn);
            goto again;