Slightly nicer error message when node start fails due to duplicate name

When starting up an Erlang node using a node name that is already in
use, the new node used to crash with output starting with this message:

{error_logger,{{2013,1,25},{16,0,42}},"Protocol: ~p: register error: ~p~n",["inet_tcp",{{badmatch,{error,duplicate_name}},[{inet_tcp_dist,listen,1,[.....

With this change, the first line in the output changes to:

{error_logger,{{2013,1,25},{16,40,41}},"Protocol: ~tp: the name foo@localhost seems to be in use by another Erlang node",["inet_tcp"]}
kernel docs: Remove references to specs_packages.xml
Add a new function code:get_mode() can be used to detect how the code servers behaves

Rationale:
    Some applications (like erlide) have code to be loaded dynamically on a
    node. It may be slow to load everything upfront every time, so if the
    node is in interactive mode, we would like to just append to the load
    path. Currently, there is no direct way to detect if the node is running
    in embedded mode or not so that we can do the right thing.
Added name prefix to code.xml
Update version numbers
Merge branch 'bjorn/remove-packages/OTP-10348'

* bjorn/remove-packages/OTP-10348:
  kernel docs: Remove references to specs_packages.xml
Merge branch 'mh/duplicate_name_error_message/OTP-10797'

* mh/duplicate_name_error_message/OTP-10797:
  Slightly nicer error message when node start fails due to duplicate name
Test that list_dir("non-existing-dir") fails with the correct error
Merge branch 'vd/code_get_mode/OTP-10823'

* vd/code_get_mode/OTP-10823:
  Added name prefix to code.xml
  Add a new function code:get_mode() can be used to detect how the code servers behaves
prim_file: Add list_dir_all() and read_link_all()
Make Unicode corrections
Add file:list_dir_all/1 and file:read_link_all/1
Fix type of error Reason on gen_tcp:send/2

When the TCP socket is in passive mode, it is possible that a close
message has not been delivered to the controlling process before
calling send/2. This results in the returning {error, closed} to the
caller, in the same way that recv/2,3 does. This commit adjusts the
type of the error "Reason" to include the atom 'closed'.
Merge branch 'pan/unicode_filename_warnings'

* pan/unicode_filename_warnings:
  Add file:list_dir_all/1 and file:read_link_all/1
  prim_file: Add list_dir_all() and read_link_all()
  Teach prim_file:set_cwd() to avoid entering non-translatable directories
  Make prim_file skip invalid filenames in unicode mode
  prim_file: Refactor functions that return filenames
  prim_file: Refactor handling of responses
  prim_file: Always open non-file ports in binary mode
  Test that list_dir("non-existing-dir") fails with the correct error
Change the return value of hipe_bifs:remove_refs_from/1

In order to avoid an ummatched return warning in erts and make the code
more sane, the return value of the bif was changed from [] to 'ok'.
(Probably more hipe_bifs need such changes but they will have to wait.)

While at it, the code of various functions in hipe_unified_loader was
shortened by using lists:foreach/1 instead of explicit recursion.
Make the file:filename() type more restrictive

The recommended type for filenames is a list of characters (which
may be Unicode characters greater than 255). Change the
file:filename() to reflect that.

For the filename module we still need a type that can be either
a string or a binary, so we need to introduce the type
file:filename_all().
[kernel] FIx a bug that could cause crash with wrong reason
Rethink the filelib:wildcard() functions

Commit 70b5e24c9498225fadc08d19503269c8aad851bf broke
filelib:wildcard(Pattern, ".").

Over the years, the logic for filelib:wilcard() has become a mess
of special cases.

Probably because of premature optimization, filelib:wildcard(Pattern)
and filelib:wildcard(Pattern, Cwd) are handled differently.
They can be consolidated if we use a "." as the default Cwd argument.

We can also simplify things by compiling the Cwd argument into the
wildcard. We did not that in the initial implementation because it
used to be possible to pre-compile a wildcard and pass it to
filelib:wildcard/{1,2}. Since that is no longer possible, there is
no point in keeping the compiled wildcard "portable" (not dependent
on the Cwd argument).
Merge branch 'bjorn/stdlib/types'

* bjorn/stdlib/types:
  Make the file:filename() type more restrictive
  c: Remove handling of binaries in return from file:list_dir/1
Merge branch 'bjorn/stdlib/filelib-wildcard/OTP-10812'

* bjorn/stdlib/filelib-wildcard/OTP-10812:
  Remove special case handling "-" at the beginning of a charset
  Optimize character sets using gb_sets
  Clean up and simplify the inner matching loop
  Only sort the result list once, just before returning
  Replace filename:join/2 with '++'
  Rethink the filelib:wildcard() functions
  Don't redefine error/1
  Don't allow binaries as the Cwd argument for filelib:wildcard()
  Don't handle binaries from file:list_dir/1
  Strengthen test suite