You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@commons.apache.org by re...@apache.org on 2002/02/19 03:44:14 UTC
cvs commit: jakarta-commons-sandbox/daemon/src/native/unix/native Makefile.in java.c java.h
remm 02/02/18 18:44:14
Modified: daemon/src/native/unix .cvsignore Makefile.in configure.in
daemon/src/native/unix/native Makefile.in java.c java.h
Log:
- Fix basic problems with the jsvc Unix code.
Revision Changes Path
1.2 +1 -0 jakarta-commons-sandbox/daemon/src/native/unix/.cvsignore
Index: .cvsignore
===================================================================
RCS file: /home/cvs/jakarta-commons-sandbox/daemon/src/native/unix/.cvsignore,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- .cvsignore 18 Feb 2002 21:15:41 -0000 1.1
+++ .cvsignore 19 Feb 2002 02:44:14 -0000 1.2
@@ -1,3 +1,4 @@
+confdefs.h
config.cache
config.log
config.status
1.2 +3 -8 jakarta-commons-sandbox/daemon/src/native/unix/Makefile.in
Index: Makefile.in
===================================================================
RCS file: /home/cvs/jakarta-commons-sandbox/daemon/src/native/unix/Makefile.in,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- Makefile.in 18 Feb 2002 21:15:41 -0000 1.1
+++ Makefile.in 19 Feb 2002 02:44:14 -0000 1.2
@@ -56,28 +56,23 @@
# ========================================================================= #
# @author Pier Fumagalli <ma...@eng.sun.com>
-# @version $Id: Makefile.in,v 1.1 2002/02/18 21:15:41 remm Exp $
+# @version $Id: Makefile.in,v 1.2 2002/02/19 02:44:14 remm Exp $
-SUBDIRS = native java
+SUBDIRS = native
-all: native/all java/all
+all: native/all
native/all:
$(MAKE) -C native all
-java/all:
- $(MAKE) -C java all
-
clean:
$(MAKE) -C native clean
- $(MAKE) -C java clean
distclean: clean
rm -f config.cache
rm -f config.log
rm -f config.status
rm -f native/Makefile
- rm -f java/Makefile
rm -f Makefile
rm -f Makedefs
1.2 +2 -2 jakarta-commons-sandbox/daemon/src/native/unix/configure.in
Index: configure.in
===================================================================
RCS file: /home/cvs/jakarta-commons-sandbox/daemon/src/native/unix/configure.in,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- configure.in 18 Feb 2002 21:15:41 -0000 1.1
+++ configure.in 19 Feb 2002 02:44:14 -0000 1.2
@@ -57,7 +57,7 @@
dnl -------------------------------------------------------------------------
dnl Author Pier Fumagalli <ma...@eng.sun.com>
-dnl Version $Id: configure.in,v 1.1 2002/02/18 21:15:41 remm Exp $
+dnl Version $Id: configure.in,v 1.2 2002/02/19 02:44:14 remm Exp $
dnl -------------------------------------------------------------------------
dnl -------------------------------------------------------------------------
@@ -122,7 +122,7 @@
dnl Random programs we need to compile locally
dnl -------------------------------------------------------------------------
AP_MSG_HEADER([Writing output files])
-AC_OUTPUT(Makefile Makedefs native/Makefile java/Makefile)
+AC_OUTPUT(Makefile Makedefs native/Makefile)
dnl -------------------------------------------------------------------------
dnl Done
1.2 +3 -3 jakarta-commons-sandbox/daemon/src/native/unix/native/Makefile.in
Index: Makefile.in
===================================================================
RCS file: /home/cvs/jakarta-commons-sandbox/daemon/src/native/unix/native/Makefile.in,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- Makefile.in 18 Feb 2002 21:15:42 -0000 1.1
+++ Makefile.in 19 Feb 2002 02:44:14 -0000 1.2
@@ -56,7 +56,7 @@
# ========================================================================= #
# @author Pier Fumagalli <ma...@eng.sun.com>
-# @version $Id: Makefile.in,v 1.1 2002/02/18 21:15:42 remm Exp $
+# @version $Id: Makefile.in,v 1.2 2002/02/19 02:44:14 remm Exp $
include ../Makedefs
@@ -78,8 +78,8 @@
ranlib libservice.a
jsvc: jsvc-unix.o libservice.a
- $(CC) $(LDFLAGS) jsvc-unix.o libservice.a -o jsvc
+ $(CC) $(LDFLAGS) jsvc-unix.o libservice.a -o ../../../../dist/jsvc
clean:
- rm -f $(OBJS) jsvc jsvc-unix.o libservice.a
+ rm -f $(OBJS) ../../../../dist/jsvc jsvc-unix.o libservice.a
1.2 +21 -21 jakarta-commons-sandbox/daemon/src/native/unix/native/java.c
Index: java.c
===================================================================
RCS file: /home/cvs/jakarta-commons-sandbox/daemon/src/native/unix/native/java.c,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- java.c 18 Feb 2002 21:15:42 -0000 1.1
+++ java.c 19 Feb 2002 02:44:14 -0000 1.2
@@ -55,7 +55,7 @@
* *
* ========================================================================= */
-/* @version $Id: java.c,v 1.1 2002/02/18 21:15:42 remm Exp $ */
+/* @version $Id: java.c,v 1.2 2002/02/19 02:44:14 remm Exp $ */
#include "jsvc.h"
#ifdef OS_CYGWIN
@@ -212,7 +212,7 @@
cls=(*env)->FindClass(env,LOADER);
if (cls==NULL) {
- log_error("Cannot find service loader %s",LOADER);
+ log_error("Cannot find daemon loader %s",LOADER);
return(false);
}
log_debug("Class %s found",LOADER);
@@ -256,7 +256,7 @@
return(true);
}
-/* Call the load method in our ServiceLoader class */
+/* Call the load method in our DaemonLoader class */
bool java_load(arg_data *args) {
jclass stringClass=NULL;
jstring className=NULL;
@@ -296,69 +296,69 @@
method=(*env)->GetStaticMethodID(env,cls,"load",
"(Ljava/lang/String;[Ljava/lang/String;)Z");
if (method==NULL) {
- log_error("Cannot found Service Loader \"load\" entry point");
+ log_error("Cannot found Daemon Loader \"load\" entry point");
return(false);
}
ret=(*env)->CallStaticBooleanMethod(env,cls,method,className,stringArray);
if (ret==FALSE) {
- log_error("Cannot load service");
+ log_error("Cannot load daemon");
return(false);
}
- log_debug("Service loaded successfully");
+ log_debug("Daemon loaded successfully");
return(true);
}
-/* Call the start method in our service loader */
+/* Call the start method in our daemon loader */
bool java_start(void) {
jmethodID method;
jboolean ret;
method=(*env)->GetStaticMethodID(env,cls,"start","()Z");
if (method==NULL) {
- log_error("Cannot found Service Loader \"start\" entry point");
+ log_error("Cannot found Daemon Loader \"start\" entry point");
return(false);
}
ret=(*env)->CallStaticBooleanMethod(env,cls,method);
if (ret==FALSE) {
- log_error("Cannot start service");
+ log_error("Cannot start daemon");
return(false);
}
- log_debug("Service started successfully");
+ log_debug("Daemon started successfully");
return(true);
}
-/* Call the stop method in our service loader */
+/* Call the stop method in our daemon loader */
bool java_stop(void) {
jmethodID method;
jboolean ret;
method=(*env)->GetStaticMethodID(env,cls,"stop","()Z");
if (method==NULL) {
- log_error("Cannot found Service Loader \"stop\" entry point");
+ log_error("Cannot found Daemon Loader \"stop\" entry point");
return(false);
}
ret=(*env)->CallStaticBooleanMethod(env,cls,method);
if (ret==FALSE) {
- log_error("Cannot stop service");
+ log_error("Cannot stop daemon");
return(false);
}
- log_debug("Service stopped successfully");
+ log_debug("Daemon stopped successfully");
return(true);
}
-/* Call the version method in our service loader */
+/* Call the version method in our daemon loader */
bool java_version(void) {
jmethodID method;
method=(*env)->GetStaticMethodID(env,cls,"version","()V");
if (method==NULL) {
- log_error("Cannot found Service Loader \"version\" entry point");
+ log_error("Cannot found Daemon Loader \"version\" entry point");
return(false);
}
@@ -366,13 +366,13 @@
return(true);
}
-/* Call the check method in our ServiceLoader class */
+/* Call the check method in our DaemonLoader class */
bool java_check(arg_data *args) {
jstring className=NULL;
jmethodID method=NULL;
jboolean ret=FALSE;
- log_debug("Checking service");
+ log_debug("Checking daemon");
className=(*env)->NewStringUTF(env,args->clas);
if (className==NULL) {
@@ -382,17 +382,17 @@
method=(*env)->GetStaticMethodID(env,cls,"check","(Ljava/lang/String;)Z");
if (method==NULL) {
- log_error("Cannot found Service Loader \"check\" entry point");
+ log_error("Cannot found Daemon Loader \"check\" entry point");
return(false);
}
ret=(*env)->CallStaticBooleanMethod(env,cls,method,className);
if (ret==FALSE) {
- log_error("An error was detected checking the %s service",args->clas);
+ log_error("An error was detected checking the %s daemon",args->clas);
return(false);
}
- log_debug("Service checked successfully");
+ log_debug("Daemon checked successfully");
return(true);
}
1.2 +2 -2 jakarta-commons-sandbox/daemon/src/native/unix/native/java.h
Index: java.h
===================================================================
RCS file: /home/cvs/jakarta-commons-sandbox/daemon/src/native/unix/native/java.h,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- java.h 18 Feb 2002 21:15:42 -0000 1.1
+++ java.h 19 Feb 2002 02:44:14 -0000 1.2
@@ -55,9 +55,9 @@
* *
* ========================================================================= */
-/* @version $Id: java.h,v 1.1 2002/02/18 21:15:42 remm Exp $ */
+/* @version $Id: java.h,v 1.2 2002/02/19 02:44:14 remm Exp $ */
-#define LOADER "org/apache/service/support/ServiceLoader"
+#define LOADER "org/apache/commons/daemon/support/DaemonLoader"
char *java_library(arg_data *args, home_data *data);
bool java_init(arg_data *args, home_data *data);
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>