Add APR_DECLARE statements for the DSO functions. ---------- cut here ------------------ Index: apr_dso.h =================================================================== RCS file: /home/cvspublic/apr/include/apr_dso.h,v retrieving revision 1.25 diff -u -d -b -r1.25 apr_dso.h --- apr_dso.h 2000/12/04 05:40:25 1.25 +++ apr_dso.h 2001/01/11 21:04:16 @@ -86,23 +86,26 @@ * @param res_handle Location to store new handle for the DSO. * @param path Path to the DSO library * @param ctx Pool to use. + * @deffunc apr_status_t apr_dso_load(apr_dso_handle_t **res_handle, const char *path, apr_pool_t *ctx) */ -apr_status_t apr_dso_load(apr_dso_handle_t **res_handle, const char *path, +APR_DECLARE(apr_status_t) apr_dso_load(apr_dso_handle_t **res_handle, const char *path, apr_pool_t *ctx);
/** * Close a DSO library. * @param handle handle to close. + * @deffunc apr_status_t apr_dso_unload(apr_dso_handle_t *handle) */ -apr_status_t apr_dso_unload(apr_dso_handle_t *handle); +APR_DECLARE(apr_status_t) apr_dso_unload(apr_dso_handle_t *handle); /** * Load a symbol from a DSO handle. * @param ressym Location to store the loaded symbol * @param handle handle to load the symbol from. * @param symname Name of the symbol to load. + * @deffunc apr_status_t apr_dso_sym(apr_dso_handle_sym_t *ressym, apr_dso_handle_t *handle, const char *symname) */ -apr_status_t apr_dso_sym(apr_dso_handle_sym_t *ressym, apr_dso_handle_t *handle, +APR_DECLARE(apr_status_t) apr_dso_sym(apr_dso_handle_sym_t *ressym, apr_dso_handle_t *handle, const char *symname); /** @@ -110,8 +113,9 @@ * @param dso The dso handle that has been opened * @param buf Location to store the dso error * @param bufsize The size of the provided buffer + * @deffunc const char *apr_dso_error(apr_dso_handle_t *dso, char *buf, apr_size_t bufsize) */ -const char *apr_dso_error(apr_dso_handle_t *dso, char *buf, apr_size_t bufsize); +APR_DECLARE(const char *) apr_dso_error(apr_dso_handle_t *dso, char *buf, apr_size_t bufsize); #endif /* APR_HAS_DSO */ Index: aix/dso.c =================================================================== RCS file: /home/cvspublic/apr/dso/aix/dso.c,v retrieving revision 1.8 diff -u -d -b -r1.8 dso.c --- aix/dso.c 2000/11/09 06:08:35 1.8 +++ aix/dso.c 2001/01/11 21:05:29 @@ -132,7 +132,7 @@ * add the basic "wrappers" here. */ -apr_status_t apr_dso_load(apr_dso_handle_t **res_handle, const char *path, +APR_DECLARE(apr_status_t) apr_dso_load(apr_dso_handle_t **res_handle, const char *path, apr_pool_t *ctx) { void *os_handle = dlopen((char *)path, RTLD_NOW | RTLD_GLOBAL); @@ -146,7 +146,7 @@ return APR_SUCCESS; } -apr_status_t apr_dso_unload(apr_dso_handle_t *handle) +APR_DECLARE(apr_status_t) apr_dso_unload(apr_dso_handle_t *handle) { if (dlclose(handle->handle) != 0) return APR_EINIT; @@ -154,7 +154,7 @@ return APR_SUCCESS; } -apr_status_t apr_dso_sym(apr_dso_handle_sym_t *ressym, +APR_DECLARE(apr_status_t) apr_dso_sym(apr_dso_handle_sym_t *ressym, apr_dso_handle_t *handle, const char *symname) { Index: beos/dso.c =================================================================== RCS file: /home/cvspublic/apr/dso/beos/dso.c,v retrieving revision 1.11 diff -u -d -b -r1.11 dso.c --- beos/dso.c 2000/11/09 06:08:35 1.11 +++ beos/dso.c 2001/01/11 21:05:30 @@ -56,7 +56,7 @@ #if APR_HAS_DSO -apr_status_t apr_dso_load(apr_dso_handle_t **res_handle, const char *path, +APR_DECLARE(apr_status_t) apr_dso_load(apr_dso_handle_t **res_handle, const char *path, apr_pool_t *ctx) { image_id newid; @@ -70,7 +70,7 @@ return APR_SUCCESS; } -apr_status_t apr_dso_unload(apr_dso_handle_t *handle) +APR_DECLARE(apr_status_t) apr_dso_unload(apr_dso_handle_t *handle) { if(unload_add_on(handle->handle) < B_NO_ERROR) return APR_EINIT; @@ -78,7 +78,7 @@ return APR_SUCCESS; } -apr_status_t apr_dso_sym(apr_dso_handle_sym_t *ressym, apr_dso_handle_t *handle, +APR_DECLARE(apr_status_t) apr_dso_sym(apr_dso_handle_sym_t *ressym, apr_dso_handle_t *handle, const char *symname) { int err; @@ -95,7 +95,7 @@ return APR_SUCCESS; } -const char *apr_dso_error(apr_dso_handle_t *dso, char *buffer, apr_size_t buflen) +APR_DECLARE(const char *) apr_dso_error(apr_dso_handle_t *dso, char *buffer, apr_size_t buflen) { strncpy(strerror(errno), buffer, buflen); return buffer; Index: os2/dso.c =================================================================== RCS file: /home/cvspublic/apr/dso/os2/dso.c,v retrieving revision 1.16 diff -u -d -b -r1.16 dso.c --- os2/dso.c 2000/12/23 03:07:10 1.16 +++ os2/dso.c 2001/01/11 21:05:31 @@ -68,7 +68,7 @@ } -apr_status_t apr_dso_load(apr_dso_handle_t **res_handle, const char *path, apr_pool_t *ctx) +APR_DECLARE(apr_status_t) apr_dso_load(apr_dso_handle_t **res_handle, const char *path, apr_pool_t *ctx) { char failed_module[200]; HMODULE handle; @@ -92,7 +92,7 @@ -apr_status_t apr_dso_unload(apr_dso_handle_t *handle) +APR_DECLARE(apr_status_t) apr_dso_unload(apr_dso_handle_t *handle) { int rc; @@ -109,7 +109,7 @@ -apr_status_t apr_dso_sym(apr_dso_handle_sym_t *ressym, +APR_DECLARE(apr_status_t) apr_dso_sym(apr_dso_handle_sym_t *ressym, apr_dso_handle_t *handle, const char *symname) { @@ -128,7 +128,7 @@ -const char *apr_dso_error(apr_dso_handle_t *dso, char *buffer, apr_size_t buflen) +APR_DECLARE(const char *) apr_dso_error(apr_dso_handle_t *dso, char *buffer, apr_size_t buflen) { char message[200]; apr_strerror(dso->load_error, message, sizeof(message)); Index: os390/dso.c =================================================================== RCS file: /home/cvspublic/apr/dso/os390/dso.c,v retrieving revision 1.3 diff -u -d -b -r1.3 dso.c --- os390/dso.c 2000/11/09 06:08:36 1.3 +++ os390/dso.c 2001/01/11 21:05:32 @@ -65,7 +65,7 @@ return apr_dso_unload(dso); } -apr_status_t apr_dso_load(apr_dso_handle_t **res_handle, const char *path, +APR_DECLARE(apr_status_t) apr_dso_load(apr_dso_handle_t **res_handle, const char *path, apr_pool_t *ctx) { dllhandle *handle; @@ -83,7 +83,7 @@ return errno; } -apr_status_t apr_dso_unload(apr_dso_handle_t *handle) +APR_DECLARE(apr_status_t) apr_dso_unload(apr_dso_handle_t *handle) { int rc; @@ -100,7 +100,7 @@ return errno; } -apr_status_t apr_dso_sym(apr_dso_handle_sym_t *ressym, +APR_DECLARE(apr_status_t) apr_dso_sym(apr_dso_handle_sym_t *ressym, apr_dso_handle_t *handle, const char *symname) { @@ -119,7 +119,7 @@ return errno; } -const char *apr_dso_error(apr_dso_handle_t *handle, char *buffer, +APR_DECLARE(const char *) apr_dso_error(apr_dso_handle_t *handle, char *buffer, apr_size_t buflen) { apr_cpystrn(buffer, strerror(handle->failing_errno), buflen); Index: unix/dso.c =================================================================== RCS file: /home/cvspublic/apr/dso/unix/dso.c,v retrieving revision 1.27 diff -u -d -b -r1.27 dso.c --- unix/dso.c 2000/12/15 16:56:54 1.27 +++ unix/dso.c 2001/01/11 21:05:34 @@ -61,7 +61,7 @@ #include <stddef.h> #endif -apr_status_t apr_dso_load(apr_dso_handle_t **res_handle, const char *path, +APR_DECLARE(apr_status_t) apr_dso_load(apr_dso_handle_t **res_handle, const char *path, apr_pool_t *ctx) { #if defined(HPUX) || defined(HPUX10) || defined(HPUX11) @@ -91,7 +91,7 @@ return APR_SUCCESS; } -apr_status_t apr_dso_unload(apr_dso_handle_t *handle) +APR_DECLARE(apr_status_t) apr_dso_unload(apr_dso_handle_t *handle) { #if defined(HPUX) || defined(HPUX10) || defined(HPUX11) shl_unload((shl_t)handle->handle); @@ -104,7 +104,7 @@ return APR_SUCCESS; } -apr_status_t apr_dso_sym(apr_dso_handle_sym_t *ressym, +APR_DECLARE(apr_status_t) apr_dso_sym(apr_dso_handle_sym_t *ressym, apr_dso_handle_t *handle, const char *symname) { @@ -146,7 +146,7 @@ #endif /* not HP-UX; use dlsym()/dlerror() */ } -const char *apr_dso_error(apr_dso_handle_t *dso, char *buffer, apr_size_t buflen) +APR_DECLARE(const char *) apr_dso_error(apr_dso_handle_t *dso, char *buffer, apr_size_t buflen) { if (dso->errormsg) { apr_cpystrn(buffer, dso->errormsg, buflen); Index: win32/dso.c =================================================================== RCS file: /home/cvspublic/apr/dso/win32/dso.c,v retrieving revision 1.14 diff -u -d -b -r1.14 dso.c --- win32/dso.c 2000/11/11 03:23:11 1.14 +++ win32/dso.c 2001/01/11 21:05:35 @@ -59,7 +59,7 @@ #if APR_HAS_DSO -apr_status_t apr_dso_load(struct apr_dso_handle_t **res_handle, const char *path, +APR_DECLARE(apr_status_t) apr_dso_load(struct apr_dso_handle_t **res_handle, const char *path, apr_pool_t *ctx) { HINSTANCE os_handle; @@ -114,7 +114,7 @@ return APR_SUCCESS; } -apr_status_t apr_dso_unload(struct apr_dso_handle_t *handle) +APR_DECLARE(apr_status_t) apr_dso_unload(struct apr_dso_handle_t *handle) { if (!FreeLibrary(handle->handle)) { return apr_get_os_error(); @@ -122,7 +122,7 @@ return APR_SUCCESS; } -apr_status_t apr_dso_sym(apr_dso_handle_sym_t *ressym, +APR_DECLARE(apr_status_t) apr_dso_sym(apr_dso_handle_sym_t *ressym, struct apr_dso_handle_t *handle, const char *symname) { @@ -136,7 +136,7 @@ return APR_SUCCESS; } -const char *apr_dso_error(apr_dso_handle_t *dso, char *buf, apr_size_t bufsize) +APR_DECLARE(const char *) apr_dso_error(apr_dso_handle_t *dso, char *buf, apr_size_t bufsize) { return apr_strerror(dso->load_error, buf, bufsize); }