hans

4 Reputation

2 Badges

19 years, 123 days

MaplePrimes Activity


These are questions asked by hans

I have a module with an exported procedure defined by define_external, like this:

loadtest := module()
export hb;
option package;
hb:=define_external(
`hb`,
`MAPLE`,
`LIB`="/home/hans/system/maple/libhb.so");
end module:

This works if I put the code above into a .mpl file, and use read to load it. The problem is that I would like to save this module to a maple library:

> libname;
"/home/hans/system/maple", "/usr/local/maple8/lib"
> savelibname:="/home/hans/system/maple/loadtest.lib":
> march('create',savelibname,100);
> savelib('loadtest');
> map( march, [ 'gc', 'reindex', 'pack' ], savelibname ):

When I try to use this newly created library after restarting maple the following happens:

> A:=Matrix([[3,2,1,-2,-1,-4],[1,0,1,0,-1,0]]):
> with(loadtest);
[hb]
> hb(A);
[3 2 1 -2 -1 -4]
CALL_EXTERNAL([ ])
[1 0 1 0 -1 0]

Page 1 of 1