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

Re: [PATCH] git-gui: Build even if tclsh is not available

From
Shawn O. Pearce <spearce@spearce.org>
Date
May 17, 2007, 02:18 UTC
Message-ID
<20070517021858.GY3141@spearce.org>
In-Reply-To
<20070517021448.24022.8282.stgit@rover>
Petr Baudis <pasky@suse.cz> wrote:
Show 20 quoted lines
> As of now, git fails to build with default config if tclsh is not
> available, thus requiring manual config tweaking just because of some
> optimizations done at build time; this is a needless hassle when building
> git on any kind of a server.
> 
> This patch makes git-gui's build process to handle this gracefully; unless
> TCL_PATH is explicitly set, if tclsh cannot be executed only a warning is
> printed and the build goes on. I have tested this only on that server with
> no tclsh, but hopefully it shouldn't break the build process with tclsh
> available either.
> 
> Version 2, sorry - the previous version of the patch had the install hunk
> missing. And apologies for the duplicate submission... :-)
> 
> Signed-off-by: Petr Baudis <pasky@suse.cz>
> ---
> 
>  Makefile         |    8 +++++---
>  git-gui/Makefile |    4 ++--
>  2 files changed, 7 insertions(+), 5 deletions(-)

I have a couple of problems with the patch as-is. The first is of course that the patch needs to be split into two; one patch for the git-gui subdirectory itself and one for git.git.

My other problem is 
Show 8 quoted lines
>  ifeq ($(findstring $(MAKEFLAGS),s),s)
> @@ -92,7 +92,7 @@ install: all
>  	$(INSTALL) git-gui '$(DESTDIR_SQ)$(gitexecdir_SQ)'
>  	$(foreach p,$(GITGUI_BUILT_INS), rm -f '$(DESTDIR_SQ)$(gitexecdir_SQ)/$p' && ln '$(DESTDIR_SQ)$(gitexecdir_SQ)/git-gui' '$(DESTDIR_SQ)$(gitexecdir_SQ)/$p' ;)
>  	$(INSTALL) -d -m755 '$(DESTDIR_SQ)$(libdir_SQ)'
> -	$(INSTALL) -m644 lib/tclIndex '$(DESTDIR_SQ)$(libdir_SQ)'
> +	[ ! -e lib/tclIndex ] || $(INSTALL) -m644 lib/tclIndex '$(DESTDIR_SQ)$(libdir_SQ)'
>  	$(foreach p,$(ALL_LIBFILES), $(INSTALL) -m644 $p '$(DESTDIR_SQ)$(libdir_SQ)' ;)

git-gui won't work if lib/tclIndex is missing or invalid. So not installing it means we should just disable git-gui entirely.

-- 
Shawn.
Previous: Petr BaudisNext: Petr Baudis
Message 3 of 6 in “git-gui: Build even if tclsh is not available”
  1. git-gui: Build even if tclsh is not availablePetr Baudis, May 17, 2007
  2. git-gui: Build even if tclsh is not availablePetr Baudis, May 17, 2007
  3. Shawn O. PearceMay 17, 2007
  4. Petr BaudisMay 17, 2007
  5. Shawn O. PearceMay 17, 2007
  6. Shawn O. PearceMay 17, 2007

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.