FFI Load Failure

When Agile Artificial Intelligence was published as a book I was so excited to pick up a copy. I was quite surprised to see my name in the acknowledgements even though I had only contributed a few suggestions.

One of the interesting examples in the book is using FFI (Foreign Function Interface) to utilize C for matrix operations. This was something new to me, but I was disappointed to see that the MMAtrixTest fail with the error:

Error: External module not found

I moved matrix.dylib to several different directories including the bin and MacOS/Plugins but nothing worked. Testing the same code on RedHat Linux was successful, but not not as enjoyable as working on the Mac. Finally I tried installing Pharo 8 again (upgrading from vers. 68021 to vers. 6521), and the code was suddenly successful. It seems that using Pharo Launcher would be a good practice.

Posted by John Borden at 18 July 2020, 2:42 pm link