Re: [Oorexx-devel] Installing from source

2009-05-03 Thread Klaas.
Op 03-mei-09 schreef Mark Miesfeld:

>On Sun, May 3, 2009 at 9:31 AM, Klaas.  wrote:

>>  I am trying to get ooRexx 4.0 up on my openSuse
>>  system.

>Until I get the source file package fixed, I'm curious as to why you
>don't want to install one of the already built packages for your
>openSuse system?

Well, my hardware is Mac. I use mostly PPC Macs and one Intel Mac.
On 2 of those I have open Suse installed. On all of those I have
ooRexx 3.2 (both Suse and OS X).

So that's why.

greetings,
  Klaas.  

>There's nothing wrong with wanting to build yourself, I probably
>would.  As I said just curious.


--
Register Now & Save for Velocity, the Web Performance & Operations 
Conference from O'Reilly Media. Velocity features a full day of 
expert-led, hands-on workshops and two days of sessions from industry 
leaders in dedicated Performance & Operations tracks. Use code vel09scf 
and Save an extra 15% before 5/3. http://p.sf.net/sfu/velocityconf
___
Oorexx-devel mailing list
Oorexx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-devel


Re: [Oorexx-devel] Some findings on how orxscript works

2009-05-03 Thread Rony G. Flatscher

> A maybe helpful URL, that contains other interesting links:
>  with a lot of
> interesting downloads>
>   
Ah, was too quick, here a few more links, which you may know of already:

* : Scripting
  Main Entry point
* 
  Windows Script Host Main Entry
* 
  Developer's Branch into Windows Script Host (look at all subnodes)

These pointers should give quite a fair overview.

Also, if you download the WSH package (don't have a URL handy) one gets
an installable help-file that not only documents the WSH classes, but
also the COM interfaces defined for Windows script host applications.
(Have a zip-archive someplace.)

---rony

--
Register Now & Save for Velocity, the Web Performance & Operations 
Conference from O'Reilly Media. Velocity features a full day of 
expert-led, hands-on workshops and two days of sessions from industry 
leaders in dedicated Performance & Operations tracks. Use code vel09scf 
and Save an extra 15% before 5/3. http://p.sf.net/sfu/velocityconf___
Oorexx-devel mailing list
Oorexx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-devel


Re: [Oorexx-devel] Some findings on how orxscript works

2009-05-03 Thread Rony G. Flatscher

Mark Miesfeld wrote:
> I don't have a whole lot of help here.  I really don't have much
> understanding of how the scripting host is supposed to function, and
> at one point I spent a lot of time trying to find examples and / or
> documentation on it.
>
> A couple of comments that really are more to your original post
> yesterday.  It seems to me that:
>
> a.) Microsoft never expected people to write their own scripting host
> engines.  They expected people to script using the Microsoft provided
> host engines.  I say this because compared to their other
> technologies, there is just no documentation on how to write a
> scripting host engine.
>   
There is a company, named ActiveState which has been producing
WSH/ActiveX scripting engines for popular scirpting languages like Perl
(a.k.a. Perlscript). AFAIK they have hired former Microsoft employees
who have worked on WSH/ActiveX and therefore have been able to know all
the ins and outs.

> b.) It seems to be a technology that Microsoft abandoned, or just let
> drift away.  I say that because they haven't done anything new with it
> since the 90's.  Sure they still support it, but they support in the
> same way they still support using the 16-bit Windows APIs.
>   
It is as dead or as alive as COM/OLE itself, IMHO. Microsoft has been
trying hard to persuade everyone into .Net instead. However, it is
reported that more than 50 % of the .Net efforts got invested in making
the brdiging between COM/OLE and .Net as stable as possible, as too many
customers have invested too heavily into COM/OLE.

Actually, I would dub WSH/ActiveX to be a "mature technology", as it is
at the heart of the MS InternetExplorer's DHTML for JSCript and
VBScript. In addition it is the core technology for ASP AFAIK. These are
also reasons, I think, why MS tried from the beginning to get it as
stable as possible as early as possible as well. There may just be no
reason to add anything new to it, as it serves already nicely its purpose.

The WSH technology is also vital for scripting Windows itself (and there
are mega-tons of scripts out there that use that part). [PowerShell is
another attempt to allow for replacing that application area, but this
will take decades as well.]

The WSH is of strategic importance for the Windows platform, hence I
think WSH will probably be around - like Windows itself - another
twenty, thirty years or more.


> That said, I do have a collection URLs pointing to things I found that
> seemed  most helpful.  I send that to you in an e-mail so you can take
> look at them.
>   

A maybe helpful URL, that contains other interesting links:
 with a lot of
interesting downloads>

---rony


--
Register Now & Save for Velocity, the Web Performance & Operations 
Conference from O'Reilly Media. Velocity features a full day of 
expert-led, hands-on workshops and two days of sessions from industry 
leaders in dedicated Performance & Operations tracks. Use code vel09scf 
and Save an extra 15% before 5/3. http://p.sf.net/sfu/velocityconf
___
Oorexx-devel mailing list
Oorexx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-devel


Re: [Oorexx-devel] Question on New Translate Parameters

2009-05-03 Thread Gil Barmwater
Will do and thanks for the reassurance that I'm not yet senile!

Rick McGuire wrote:
> Gil,
> 
> This is a category of problem known as a "doc bug".  The correct
> results for these calls
> are "aBCDef" and "4ab3", as you expected.  Please open a doc tracker for this.
> 
> Rick
> 
> On Sun, May 3, 2009 at 11:28 AM, Gil Barmwater  
> wrote:
> 
>>In working on my Symposium presentation on the new stuff in 4.0.0, I
>>came across the examples of the new Translate parameters - pos, length.
>> At first, I thought this one - TRANSLATE("abcdef", , , , 2, 3) ->
>>"ABCDEF" - must be wrong as I expected the result to be "aBCDef" but
>>then realised that since both tables and pad were omitted, the default
>>"uppercasing" was done and the pos, length parameters were ignored.  OK,
>> a bit surprising but so far, so good.  Then I got to the second
>>example of the new parameters - TRANSLATE("4123", "abcd", "1234", , 2,
>>2) -> "1ab4" - and I'm really confused.  Why isn't the result "4ab3",
>>i.e. only the second and third characters are translated?
>>--
>>Gil Barmwater
>>
>>--
>>Register Now & Save for Velocity, the Web Performance & Operations
>>Conference from O'Reilly Media. Velocity features a full day of
>>expert-led, hands-on workshops and two days of sessions from industry
>>leaders in dedicated Performance & Operations tracks. Use code vel09scf
>>and Save an extra 15% before 5/3. http://p.sf.net/sfu/velocityconf
>>___
>>Oorexx-devel mailing list
>>Oorexx-devel@lists.sourceforge.net
>>https://lists.sourceforge.net/lists/listinfo/oorexx-devel
>>
> 
> 
> --
> Register Now & Save for Velocity, the Web Performance & Operations 
> Conference from O'Reilly Media. Velocity features a full day of 
> expert-led, hands-on workshops and two days of sessions from industry 
> leaders in dedicated Performance & Operations tracks. Use code vel09scf 
> and Save an extra 15% before 5/3. http://p.sf.net/sfu/velocityconf
> ___
> Oorexx-devel mailing list
> Oorexx-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/oorexx-devel
> 

-- 
Gil Barmwater

--
Register Now & Save for Velocity, the Web Performance & Operations 
Conference from O'Reilly Media. Velocity features a full day of 
expert-led, hands-on workshops and two days of sessions from industry 
leaders in dedicated Performance & Operations tracks. Use code vel09scf 
and Save an extra 15% before 5/3. http://p.sf.net/sfu/velocityconf
___
Oorexx-devel mailing list
Oorexx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-devel


Re: [Oorexx-devel] Some findings on how orxscript works

2009-05-03 Thread Mark Miesfeld
Rick,

I don't have a whole lot of help here.  I really don't have much
understanding of how the scripting host is supposed to function, and
at one point I spent a lot of time trying to find examples and / or
documentation on it.

A couple of comments that really are more to your original post
yesterday.  It seems to me that:

a.) Microsoft never expected people to write their own scripting host
engines.  They expected people to script using the Microsoft provided
host engines.  I say this because compared to their other
technologies, there is just no documentation on how to write a
scripting host engine.

b.) It seems to be a technology that Microsoft abandoned, or just let
drift away.  I say that because they haven't done anything new with it
since the 90's.  Sure they still support it, but they support in the
same way they still support using the 16-bit Windows APIs.

That said, I do have a collection URLs pointing to things I found that
seemed  most helpful.  I send that to you in an e-mail so you can take
a look at them.

--
Mark Miesfeld

On Sun, May 3, 2009 at 8:44 AM, Rick McGuire  wrote:
> Ok, I've managed to get a debug 3.2.0 install set up on my system, and
> the stuff I'm finding is a bit on the bizarre side.  Essentially all I
> did was set break points on all of the methods of orxscript.cpp and
> trace all of the calls between the scripting host and the Rexx
> scripting engine.  Initially, things look pretty good.  When running
> the simpleorexx.wsf sample, the script engine initializes, and is
> asked to parse the fragment of ooRexx code in the file that looks like
> this:
>
> Say "This is "GetScriptEngineInfo()
> Ver = "Accessing the version info from Rexx yields
> "ScriptEngineMajorVersion()"."
> Ver = Ver||ScriptEngineMinorVersion()"."ScriptEngineBuildVersion()
> Say Ver
>
> WScript~Echo("Done!")
>
>
> The code for parsing this file is truly strange.  It first calls
> RexxStart on a second thread to actually run this code, and uses one
> of those private APIs to grab the names of the ::ROUTINES PUBLIC
> contained in the file.  These function names are recorded, I believe,
> as globally available routines that can be called from other script
> contexts.  Then another undocumented API is called to convert this
> into a callable script.  This is very strange, but we can accomplish
> all of this using the routine/package classes in 4.0.
>
> Then it gets a little strange.  There is a call to the
> OrxScript::SetScriptState() method to set the state to UNINITIALIZED.
> This has the following comment at the code that is executed.
>
>    case SCRIPTSTATE_UNINITIALIZED:
>      // IIS (ASP server) sets the engine from STARTED to UNINITIALIZED
>      // from what I remember from the documentation, this is ILLEGAL
>      // it may be a shortcut way of rerunning a script, but only Microsoft
>      // knows exactly what is intended to happen in this scenario
>      // returning this error causes the webserver to shut down the engine
>      // and create a new instance again...
>      hResult = E_UNEXPECTED;
>      break;
>
> Well, this does exactly what the comment says it does.  The script
> engine instance is shut down, then a second instance is initialized.
> This one handles a different sequence of calls.  This time, a number
> of calls are made to AddNamedItem() passing in items with names like
> "WScript".  These are obviously the global objects that the script
> host exposes.  Then the ParseScriptText() method is called again to
> reparse the same script fragment that was used with the first instance
> of the engine.  This time, the fragment is run after being parsed, and
> a couple of special (and undocumented exits) come into play.  The
> first exit handles NOVALUE events, and will check for items that were
> added via AddNamedItem() on references to uninitialized variables.
> This is the magic that allows WScript to be a valid variable name when
> the script runs.  When the fragment completes, the termination exit is
> used to capture all of the variable names and register them as global
> names in the environment as well.
>
> I think I need to do some more tracing with a more complicated example
> that has multiple fragments so I understand the interactions between
> fragments, but this is what I've discovered so far.
>
> Right now, I have some obvious questions:
>
> 1)  Is this how the variable model should be handled, or should
> imported/exported variables be handled explicitly?  For example,
> Rony's suggestion of a .host environment entry might make some sense
> rather than using the somewhat strange implicit model.  These variable
> names as currently handled appear only visible for the toplevel
> fragments, and are not propagated to call ::routines included in the
> fragments.  Using the special accessor would allow a single visibility
> model.
>
> 2) Somewhat related is the question of what variables/routines get
> made visible to the outside worldand it would be nice to apply
> 

Re: [Oorexx-devel] Installing from source

2009-05-03 Thread Mark Miesfeld
On Sun, May 3, 2009 at 9:31 AM, Klaas.  wrote:

>  I am trying to get ooRexx 4.0 up on my openSuse
>  system.

Until I get the source file package fixed, I'm curious as to why you
don't want to install one of the already built packages for your
openSuse system?

There's nothing wrong with wanting to build yourself, I probably
would.  As I said just curious.

--
Mark Miesfeld

--
Register Now & Save for Velocity, the Web Performance & Operations 
Conference from O'Reilly Media. Velocity features a full day of 
expert-led, hands-on workshops and two days of sessions from industry 
leaders in dedicated Performance & Operations tracks. Use code vel09scf 
and Save an extra 15% before 5/3. http://p.sf.net/sfu/velocityconf
___
Oorexx-devel mailing list
Oorexx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-devel


Re: [Oorexx-devel] Installing from source

2009-05-03 Thread Mark Miesfeld
On Sun, May 3, 2009 at 9:31 AM, Klaas.  wrote:

>  I am trying to get ooRexx 4.0 up on my openSuse
>  system.
>  Downloaded the source - for all environments.
>  Tries to use ./configure as I would expect.
>  Nothing.

Sorry, this is probably my fault.  I've been packaging up the source
tar file for the beta since David has been very busy.  I probably
skipped a step.

I just tarred up the source tree as is, from a fresh checkout.  Now
that I think about it, there is a make target for "packaging" that I
think also produces a tar file.  That target probably produces what
you want.

I'll fix that later today.

--
Mark Miesfeld

--
Register Now & Save for Velocity, the Web Performance & Operations 
Conference from O'Reilly Media. Velocity features a full day of 
expert-led, hands-on workshops and two days of sessions from industry 
leaders in dedicated Performance & Operations tracks. Use code vel09scf 
and Save an extra 15% before 5/3. http://p.sf.net/sfu/velocityconf
___
Oorexx-devel mailing list
Oorexx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-devel


Re: [Oorexx-devel] Question on New Translate Parameters

2009-05-03 Thread Rick McGuire
Gil,

This is a category of problem known as a "doc bug".  The correct
results for these calls
are "aBCDef" and "4ab3", as you expected.  Please open a doc tracker for this.

Rick

On Sun, May 3, 2009 at 11:28 AM, Gil Barmwater  wrote:
> In working on my Symposium presentation on the new stuff in 4.0.0, I
> came across the examples of the new Translate parameters - pos, length.
>  At first, I thought this one - TRANSLATE("abcdef", , , , 2, 3) ->
> "ABCDEF" - must be wrong as I expected the result to be "aBCDef" but
> then realised that since both tables and pad were omitted, the default
> "uppercasing" was done and the pos, length parameters were ignored.  OK,
>  a bit surprising but so far, so good.  Then I got to the second
> example of the new parameters - TRANSLATE("4123", "abcd", "1234", , 2,
> 2) -> "1ab4" - and I'm really confused.  Why isn't the result "4ab3",
> i.e. only the second and third characters are translated?
> --
> Gil Barmwater
>
> --
> Register Now & Save for Velocity, the Web Performance & Operations
> Conference from O'Reilly Media. Velocity features a full day of
> expert-led, hands-on workshops and two days of sessions from industry
> leaders in dedicated Performance & Operations tracks. Use code vel09scf
> and Save an extra 15% before 5/3. http://p.sf.net/sfu/velocityconf
> ___
> Oorexx-devel mailing list
> Oorexx-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/oorexx-devel
>

--
Register Now & Save for Velocity, the Web Performance & Operations 
Conference from O'Reilly Media. Velocity features a full day of 
expert-led, hands-on workshops and two days of sessions from industry 
leaders in dedicated Performance & Operations tracks. Use code vel09scf 
and Save an extra 15% before 5/3. http://p.sf.net/sfu/velocityconf
___
Oorexx-devel mailing list
Oorexx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-devel


[Oorexx-devel] Some findings on how orxscript works

2009-05-03 Thread Rick McGuire
Ok, I've managed to get a debug 3.2.0 install set up on my system, and
the stuff I'm finding is a bit on the bizarre side.  Essentially all I
did was set break points on all of the methods of orxscript.cpp and
trace all of the calls between the scripting host and the Rexx
scripting engine.  Initially, things look pretty good.  When running
the simpleorexx.wsf sample, the script engine initializes, and is
asked to parse the fragment of ooRexx code in the file that looks like
this:

Say "This is "GetScriptEngineInfo()
Ver = "Accessing the version info from Rexx yields
"ScriptEngineMajorVersion()"."
Ver = Ver||ScriptEngineMinorVersion()"."ScriptEngineBuildVersion()
Say Ver

WScript~Echo("Done!")


The code for parsing this file is truly strange.  It first calls
RexxStart on a second thread to actually run this code, and uses one
of those private APIs to grab the names of the ::ROUTINES PUBLIC
contained in the file.  These function names are recorded, I believe,
as globally available routines that can be called from other script
contexts.  Then another undocumented API is called to convert this
into a callable script.  This is very strange, but we can accomplish
all of this using the routine/package classes in 4.0.

Then it gets a little strange.  There is a call to the
OrxScript::SetScriptState() method to set the state to UNINITIALIZED.
This has the following comment at the code that is executed.

case SCRIPTSTATE_UNINITIALIZED:
  // IIS (ASP server) sets the engine from STARTED to UNINITIALIZED
  // from what I remember from the documentation, this is ILLEGAL
  // it may be a shortcut way of rerunning a script, but only Microsoft
  // knows exactly what is intended to happen in this scenario
  // returning this error causes the webserver to shut down the engine
  // and create a new instance again...
  hResult = E_UNEXPECTED;
  break;

Well, this does exactly what the comment says it does.  The script
engine instance is shut down, then a second instance is initialized.
This one handles a different sequence of calls.  This time, a number
of calls are made to AddNamedItem() passing in items with names like
"WScript".  These are obviously the global objects that the script
host exposes.  Then the ParseScriptText() method is called again to
reparse the same script fragment that was used with the first instance
of the engine.  This time, the fragment is run after being parsed, and
a couple of special (and undocumented exits) come into play.  The
first exit handles NOVALUE events, and will check for items that were
added via AddNamedItem() on references to uninitialized variables.
This is the magic that allows WScript to be a valid variable name when
the script runs.  When the fragment completes, the termination exit is
used to capture all of the variable names and register them as global
names in the environment as well.

I think I need to do some more tracing with a more complicated example
that has multiple fragments so I understand the interactions between
fragments, but this is what I've discovered so far.

Right now, I have some obvious questions:

1)  Is this how the variable model should be handled, or should
imported/exported variables be handled explicitly?  For example,
Rony's suggestion of a .host environment entry might make some sense
rather than using the somewhat strange implicit model.  These variable
names as currently handled appear only visible for the toplevel
fragments, and are not propagated to call ::routines included in the
fragments.  Using the special accessor would allow a single visibility
model.

2) Somewhat related is the question of what variables/routines get
made visible to the outside worldand it would be nice to apply
this to object instances too.  This is really item 1A) really, rather
than a separate item.

Rick

--
Register Now & Save for Velocity, the Web Performance & Operations 
Conference from O'Reilly Media. Velocity features a full day of 
expert-led, hands-on workshops and two days of sessions from industry 
leaders in dedicated Performance & Operations tracks. Use code vel09scf 
and Save an extra 15% before 5/3. http://p.sf.net/sfu/velocityconf
___
Oorexx-devel mailing list
Oorexx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-devel


[Oorexx-devel] Installing from source

2009-05-03 Thread Klaas.
Hi,

  I am trying to get ooRexx 4.0 up on my openSuse
  system.
  Downloaded the source - for all environments.
  Tries to use ./configure as I would expect.
  Nothing.
  After some time and study of older documentation
  (there doesn't seem to be recent doc in the source
   directory) I found the bootstrap file. 
  Apparently all necessary info is generated by
  utilities. During install of autoconf I realised
  that it would probably be much more efficient
  if one of the developers would generate the 
  necessary confihure file and make this available
  for anyone wishing to install from source.

  Is this an option?

greetings,
  Klaas Punt 


--
Register Now & Save for Velocity, the Web Performance & Operations 
Conference from O'Reilly Media. Velocity features a full day of 
expert-led, hands-on workshops and two days of sessions from industry 
leaders in dedicated Performance & Operations tracks. Use code vel09scf 
and Save an extra 15% before 5/3. http://p.sf.net/sfu/velocityconf
___
Oorexx-devel mailing list
Oorexx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-devel


[Oorexx-devel] Question on New Translate Parameters

2009-05-03 Thread Gil Barmwater
In working on my Symposium presentation on the new stuff in 4.0.0, I 
came across the examples of the new Translate parameters - pos, length. 
  At first, I thought this one - TRANSLATE("abcdef", , , , 2, 3) -> 
"ABCDEF" - must be wrong as I expected the result to be "aBCDef" but 
then realised that since both tables and pad were omitted, the default 
"uppercasing" was done and the pos, length parameters were ignored.  OK, 
  a bit surprising but so far, so good.  Then I got to the second 
example of the new parameters - TRANSLATE("4123", "abcd", "1234", , 2, 
2) -> "1ab4" - and I'm really confused.  Why isn't the result "4ab3", 
i.e. only the second and third characters are translated?
-- 
Gil Barmwater

--
Register Now & Save for Velocity, the Web Performance & Operations 
Conference from O'Reilly Media. Velocity features a full day of 
expert-led, hands-on workshops and two days of sessions from industry 
leaders in dedicated Performance & Operations tracks. Use code vel09scf 
and Save an extra 15% before 5/3. http://p.sf.net/sfu/velocityconf
___
Oorexx-devel mailing list
Oorexx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-devel