Full_Name: Roberto De Luca
Version: 2.8.1
OS: Solaris 7
Submission from: (NULL) (168.96.66.29)


Trying to compile mod_ssl with the gcc compiler I got the same problem
found by Stephen Taylor and stated in report PR#176 (long lines were
broken for readability):

-------------------------------------------------------------------------
gcc -c  -I../../os/unix -I../../include   -DSOLARIS2=270 -DMOD_SSL=208101
    -DEAPI -DUSE_EXPAT -I../../lib/expat-lite -fPIC -DSHARED_CORE -O2
    `../../apaci` -DSHARED_MODULE -I/usr/include -DMOD_SSL_VERSION=\"2.8.1\"
    ssl_engine_log.c && mv ssl_engine_log.o ssl_engine_log.lo
ssl_engine_log.c: In function `ssl_log':
ssl_engine_log.c:201: `__builtin_va_alist' undeclared (first use in this
functio
n)
ssl_engine_log.c:201: (Each undeclared identifier is reported only once
ssl_engine_log.c:201: for each function it appears in.)
*** Error code 1
make: Fatal error: Command failed for target `ssl_engine_log.lo'
----------------------------------------------------------------------

It believe that, at least in my case, the problem is due to the 
(somewhat) unusual location of the OpenSSL suite in my system.

I put the libraries (both libssl and libcrypto) under /usr/lib and 
the related include files under /usr/include/openssl.

When running the configure script it detects the include files under
/usr/include and adds "-I/usr/include" to the compiler command line.

It seems that locations specified on the command line with "-I" takes
precedence over the internal compiler (preprocessor) defaults. So the
gcc compiler is unable to find the patched version of some include
files, particularly "varargs.h", located in some obscure location,
something like /usr/local/lib/gcc-lib/sparc-sun-solarisX.X/X.XX.X/include.
Instead of that it takes the standard version of this file (located 
in /usr/include) and reports the stated error.

I want to remark that this problem does not occur when using the Sun 
C compiler (there is no need of patched include files in this case!).

I was able to correct the problem with a minor modification in the 
configure procedure. After this, both cc and gcc successfully compile
mod_ssl. In file src/modules/ssl/libssl.module I introduce the
following change:

========================================================================
*** src/modules/ssl/libssl.module.orig  Mon Jan  1 07:48:53 2001
--- src/modules/ssl/libssl.module       Sat Mar  3 14:13:57 2001
***************
*** 396,402 ****
              exit 1
          fi
      fi
!     SSL_CFLAGS="$SSL_CFLAGS -I\$(SSL_INCDIR)"

      #
      #  determine location of OpenSSL libraries
--- 396,404 ----
              exit 1
          fi
      fi
!     if [ ".$SSL_INCDIR" != ./usr/include ]; then
!         SSL_CFLAGS="$SSL_CFLAGS -I\$(SSL_INCDIR)"
!     fi

      #
      #  determine location of OpenSSL libraries
========================================================================

This change prevents the script to add "-I/usr/include" to the
command line. I believe that this modification have no negative
side effects, /usr/include should be among the compiler internal
default list of searched directories.

For your reference, my gcc compiler version is 2.95.2 (19991024) and
my Sun C compiler version is 4.2 (30 Oct 1996)
Finally, my APACI configure command was
"configure --enable-rule=SHARED_CORE --enable-module=most --enable-shared=max
           --enable-module=ssl --enable-shared=ssl --enable-rule=EAPI
           --disable-rule=SSL_COMPAT"
 



______________________________________________________________________
Apache Interface to OpenSSL (mod_ssl)                   www.modssl.org
User Support Mailing List                      [EMAIL PROTECTED]
Automated List Manager                            [EMAIL PROTECTED]

Reply via email to