You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@perl.apache.org by on 2002/08/16 01:14:52 UTC

compilation errors

trying to compile mod_perl-2.0 gives the following errors:
(apache-2.0.40 already built/installed):


$ make
cd "src/modules/perl" && make -f Makefile.modperl
make[1]: Entering directory `/usr/local/src/modperl-2.0_cvs/src/modules/perl'
cc -I/usr/local/src/modperl-2.0_cvs/src/modules/perl -I/usr/local/src/modperl-2.0_cvs/xs -I/usr/local/src/httpd-2.0_cvs/include -I/usr/local/src/httpd-2.0_cvs/srclib/apr/include -I/usr/local/src/httpd-2.0_cvs/srclib/apr-util/include -I/usr/local/src/httpd-2.0_cvs/os/unix -D_REENTRANT -fno-strict-aliasing -I/usr/local/include   -I/usr/local/lib/perl5/5.6.1/i686-linux-thread/CORE -DMOD_PERL -O2 -fpic \
-c mod_perl.c && mv mod_perl.o mod_perl.lo
mod_perl.c: In function `modperl_shutdown':
mod_perl.c:10: `thr' undeclared (first use in this function)
mod_perl.c:10: (Each undeclared identifier is reported only once
mod_perl.c:10: for each function it appears in.)
mod_perl.c: In function `modperl_hook_post_config':
mod_perl.c:414: `thr' undeclared (first use in this function)
mod_perl.c: In function `modperl_response_handler_cgi':
mod_perl.c:675: `thr' undeclared (first use in this function)
make[1]: *** [mod_perl.lo] Error 1
make[1]: Leaving directory `/usr/local/src/modperl-2.0_cvs/src/modules/perl'
make: *** [modperl_lib] Error 2
root@sindhu [make] /usr/local/src/modperl-2.0                                                                                     02-08-15  6:39PM



$ t/REPORT

-------------8<---------- Start Bug Report ------------8<----------
1. Problem Description:

  [DESCRIBE THE PROBLEM HERE]

2. Used Components and their Configuration:

*** using lib/Apache/BuildConfig.pm
*** Makefile.PL options:
  MP_AP_PREFIX    => /usr/local/src/httpd-2.0_cvs
  MP_GENERATE_XS  => 1
  MP_INST_APACHE2 => 1
  MP_LIBNAME      => mod_perl
  MP_USE_DSO      => 1
  MP_USE_STATIC   => 1


*** /usr/sbin/httpd -V
Server version: Apache/1.3.23 (Unix)  (Red-Hat/Linux)
Server built:   Jun 19 2002 11:55:23
Server's Module Magic Number: 19990320:13
Server compiled with....
 -D EAPI
 -D EAPI_MM
 -D EAPI_MM_CORE_PATH="/var/run/httpd.mm"
 -D HAVE_MMAP
 -D HAVE_SHMGET
 -D USE_SHMGET_SCOREBOARD
 -D USE_MMAP_FILES
 -D HAVE_FCNTL_SERIALIZED_ACCEPT
 -D HAVE_SYSVSEM_SERIALIZED_ACCEPT
 -D SINGLE_LISTEN_UNSERIALIZED_ACCEPT
 -D HTTPD_ROOT="/etc/httpd"
 -D SUEXEC_BIN="/usr/sbin/suexec"
 -D DEFAULT_PIDLOG="/var/run/httpd.pid"
 -D DEFAULT_SCOREBOARD="/var/run/httpd.scoreboard"
 -D DEFAULT_LOCKFILE="/var/run/httpd.lock"
 -D DEFAULT_XFERLOG="/var/log/httpd/access_log"
 -D DEFAULT_ERRORLOG="/var/log/httpd/error_log"
 -D TYPES_CONFIG_FILE="conf/mime.types"
 -D SERVER_CONFIG_FILE="conf/httpd.conf"
 -D ACCESS_CONFIG_FILE="conf/access.conf"
 -D RESOURCE_CONFIG_FILE="conf/srm.conf"


*** /usr/local/bin/perl -V
Summary of my perl5 (revision 5.0 version 6 subversion 1) configuration:
  Platform:
    osname=linux, osvers=2.4.3-12, archname=i686-linux-thread
    uname='linux sindhu 2.4.3-12 #1 fri jun 8 15:05:56 edt 2001 i686 unknown '
    config_args=''
    hint=recommended, useposix=true, d_sigaction=define
    usethreads=define use5005threads=define useithreads=undef usemultiplicity=undef
    useperlio=undef d_sfio=undef uselargefiles=define usesocks=undef
    use64bitint=undef use64bitall=undef uselongdouble=undef
  Compiler:
    cc='cc', ccflags ='-D_REENTRANT -fno-strict-aliasing -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64',
    optimize='-O2',
    cppflags='-D_REENTRANT -fno-strict-aliasing -I/usr/local/include'
    ccversion='', gccversion='2.96 20000731 (Red Hat Linux 7.1 2.96-85)', gccosandvers=''
    intsize=4, longsize=4, ptrsize=4, doublesize=8, byteorder=1234
    d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=12
    ivtype='long', ivsize=4, nvtype='double', nvsize=8, Off_t='off_t', lseeksize=8
    alignbytes=4, usemymalloc=n, prototype=define
  Linker and Libraries:
    ld='cc', ldflags =' -L/usr/local/lib'
    libpth=/usr/local/lib /lib /usr/lib
    libs=-lnsl -ldl -lm -lpthread -lc -lcrypt -lutil
    perllibs=-lnsl -ldl -lm -lpthread -lc -lcrypt -lutil
    libc=/lib/libc-2.2.2.so, so=so, useshrplib=false, libperl=libperl.a
  Dynamic Linking:
    dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='-rdynamic'
    cccdlflags='-fpic', lddlflags='-shared -L/usr/local/lib'


Characteristics of this binary (from libperl): 
  Compile-time options: USE_THREADS USE_LARGE_FILES PERL_IMPLICIT_CONTEXT
  Built under linux
  Compiled at Oct  6 2001 13:39:45
  %ENV:
    PERL_LWP_USE_HTTP_10="1"
  @INC:
    /usr/local/lib/perl5/5.6.1/i686-linux-thread
    /usr/local/lib/perl5/5.6.1
    /usr/local/lib/perl5/site_perl/5.6.1/i686-linux-thread
    /usr/local/lib/perl5/site_perl/5.6.1
    /usr/local/lib/perl5/site_perl/5.6.0
    /usr/local/lib/perl5/site_perl
    .


3. This is the core dump trace: (if you get a core dump):

  [CORE TRACE COMES HERE]

This report was generated by t/REPORT on Thu Aug 15 22:50:21 2002 GMT.

-------------8<---------- End Bug Report --------------8<----------


-- 
Dave Smith
<ds...@prastha.com>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: compilation errors

Posted by Doug MacEachern <do...@covalent.net>.
On Wed, 28 Aug 2002, Dave Smith wrote:

> Starting Apache2: [Wed Aug 28 14:42:31 2002] [error] unknown constant
> DIR_MAGIC_TYPE at

try modperl from cvs.  or if you want to wait until 1.99_06, simply define 
in your startup.pl:
sub Apache::DIR_MAGIC_TYPE () { "httpd/unix-directory" }


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: compilation errors

Posted by Dave Smith <ds...@prastha.com>.
>> (now if I
>> could just got Apache::MP3 to run under mod_perl2/Apache2...)
>
> You should be able to by adding:
>
> PerlModule Apache::compat
>
> If not, let us know what doesn't work.

Starting Apache2: [Wed Aug 28 14:42:31 2002] [error] unknown constant
DIR_MAGIC_TYPE at
/usr/local/lib/perl5/site_perl/5.8.0/i686-linux/Apache2/Apache/compat.pm
line 120.
BEGIN failed--compilation aborted at
/usr/local/lib/perl5/site_perl/5.8.0/Apache/MP3.pm line 5.
Compilation failed in require at /data/httpd/perl/startup2.pl line 35.
BEGIN failed--compilation aborted at /data/httpd/perl/startup2.pl line 35.
Compilation failed in require at (eval 1) line 1.

[Wed Aug 28 14:42:31 2002] [error] Can't load Perl file:
/data/httpd/perl/startup2.pl for server ...

my startup2.pl contains:
(Is there a difference between "use pkg();" and "use pkg;" )

########################
#!/opt/local/bin/perl -w

   use strict;

   use Apache2 ();
   use Apache::compat();

   $ENV{GATEWAY_INTERFACE} =~ /^CGI-Perl/
   or die "GATEWAY_INTERFACE not Perl!";

   use MP3::Info;
   use Apache::MP3;

   use Apache::CodeRed;
   use Apache::Nimba;

   use MIME::Body;
   use LWP::UserAgent ();

   use DBD::Oracle;
   use DBI;
   use Apache::DBI ();

   use CGI qw(-compile :all);

   use Carp ();
   $SIG{__WARN__} = \&Carp::cluck;

##################################






---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: compilation errors

Posted by Stas Bekman <st...@stason.org>.
Dave Smith wrote:
>>So since you are using prefork you don't have to upgrade to 5.8.0,
>>simply rebuild perl 5.6.1 without any threading enabled. (it'll also
>>make your mod_perl and perl faster). But if it's for testing go with
>>5.8.0 of course, since it's mucho improved compared to 5.6.1.

> I went ahead and upgraded to 5.8.0 and it worked fine. Thanks! 

Cool!

> (now if I
> could just got Apache::MP3 to run under mod_perl2/Apache2...)

You should be able to by adding:

PerlModule Apache::compat

If not, let us know what doesn't work.

__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: compilation errors

Posted by Dave Smith <ds...@prastha.com>.
> So since you are using prefork you don't have to upgrade to 5.8.0,
> simply rebuild perl 5.6.1 without any threading enabled. (it'll also
> make your mod_perl and perl faster). But if it's for testing go with
> 5.8.0 of course, since it's mucho improved compared to 5.6.1.
>
> __________________________________________________________________
> Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
> http://stason.org/     mod_perl Guide ---> http://perl.apache.org
> mailto:stas@stason.org http://use.perl.org http://apacheweek.com
> http://modperlbook.org http://apache.org   http://ticketmaster.com

I went ahead and upgraded to 5.8.0 and it worked fine. Thanks! (now if I
could just got Apache::MP3 to run under mod_perl2/Apache2...)




---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: compilation errors

Posted by Stas Bekman <st...@stason.org>.
Dave Smith wrote:
>>so we cannot see the build args. how did you build httpd-2.0?
>>/whereever/httpd-2.0/is/installed/httpd -V
> 
> 
> Server version: Apache/2.0.40
> Server built:   Aug 15 2002 07:27:22
> Server's Module Magic Number: 20020628:0
> Architecture:   32-bit
> Server compiled with....
>       -D APACHE_MPM_DIR="server/mpm/prefork"
>       -D APR_HAS_SENDFILE
>       -D APR_HAS_MMAP
>       -D APR_HAVE_IPV6
>       -D APR_USE_SYSVSEM_SERIALIZE
>       -D APR_USE_PTHREAD_SERIALIZE
>       -D SINGLE_LISTEN_UNSERIALIZED_ACCEPT
>       -D APR_HAS_OTHER_CHILD
>       -D AP_HAVE_RELIABLE_PIPED_LOGS
>       -D HTTPD_ROOT="/opt/local/apache2"
>       -D SUEXEC_BIN="/opt/local/apache2/bin/suexec"
>       -D DEFAULT_PIDLOG="logs/httpd.pid"
>       -D DEFAULT_SCOREBOARD="logs/apache_runtime_status"
>       -D DEFAULT_LOCKFILE="logs/accept.lock"
>       -D DEFAULT_ERRORLOG="logs/error_log"
>       -D AP_TYPES_CONFIG_FILE="conf/mime.types"
>       -D SERVER_CONFIG_FILE="conf/httpd.conf"
> 
> 
>  
> 
>> >    usethreads=define use5005threads=define useithreads=undef 
>>usemultiplicity=undef
>>
>>You need to build perl with -Duseithreads or without threads at all (if 
>>you aren't building a threaded mpm). Yours is built with 
>>-Duse5005threads, which won't work with mod_perl 2.0, since this perl 
>>threading model is deprecated. In any case for using the threaded mpms 
>>you need perl 5.8.0.
> 
> 
> I'll upgrade perl - thanx.

So since you are using prefork you don't have to upgrade to 5.8.0, 
simply rebuild perl 5.6.1 without any threading enabled. (it'll also 
make your mod_perl and perl faster). But if it's for testing go with 
5.8.0 of course, since it's mucho improved compared to 5.6.1.

__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: compilation errors

Posted by .
> so we cannot see the build args. how did you build httpd-2.0?
> /whereever/httpd-2.0/is/installed/httpd -V

Server version: Apache/2.0.40
Server built:   Aug 15 2002 07:27:22
Server's Module Magic Number: 20020628:0
Architecture:   32-bit
Server compiled with....
      -D APACHE_MPM_DIR="server/mpm/prefork"
      -D APR_HAS_SENDFILE
      -D APR_HAS_MMAP
      -D APR_HAVE_IPV6
      -D APR_USE_SYSVSEM_SERIALIZE
      -D APR_USE_PTHREAD_SERIALIZE
      -D SINGLE_LISTEN_UNSERIALIZED_ACCEPT
      -D APR_HAS_OTHER_CHILD
      -D AP_HAVE_RELIABLE_PIPED_LOGS
      -D HTTPD_ROOT="/opt/local/apache2"
      -D SUEXEC_BIN="/opt/local/apache2/bin/suexec"
      -D DEFAULT_PIDLOG="logs/httpd.pid"
      -D DEFAULT_SCOREBOARD="logs/apache_runtime_status"
      -D DEFAULT_LOCKFILE="logs/accept.lock"
      -D DEFAULT_ERRORLOG="logs/error_log"
      -D AP_TYPES_CONFIG_FILE="conf/mime.types"
      -D SERVER_CONFIG_FILE="conf/httpd.conf"


 
>  >    usethreads=define use5005threads=define useithreads=undef 
> usemultiplicity=undef
> 
> You need to build perl with -Duseithreads or without threads at all (if 
> you aren't building a threaded mpm). Yours is built with 
> -Duse5005threads, which won't work with mod_perl 2.0, since this perl 
> threading model is deprecated. In any case for using the threaded mpms 
> you need perl 5.8.0.

I'll upgrade perl - thanx.

-- 
Dave Smith
<ds...@prastha.com>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: compilation errors

Posted by Stas Bekman <st...@stason.org>.
[it'd be nice if you set your From: field:

From: Dave Smith <>
To: dev@perl.apache.org

]

Dave Smith wrote:
> trying to compile mod_perl-2.0 gives the following errors:
> (apache-2.0.40 already built/installed):

For some reason it finds Apache/1.3.23

> *** /usr/sbin/httpd -V
> Server version: Apache/1.3.23 (Unix)  (Red-Hat/Linux)
                   ^^^^^^^^^^^^^

so we cannot see the build args. how did you build httpd-2.0?
/whereever/httpd-2.0/is/installed/httpd -V

 >    usethreads=define use5005threads=define useithreads=undef 
usemultiplicity=undef

You need to build perl with -Duseithreads or without threads at all (if 
you aren't building a threaded mpm). Yours is built with 
-Duse5005threads, which won't work with mod_perl 2.0, since this perl 
threading model is deprecated. In any case for using the threaded mpms 
you need perl 5.8.0.


__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org