php with oci functions

Discussion in 'Plesk 7.0 3rd Party Software' started by marco.sala, Apr 29, 2004.

  1. marco.sala

    marco.sala Guest

    Hi to all,
    I'm new to this forum and I want to say hello to all...
    Now the problem:
    I need to configure plesk to resolve php code that use oci functions to work with oracle. I've already do that with plesk 2.5 recompiling apache and php sources with oci extension but now with the new plesk 7 I'm not able.
    I tried to copy all the compiling option of the php installed system but the server said:
    configure: error: Cannot find rfc822.h. Please check your IMAP installation.
    I know that imap and imap-ssl is installed on my server because it is up and running in plesk stack and also I cannot remove this option cause I think thet horde/imp works with imap service.
    Anyone has experience in plesk and oracle?

    Thanks in advance and reguards
     
  2. atomicturtle

    atomicturtle Product Expert

    Messages:
    3,812
    Heh, typical. Just when I drop the oracle support in my php rpms due to lack of interest... someone comes asking for it.

    Are you using oracle 9i?
     
  3. marco.sala

    marco.sala Guest

    Hi again,
    I'm using both oracle 9i and 10g but the 10g oci may only compiled with php 4.3.6.
    Any suggestion?

    Thanks in advance
     
  4. atomicturtle

    atomicturtle Product Expert

    Messages:
    3,812
    Ive only got 9i in my test environment, so I could put out a version with that in it. Cant do anything about 10g though, although I suspect it wont make any difference.

    Barring that, there are some compile-time settings that will let you add in oracle support when you rebuild the rpm (--define 'oracle 1'), assuming youve got your ld paths set up to point to the oracle 9i client library.
     
  5. marco.sala

    marco.sala Guest

    hi,
    when I've recompiled php with the oci support the only enviroment I've to set was --with-oci=$ORACLE_HOME and the oracle_home is one of my env parameters.
    I think that I're in right reguarding the support of ora9i angd ora10g but do you know where I can found the rpm - rpms?
    thanks and reguards
     
  6. atomicturtle

    atomicturtle Product Expert

    Messages:
    3,812
    I ment in regard to my/redhat's rpms. If youve got the libclntsh.so library on the box, you just do:

    rpmbuild --define 'oracle 1' --rebuild php-4.3.5-art.rh9.1.src.rpm
     
  7. marco.sala

    marco.sala Guest

    here's my shell output:

    rpmbuild --define 'ORACLE_HOME' --rebuild php-4.3.5-art.1.src.rpm

    error: Macro %ORACLE_HOME has empty body
    error: Macro %ORACLE_HOME has empty body
    error: Macro %ORACLE_HOME has empty body
    Installing php-4.3.5-art.1.src.rpm
    error: Failed build dependencies:
    imap-devel is needed by php-4.3.5-art.1

    and in the ORACLE_HOME\lib path there is the libclntsh.so of oracle, I've also find for imap-devel package but I can't found it, also RH3 channel does not have it.
    Can you help me to solve this trouble??

    thanks again and reguards
     
  8. atomicturtle

    atomicturtle Product Expert

    Messages:
    3,812
    I just told you how in the post above :)
     
  9. marco.sala

    marco.sala Guest

    hi again,
    I'm sorry but I'm not able to do that, this is my shell output:

    rpmbuild --define 'oracle 1' --rebuild php-4.3.5-art.1.src.rpm
    Installing php-4.3.5-art.1.src.rpm
    error: Failed build dependencies:
    imap-devel is needed by php-4.3.5-art.1

    I've used php-4.3.5-art.1.src.rpm insted of php-4.3.5-art.rh9.1.src.rpm because I use RH3.0 and I've found that rpm on your very usefull site but I cannot find imap-devel package, neither for RH9 or RH3.0.
    Thanks in advance.
     
  10. atomicturtle

    atomicturtle Product Expert

    Messages:
    3,812
    On my 3ES system its:
    imap-devel-1-2001a-18

    I pulled it from up2date (up2date -i imap-devel)
     
  11. marco.sala

    marco.sala Guest

    Hi again,
    I find all your suggest and it seems to work but after few minutes the compiling procedure went well but after few minutes in make process the output was:

    /usr/src/redhat/BUILD/php-4.3.5/ext/oci8/oci8.c:5527: request for member `in_call' in something not a structure or union
    /usr/src/redhat/BUILD/php-4.3.5/ext/oci8/oci8.c:5527: request for member `in_call' in something not a structure or union
    /usr/src/redhat/BUILD/php-4.3.5/ext/oci8/oci8.c:5527: request for member `tdo' in something not a structure or union
    /usr/src/redhat/BUILD/php-4.3.5/ext/oci8/oci8.c:5527: syntax error before ')' token
    /usr/src/redhat/BUILD/php-4.3.5/ext/oci8/oci8.c:5527: request for member `in_call' in something not a structure or union
    /usr/src/redhat/BUILD/php-4.3.5/ext/oci8/oci8.c:5535: request for member `id' in something not a structure or union
    make: *** [ext/oci8/oci8.lo] Error 1
    + popd
    /usr/src/redhat/BUILD/php-4.3.5
    + exit 0

    and also other errors before but they're really a lot and I think they are similar to the above.
    suggest?
    Thanks again in advance I really apprerciate
     
  12. atomicturtle

    atomicturtle Product Expert

    Messages:
    3,812
    thats too far down in the errors to see the cause, but rough guess, you're either missing the oracle includes, or your build environment is set up wrong.
     
  13. marco.sala

    marco.sala Guest

    Hello,
    Finally I've solved my problems: I've recompiled php-4.3.6 from sources with the same options phpinfo gives to me and the old error about the imap package was solved with the rpm you've told me to install (imap-devel-1-2001a-18).
    But I've found an oci library problem so I've reinstalled my oracle client stack (10g) and all sounds good, now I've complete control of oracle databases 10g under plesk.
    Thank for all suggests and best reguards
     

Share This Page