Gerd Pokorra
pokorra[at]uni-siegen.de
I think the easiest thing to do is have a look at the dynoplibs
directory. In this directory are a few test files with user-defined ops.
read the README file. It doesn't quite work for me as it is described
there, but that's probably something with my path settings.
Anyhow, this works for me:
according to the readme file, type this: (in the parrot root dir, not in
the dynoplibs directory)
parrot$ export LD_LIBRARY_PATH=.:blib/lib
parrot$ make -s
parrot$ make shared
parrot$ make -C dynoplibs
Then, I have to edit the test.pasm file in the dynoplibs directory a
bit: instead of loading "myops_ops", I write:
loadlib P1, "dynoplibs/myops_ops"
The same is true for the ohter loadlib instructions in the file.
And I run the test.pasm file from the parrot root dir, not from the
dynoplibs directory. So:
parrot$ parrot dynoplibs/test.pasm
Hope this helps,
klaas-jan
As Klaas-Jan describes, you can create a dynamic oplib. If this isn't an
option, you can add an opcode to ops/experimental.ops. Other ops files
are checked against ops/ops.num.
> Gerd Pokorra
leo