The only messages I got were in relation to the definition of __memset.
I had a fellow create a dummy C module that used memset. We created the
module and added to the binding directory. I received no compilation
errors regarding memset usage from the dummy program when I compiled my
test program. The only difference I see is that the source for his is
in a member in his lib VS. being on the IFS. Below is the command used
to create the C module.
===> CRTCMOD MODULE(MIKELIB/EODELE) SRCSTMF('/source/endofdayelement.c')
DBGVIEW(*SOURCE) TERASPACE(*YES) INCDIR('/source'
'/qibm/ProdData/xmltoolkit/wscc-1.0-os400/include' '/usr/include')
In endofdayelement.c, this is the only code that refers to memset
void* Axis_Create_EndOfDayElement(int nSize)
{
if (nSize > 0)
{
int i;
EndOfDayElement** pNew = (EndOfDayElement**)
axiscAxisNewCArray(nSize);
for (i=0; i < nSize; ++i)
pNew[i] =
(EndOfDayElement*)Axis_Create_EndOfDayElement(0);
return (void *)pNew;
}
else
{
EndOfDayElement* pTemp = (EndOfDayElement
*)malloc(sizeof(EndOfDayElement));
memset(pTemp, 0, sizeof(EndOfDayElement));
return pTemp;
}
}
Could it be that the includes on the IFS are not the same as the
includes in QSYSINC? I tried adding '/qsys.lib/qsysinc.lib/h.file' to
the include directory part of the CRTMOD command. That did not work
either.
Here is the other information you requested.
DSPMOD
Display Module Information
Display
4 of 7
Module . . . . . . . . . . . . : EODELE
Library . . . . . . . . . . : MIKELIB
Detail . . . . . . . . . . . . : *IMPORT
Module attribute . . . . . . . : CLE
Imported (unresolved) symbols:
Symbol Name Symbol Type
ARGOPT
strtod PROCEDURE
*UNKNOWN
axiscSoapSerializerSerializeAsAttribute PROCEDURE *NO
axiscSoapSerializerSerialize PROCEDURE *NO
axiscSoapSerializerGetNamespacePrefix PROCEDURE *NO
axiscSoapSerializerSerializeAsElement PROCEDURE *NO
axiscSoapSerializerRemoveNamespacePrefix PROCEDURE *NO
axiscSoapDeSerializerPeekNextElementName PROCEDURE *NO
__strcmp PROCEDURE *NO
axiscSoapDeSerializerGetElementAsString PROCEDURE *NO
axiscSoapDeSerializerGetStatus PROCEDURE *NO
axiscAxisNewCArray PROCEDURE *NO
malloc PROCEDURE *NO
__memset PROCEDURE *NO
axiscAxisDeleteCArray PROCEDURE *NO
axiscAxisDelete PROCEDURE *NO
free PROCEDURE *NO
_C_exception_router PROCEDURE
*UNKNOWN
Q LE leDefaultEh PROCEDURE
*UNKNOWN
Display Module Information
Display
1 of 1
Module . . . . . . . . . . . . : EODELE
Library . . . . . . . . . . : MIKELIB
Detail . . . . . . . . . . . . : *REFSYSOBJ
Module attribute . . . . . . . : CLE
Reference system objects for bind time:
Object Library Type
QC2LE QSYS *BNDDIR
QILE *LIBL *BNDDIR
QUSAPIBD *LIBL *BNDDIR
-----Original Message-----
From: rpg400-l-bounces+mjfasnacht=theoccasionsgroup.com@xxxxxxxxxxxx
[mailto:rpg400-l-bounces+mjfasnacht=theoccasionsgroup.com@xxxxxxxxxxxx]
On Behalf Of Simon Coulter
Sent: Wednesday, October 03, 2007 10:36 PM
To: RPG programming on the AS400 / iSeries
Subject: Re: Definition not found for symbol '__memset'.
memset() is a function exported from the QC2UTIL2 service program.
memset() is defined in QSYSINC/H(STRING)
If you examine this member you'll see that memset() is mapped to
__memset() which is a built-in.
C source code, especially from another environment, will not directly
invoke __memset(). It will always use memset(). On i5/OS the compiler
will convert from the function to the built-in.
Now as to why __memset() cannot be resolved I cannot tell from the
supplied diagnostics. The supplied test code does not directly invoke
either memset or __memset so it must be from another module you are
binding to the test code. It would appear the EODELE *MODULE is found
via the MIKEBND binding directory.
The curious thing is that __memset does not need to be resolved. Run
DSPMOD on the OEDELE module. Examine the *IMPORT detail. Does
__memset appear in the list? It shouldn't. Examine the *REFSYSOBJ
detail. Does it include QC2LE? It should.
How was this module compiled? What compiler options were in effect?
Are there other error messages from the program creation step?
On 04/10/2007, at 6:27 AM, Fasnacht, Mike J (TOG) wrote:
Searching through the generated code I didn't find "__memset". I did
find plenty of usage of the "memset" c operation.
-----Original Message-----
From: rpg400-l-bounces@xxxxxxxxxxxx
[mailto:rpg400-l-bounces@xxxxxxxxxxxx] On Behalf Of Fasnacht, Mike J
(TOG)
Sent: Wednesday, October 03, 2007 1:27 PM
To: RPG programming on the AS400 / iSeries
Subject: RE: Definition not found for symbol '__memset'.
The place this __memset exists is in C code that was automatically
generated for me by the xmltoolkit program wsdl2ws.sh. I'm fairly
confident I can screw that code up. I'm not sure if that is the right
thing to do. Worst case scenario I can regenerate the code.
-----Original Message-----
From: rpg400-l-bounces@xxxxxxxxxxxx
[mailto:rpg400-l-bounces@xxxxxxxxxxxx] On Behalf Of Rory Hewitt
Sent: Wednesday, October 03, 2007 1:01 PM
To: RPG programming on the AS400 / iSeries
Subject: Re: Definition not found for symbol '__memset'.
Mike,
You should be able to simply replace '__memset' with 'memset' where
it's
defined on the procedure prototype (in one of your copybooks, I
guess).
Rory
--
Rory Hewitt
http://www.linkedin.com/in/roryhewitt
--
This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing
list
To post a message email: RPG400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/rpg400-l.
--
This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing
list
To post a message email: RPG400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/rpg400-l.
--
This is the RPG programming on the AS400 / iSeries (RPG400-L)
mailing list
To post a message email: RPG400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/rpg400-l.
Regards,
Simon Coulter.
--------------------------------------------------------------------
FlyByNight Software OS/400, i5/OS Technical Specialists
http://www.flybynight.com.au/
Phone: +61 2 6657 8251 Mobile: +61 0411 091 400 /"\
Fax: +61 2 6657 8251 \ /
X
ASCII Ribbon campaign against HTML E-Mail / \
--------------------------------------------------------------------
As an Amazon Associate we earn from qualifying purchases.