× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



I am trying to build a serviceprogram with ILE C modules so that the functions/procedures are accessable from RPG.

-----Original Message-----
From: c400-l-bounces+mihael.schmidt=rossmann.de@xxxxxxxxxxxx [mailto:c400-l-bounces+mihael.schmidt=rossmann.de@xxxxxxxxxxxx] On Behalf Of Mark S. Waterbury
Sent: Friday, December 03, 2010 3:23 PM
To: C programming iSeries / AS400
Subject: Re: [C400-L] Pointer to int and vice versa

Mihael:

Another alternative would be to compile your programs to run in PASE,
using either the GNU C/C++ compiler (GCC) or the AIX XL/C compiler, that
can be installed on i5/OS and runs under PASE. Then, you would just
need to run these programs from the PASE shell, QP2SHELL, or via QP2TERM
(interactive shell).

Mark

On 12/3/2010 9:05 AM, Schmidt, Mihael wrote:
I have gone that road (DTAMDL(*LLP64) with another project (which ain't finished yet) and it was aweful. It worked but I had to changed very much of the code which would not be necessary if I could just use the 128 data model.

Using 64bit data model would be my last choice atm.

But thanx.

Mihael

-----Original Message-----
From: c400-l-bounces+mihael.schmidt=rossmann.de@xxxxxxxxxxxx [mailto:c400-l-bounces+mihael.schmidt=rossmann.de@xxxxxxxxxxxx] On Behalf Of Mark S. Waterbury
Sent: Friday, December 03, 2010 2:54 PM
To: C programming iSeries / AS400
Subject: Re: [C400-L] Pointer to int and vice versa

Mihael:

This is precisely the problem of "storing a pointer in an integer."
(Those macros "cast" a pointer to an integer and vice versa.)

Create your C modules, programs or service programs to run "teraspace
enabled" and use only 64-bit pointers. That way, it is possible to
"cast" an integer to a pointer and vice versa, and to store a pointer in
an integer.

Use the ILE C compiler options DTAMDL(*LLP64) STGMDL(*TERASPACE)
TERASPACE(*YES *TSIFC) on the CRTCMOD or CRTBNDC commands.

Hope that helps,

Mark S. Waterbury

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.