mod_jk2 compilation issues on tru64 with gcc

W

William Rusch

Im having issues getting mod_jk2 for Apache and tomcat to compile
using, cygnus's gcc on tru64 5.1a

from the looks of it I dont understand why this is an issue.

here is the error:

gcc -g -O2 -DOSF1 -I../../include -I/install/httpd-2.0.48/include
-I/install/httpd-2.0.48/os/s%@OSDIR@%unix%g -g -O2
-I/install/httpd-2.0.48/srclib/apr-util/include
-I/install/httpd-2.0.48/srclib/apr/include -DCHUNK_SIZE=4096
-DUSE_APACHE_MD5 -DHAS_APR -DHAS_AP_PCRE -c
.../../common/jk_logger_file.c -DPIC -o
.../../../build/jk2/apache2/.libs/jk_logger_file.lo
In file included from ../../include/jk_global.h:104,
from ../../include/jk_logger.h:27,
from ../../include/jk_env.h:25,
from ../../common/jk_logger_file.c:25:
/usr/local/lib/gcc-lib/alpha-dec-osf5.1/2.9-gnupro-99r1/include/unistd.h:609:
warning: `cuserid' redefined
/usr/local/lib/gcc-lib/alpha-dec-osf5.1/2.9-gnupro-99r1/include/stdio.h:458:
warning: this is the location of the previous definition
.../../common/jk_logger_file.c: In function `jk2_logger_file_jkVLog':
.../../common/jk_logger_file.c:197: wrong type argument to unary
exclamation mark
gmake[1]: *** [../../../build/jk2/apache2/jk_logger_file.lo] Error 1
gmake[1]: Leaving directory
`/tomcat/tomcat.5.0.19/src/jakarta-tomcat-connectors/jk/native2/server/apache2'
gmake: *** [jk2-build] Error 1



here is the code snippet:

static int JK_METHOD jk2_logger_file_jkVLog(jk_env_t *env, jk_logger_t
*l,
const char *file,
int line,
int level,
const char *fmt,
va_list args)
{
int rc = 0;
char *buf;
char *fmt1;
apr_pool_t *aprPool = env->tmpPool->_private;
char rfctime[APR_RFC822_DATE_LEN];
apr_time_t time = apr_time_now();

if (!file || !args) ### this is the error line
return -1;


Any insight would be greatly appreciated.

Bill
 
M

Mark A. Odell

(e-mail address removed) (William Rusch) wrote in


va_list args)
{
int rc = 0;
char *buf;
char *fmt1;
apr_pool_t *aprPool = env->tmpPool->_private;
char rfctime[APR_RFC822_DATE_LEN];
apr_time_t time = apr_time_now();

if (!file || !args) ### this is the error line 197
return -1;

../../common/jk_logger_file.c:197: wrong type argument to unary

Any insight would be greatly appreciated.

It appears that !args is not a pointer or scalar. Look for some other way
to determine if 'args' is a valid object.
 
O

Old Wolf

Im having issues getting mod_jk2 for Apache and tomcat to compile
using, cygnus's gcc on tru64 5.1a

from the looks of it I dont understand why this is an issue.

here is the error:
../../common/jk_logger_file.c: In function `jk2_logger_file_jkVLog':
../../common/jk_logger_file.c:197: wrong type argument to unary
exclamation mark

here is the code snippet:

static int JK_METHOD jk2_logger_file_jkVLog(jk_env_t *env, jk_logger_t
*l,
const char *file,
int line,
int level,
const char *fmt,
va_list args)
{ [snip]
if (!file || !args) ### this is the error line
return -1;

You cannot go "!args" with a va_list. You should submit a bug
report to Apache or whoever is the appropriate organization.
If you feel dutiful you could re-write it to work, and also check
that they do not do other illegal things with va-lists.

I suggest making it "va_list *args" at first. Look out for when
va_end() is called too (make sure it is called exactly once for
each list).
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,054
Latest member
TrimKetoBoost

Latest Threads

Top