Wouldn't you know it... Just when Forth is starting to get some attention in OSX, I find that an assumption is no longer correct. ;(

Has anyone figured out how to make lib.fs work in Panther (10.3.2)?

I now get:

in file included from *the terminal*:0
/Volumes/MyUFS/BRDaR/Samples/GForth/sleep.fth:43: Proc not found!
1 (int) libc sleep _sleep
                   ^^^^^^
Backtrace:
$207BBC throw
$22384C c(abort")
$223924 @proc
$223A30 proc,
$223D20 proc:

I should have figured that the transition to Panther couldn't be as smooth as it had seemed, but I had a few other priorities (G5) since I tried it last August.

DaR

On Jun 11, 2003, at 9:02 AM, Dennis Ruffer wrote:

Thanks Jorge! Simple and complete and it even works. ;) DaR

On 6/11/03 8:37 AM, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote:



----- Mensaje Original -----
Remitente: Dennis Ruffer <[EMAIL PROTECTED]>
Fecha: Domingo, Junio 8, 2003 7:20 pm
Asunto: Re: [gforth] dylib vs. open-lib

Jorge,

Do you, maybe, have a simple example of calling a dylib that I
could use as
a starting point?  I'm having a hard time getting my head around
how this
works, and I don't even know if I have the gforth side setup
correctly yet.
I have both a fink setup (0.5.0-2) and my own (0.6.1).

Try this:

\ load library support
require lib.fs

\ create the word-defining word libc
library libc /usr/lib/libc.dylib

\ sleep() is called _sleep in libc.dylib
\ takes 1 argument and returns an int
1 (int) libc sleep _sleep

\ testing
10 sleep .

I guess the best reference is /sw/share/gforth/0.5.0/lib.fs

Tell me if you have any problem. Greetings,
Jorge



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Attachment: smime.p7s
Description: S/MIME cryptographic signature



Reply via email to