Thread: [cx-oracle-users] xa.h missing
Brought to you by:
atuining
From: Harri P. <har...@tr...> - 2004-11-18 09:03:11
|
Hello, I saw someone else had hit the same problem on linux, where by xa.h header was not found. Wouldn't it be prudent to inline the relevant bits in cx_Oracle.c, as xa.h does not seem to be a standard include? The only place I could find it was on a windows machine Oracle 9.2 directory, at rdbms/demo/xa.h. I modified my local copy by adding the following in cx_Oracle.c, in place of #include "xa.h" ------------------------------------------------ // Inline relevant bits from non-std xa.h /* * Transaction branch identification: XID and NULLXID: */ #define XIDDATASIZE 128 /* size in bytes */ #define MAXGTRIDSIZE 64 /* maximum size in bytes of gtrid */ #define MAXBQUALSIZE 64 /* maximum size in bytes of bqual */ struct xid_t { long formatID; /* format identifier */ long gtrid_length; /* value from 1 through 64 */ long bqual_length; /* value from 1 through 64 */ char data[XIDDATASIZE]; }; typedef struct xid_t XID; // end of inline --------------------------------------------------- Now it compiles, yet to see if it actually works ;-) -Harri This message, including any attachments, is intended only for the person(s) to whom it is addressed. If you received it in error, please let us know and delete the message from your system. This message may be confidential and may fall under the duty of non-disclosure. Any use by others than the intended addressee is prohibited. Trema shall not be liable for any damage related to the electronic transmission of this message, such as failure or delay of its delivery, interception or manipulation by third parties, or transmission of viruses or other malicious code. |
From: Anthony T. <an...@co...> - 2004-11-18 14:54:51
|
Simply including the file would be simpler I'd agree but are there any implications with respect to distributing code which is not my own? Is it enough to simply state that this section of code comes from xa.h and leave it at that or is something more elaborate required? I've left it alone since in general those who are missing these files have not installed all of the developer packages for Oracle -- Oracle makes this fairly easy to do, unfortunately. Any others have comments? Harri Pasanen wrote: > Hello, > > I saw someone else had hit the same problem on linux, where by xa.h > header was not found. > > Wouldn't it be prudent to inline the relevant bits in cx_Oracle.c, as > xa.h does not seem to be a standard include? The only place I could > find it was on a windows machine Oracle 9.2 directory, at > rdbms/demo/xa.h. > > I modified my local copy by adding the following in cx_Oracle.c, in > place of #include "xa.h" > > ------------------------------------------------ > // Inline relevant bits from non-std xa.h > > /* > * Transaction branch identification: XID and NULLXID: > */ > > > #define XIDDATASIZE 128 /* size in bytes */ > #define MAXGTRIDSIZE 64 /* maximum size in bytes of gtrid */ > #define MAXBQUALSIZE 64 /* maximum size in bytes of bqual */ > struct xid_t { > long formatID; /* format identifier */ > long gtrid_length; /* value from 1 through 64 */ > long bqual_length; /* value from 1 through 64 */ > char data[XIDDATASIZE]; > }; > typedef struct xid_t XID; > > // end of inline > --------------------------------------------------- > > Now it compiles, yet to see if it actually works ;-) > > > -Harri > > > This message, including any attachments, is intended only for the person(s) to whom it is addressed. If you received it in error, please let us know and delete the message from your system. This message may be confidential and may fall under the duty of non-disclosure. Any use by others than the intended addressee is prohibited. Trema shall not be liable for any damage related to the electronic transmission of this message, such as failure or delay of its delivery, interception or manipulation by third parties, or transmission of viruses or other malicious code. > > > > ------------------------------------------------------- > This SF.Net email is sponsored by: InterSystems CACHE > FREE OODBMS DOWNLOAD - A multidimensional database that combines > robust object and relational technologies, making it a perfect match > for Java, C++,COM, XML, ODBC and JDBC. www.intersystems.com/match8 > _______________________________________________ > cx-oracle-users mailing list > cx-...@li... > https://lists.sourceforge.net/lists/listinfo/cx-oracle-users -- Anthony Tuininga an...@co... Computronix Distinctive Software. Real People. Suite 200, 10216 - 124 Street NW Edmonton, AB, Canada T5N 4A3 Phone: (780) 454-3700 Fax: (780) 454-3838 http://www.computronix.com |
From: Jim B. <ma...@ji...> - 2004-11-18 18:51:25
|
Anthony Tuininga wrote: > Simply including the file would be simpler I'd agree but are there any > implications with respect to distributing code which is not my own? Is > it enough to simply state that this section of code comes from xa.h > and leave it at that or is something more elaborate required? I've > left it alone since in general those who are missing these files have > not installed all of the developer packages for Oracle -- Oracle makes > this fairly easy to do, unfortunately. Any others have comments? > > Harri Pasanen wrote: > >> Hello, >> >> I saw someone else had hit the same problem on linux, where by xa.h >> header was not found. >> >> Wouldn't it be prudent to inline the relevant bits in cx_Oracle.c, as >> xa.h does not seem to be a standard include? The only place I could >> find it was on a windows machine Oracle 9.2 directory, at >> rdbms/demo/xa.h. >> >> I modified my local copy by adding the following in cx_Oracle.c, in >> place of #include "xa.h" >> >> ... > > Anthony, I agree with your decision on IP grounds. The one time this caused an issue for us is when we tried installing cx_Oracle with the new 10g Instant Client on RHEL3. Oracle on RHEL3 requires 10g or patches to 9iR2, available only under the support contract, which is gray for us because we are outside consultants to our customer with actual support; cx_Oracle requires such dev files as xa.h. So an obvious solution for now is the full install of Oracle 10g client, and building cx_Oracle on the target machine. Obviously an even easier solution for Instant Client users - and that sort of describes this type of user - would be an RPM for 10g. (Hint, hint! :) ) For those who don't know about the client: http://www.oracle.com/technology/tech/oci/instantclient/instantclient.html. - Jim PS BTW, Anthony, kudos for making such a robust & useful package available! |
From: Anthony T. <an...@co...> - 2004-11-18 19:23:32
|
Jim Baker wrote: > Anthony Tuininga wrote: > >> Simply including the file would be simpler I'd agree but are there any >> implications with respect to distributing code which is not my own? Is >> it enough to simply state that this section of code comes from xa.h >> and leave it at that or is something more elaborate required? I've >> left it alone since in general those who are missing these files have >> not installed all of the developer packages for Oracle -- Oracle makes >> this fairly easy to do, unfortunately. Any others have comments? >> >> Harri Pasanen wrote: >> >>> Hello, >>> >>> I saw someone else had hit the same problem on linux, where by xa.h >>> header was not found. >>> >>> Wouldn't it be prudent to inline the relevant bits in cx_Oracle.c, as >>> xa.h does not seem to be a standard include? The only place I could >>> find it was on a windows machine Oracle 9.2 directory, at >>> rdbms/demo/xa.h. >>> >>> I modified my local copy by adding the following in cx_Oracle.c, in >>> place of #include "xa.h" >>> >>> ... >> >> > Anthony, > > I agree with your decision on IP grounds. > > The one time this caused an issue for us is when we tried installing > cx_Oracle with the new 10g Instant Client on RHEL3. Oracle on RHEL3 > requires 10g or patches to 9iR2, available only under the support > contract, which is gray for us because we are outside consultants to our > customer with actual support; cx_Oracle requires such dev files as xa.h. > > So an obvious solution for now is the full install of Oracle 10g client, > and building cx_Oracle on the target machine. Obviously an even easier > solution for Instant Client users - and that sort of describes this type > of user - would be an RPM for 10g. (Hint, hint! :) ) I hope to be able to do that for the next release (which will be 4.1). > For those who don't know about the client: > http://www.oracle.com/technology/tech/oci/instantclient/instantclient.html. > > - Jim > > PS > > BTW, Anthony, kudos for making such a robust & useful package available! You're welcome. -- Anthony Tuininga an...@co... Computronix Distinctive Software. Real People. Suite 200, 10216 - 124 Street NW Edmonton, AB, Canada T5N 4A3 Phone: (780) 454-3700 Fax: (780) 454-3838 http://www.computronix.com |