On Sun, Feb 26, 2012 at 3:30 PM, Michael Felt <[email protected]> wrote:
> Unfortunately, although it builds fine, it does not start:
>
> httpd: Syntax error on line 143 of /etc/httpd/httpd.conf: Cannot load
> /opt/httpd/libexec/mod_mpm_worker.so into server: rtld: 0712-001 Symbol
> ap_fatal_signal_setup was referenced\n      from module
> /opt/httpd/libexec/mod_mpm_worker.so(), but a runtime definition\n      of
> the symbol was not found.\nrtld: 0712-001 Symbol ap_pid_fname was
> referenced\n      from module /opt/httpd/libexec/mod_mpm_worker.so(), but a
> runtime definition\n      of the symbol was not found.\nrtld: 0712-001
> Symbol ap_reclaim_child_processes was referenced\n      from module
> /opt/httpd/libexec/mod_mpm_worker.so(), but a runtime definition\n      of
> the symbol was not found.\nrtld: 0712-001 Symbol ap_relieve_child_processes
> was referenced\n      from module /opt/httpd/libexec/mod_mpm_worker.so(),
> but a runtime definition\n      of the symbol was not found.\nrtld: 0712-001
> Symbol ap_graceful_shutdown_timeout was referenced\n      from module
> /opt/httpd/libexec/mod_mpm_worker.so(), but a runtime definition\n      of
> the symbol was not found.\nrtld: 0712-001 Symbol ap_mpm_safe_kill was
> referenced\n      from module /opt/httpd/libexec/mod_mpm_worker.so(), but a
> runtime definition\n      of the symbol was not found.\nrtld: 0712-001
> Symbol ap_wait_or_timeout was referenced\n      from module
> /opt/httpd/libexec/mod_mpm_worker.so(), but a runtime definition\n      of
> the symbol was not found.\n\t0509-021 Additional errors occurred but are not
> reported.
>
> I have been able to find a few of these routines in source code, e,g,
> server/mpm_unix.c, but the routines are not included in server/mpm_worker.o,
> hence ....
>
> Suggestions welcome (other than filing a bug report).

I guess the problem is that those MPM APIs are not decorated with
AP_DECLARE() so they don't get added to httpd.exp so they don't get
exported from httpd on AIX.

Can you try the attached patch to mpm_common.h?
Index: include/mpm_common.h
===================================================================
--- include/mpm_common.h	(revision 1293841)
+++ include/mpm_common.h	(working copy)
@@ -102,8 +102,8 @@
  * in the scoreboard as well as those currently registered via
  * ap_register_extra_mpm_process().
  */
-void ap_reclaim_child_processes(int terminate,
-                                ap_reclaim_callback_fn_t *mpm_callback);
+AP_DECLARE(void) ap_reclaim_child_processes(int terminate,
+                                            ap_reclaim_callback_fn_t *mpm_callback);
 
 /**
  * Catch any child processes that have been spawned by the parent process
@@ -115,7 +115,7 @@
  * in the scoreboard as well as those currently registered via
  * ap_register_extra_mpm_process().
  */
-void ap_relieve_child_processes(ap_reclaim_callback_fn_t *mpm_callback);
+AP_DECLARE(void) ap_relieve_child_processes(ap_reclaim_callback_fn_t *mpm_callback);
 
 /**
  * Tell ap_reclaim_child_processes() and ap_relieve_child_processes() about
@@ -154,7 +154,7 @@
  * APR_EINVAL is returned if passed either an invalid (< 1) pid, or if
  * the pid is not in the current process group
  */
-apr_status_t ap_mpm_safe_kill(pid_t pid, int sig);
+AP_DECLARE(apr_status_t) ap_mpm_safe_kill(pid_t pid, int sig);
 
 /**
  * Run the monitor hook (once every ten calls), determine if any child
@@ -166,8 +166,9 @@
  * @param p The pool to allocate out of
  * @param s The server_rec to pass
  */
-void ap_wait_or_timeout(apr_exit_why_e *status, int *exitcode, apr_proc_t *ret,
-                        apr_pool_t *p, server_rec *s);
+AP_DECLARE(void) ap_wait_or_timeout(apr_exit_why_e *status, int *exitcode,
+                                    apr_proc_t *ret, apr_pool_t *p, 
+                                    server_rec *s);
 
 /**
  * Log why a child died to the error log, if the child died without the
@@ -296,7 +297,7 @@
 /**
  * The filename used to store the process id.
  */
-extern const char *ap_pid_fname;
+AP_DECLARE_DATA const char *ap_pid_fname;
 const char *ap_mpm_set_pidfile(cmd_parms *cmd, void *dummy,
                                const char *arg);
 void ap_mpm_dump_pidfile(apr_pool_t *p, apr_file_t *out);
@@ -312,7 +313,7 @@
 /**
  * Set the timeout period for a graceful shutdown.
  */
-extern int ap_graceful_shutdown_timeout;
+AP_DECLARE_DATA extern int ap_graceful_shutdown_timeout;
 const char *ap_mpm_set_graceful_shutdown(cmd_parms *cmd, void *dummy,
                                          const char *arg);
 #define AP_GRACEFUL_SHUTDOWN_TIMEOUT_COMMAND \
@@ -332,7 +333,7 @@
 extern const char *ap_mpm_set_thread_stacksize(cmd_parms *cmd, void *dummy,
                                                const char *arg);
 
-extern apr_status_t ap_fatal_signal_setup(server_rec *s, apr_pool_t *pconf);
+AP_DECLARE(apr_status_t) ap_fatal_signal_setup(server_rec *s, apr_pool_t *pconf);
 extern apr_status_t ap_fatal_signal_child_setup(server_rec *s);
 
 /* core's implementation of child_status hook */

Reply via email to