Simon Coulter | 1 Jul 2010 02:03
Picon

Re: Problem with C++ module creation using INCLUDE env. variable


On 01/07/2010, at 12:40 AM, DARIUSZ OLBER wrote:

> it is running interactively.

OK, then it's not because the environment variables are not being  
copied to the batch job (see CPYENVVAR keyword on SBMJOB command for  
more information).

I think it's perhaps because of the complicated relationships between  
SRCSTMF, INCDIR, OPTION, and the INCLUDE environment variable. Note  
that I don't use source stream files but I note from the C/C++  
Compiler Reference (for VRM610):

Chapter 4. Page 85

	2. If SRCSTMF is specified, then the following compiler options are  
ignored:
	  o INCDIR( )
	  o OPTION(*INCDIRFIRST)
	  o TEXT(*SRCMBRTXT)
	  o OPTION(*STDINC)
	  o OPTION(*SYSINCPATH)

Note that INCDIR is ignored in this case (seems peculiar behaviour to  
me so perhaps the documentation is wrong on this point. It also  
contradicts the C/C++ Programmer's Guide). Note also that  
OPTION(*INCDIRFIRST) is ignored; this is relevant to the next item  
(but also seems wrong to me).

(Continue reading)

Dennis Lovelady | 1 Jul 2010 02:42

Re: Problem with C++ module creation using INCLUDE env. variable

I finally got the opportunity to play with this.  INCLUDE values that did
not work for me:
     ./include
     include

But both of these worked for me:
    ./include/
    include/

I hope it's that simple for you!

Dennis Lovelady
http://www.linkedin.com/in/dennislovelady
--
Change is inevitable, except from a vending machine. 

> > it is running interactively.
> 
> OK, then it's not because the environment variables are not being
> copied to the batch job (see CPYENVVAR keyword on SBMJOB command for
> more information).
> 
> I think it's perhaps because of the complicated relationships between
> SRCSTMF, INCDIR, OPTION, and the INCLUDE environment variable. Note
> that I don't use source stream files but I note from the C/C++
> Compiler Reference (for VRM610):
> 
> Chapter 4. Page 85
> 
> 	2. If SRCSTMF is specified, then the following compiler options
(Continue reading)

DARIUSZ OLBER | 1 Jul 2010 13:25
Picon

Re: Problem with C++ module creation using INCLUDE env. variable

Dennis Lovelady <iseries <at> ...> writes:

> 
> I finally got the opportunity to play with this.  INCLUDE values that did
> not work for me:
>      ./include
>      include
> 
> But both of these worked for me:
>     ./include/
>     include/
> 
> I hope it's that simple for you!
> 
> Dennis Lovelady
> http://www.linkedin.com/in/dennislovelady
> --
> Change is inevitable, except from a vending machine. 
> 
> > > it is running interactively.
> > 
> > OK, then it's not because the environment variables are not being
> > copied to the batch job (see CPYENVVAR keyword on SBMJOB command for
> > more information).
> > 
> > I think it's perhaps because of the complicated relationships between
> > SRCSTMF, INCDIR, OPTION, and the INCLUDE environment variable. Note
> > that I don't use source stream files but I note from the C/C++
> > Compiler Reference (for VRM610):
> > 
(Continue reading)

mailman | 1 Jul 2010 13:31

Guidelines for C400-L mailing list

Monthly posting of the guidelines for participation in the C/400 Language
Mailing List.

Keep to the subject.  The topic of the list is C and C++ Programming on and
for the AS/400. This includes programming on other platforms in C/C++ when
it RELATES to the AS/400.  Eg: Considerations of Sockets programming from
Windows to the AS/400 using MSVC & ILE/C is allowed and encouraged.  How to
manipulate a ClistView object in the Windows world is not allowed.

When quoting messages, do not quote the entire message.  Just quote the
parts that are needed to make the appropriate references.

Flames are absolutely prohibited.  If you disagree with someone, feel
free to argue the facts, but no personal attacks will be tolerated.

The official language of the C/400 Programming Mailing List is English.

Do not post personal messages.  Please use direct E-Mail.  This list is
international in scope and personal messages just end up costing money.

Please do not use HTML to format messages ... not everyone has a HTML
enabled message reader and the extra text can (and does) cause some
mail readers to truncate messages.

Advertising products or services (including press releases) are strictly
prohibited.  Also, if you have a solution that will specifically help
another participant, feel free to tell that person.  And finally, if you
are a vendor, please identify yourself as such... do not try to pass
yourself off as a user of your own products (even if you are).

(Continue reading)

Dennis Lovelady | 1 Jul 2010 14:25

Re: Problem with C++ module creation using INCLUDE env. variable

Interestingly, my working example was on a V5R3 system.  This morning I took that same working sample to
another system, and it will not compile with any of the INCLUDE values I had tried before.

Unfortunately I am not in a position where I can compare PTFs, but (if available) I'd look hard for PTFs in
that area for V5R3.

My test case:

/home/dlovelady/source/try-c.c
 #include "try-c.h"
 int main(int argc, char *argv[]) {
     }

/home/dlovelady/source/include/try-c.h
  // This is my include file and you cannot have it

ADDENVVAR INCLUDE '/home/dlovelady/source/include/'

Dennis Lovelady
http://www.linkedin.com/in/dennislovelady
--
"The only kind of love that makes a lifetime
Into a life well lived,
The only kind of love that ever fills you,
Is the love you give."
        -- David Wilcox 

> > I finally got the opportunity to play with this.  INCLUDE values that
> did
> > not work for me:
(Continue reading)

Victor Gonzalez | 12 Jul 2010 23:29
Picon
Favicon

keyed user queue


Hello to all,

I need to make an application that use keyed user 
queue. All examples in ibm site are with FIFO user queue. 
I was 
wondering if anyone in this mailing list have a simple example on how to
 use user queue with key, or any documentation where i can read in 
detail about the api for user queue ( i already checked ibm site )

Thanks
 in advance
 		 	   		   		 	   		  
_________________________________________________________________
The New Busy is not the old busy. Search, chat and e-mail from your inbox.
http://www.windowslive.com/campaign/thenewbusy?ocid=PID28326::T:WLMTAGL:ON:WL:en-US:WM_HMP:042010_3
--

-- 
This is the C programming iSeries / AS400 (C400-L) mailing list
To post a message email: C400-L@...
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/c400-l
or email: C400-L-request@...
Before posting, please take a moment to review the archives
at http://archive.midrange.com/c400-l.

Dennis Lovelady | 13 Jul 2010 00:36

Re: keyed user queue

I have a chat application that works based upon data queues, but I'd rather
not post the full source.

Can you help me focus on an area of interest?  What about keyed DQ gives you
trouble? 

Dennis Lovelady
http://www.linkedin.com/in/dennislovelady
--
"The brain is a wonderful organ; it starts the moment you get up in the
morning and does not stop until you get to the office."
        -- Robert Frost 

> I need to make an application that use keyed user
> queue. All examples in ibm site are with FIFO user queue.
> I was
> wondering if anyone in this mailing list have a simple example on how
> to
>  use user queue with key, or any documentation where i can read in
> detail about the api for user queue ( i already checked ibm site )
> 
> Thanks
>  in advance
> 
> _________________________________________________________________
> The New Busy is not the old busy. Search, chat and e-mail from your
> inbox.
> http://www.windowslive.com/campaign/thenewbusy?ocid=PID28326::T:WLMTAGL
> :ON:WL:en-US:WM_HMP:042010_3
> --
(Continue reading)

Simon Coulter | 13 Jul 2010 01:13
Picon

Re: keyed user queue


On 13/07/2010, at 7:29 AM, Victor Gonzalez wrote:

> I need to make an application that use keyed user
> queue. All examples in ibm site are with FIFO user queue.
> I was
> wondering if anyone in this mailing list have a simple example on  
> how to
> use user queue with key, or any documentation where i can read in
> detail about the api for user queue ( i already checked ibm site )

You didn't look very hard then. See the Information Centre:

Programming->APIs by category->Objects->User Queue APIs->Using User  
Queue APIs

This page says you need to use MI instructions to access the queue.  
The "batch machine" example on this page shows that MI instructions  
ENQ and DEQ (or rather the C function interfaces--enq() and deq() are  
used). Knowing that these are MI instructions might prompt you to look  
in the:

Programming->Machine interface programming->Machine interface  
instructions->i5/OS machine interface

where you will find documentation for the MI instructions. Also, the  
ILE C/C++ MI Library Reference (SC09-2418), which hasn't been updated  
in over a decade, provides documentation for the C function interfaces  
to MI. Note that they are really ILE interfaces and can be called from  
any ILE language that supports the necessary data types.
(Continue reading)

Dennis Lovelady | 13 Jul 2010 03:19

Re: keyed user queue

Of course I meant user spaces.  But Simon has you squared away, looks like.

Dennis Lovelady
http://www.linkedin.com/in/dennislovelady
--
Follow your dream! (Unless it's the one where you're at work in your
underwear during a fire drill.) 

> I have a chat application that works based upon data queues, but I'd
> rather
> not post the full source.
> 
> Can you help me focus on an area of interest?  What about keyed DQ
> gives you
> trouble?
> 
> Dennis Lovelady
> http://www.linkedin.com/in/dennislovelady
> --
> "The brain is a wonderful organ; it starts the moment you get up in the
> morning and does not stop until you get to the office."
>         -- Robert Frost
> 
> 
> > I need to make an application that use keyed user
> > queue. All examples in ibm site are with FIFO user queue.
> > I was
> > wondering if anyone in this mailing list have a simple example on how
> > to
> >  use user queue with key, or any documentation where i can read in
(Continue reading)

Dennis Lovelady | 13 Jul 2010 03:35

Re: keyed user queue

Q-U-E-U-E-S.  Sheesh.  I can do 'em, I just can't spell 'em.

Dennis Lovelady
http://www.linkedin.com/in/dennislovelady
--
"When science discovers the center of the universe a lot of people will be
disappointed to find they are not it."
        -- Bernard Baily 

> Of course I meant user spaces.  But Simon has you squared away, looks
> like.
> 
> Dennis Lovelady
> http://www.linkedin.com/in/dennislovelady
> --
> Follow your dream! (Unless it's the one where you're at work in your
> underwear during a fire drill.)
> 
> 
> > I have a chat application that works based upon data queues, but I'd
> > rather
> > not post the full source.
> >
> > Can you help me focus on an area of interest?  What about keyed DQ
> > gives you
> > trouble?
> >
> > Dennis Lovelady
> > http://www.linkedin.com/in/dennislovelady
> > --
(Continue reading)


Gmane