git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH v7 0/3] RUNTIME_PREFIX relocatable Git

From
Daniel Jacques <dnj@google.com>
Date
Mar 26, 2018, 13:00 UTC
Message-ID
<CAD1RUU-oUXx+mGUe6QuTawLhLz1nGFZiOWnF7=DVA1uf455zfw@mail.gmail.com>
In-Reply-To
<xmqq4ll3e5pb.fsf@gitster-ct.c.googlers.com>
On Mon, Mar 26, 2018 at 2:01 AM Junio C Hamano <gitster@pobox.com> wrote:
Show 7 quoted lines
> When testing the non-relocatable (i.e. traditional) Git, we use
> GIT_EXEC_PATH and bin-wrappers/ trick to ensure that we test the
> version we just have built, not a random version that happen to be
> on the $PATH, without requiring the built product first to be
> installed before being tested.  From the diffstat for this patchset,
> I am guessing that you are using the same mechanism even when
> testing the relocatable one.

I am - the tests will run against a runtime-prefix-enabled binary, but the overrides supplied by the test suite will still be respected, so it should generally behave like non-runtime-prefix in the tests.

> I wonder if the relocatable Git would allow a simpler arrangement to
> test without installing.
> I am asking merely out of curiosity, not suggesting to make a trial
> install somewhere in the build area and run the built Git normally
> without GIT_EXEC_PATH trick.

RUNTIME_PREFIX resolves paths relative to the runtime path of the Git binary. These path expectations are constructed around installation directories, so I'd expect that installation is a prerequisite of testing. It's also worth noting that the runtime path resolution is platform-dependent, so some Git-supported platforms will not be able to be built and/or tested in this manner (at the moment). I only implemented support for platforms I / Chromium uses, both because of my ability to test on them and my own familiarity with them.

That said, if the test suite dropped its overrides and did a local (testing) installation, that would be expected to work on the RUNTIME_PREFIX binary. I assumed that one of the reasons we don't test against an installation is b/c Git hard-codes its paths, but this would not be a problem with RUNTIME_PREFIX enabled.

-Dan
Previous: Junio C HamanoNext: Johannes Schindelin
Message 10 of 20 in “RUNTIME_PREFIX relocatable Git”
  1. 0/3 RUNTIME_PREFIX relocatable GitDan Jacques, Mar 25, 2018
  2. 1/3 Makefile: generate Perl header from template fileDan Jacques, Mar 25, 2018
  3. 2/3 Makefile: add Perl runtime prefix supportDan Jacques, Mar 25, 2018
  4. 3/3 exec_cmd: RUNTIME_PREFIX on some POSIX systemsDan Jacques, Mar 25, 2018
  5. Ævar Arnfjörð BjarmasonMar 25, 2018
  6. Daniel JacquesMar 26, 2018
  7. Ævar Arnfjörð BjarmasonMar 26, 2018
  8. Daniel JacquesMar 26, 2018
  9. Junio C HamanoMar 26, 2018
  10. Daniel JacquesMar 26, 2018
  11. Johannes SchindelinMar 26, 2018
  12. 0/2 Add Windows support to the new RUNTIME_PREFIX designJohannes Schindelin, Mar 26, 2018
  13. Daniel JacquesMar 27, 2018
  14. Johannes SchindelinMar 27, 2018
  15. Daniel JacquesMar 27, 2018
  16. Johannes SchindelinMar 27, 2018
  17. Junio C HamanoMar 28, 2018
  18. Johannes SchindelinMar 29, 2018
  19. 1/2 exec_cmd: provide a new-style RUNTIME_PREFIX helper for WindowsJohannes Schindelin, Mar 26, 2018
  20. 2/2 mingw/msvc: use the new-style RUNTIME_PREFIX helperJohannes Schindelin, Mar 26, 2018

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.