Add plugin support for alternative name lookup

OTP behaviour instances (gen_server, gen_fsm, gen_event) can currently
register themselves either locally or globally, and the behaviour
libraries (including gen.erl) support both addressing methods, as well
as the normal Pid and {Name, Node}.

However, there are alternative registry implementations - e.g. gproc -
and one can well imagine other ways of locating a behaviour instance,
e.g. on a node connected only via a TCP tunnel, rather than via
Distributed Erlang. In all these cases, one needs to write extra code
to identify the behaviour instance, even though the instance itself
need not be aware of how it is located.

This patch introduces a new way of locating a behaviour instance:
{via, Module, Name}.

Module is expected to export a subset of the functions in global.erl,
namely:

register_name(Name, Pid) -> yes | no
whereis_name(Name)  -> pid() | undefined
unregister_name(Name) -> ok
send(Name, Msg) -> Pid

Semantics are expected to be the same as for global.erl

This can be used in all places where {global, Name} is accepted.

faulty export in gen_fsm_SUITE.erl

await process death in dummy_via:reset()

fix error in gen_[server|fsm]:enter_loop()

fix documentation
add escript win32 alternative invocation (thanks Pierre Rouleau)

On Windows, escript may be passed different arvg[0] values depending
on how it was started up.

This patch allows for escript to be started as "escript.exe"
(current behaviour) and also "escript" which is more likely when
called from the default Windows cmd.exe shell.
Update version number
Merge branch 'maint'
Remove bad assert

It is possible also in non-SMP case:
1. The process receives an exit signal and is set in status exiting
   and inserted into the run queue.
2. The distribution port exits before the process has been selected
   for execution and cannot remove the link half on the process since
   it is in status exiting.
3. Process is selected for execution and when removing this link half
   the distribution channel is gone!
Merge branch 'maint'

* maint:
  Remove bad assert
Merge branch 'maint'

* maint: (25 commits)
  Install example dictionaries
  Move example code to examples/code
  Move example dictionaries to examples/dict
  Set name/prefix at compilation, not in dictionaries
  Add RFC 4004 (MIP) dictionary
  Add RFC 4740 (SIP) dictionary
  Add RFC 4072 (EAP) dictionary
  Add RFC 4006 (CC) dictionary
  Add RFC 4005 (NAS) dictionary
  Add standards testcase to compiler suite
  Remove {init,end}_per_group workaround
  Use new syntax for specifying ct group properties
  Increase timetrap in compiler suite
  Minor capx suite tweaks
  Minor makefile tweak
  Remove trailing whitespace
  Update skip condition in gen_sctp suite
  Reintroduce gen_sctp suite
  Remove delay from connect in transport suite
  Add codec testcase for decode of unknown AVPs
  ...
[megaco] Fixed faulty test case (connect)
Merge branch 'maint'

* maint:
  Check that sys.config and relup have valid content when added to tar
  Reject systools:make_script if kernel and stdlib are not permanent in .rel
  Don't save child spec for temporary child if child's start func returns ignore
  Generate links in C libraries correctly
Merge branch 'maint'
Update appup files for kernel and stdlib for OTP R16

The appup files shall allow upgrade from two major versions back,
i.e. for R16 they shall match back to R14. They shall no longer match
for R13.
Merge branch 'maint'
Fixes value returned by mnesia_loader:do_get_disc_copy2/4

Returns the same value for `mnesia_loader:disc_load_table/2' as
`mnesia_loader:net_load_table/4' if a table copy can not be found.

This patch was stuck as a pull request in GitHub (authored by Uwe
Dauernheim):
	https://github.com/erlang/otp/pull/16
Remove hipe_ceach from hipe.app.src to fix reltool-generated release startup

hipe_ceach.erl has disappeared, but is still referred to from
hipe.app.src, causing reltool-generated releases crash when they
cannot find the module.
Merge branch 'maint'
Merge branch 'maint'

* maint:
  Update primary bootstrap
  Add the beam_except pass to optimize exceptions
  Eliminate the match_fail primop in v3_kernel and later passes
Fix returned error from gen_tcp:accept/1,2 when running out of ports

The {error, enfile} return value is badly misleading and confusing for
this case, since the Posix ENFILE errno value has a well-defined meaning
that has nothing to do with Erlang ports. The fix changes the return
value to {error, system_limit}, which is consistent with e.g. various
file(3) functions. inet:format_error/1 has also been updated to support
system_limit in the same manner as file:format_error/1.
Merge branch 'maint'

* maint:
  erts: Do not profile system profiler pid
  test: system_profile profiler pid is not profiled
  Remove line macros in system_profile_SUITE
Merge branch 'maint'

* maint:
  erts: Use re instead of regexp in testsuite
  erts: Remove unused code in testsuites
  orber: Use modern list guard in testsuite
  orber: Ignore unused variable in orber_tb.erl
  xmerl: Ignore unused variable in xmerl_uri.erl
  syntax_tool: Add missing type information
  hipe: Suppress warnings for unused variables
  hipe: Add type information to cfg_info record
  tools: Use literal formatting in erl_memory.c
  asn1: Remove unused variable in asn1_erl_nif.c
  ei: Remove unused variable in ei_format.c
  erts: Add missing prototype to DRIVER_INIT
  runtime_tools: Fix signedness in trace_ip_drv.c
  to_erl: Remove compiler warnings
  heart: Suppress compiler warnings
  erts: Remove compiler warnings in inet_gethost.c
  erts: Remove dead code in inet_gethost.c
  erts: Remove dead code
Merge branch 'siri/update-generic-appup-files/OTP-9845'

* siri/update-generic-appup-files/OTP-9845:
  Update appup files for kernel and stdlib for OTP R16