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

Re: obscure platform autobuilders

From
Jeff King <peff@peff.net>
Date
Oct 1, 2008, 15:37 UTC
Message-ID
<20081001153703.GC4962@coredump.intra.peff.net>
In-Reply-To
<e2b179460810010346j23617764i8134c1f24b2746f0@mail.gmail.com>
On Wed, Oct 01, 2008 at 11:46:43AM +0100, Mike Ralphson wrote:
> My googling led me to think that INTERNAL_QSORT would be a good idea
> on at least some versions of Solaris... it may depend on the fs
> though.

I thought it was purely a performance enhancement. Should it affect the test results?

> How about this - let me know if ok, and I'll push it.

It mostly looks good, though I would have split it into several distinct commits for readability. A few comments below.

> -  - 'branches', a list of branches, one per line, to build and test
> +  - 'branches', a list of branches, one per line, to build and test.
> +    Lines starting with # are treated as comments
Makes sense.
Show 5 quoted lines
>    - 'config.mak'; if this file exists, it will be used as the config.mak
> -    file for building git
> +    file for building git. If it is not present, but there is a
> +    config.mak file in your project directory, it is copied here to
> +    prevent it being removed by 'git clean'

I'm not sure I agree with this. My goal was to treat the project directory as nothing more than a cache, with the gitbuild repo as the master source driving the tests. So this works backwards to that.

One of the things I was (and am) considering is rather than doing checkout/clean, to simply export each branch to a new directory and build from there. Then the "project" repo could actually be bare.

How is this feature intended to be used? It looks like it would basically be invoked one time, when running this script on an existing gitbuild setup. So it saves one manual step of copying your config.mak to the platform directory. But you still have to manually inspect, add, and commit that config.mak file.

Show 6 quoted lines
> +  - 'catch', a shell script sourced by the build script if an error
> +    occurs. It is passed the failing command-line in its arguments
> +
> +  - 'finally', a shell script sourced by the build script at the end
> +    of the process. It is passed the exit code of build.sh as its
> +    argument
These look like sensible hooks.
> +  - project; the path to the directory to build in. If not set, defaults
> +             to ./project relative to the starting directory
> +

I am accomplishing the same thing with a symlink, but I think this is probably cleaner.

> +if ! test -d $project; then
> +  try mkdir $project
> +  try cd $project

Quotes around $project? I'm not sure how robust the rest of the script is to paths with spaces (which I personally consider insane).

> -  for i in `cat "$root/branches"`; do
> +  for i in `cat "$root/branches" | grep -v '^#'`; do
Useless use of cat. :)
  grep -v ^# < "$root/branches"
-Peff
Previous: Mike Ralphson
Message 7 of 7 in “A note from the interim Git maintainer”
  1. Shawn O. PearceSep 24, 2008
  2. Mike RalphsonSep 26, 2008
  3. Jeff KingSep 26, 2008
  4. Mike RalphsonSep 29, 2008
  5. obscure platform autobuildersJeff King, Oct 1, 2008
  6. Mike RalphsonOct 1, 2008
  7. Jeff KingOct 1, 2008

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.