For FreeBSD users, calling a shared object file requires "branding"
the file as SVR4. Here is a simple example:

C (sqr.c):
int     square(int x)
{
       return x*x;
}


FreeBSD:
$ gcc -shared -o sqr.so sqr.c
$ brandelf -t SVR4 sqr.so


J:
   load 'dll'
   '"/home/steve/j/sqr.so" square > i i' cd 4
16


Steve
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to