[erlang-questions] Building a C port

Tom Burdick <>
Fri Oct 14 23:53:14 CEST 2011


I'm looking to wrap libsamplerate and am looking for some advice on
how to go about it.

I can't use NIF or port driver as libsamplerate is GPL. NIF or a port
driver don't seem to be the right solution anyways as libsamplerate
may take awhile to do some work and report back.

So I'm left thinking either a C port or a C node would be best, I'm
leaning towards a C port implementation.

The C port example however as it shows running gcc with -I and -L
flags pointing to a particular erlang install. I'd like to make my
port portable so that it can compile on different machines with
possible different versions of erlang without having to always specify
where erlang is installed, or even worse where erl_interface is
located.

Do people use autotools for this? Is there a project template that
uses autotools for this?

Could I use rebar instead?

Thanks!

Tom Burdick



More information about the erlang-questions mailing list