r3wp [groups: 83 posts: 189283]
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

World: r3wp

[SDK]

Maxim
23-Sep-2006
[783]
maybe that could get pushed in too.  it seems to me like a very easy 
fix...
BrianH
23-Sep-2006
[784]
Hey, they're doing all sorts of stuff for R3, this sounds like a 
good idea too
Maxim
23-Sep-2006
[785]
are you aware if rebcode is available within the SDK ?
BrianH
23-Sep-2006
[786]
It is not. It's not even finished, or stable for that matter.
Maxim
23-Sep-2006
[787]
arggghhh  :-)   I was doing wishfull thinking.  I really hope RT 
starts closing loose ends.  it seems to just be creating more and 
more.
BrianH
23-Sep-2006
[788]
I know the feeling.
Maxim
23-Sep-2006
[789]
bye, got to go get some zzzzzz  thanks for the chat  :-)
BrianH
23-Sep-2006
[790]
sleep too :-)
Gregg
23-Sep-2006
[791]
The resource APIs should make it easy, but you can also work against 
PE (Protable Executable) format files directly, editing resource 
tables and such. I wrote a resource compiler in VB a long time ago, 
and did quite a bit of research when writing a resource browser for 
PE files as well.
Maxim
28-Sep-2006
[792x5]
everyone, I just discovered the reason 'CALL hangs (wihtin SDK or 
straight within rebol/view 1.3.2)
if you do not have the console open, the moment CALL would print 
out something, it gets lost in stdout hell.
so, basically you should always do:


print " " to make sure you have a rebol console window up (or print 
to stdout if using cgi option in view or SDK) otherwise, call hangs 
indefinitely, occupying 100% of your cpu!
(or use Gabriele's async-call  ;-)
(or dockimbel's async-call)
Gabriele
29-Sep-2006
[797x2]
really? that is a very old bug, i had to do that in view 1.2.10, 
but i thought it was fixed in the newer sdk.
maybe it's still in rambo... (if not, please add it max)
Maxim
29-Sep-2006
[799x2]
will do
there is a similar post, I'll add my specificity and refer to the 
other within mine.
Louis
14-Oct-2006
[801x2]
Am I right that  REBOL/Encap 1.2.0.3.1 does not include the round 
function?
What do I have to change in my scripts so they will work with current 
version of encap?
Sunanda
14-Oct-2006
[803x2]
As far as I know the SDK is a version or two behind -- so no round 
(or maybe you have an out of date SDK)
Technically: all you need to do is copy
  source round
  source mod
from a later version of REBOL to your application
Licensing: is that permissable? You may need to ask RTmod: func [
    "Compute a nonnegative remainder of A divided by B."
    [catch]
    a [number! money! time!]
    b [number! money! time!] "Must be nonzero."
    /local r
][
    all [negative? r: a // b r: r + b]
    a: abs a
    either all [a + r = (a + b) positive? r + r - b] [r - b] [r]
]
Oops -- that answers the question "how to gte round to work with 
current SDK"
Your question was the other way around :-(
Plus I cat'npaste'ed too much in my reply
BrianH
14-Oct-2006
[805x2]
There are more current versions of the SDK that support all of the 
latest toys.
Encap/Face 1.2.0 is a little old - current is 1.3.2, just like with 
View. This is part of the 2.6.2 SDK, available for download for a 
while now.
Louis
14-Oct-2006
[807x2]
I also have 2.6.2, but I'm working on a script written several years 
ago, using 1.2.0.3.1, and it won't encap with 2.6.2.
What do I have to change in my script to make it encap with 2.6.2?
Oldes
15-Oct-2006
[809]
Nobody can say as nobody know what script you are talking about and 
what problem you have:-)
Sunanda
15-Oct-2006
[810]
More to the point, there is no published list of incompatibilties 
between diffeent versions of REBOL (not that I know of anyway).

Old scripts break in newer versions of REBOL. Some say that is an 
advantage of the language. For the rest of us, it's (at best) an 
annoyance.
Louis
15-Oct-2006
[811x3]
Oldes, the script is a double-entry fund accounting package. The 
problem is 2.6.2 dies trying to encap it.
Sunanda, that is what I was afraid of.  Without such a list I doubt 
that I could convert.  I'll just have keep and use my old version 
of the SDKI for encapping this script.
Thank all of you guys for your comments.
Oldes
15-Oct-2006
[814]
How it dies? Is it screaming? :-)
Louis
15-Oct-2006
[815]
It just lies down on its back, vomits out some meaningless error 
messages (perhaps confessing past sins), then quits breathing. Doesn't 
even blink an eye.  Then I click a button and it completely disappears, 
buried somewhere on my hard drive.  I dig it up and try to revive 
it, but it is hopeless....at least for now. :>) I'm trying to get 
over it, but it is hard.
Gabriele
15-Oct-2006
[816]
Sunanda: well, porting the Detective (which is 700k of uncompressed 
rebol code) from view 1.2 to 1.3 required only removing a patch for 
a bug in 1.2. everything else works without any change.
Louis
15-Oct-2006
[817x6]
Oldes, I have to eat some words. 2.6.2 encaps the script. But when 
I run the encapped script I get this error message:

Misplaced item: "imanXw"
** Script Error: Cannot use path on word!
value
** Near: insert tail funds fb/1
** Press enter to quit...
Does that help you, or Gabriele or someone know what is wrong?
If %view.r from the old SDK is included instead of %view.r from the 
new SDK, the script runs but gives the following error message:

Misplaced item: "imanXw"
Misplaced item: "Quit"
Misplaced item: [
    (write %session-time.txt (session-time
 + (difference now/precise time-start)))
    (write %exchange-rate.txt exchange-rat
e/text)
    quit
]
That is using 2.6.2 to do the encapping.
If I encap with 2.6.2, including %view.r also from 2.6.2 the script 
does not run, but instantly gives this error message:

** Script Error: exchange-rate has no valu
e
** Where: switch
** Near: forall args [
    val: first args
    switch/default type?/word val [
        pair! [append pairs val]
        integer...
** Press enter to quit...
Using the old SDK and the old %view.r the program runs without error.
Gabriele
16-Oct-2006
[823]
Louis: it's hard to say without having the source. Using the new 
SDK with the old SDK sources will probably not work. I think your 
problem is probably a change in VID (the latter error you report 
is from LAYOUT parsing values), so you should probably check your 
layout blocks (and related code). Try to run them from View and see 
what could be wrong.
Louis
16-Oct-2006
[824]
OK, Gabriele, thanks.
Louis
18-Oct-2006
[825x2]
Is there a better way to do this:

comment {
    ;do %/c/sdk/source/view.r
    do %/c/sdk-2-6-2/source/view.r
    do %t-db-functions.r
    do %request-date.r
}

    #include %/c/sdk/source/view.r ;NOTE: THIS IS THE OLD SDK. WON'T 
    WORK WITH NEW SDK.
    #include %t-db-functions.r
    #include %request-date.r


So that I don't have to comment out  lines when I switch from interpreter 
to encap and back.
Also, would be nice if security didn't popup when using the interpreter---it 
slow programming down.
BrianH
18-Oct-2006
[827x2]
First question: Have you considered using the preprocessor yourself 
to generate a script to interpret? See %prebol.r and %prerebol.r 
in the SDK. Second question: Try the -s parameter to the interpreter, 
it will turn security off.
BTW, those were not my questions, they were answers to the questions 
asked by Louis.
Louis
18-Oct-2006
[829]
Thanks, Brian. I'll check this out.
Gregg
18-Oct-2006
[830]
The common approach with INCLUDE is to have a "launcher" script  
that builds a complete script, as you would use PREREBOL; then you 
just DO that output script. Another way you can do it is to check 
a known word from the script with VALUE? and only DO the script if 
VALUE? returns false for a word you know is set in the script. That's 
also easy to put into a loop, with word and script pairs.
Maxim
8-Nov-2006
[831x2]
for all SDK experts..   why is this not actually dumping the print 
to the CMD.EXE command shell?

this is encapped using enpro.exe:

rebol [
	Encap: [cgi]
]

print "-----"
I can only view output if I execute my command with a pipe to more 
like so:

> test.exe | more