[erlang-questions] small build

Kenneth Lundin kenneth.lundin@REDACTED
Thu Apr 17 17:28:01 CEST 2008


What you get when you fetch, build and install the Erlang/OTP
distribution from www.erlang.org is a development system for Erlang.

With this you can develop your own SW product and bundle this in a way
that suit you.
When doing so you just select the runtime system and the components
from OTP you need together with your own code and package it, possibly
making an installer
to be used by the user.

In the packaging step there is no need to build any of the OTP
components or the Erlang runtime system it is just a matter of copying
the needed parts and possibly strip the executables and the .beam
files if you want to minimize the package.
Note that I am assuming that the development system and the target system
runs on the same CPU architecture and OS.


The principle of how to do this can be read
here:http://www.erlang.org/doc/system_principles/part_frame.html
(chapter 3, Creating a first target system)
(we have in our plans to make better support for this (i.e provide SW
that does this
based on your input).

Picking the necessary OTP applications is quite easy if you pick full
applications
since they are layered like this (with a few exceptions)

ERTS
     (stdlib,kernel)
          (compiler,mnesia, orber, ssh, inets, ssl, asn1, snmp, megaco, ....)

I.e. 3 layers.

If you try to minimize by excluding modules from the applications it
will be trickier but you will have good help from xref (in tools)

/Kenneth Erlang/OTP team , Ericsson

On 4/17/08, Steve Vinoski <vinoski@REDACTED> wrote:
> Seems that if you turn on OTP_SMALL_BUILD when building, you get a
> very minimal system, but if you leave it out, you get everything.
> Makes sense, but what if you want something in between?
>
> Is there a way to use OTP_SMALL_BUILD first, do a build and install,
> and then individually build and install any extra packages you might
> want on top of that? Or is it better to do a full build but tell
> configure to leave out the packages you don't want, assuming that's
> possible via --with-package=no? Leaving out Megaco and the ORB seems
> like it would cut out a lot of stuff that I don't need, for example.
>
> Also, how does one build from source (I'm on Linux, BTW) in such a way
> to ensure that C object files, libraries, and executables are not
> debuggable (and are maybe even stripped), erlang sources are compiled
> without +debug_info, etc. in order to minimize system size?
>
> I've searched and searched for answers to these questions, but have
> found very little. All pointers appreciated.
>
> thanks,
> --steve
> _______________________________________________
> erlang-questions mailing list
> erlang-questions@REDACTED
> http://www.erlang.org/mailman/listinfo/erlang-questions
>



More information about the erlang-questions mailing list