Re: Undefined symbol "modperl_io_perlio_restore_stdout"

2014-11-06 Thread Michael Schout
On 9/14/14 1:08 PM, Bernard T. Higonnet wrote:
> -8<-- Start Bug Report 8<--
> 1. Problem Description:

99% sure what happened is that you didn't patch libtool in the mod_perl
dist.

Libtool misidentifies FreeBSD 10 as FreeBSD 1.x, and therefore thinks it
cannot create shared libraries.  You have to patch libtool and all of
the libtool associated files so that it does not recognize it as FreeBSD
1.x.

You need to patch configure, ltconfig, and ltmain.sh to fix this.

See the patch-libtool rule in your FreeBSD ports tree at:

Mk/Uses/libtool.mk

for an example of how to patch this.

If you fail to patch libtool, the error below is exactly what you will see:

> /tmp/mod_perl-2.0.8/src/modules/perl/mod_perl.so: Undefined symbol
> "modperl_io_perlio_restore_stdout"

I just ran into this myself a few weeks ago.

Hope it helps.

Its not really mod_perl specific.  Many packages have this problem due
to shipping with libtool that mis-identifies FreeBSD 10.

Regards,
Michael Schout


Undefined symbol "modperl_io_perlio_restore_stdout"

2014-09-14 Thread Bernard T. Higonnet

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

Can't even start tests...

waiting 120 seconds for server to start: .httpd: Syntax error on line 13 
of /tmp/mod_perl-2.0.8/t/conf/httpd.conf: Cannot load 
/tmp/mod_perl-2.0.8/src/modules/perl/mod_perl.so into server: 
/tmp/mod_perl-2.0.8/src/modules/perl/mod_perl.so: Undefined symbol 
"modperl_io_perlio_restore_stdout"



2. Used Components and their Configuration:

*** mod_perl version 2.08

*** using /tmp/mod_perl-2.0.8/lib/Apache2/BuildConfig.pm

*** Makefile.PL options:
  MP_APR_LIB => aprext
  MP_APXS=> /usr/local/apache2/bin/apxs
  MP_COMPAT_1X   => 1
  MP_GENERATE_XS => 1
  MP_LIBNAME => mod_perl
  MP_USE_DSO => 1


*** /usr/local/apache2/bin/httpd -V
Server version: Apache/2.2.29 (Unix)
Server built:   Sep 14 2014 12:19:19
Server's Module Magic Number: 20051115:36
Server loaded:  APR 1.5.1, APR-Util 1.5.3
Compiled using: APR 1.5.1, APR-Util 1.5.3
Architecture:   32-bit
Server MPM: Prefork
  threaded: no
forked: yes (variable process count)
Server compiled with
 -D APACHE_MPM_DIR="server/mpm/prefork"
 -D APR_HAS_SENDFILE
 -D APR_HAS_MMAP
 -D APR_HAVE_IPV6 (IPv4-mapped addresses enabled)
 -D APR_USE_FLOCK_SERIALIZE
 -D APR_USE_PTHREAD_SERIALIZE
 -D SINGLE_LISTEN_UNSERIALIZED_ACCEPT
 -D APR_HAS_OTHER_CHILD
 -D AP_HAVE_RELIABLE_PIPED_LOGS
 -D DYNAMIC_MODULE_LIMIT=128
 -D HTTPD_ROOT="/usr/local/apache2"
 -D SUEXEC_BIN="/usr/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"

*** /usr/bin/ldd /usr/local/apache2/bin/httpd
/usr/local/apache2/bin/httpd:
libldap-2.4.so.2 => /usr/local/lib/libldap-2.4.so.2 (0x28144000)
liblber-2.4.so.2 => /usr/local/lib/liblber-2.4.so.2 (0x28183000)
libm.so.5 => /lib/libm.so.5 (0x2819)
libexpat.so.6 => /usr/local/lib/libexpat.so.6 (0x281b2000)
libcrypt.so.5 => /lib/libcrypt.so.5 (0x281d5000)
libthr.so.3 => /lib/libthr.so.3 (0x281f8000)
libc.so.7 => /lib/libc.so.7 (0x2821a000)
libssl.so.7 => /usr/lib/libssl.so.7 (0x28384000)
libcrypto.so.7 => /lib/libcrypto.so.7 (0x283de000)


*** (apr|apu)-config linking info

 -L/usr/local/apache2/lib -laprutil-1 -lldap -llber-lexpat 
-L/usr/local/lib

 -L/usr/local/apache2/lib -lapr-1 -lcrypt  -lpthread



*** /usr/local/bin/perl -V
Summary of my perl5 (revision 5 version 16 subversion 3) configuration:

  Platform:
osname=freebsd, osvers=10.0-release-p7, 
archname=i386-freebsd-thread-multi-64int
uname='freebsd 10i386-default-job-04 10.0-release-p7 freebsd 
10.0-release-p7 i386 '
config_args='-sde -Dprefix=/usr/local 
-Darchlib=/usr/local/lib/perl5/5.16/mach 
-Dprivlib=/usr/local/lib/perl5/5.16 -Dman3dir=/usr/lo
config_args='-sde -Dprefix=/usr/local 
-Darchlib=/usr/local/lib/perl5/5.16/mach 
-Dprivlib=/usr/local/lib/perl5/5.16 
-Dman3dir=/usr/local/lib/perl5/5.16/perl/man/man3 
-Dman1dir=/usr/local/man/man1 
-Dsitearch=/usr/local/lib/perl5/site_perl/5.16/mach 
-Dsitelib=/usr/local/lib/perl5/site_perl/5.16 -Dscriptdir=/usr/local/bin 
-Dsiteman3dir=/usr/local/lib/perl5/5.16/man/man3 
-Dsiteman1dir=/usr/local/man/man1 -Ui_malloc -Ui_iconv 
-Uinstallusrbinperl -Dcc=cc -Duseshrplib -Dinc_version_list=none 
-Dccflags=-DAPPLLIB_EXP="/usr/local/lib/perl5/5.16/BSDPAN" 
-Doptimize=-O2 -pipe -fno-strict-aliasing -Ui_gdbm -Dusethreads=y 
-Dusemymalloc=n -Duse64bitint'

hint=recommended, useposix=true, d_sigaction=define
useithreads=define, usemultiplicity=define
useperlio=define, d_sfio=undef, uselargefiles=define, usesocks=undef
use64bitint=define, use64bitall=undef, uselongdouble=undef
usemymalloc=n, bincompat5005=undef
  Compiler:
cc='cc', ccflags ='-DAPPLLIB_EXP="/usr/local/lib/perl5/5.16/BSDPAN" 
-DHAS_FPSETMASK -DHAS_FLOATINGPOINT_H -fno-strict-aliasing -pipe 
-fstack-protector -I/usr/local/include',

optimize='-O2 -pipe -fno-strict-aliasing',
cppflags='-DAPPLLIB_EXP="/usr/local/lib/perl5/5.16/BSDPAN" 
-DHAS_FPSETMASK -DHAS_FLOATINGPOINT_H -fno-strict-aliasing -pipe 
-fstack-protector -I/usr/local/include'
ccversion='', gccversion='4.2.1 Compatible FreeBSD Clang 3.3 
(tags/RELEASE_33/final 183502)', gccosandvers=''

intsize=4, longsize=4, ptrsize=4, doublesize=8, byteorder=12345678
d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=12
ivtype='long long', ivsize=8, nvtype='double', nvsize=8, 
Off_t='off_t', lseeksize=8