Sat Apr 22 18:55:27 CEST 2006
I am trying to install EUnit2 on my system to use it from one of my packages
and it lead to some general questions about includes/header files.
Where should header files needed for others to use my library go ?
I have Erlang on /usr/lib/erlang/ so my project, let's suppose Serlvers, go
where x.y.z is the version (0.1.0 now, 0.2.0 soon). Is that right ? wrong ?
nobody knows ?
Then include files would go on:
How should then the applications using Serlvers include those files ?
-include("/usr/lib/erlang/serlvers-0.1.0/include/dns.hrl"). I don't think full
paths are right here.
-include("serlvers-0.1.0/include/dns.hrl"). and adding -l /usr/lib/erlang/ at
build time ? Then in the next patchlevel serlvers-0.1.1, whatever was using
serlvers won't work.
-include("dns.hrl"). then the build system should find out what version of
serlvers are there and which one to use to pass to -l, nasty.
And this takes me to a more problematic point: How should header files of
project A include header files of project A and project B ?
Supouse that I have /usr/lib/erlang/serlvers-x.y.z/include/common.hrl, should
dns.hrl -include("common.hrl") ? -include("include/common.hrl") ?
-include("serlvers-0.1.0/include/common.hrl")* ? or what ?
* it would requiring changing all the include paths each time I change
Any help is really appreciated, I am lost here.
Pupeno <> (http://pupeno.com)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 189 bytes
Desc: not available
More information about the erlang-questions