in reply to About Moo and Inline::C

One problem is where and when the _Inline build directory gets installed. If you don't plan ahead, and you're basing a module on Inline::C, the default behavior isn't usually optimal.

There is a proof of concept one good way to do this if you look at Math::Prime::FastSieve. (It used to be the easy way until recently, but the method demonstrated in that module has probably been made obsolete.)

The new easy way uses Inline::Module to assist in creating a distribution that, once installed on the end user's system, looks and feels light-weight, like a plain old XS module. The Inline::Module::Tutorial has pretty good examples that should help you get through the next step.


Dave

Replies are listed 'Best First'.
Re^2: About Moo and Inline::C
by marioroy (Prior) on Jun 10, 2015 at 10:55 UTC

    Hi David. Thank you for the tip on Inline::Module. I played with Math::Prime::FastSieve some time back and made a local version by replacing the primes function with Algorithm3, a practical sieve algorithm by Xuedong Luo. It was a learning experience at the time and got to see primes compute faster.

    Update: If interested, Algorithm3 which I applied to my local copy of Math::Prime::FastSieve.

Re^2: About Moo and Inline::C
by karlgoethebier (Abbot) on Jun 10, 2015 at 14:23 UTC

    Thank you very much for advice davido. I didn't know Inline::Module .

    Best regards, Karl

    «The Crux of the Biscuit is the Apostrophe»