<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "http://bugs.gentoo.org/bugzilla.dtd">

<bugzilla version="2.22.7"
          urlbase="http://bugs.gentoo.org/"
          maintainer="bugzilla@gentoo.org"
>

    <bug>
          <bug_id>56917</bug_id>
          
          <creation_ts>2004-07-13 09:24 0000</creation_ts>
          <short_desc>mod_php with USE=&quot;imap&quot; doesn&apos;t load under apache</short_desc>
          <delta_ts>2005-07-03 19:34:40 0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>Gentoo Linux</product>
          <component>Server</component>
          <version>unspecified</version>
          <rep_platform>PPC</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          
          <priority>P2</priority>
          <bug_severity>critical</bug_severity>
          <target_milestone>---</target_milestone>
          
          <blocked>56963</blocked>
          
          <everconfirmed>1</everconfirmed>
          <reporter>tobias@ppckernel.org</reporter>
          <assigned_to>ppc@gentoo.org</assigned_to>
          <cc>php-bugs@gentoo.org</cc>
    
    <cc>zul@gentoo.org</cc>

      

      
          <long_desc isprivate="0">
            <who>tobias@ppckernel.org</who>
            <bug_when>2004-07-13 09:24:44 0000</bug_when>
            <thetext>See below.  I tried remerging and got the same results.  4.3.4-r4 has been unmerged.  When I remove -D PHP4 from conf.d/apache2, apache runs fine.

Reproducible: Always
Steps to Reproduce:
1. emerge mod_php
2. /etc/init.d/apache2 restart
Actual Results:  
 * Stopping apache2...            [ ok ]
 * Starting apache2...            [ !! ]

Expected Results:  
 * Stopping apache2...            [ ok ]
 * Starting apache2...            [ ok ]

tail /var/log/apache2/error_log:

[Tue Jul 13 09:21:01 2004] [notice] caught SIGTERM, shutting down
Syntax error on line 5 of /usr/lib/apache2/conf/modules.d/70_mod_php.conf:
Cannot load /usr/lib/apache2/extramodules/libphp4.so into server:
/usr/lib/apache2/extramodules/libphp4.so: R_PPC_REL24 relocation at 0x0dba7f40
for symbol `RAND_seed&apos; out of range


emerge info:

Portage 2.0.50-r9 (default-ppc-2004.1, gcc-3.2.3, glibc-2.3.2-r9, 2.4.26-ppc-r2)
=================================================================
System uname: 2.4.26-ppc-r2 ppc 7400, altivec supported
Gentoo Base System version 1.4.16
Autoconf: sys-devel/autoconf-2.58-r1
Automake: sys-devel/automake-1.8.3
ACCEPT_KEYWORDS=&quot;ppc&quot;
AUTOCLEAN=&quot;yes&quot;
CFLAGS=&quot;-O2 -mcpu=7400 -maltivec -mabi=altivec -pipe&quot;
CHOST=&quot;powerpc-unknown-linux-gnu&quot;
COMPILER=&quot;gcc3&quot;
CONFIG_PROTECT=&quot;/etc /usr/kde/2/share/config /usr/kde/3/share/config
/usr/share/config /var/qmail/control&quot;
CONFIG_PROTECT_MASK=&quot;/etc/gconf /etc/env.d&quot;
CXXFLAGS=&quot;-O2 -mcpu=7400 -maltivec -mabi=altivec -pipe&quot;
DISTDIR=&quot;/usr/portage/distfiles&quot;
FEATURES=&quot;ccache&quot;
GENTOO_MIRRORS=&quot;gentoo.oregonstate.edu&quot;
MAKEOPTS=&quot;-j2&quot;
PKGDIR=&quot;/usr/portage/packages&quot;
PORTAGE_TMPDIR=&quot;/var/tmp&quot;
PORTDIR=&quot;/usr/portage&quot;
PORTDIR_OVERLAY=&quot;&quot;
SYNC=&quot;rsync://rsync.gentoo.org/gentoo-portage&quot;
USE=&quot;altivec apache2 berkdb cups dvd esd foomaticdb gd gdbm gif gpm imap imlib
jpeg libwww mbox mitshm motif mozilla mysql ncurses nls oggvorbis opengl oss pam
png ppc python readline sasl sdl slang ssl tcpd truetype xml xml2 xv&quot;</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>tobias@ppckernel.org</who>
            <bug_when>2004-07-13 09:59:12 0000</bug_when>
            <thetext>I masked 4.3.7-r1 and remerged 4.3.4-r4, same problem.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>robbat2@gentoo.org</who>
            <bug_when>2004-07-13 10:17:45 0000</bug_when>
            <thetext>go and trace down the RAND_seed symbol on your system and compile it with -fPIC.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>tobias@ppckernel.org</who>
            <bug_when>2004-07-15 08:28:37 0000</bug_when>
            <thetext>I tried the previously-working version of apache (2.0.49-r3) with both versions of PHP, same problem.  I also tried remerging openssl, which I think defines RAND_seed, same problem.  I just updated to mod_php 4.3.8, same problem.

My system is current except I&apos;m using:
sys-libs/glibc-2.3.2-r9
sys-devel/gcc-3.2.3-r4

Since the current snapshots are known broken.  Please advise - I&apos;m stuck on a production machine with no PHP.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>vapier@gentoo.org</who>
            <bug_when>2004-07-15 08:57:45 0000</bug_when>
            <thetext>RAND_seed comes from openssl i believe ...</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>tobias@ppckernel.org</who>
            <bug_when>2004-07-15 09:01:22 0000</bug_when>
            <thetext>Yes I think so too - any idea why it might be failing on that symbol?
Toby</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>tobias@ppckernel.org</who>
            <bug_when>2004-07-15 13:03:25 0000</bug_when>
            <thetext>mod_php works fine when I set USE=&quot;-imap&quot;

Toby</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>tobias@ppckernel.org</who>
            <bug_when>2004-07-15 13:13:42 0000</bug_when>
            <thetext>The problem is that net-libs/c-client is not installed, and it is blocked by virtual/imap-c-client (provided by net-mail/uw-imap).  How can I get the symbols supplied by c-client without removing uw-imap?  Is it simply a matter of telling php with imap to link to the uw-imap-provided c-client?

Toby</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>tobias@ppckernel.org</who>
            <bug_when>2004-07-15 13:35:39 0000</bug_when>
            <thetext>I rebuild uw-imap (the c-client provider) with USE=&quot;pic&quot; (position independent code), in hope of fixing:

R_PPC_REL24 relocation at 0x0dba7f40 for symbol `RAND_seed&apos; out of range

but no luck.  So perhaps PHP/ppc needs to be fixed to link against the PIC code in uw-imap?</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>robbat2@gentoo.org</who>
            <bug_when>2004-07-15 13:49:44 0000</bug_when>
            <thetext>net-libs/c-client  is a stripped down uw-imap, to provide the imap library and headers ONLY.
if you don&apos;t use uw-imap at all, unmerge it and merge c-client instead.
i&apos;ve definetly made sure the PIC stuff is in c-client.

try to build openssl, c-client, php, mod_php all in sequence with USE=&quot;ssl imap pic&quot;</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>tobias@ppckernel.org</who>
            <bug_when>2004-07-15 14:07:44 0000</bug_when>
            <thetext>I would, but I use uw-imap as my local imapd.  uw-imap is built with pic, shouldn&apos;t that work?  mod_php/imap did work fine before, when I was using the plain c-client (before I swapped it with uw-imap).</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>robbat2@gentoo.org</who>
            <bug_when>2004-07-15 14:53:39 0000</bug_when>
            <thetext>i&apos;ve added an r3 of uw-imap, with some of the c-client pic stuff ported over.
please try:
USE=&quot;ssl pic imap&quot; emerge openssl uw-imap php mod_php</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>tobias@ppckernel.org</who>
            <bug_when>2004-07-15 15:19:57 0000</bug_when>
            <thetext>After emerge sync I don&apos;t see net-mail/uw-imap-2002e-r3, even in ~ppc.  Where can I find it?  I&apos;m rebuilding anyway with the latest stable ebuild (r1).  Let me know if I need something else, or if this&apos;ll use your latest changes.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>robbat2@gentoo.org</who>
            <bug_when>2004-07-15 15:28:02 0000</bug_when>
            <thetext>you&apos;ll have to wait for r3 to reach the mirrors. should take 30-90 minutes depending how busy the various mirror systems are.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>tobias@ppckernel.org</who>
            <bug_when>2004-07-16 06:45:25 0000</bug_when>
            <thetext>I merged uw-imap-2002e-r3 and then rebuilt mod_php - it worked. Thanks!

It doesn&apos;t look like any of those packages USE &apos;pic&apos; anymore, but it didn&apos;t seem to matter.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>robbat2@gentoo.org</who>
            <bug_when>2004-07-16 20:49:07 0000</bug_when>
            <thetext>yeah, PIC support is forced in at the right place for c-client/uw-imap.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>tobias@ppckernel.org</who>
            <bug_when>2005-01-04 13:38:48 0000</bug_when>
            <thetext>When will this fix be integrated into the main branch?  I just tried merging uw-imap-2004 with mod_php-4.3.10 and got the same thing.

Thanks,
Toby</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>tobias@ppckernel.org</who>
            <bug_when>2005-01-04 13:50:32 0000</bug_when>
            <thetext>FYI I&apos;ve been using net-mail/uw-imap-2002e-r3 for 6 months now with absolute stability.  Whatever change was made I trust can be added to the main branch; it&apos;s rock solid.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>pylon@gentoo.org</who>
            <bug_when>2005-01-09 01:11:16 0000</bug_when>
            <thetext>net-mail/uw-imap-2004a is stable on ppc.  Could we close this bug or is there still a problem?</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>tobias@ppckernel.org</who>
            <bug_when>2005-01-09 07:20:14 0000</bug_when>
            <thetext>Maybe it&apos;s marked as stable, but it has the same bug as its &quot;stable&quot; predecessor, net-mail/uw-imap-2002e-r1 (that&apos;s why I reopened this bug).  The fix I need is:

  15 Jul 2004; Robin H. Johnson &lt;robbat2@gentoo.org&gt; :
  bug #56917, pic stuff.

(from the ChangeLog)</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>robbat2@gentoo.org</who>
            <bug_when>2005-02-14 00:12:36 0000</bug_when>
            <thetext>ppc: the amd64 guys did some fixes for c-client and uw-imap.
take a look at them and see if they solve this for you.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>josejx@gentoo.org</who>
            <bug_when>2005-07-02 11:46:34 0000</bug_when>
            <thetext>This seems fixed for me.  Please reopen the bug if you&apos;re still having problems.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>tobias@ppckernel.org</who>
            <bug_when>2005-07-03 19:34:40 0000</bug_when>
            <thetext>Yes now that uw-imap-2002e-r3 is marked stable this but is no longer relevant (r3 is the working version 
I moved to in January).</thetext>
          </long_desc>
      
    </bug>

</bugzilla>