erlang / otp

Erlang/OTP
http://erlang.org
Apache License 2.0
11.34k stars 2.95k forks source link

ERL-983: Create Windows installer binary w/o documentation #3758

Open OTP-Maintainer opened 5 years ago

OTP-Maintainer commented 5 years ago

Original reporter: ilyan Affected version: Not Specified Component: Not Specified Migrated from: https://bugs.erlang.org/browse/ERL-983


Is it possible to generate OTP Windows 64-bit Binary File installer without documentation?
And add link to it on [https://www.erlang.org/downloads]?

We are installing Erlang (as a prerequisite for RabbitMQ) for our clients and they never need the documentation.
The installation is silent (non-interactive), so we can't disable "Erlang documentation" section.

Supporting disabling "Erlang documentation" section from command line can save 175MB and not a few seconds for each client's machine,
but IMHO, the better and simpler option is to have different (and smaller!) otp_win64.exe without documentation at all.

I looked at [https://github.com/erlang/otp/blob/master/erts/etc/win32/nsis/Makefile] and [erlang.nsi]  - it seems like they are designed for generating such exe.

P.S. if you think it is a good idea, we need it for 21.3 😊
OTP-Maintainer commented 5 years ago

rickard said:

An installer that takes a command line option that cause it to not install the documentation is preferable from our perspective. Currently this is not something we can put high priority on though. A pull request implementing this is welcome!
inikulshin commented 1 year ago

Hi,

(I'm the original reporter)

We prefer to have some minimalistic installer, without any unused files. Currently, after Erlang installation we remove the following:

gci -Recurse -Directory -Include "doc","include","src","c_src","java_src","obj","examples","emacs","usr" | Remove-Item -Recurse -Force -ErrorAction SilentlyContinue
gci -Recurse -File -Include "*.erl","*.hrl","*.inc","*.lib","*.pdb","beam.debug.smp.dll" | Remove-Item -Force -ErrorAction SilentlyContinue

If we create a PR with additional nsi file, which will create such a minimalistic installer (e.g. otp_nano_x64_26.x.x.exe), will you approve it?

inikulshin commented 1 year ago

@rickard-green @dgud ?

KennethL commented 1 year ago

Erlang/OTP that we deliver is a development system which contains tools where the user can create their own target systems. The target system typically contain a subset of the OTP applications plus the users own Erlang applications and possibly other non Erlang code as well. The target system is called a release and there are tools in OTP and outside for creating such releases. These tools create the target system as a directory structure with files and can also create a tar-file. What you request here seems to be a Windows specific add on which can create a Windows installer from the release created by the user. This is similar to creating a debian or rpm packages for Linux. I am sure there is a package format for MacOS as well but I don't remember the name. What you are suggesting could also be an add on to rebar3.