[Buildroot] [PATCH v6 02/16] package/pkg-rebar: new infrastructure

Frank Hunleth fhunleth at troodon-software.com
Tue Feb 24 18:09:17 UTC 2015


Johan, All,

On Tue, Feb 24, 2015 at 12:07 PM, Johan Oudinet <johan.oudinet at gmail.com> wrote:
> Thomas, All,
>
> Sorry for the long delay before replying to this email. I forgot it in
> my list and went to holidays in the meantime.
>
> On Tue, Feb 3, 2015 at 10:28 AM, Thomas Petazzoni
> <thomas.petazzoni at free-electrons.com> wrote:
>>> +# Directories to store rebar dependencies in.
>>> +#
>>> +# These directories actually only contain symbolic links to Erlang
>>> +# applications in either $(HOST_DIR) or $(STAGING_DIR).  One needs
>>> +# them to avoid rebar complaining about missing dependencies, as this
>>> +# infrastructure tells rebar to NOT download dependencies during
>>> +# the build stage.
>>> +#
>>> +REBAR_HOST_DEPS_DIR = $(HOST_DIR)/usr/share/rebar/deps
>>> +REBAR_TARGET_DEPS_DIR = $(STAGING_DIR)/usr/share/rebar/deps
>>
>> Rather than having those paths, why don't we point directly rebar at
>> $(STAGING_DIR)/usr/lib/erlang/lib/ ? This directory already contains
>> <erlang-app>-<version> directory for each package, and we would only
>> have to create a symlink <erlang-app> --> <erlang-app>-<version>.
>>
>> But maybe it's cleaner to have something completely separate, I don't know.
>>
>
> Indeed, this is to keep $(TARGET_DIR)/usr/lib/erlang/lib directory
> clean from unnecessary symlinks.
> I'm not even sure it won't break some erlang programs if we add
> symlinks there. At least, there is none in my Erlang installation.
> Maybe some Erlang guru can give its opinion on this?

I initially liked the idea of just keeping everything in
/usr/lib/erlang/lib rather than having a rebar/deps directory. My
thinking was that there are other Erlang build tools out there
(rebar3, erlang.mk, mix), so having a deps directory just for rebar
wasn't right. However, I'm the point now where I'm watching how how
things go for me with the new rebar/buildroot integration. The current
rebar integration isn't broken for me, so until I become more
opinionated on this, I wasn't going suggest changing anything. Per
your question, I would be surprised if switching the directory broke
anything.

Frank



More information about the buildroot mailing list