Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 327589 - dev-lang/php-5.3.3[oci8-instant-client]: 'OCI_ATTR_SPOOL_AUTH' undeclared
Summary: dev-lang/php-5.3.3[oci8-instant-client]: 'OCI_ATTR_SPOOL_AUTH' undeclared
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Development (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: PHP Bugs
URL: http://svn.php.net/viewvc/php/php-src...
Whiteboard:
Keywords: Inclusion
Depends on:
Blocks:
 
Reported: 2010-07-09 09:07 UTC by Martin von Gagern
Modified: 2010-08-08 21:54 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
Add "&& defined(OCI_ATTR_SPOOL_AUTH)" check (gentoo327589a.patch,1.01 KB, patch)
2010-07-30 10:53 UTC, Martin von Gagern
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Martin von Gagern 2010-07-09 09:07:46 UTC
.../php-5.3.2/ext/oci8/oci8.c: In function 'php_oci_create_spool':
.../php-5.3.2/ext/oci8/oci8.c:2678: error: 'OCI_ATTR_SPOOL_AUTH' undeclared
                                    (first use in this function)

This was already mentioned in bug #274512 comment #121 but is probably better dealt with in a separate bug report.

I've got these oracle instant client packages installed on my system:
[I] dev-db/oracle-instantclient-basic (11.2.0.0.2-r1@28.01.2010)
[I] dev-db/oracle-instantclient-jdbc (11.2.0.0.2@28.01.2010)

Can't find that name in any of their files.
Comment 1 Martin von Gagern 2010-07-09 19:42:38 UTC
OK, looks like oracle-instantclient-basic-11.2.0.0.2-r1 doesn't define that symbol, but 11.2.0.1-r1 does. Sadly, the latter is masked by missing ~amd64 keyword for me.

The php source code checks OCI_MINOR_VERSION which is the same for both. As there is no finer VERSION macro, the best way to adjust to both situations on the preprocessor level would probably be to check whether OCI_ATTR_SPOOL_AUTH itself is defined, as that seems to be one of only two non-comment differences between the 11.2.0.0.2 and the 11.2.0.1 oci.h.

So I've two possible approaches to suggest:
1. keyword oracle-instantclient-basic-11.2.0.1-r1 for ~amd64 and depend on it
2. add "&& defined(OCI_ATTR_SPOOL_AUTH)" to the #if in oci8.c of the php tree

I've tested neither so far, but assume both should work. The former might give additional features, but I don't even begin to understand what this added code is all about.
Comment 2 Martin von Gagern 2010-07-18 17:48:25 UTC
(In reply to comment #1)
> 2. add "&& defined(OCI_ATTR_SPOOL_AUTH)" to the #if in oci8.c of the php tree
> I've tested neither so far, but assume both should work.

I've tested this, and encountered bug #324739 next. Which is an improvement of sorts, I guess...
Comment 3 Martin von Gagern 2010-07-27 07:41:07 UTC
dev-lang/php-5.3.3 is affected as well.
Comment 4 Martin von Gagern 2010-07-30 10:53:46 UTC
Created attachment 240667 [details, diff]
Add "&& defined(OCI_ATTR_SPOOL_AUTH)" check
Comment 5 Martin von Gagern 2010-08-08 11:24:04 UTC
OK, adding this patch to src_prepare and "addpredict /usr/share/snmp/mibs/.index" to src_compile, I finally managed to emerge php 5.3.3 successfully. I wonder how long it will take current PHP devs to comment on this bug, and how long to include the fixes for both this issue and bug #324739. The solutions are here, after all.
Comment 6 Matti Bickel (RETIRED) gentoo-dev 2010-08-08 13:22:59 UTC
Thanks for taking the time to report and investigate. I'm sorry for not responding sooner.

On the positive side, I'm about to roll php-5.3.3-r1 in one or two days, depending on pending testing in the php overlay. I will make sure to include your patch in the tarball, then.

Also, I'll investigate why 11.2.0.1-r1 is not marked ~amd64.
Comment 7 Matti Bickel (RETIRED) gentoo-dev 2010-08-08 13:52:50 UTC
You can add your voice to bug #326777 if you wish.
Comment 8 Matti Bickel (RETIRED) gentoo-dev 2010-08-08 21:54:39 UTC
php-5.3.3-r1 and php-patchset-5.3.3-r2 now include your patch. Thanks!

P.S.: Tobi stated a version bump for oracle-instantclient will happen late august/september.