Git.pm: call tempfile from File::Temp as a regular function

We call File::Temp's "tempfile" function as a class method, but it was
never designed to be called this way. Older versions seemed to
tolerate it, but as of File::Temp 0.23, it blows up like this:

  $ git svn fetch
  'tempfile' can't be called as a method at .../Git.pm line 1117.

Fix it by calling it as a regular function, just inside the File::Temp
namespace.

Signed-off-by: H. Merijn Brand <h.m.brand@xs4all.nl>
Helped-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
fix --use-log-author making email without uuid in commits without "From:" field

    good: Author: tigrisc <tigrisc@8e71dc83-d81e-6649-80f2-80b843a9b2be>
    bad : Author: tigrisc <tigrisc>
increase MAX_MATCHES to 8192 to fix too many matches for svn-remote.svn.added-placeholder
git-svn: turn off 'empty_dir' messages by -q flag
git-svn: fix temp files leak from temp_acquire() misuse
git-svn: fix occasional "Failed to strip path" error on fetch next commit

When --stdlayout and --preserve-empty-dirs flags are used and a
directory becomes empty, two things happen:

* Sometimes find_empty_directories() returns empty list and no empty dir
  placeholder file created. This happens, because
  find_empty_directories() marks all directories as non-empty, if at
  least one updated directory is non-empty.

* Sometimes git-svn dies with "Failed to strip path" error. This
  happens, because find_empty_directories() returns git paths and
  add_placeholder_file() expects svn paths

> ---
v4:
renamed {pathprefix_strip} to {path_prefix}
git-svn-test: don't test for possible bug "Failed to strip path"

In the previous commit a showcase was added to
t9160-git-svn-preserve-empty-dirs.sh for the "Failed to strip path" bug.
Now the flag --stdlayout should be enough.
git-svn: fix fetch erroneously recreating empty dir placeholder deleted earlier

The Fetcher accumulates deleted paths in an array and doesn't reset the
array on next commit. This causes different results when interrupting
and resuming the fetch.
When --preserve-empty-dirs flag is used, a path in the array can be
erroneously treated as just deleted (although it was deleted in the
previous commit) and cause the creation of an empty dir placeholder.
git-svn: fix bottleneck in stash_placeholder_list()

.git/config is written on each commit. It's slow

> ---
v4:
Instead of 'config --unset-all' use 'config --unset name value_regex' to
remove individual placeholders from the config.
git-svn: fix empty dir tracking in branches

  - When creating a tag or branch from a subdir, a disjoint branch is
    created. Then git-svn re-imports the commits using this dir as strip
    path.

    During this re-import the variable %added_placeholder is not up to
    date. Because the branch is disjoint, this variable should be empty
    in the beginning, but it's not. Because of that git-svn tries to
    delete non-existent .gitignore files and dies.

  - When creating a tag or branch from a subdir, the strip path is e.g.
    "trunk/module", but change_dir_prop() can be called with just
    "trunk". This breaks tracking of placeholder files, because it
    relies on the hash {dir_prop}, filled in change_dir_prop().

  - When creating a normal tag or branch, git-svn creates a normal
    branch without reimport, but the placeholder files in the new
    branch are not added to %added_placeholder.

This patch does 3 things:

  - It makes git-svn store paths in %added_placeholder already
    translated from "trunk/subdir/" to "tags/subdir_1.0/" during
    reimport.

  - When strip path is "trunk/subdir", don't add "trunk" to {dir_prop}
    in change_dir_prop().

  - When a normal branch is created, it takes entries in
    %added_placeholder belonging to the source branch, translates them
    to target branch and adds them to %added_placeholder.

> ---
v4:
copy placeholders to new branch AFTER initing {_save_ph}
git-svn: move placeholder tracking from git config to separate file