* tools/dev/unix-build/Makefile.svn: In my custom build script,
   make some build flags more easily accessible from the command
   line using shorter names.


git-svn-id: https://svn.apache.org/repos/asf/subversion/trunk@1577185 13f79535-47bb-0310-9956-ffa450edef68
* tools/dev/unix-build/Makefile.svn: In my custom build script,
   don't fail to configure gettext if 'gsed' is not found.
   The intention is to use 'gsed' if available, and fall back
   on 'sed' otherwise. The gettext build _requires_ GNU sed.


git-svn-id: https://svn.apache.org/repos/asf/subversion/trunk@1577186 13f79535-47bb-0310-9956-ffa450edef68
* Makefile.in
  (schema): Depend on 'mkdir-init', so as not to fail if schemas are the
    first thing I build in a clean out-of-tree build dir.

git-svn-id: https://svn.apache.org/repos/asf/subversion/trunk@1577197 13f79535-47bb-0310-9956-ffa450edef68
* configure.ac: Don't ignore user-provided LDFLAGS while trying
   to detect libmagic. Fixes libmagic detection where configure
   relies on LDFLAGS to find libraries in non-standard locations.


git-svn-id: https://svn.apache.org/repos/asf/subversion/trunk@1577200 13f79535-47bb-0310-9956-ffa450edef68
Make the few remaining places that prepare files for installing use
svn_wc__db_pristine_prepare_install() to allow further refactoring the
pristine install work.

* subversion/libsvn_wc/merge.c
  (merge_file_trivial): Use the same api to obtain a tempdir as the rest
    of the merge code.

* subversion/libsvn_wc/wc_db.h
  (svn_wc__db_pristine_get_tempdir): Remove function.

* subversion/libsvn_wc/wc_db_pristine.c
  (svn_wc__db_pristine_get_tempdir): Remove function.
  (pristine_get_tempdir): Integrate svn_wc__db_pristine_get_tempdir.

* subversion/tests/libsvn_wc/pristine-store-test.c
  (write_and_checksum_temp_file): Remove function.
  (pristine_write_read,
   pristine_delete_while_open,
   reject_mismatching_text): Use svn_wc__db_pristine_prepare_install.


git-svn-id: https://svn.apache.org/repos/asf/subversion/trunk@1577215 13f79535-47bb-0310-9956-ffa450edef68
On fsfs-lock-many branch: a corrupt working copy with svn:mergeinfo
missing from 'notes/' meant that the sync merges from trunk (r1576824,
r1573603 and r1572541) did not get recorded on 'notes/' on the branch.

* notes: Subtree merge to fix svn:mergeinfo, no other changes.


git-svn-id: https://svn.apache.org/repos/asf/subversion/branches/fsfs-lock-many@1577217 13f79535-47bb-0310-9956-ffa450edef68
Add libintl link flags to SVN_INTL_LIBS on *nix builds.

The SVN_INTL_LIBS variable was referred to but never defined.

* Makefile.in: Define SVN_INTL_LIBS.

* configure.ac: Set SVN_INTL_LIBS to the linker flags required
   to link to libintl and export the value of SVN_INTL_LIBS
   to the Makefile.


git-svn-id: https://svn.apache.org/repos/asf/subversion/trunk@1577223 13f79535-47bb-0310-9956-ffa450edef68
Following up on r1577109, reorder checksum arguments of
svn_wc__db_pristine_prepare_install to match the order of
svn_wc__db_pristine_install.

No functional changes.

* subversion/libsvn_wc/adm_crawler.c
  (svn_wc__internal_transmit_text_deltas): Update caller.

* subversion/libsvn_wc/externals.c
  (apply_textdelta): Update caller.

* subversion/libsvn_wc/update_editor.c
  (lazy_open_target,
   svn_wc_add_repos_file4): Update caller.

* subversion/libsvn_wc/wc_db.h
  (svn_wc__db_pristine_prepare_install): Swap checksum arguments.

* subversion/libsvn_wc/wc_db_pristine.c
  (svn_wc__db_pristine_prepare_install): Swap checksum arguments.

* subversion/tests/libsvn_wc/pristine-store-test.c
  (pristine_write_read,
   pristine_delete_while_open,
   reject_mismatching_text): Update caller.


git-svn-id: https://svn.apache.org/repos/asf/subversion/trunk@1577225 13f79535-47bb-0310-9956-ffa450edef68
* build/generator/gen_make.py
  (Generator.write_pkg_config_dot_in_files): Stop skipping the 'intl' lib
   which is now properly handled as $(SVN_INTL_LIB) in *nix builds.


git-svn-id: https://svn.apache.org/repos/asf/subversion/trunk@1577226 13f79535-47bb-0310-9956-ffa450edef68
* subversion/svnsync/svnsync.c
  (open_source_session): When using svn:sync-from-url canonicalize it
   to avoid asserting if a non-canonical value is stored.


git-svn-id: https://svn.apache.org/repos/asf/subversion/trunk@1577238 13f79535-47bb-0310-9956-ffa450edef68
* build/generator/gen_make.py
  (write_pkg_config_dot_in_files): Following up on r1577226, try to fix the
    build on the unix buildbots.


git-svn-id: https://svn.apache.org/repos/asf/subversion/trunk@1577252 13f79535-47bb-0310-9956-ffa450edef68
* build/generator/gen_make.py
  Revert r1577252, as it only broke things further.


git-svn-id: https://svn.apache.org/repos/asf/subversion/trunk@1577258 13f79535-47bb-0310-9956-ffa450edef68
Revert part of r1577223 in an attempt to unbreak the Unix build.

* configure.ac: Don't set SVN_INTL_LIBS thus making it always empty.


git-svn-id: https://svn.apache.org/repos/asf/subversion/trunk@1577265 13f79535-47bb-0310-9956-ffa450edef68
Switch the pristine file install code in libsvn_wc to using the recently added
install streams.

On Windows these streams avoid opening and closing the same file a few times,
which avoids influence from outside processes such as indexers and
virusscanners on the intermediate operations. In many corporate environments
with strict on access virusscanners (as well as on network drives) this
will hugely improve checkout times.

* subversion/include/private/svn_io_private.h
  (svn_stream__install_delete,
   svn_stream__install_get_info): New functions.

* subversion/libsvn_subr/stream.c
  (svn_stream__install_get_info,
   svn_stream__install_delete): New function.

* subversion/libsvn_wc/adm_crawler.c
  (svn_wc__internal_transmit_text_deltas): Update caller.

* subversion/libsvn_wc/externals.c
  (edit_baton): Store install data instead of path.
  (apply_textdelta,
   close_file): Update caller.

* subversion/libsvn_wc/update_editor.c
  (handler_baton): Add install data.
  (window_handler): Update caller. Remove now unused variable.
  (lazy_open_target): Update caller.
  (apply_textdelta): Pass final path for error information instead of the now
    completely hidden intermediate path.
  (svn_wc_add_repos_file4): Update caller. Extract local file handling.
    Remove obsolete comment.

* subversion/libsvn_wc/wc_db.h
  (svn_wc__db_install_data_t): New struct.
  (svn_wc__db_pristine_prepare_install): Update output state.
  (svn_wc__db_pristine_install): Use baton for input.
  (svn_wc__db_pristine_install_abort): New function.

* subversion/libsvn_wc/wc_db_pristine.c
  (includes): Add svn_io.h and private/svn_io_private.h
  (pristine_install_txn): Use install stream to avoid opening the files
    many times.
  (svn_wc__db_install_data_t): New struct.
  (svn_wc__db_pristine_prepare_install): Initialize svn_wc__db_install_data_t.

  (svn_wc__db_pristine_install): Install file using install stream.
  (svn_wc__db_pristine_install_abort): New function.

* subversion/tests/libsvn_wc/pristine-store-test.c
  (pristine_write_read,
   pristine_delete_while_open,
   reject_mismatching_text): Update caller.


git-svn-id: https://svn.apache.org/repos/asf/subversion/trunk@1577269 13f79535-47bb-0310-9956-ffa450edef68
Merge the fsfs-lock-many branch to trunk.  This introduce multiple
path lock and unlock at the FS level and connects it up over ra_local
and ra_svn, and also uses it post-commit to release locks.  A summary
of the branch changes:

* subversion/include/svn_fs.h
  (svn_fs_lock_target_t, svn_fs_lock_result_t,
   svn_fs_lock2, svn_fs_unlock2): new.

* subversion/include/svn_repos.h
  (svn_repos_fs_lock2, svn_repos_fs_unlock2): new.

* subversion/include/svn_error.h
  (SVN_ERR_IS_LOCK_ERROR, SVN_ERR_IS_UNLOCK_ERROR): Add pre- hook errors.

* subversion/libsvn_fs/fs-loader.c
  (svn_fs_lock2, svn_fs_unlock2): New.

* subversion/libsvn_fs/fs-loader.h
  (fs_vtable_t): Change lock and unlock parameters.

* subversion/libsvn_fs_fs/lock.c
* subversion/libsvn_fs_x/lock.c
  (svn_fs_fs__lock, svn_fs_fs__unlock): New multiple path implementation.

* subversion/libsvn_fs_base/lock.c
  (svn_fs_base__lock, svn_fs_base__unlock): Iterate over paths.

* subversion/libsvn_fs_fs/lock.h
  (svn_fs_fs__lock, svn_fs_fs__unlock): Change parameters.

* subversion/libsvn_fs_x/lock.h
  (svn_fs_x__lock, svn_fs_x__unlock): Change parameters.

* subversion/libsvn_fs_base/lock.h
  (svn_fs_base__lock, svn_fs_base__unlock): Change parameters.

* subversion/libsvn_repos/fs-wrap.c
  (svn_repos_fs_lock2, svn_repos_fs_unlock2): New.

* subversion/libsvn_repos/repos.c
  (SVN_REPOS__HOOK_POST_LOCK, SVN_REPOS__HOOK_POST_UNLOCK): Tweak hook
   template text.

* subversion/libsvn_ra_local/ra_plugin.c
  (deltify_etc, svn_ra_local__lock, svn_ra_local__unlock): Use new API.

* subversion/mod_dav_svn/version.c
  (release_locks): Use new API.

* subversion/svnserve/serve.c
  (unlock_paths, lock_many, unlock_many): Use new API.

* subversion/libsvn_subr/log.c
* subversion/libsvn_fs_fs/lock.h
  (svn_fs_fs__lock, svn_fs_fs__unlock,
   svn_log__lock_one_path, svn_log__unlock_one_path): Change parameter.

* subversion/libsvn_client/locking_commands.c
  (store_locks_callback): Tweak error handling.

* subversion/tests/libsvn_fs/locks-test.c
  (lock_multiple_paths): New test.

* subversion/tests/libsvn_ra/ra-test.c
  (lock_test): New test.

* subversion/tests/cmdline/authz_tests.py
  (authz_locking): Tweak expectations.

* subversion/tests/cmdline/lock_tests.py
  (block_unlock_if_pre_unlock_hook_fails, lock_hook_messages): Tweak
   expectations.
  (failing_post_hooks): New.


git-svn-id: https://svn.apache.org/repos/asf/subversion/trunk@1577280 13f79535-47bb-0310-9956-ffa450edef68
* subversion/libsvn_subr/stream.c
  (svn_stream__install_delete): Avoid a possible double stream close. This
    most likely resolves the test failures on unix.


git-svn-id: https://svn.apache.org/repos/asf/subversion/trunk@1577282 13f79535-47bb-0310-9956-ffa450edef68
* subversion/libsvn_subr/stream.c
  (_FILE_DISPOSITION_INFO,
   FileDispositionInfo): Define when not using a recent enough SDK.
  (svn_stream__install_delete): Add an optimized codepath for WIN32.


git-svn-id: https://svn.apache.org/repos/asf/subversion/trunk@1577292 13f79535-47bb-0310-9956-ffa450edef68
Fix a typo added in r1440411 that makes 'r' always allowed in the interactive
conflict resolver.

* subversion/svn/conflict-callbacks.c
  (handle_text_conflict): Change from result->choice to opt->choice.  The
    value in result->choice is not set at this point.


git-svn-id: https://svn.apache.org/repos/asf/subversion/trunk@1577294 13f79535-47bb-0310-9956-ffa450edef68
* tools/client-side/bash_completion (_svnadmin): Add info command.

git-svn-id: https://svn.apache.org/repos/asf/subversion/trunk@1577314 13f79535-47bb-0310-9956-ffa450edef68
FSFS: Add new config option to pack after every commit for debug purposes.

This option is deliberately not in our default config file because we don't
want to encourage people to use this for normal operation.  This option will
ultimately replace the -DPACK_AFTER_EVERY_COMMIT knob used for debugging
packing.

To Subversion Admins that find this commit: You want to continue using
post-commit hooks to trigger packing.  This option blocks commits from
showing as completed to users until the pack completes.  Which is probably
not desireable.

* subversion/libsvn_fs_fs/fs.h
  (CONFIG_SECTION_DEBUG, CONFIG_OPTION_PACK_AFTER_COMMIT): New.
  (fs_fs_data_t): Add pack_after_commit member.

* subversion/libsvn_fs_fs/fs_fs.c
  (read_config): Read the new option disabling it for formats that don't
    support packing.

* subversion/libsvn_fs_fs/tree.c
  (svn_fs_fs__commit_txn): Pack if configured to do so.


git-svn-id: https://svn.apache.org/repos/asf/subversion/trunk@1577362 13f79535-47bb-0310-9956-ffa450edef68