@matheusbsbs / matheus-bagliano / commits / 62ba5143ec
Fork 0

Move gitk to its own subdirectory

This is to prepare for gitk i18n effort that makes gitk not a single file project anymore. We may use subproject to bind git.git and gitk.git more loosely in the future, but we do not want to require everybody to have subproject aware git to be able to pull from git.git yet. Signed-off-by: Junio C Hamano <gitster@pobox.com>

Junio C Hamano committed Nov 17, 2007 at 10:51 UTC 62ba5143ec2ab9d4083669b1b1679355e7639cd5
3 files changed +32 -11
Makefile
+3 -11
@@ -270,9 +270,6 @@ ALL_PROGRAMS += git-merge-subtree$X
270
271 # what 'all' will build but not install in gitexecdir
272 OTHER_PROGRAMS = git$X gitweb/gitweb.cgi
273 -ifndef NO_TCLTK
274 -OTHER_PROGRAMS += gitk-wish
275 -endif
273
274 # Set paths to tools early so that they can be used for version tests.
275 ifndef SHELL_PATH
@@ -772,6 +769,7 @@ endif
769 all::
770 ifndef NO_TCLTK
771 $(QUIET_SUBDIR0)git-gui $(QUIET_SUBDIR1) all
772 + $(QUIET_SUBDIR0)gitk-git $(QUIET_SUBDIR1) all
773 endif
774 $(QUIET_SUBDIR0)perl $(QUIET_SUBDIR1) PERL_PATH='$(PERL_PATH_SQ)' prefix='$(prefix_SQ)' all
775 $(QUIET_SUBDIR0)templates $(QUIET_SUBDIR1)
@@ -779,12 +777,6 @@ endif
777 strip: $(PROGRAMS) git$X
778 $(STRIP) $(STRIP_OPTS) $(PROGRAMS) git$X
779
782 -gitk-wish: gitk GIT-GUI-VARS
783 - $(QUIET_GEN)$(RM) $@ $@+ && \
784 - sed -e '1,3s|^exec .* "$$0"|exec $(subst |,'\|',$(TCLTK_PATH_SQ)) "$$0"|' <gitk >$@+ && \
785 - chmod +x $@+ && \
786 - mv -f $@+ $@
787 -
780 git.o: git.c common-cmds.h GIT-CFLAGS
781 $(QUIET_CC)$(CC) -DGIT_VERSION='"$(GIT_VERSION)"' \
782 $(ALL_CFLAGS) -c $(filter %.c,$^)
@@ -1025,7 +1017,7 @@ install: all
1017 $(MAKE) -C templates DESTDIR='$(DESTDIR_SQ)' install
1018 $(MAKE) -C perl prefix='$(prefix_SQ)' install
1019 ifndef NO_TCLTK
1028 - $(INSTALL) gitk-wish '$(DESTDIR_SQ)$(bindir_SQ)'/gitk
1020 + $(MAKE) -C gitk-git install
1021 $(MAKE) -C git-gui install
1022 endif
1023 if test 'z$(bindir_SQ)' != 'z$(gitexecdir_SQ)'; \
@@ -1118,7 +1110,7 @@ clean:
1110 $(MAKE) -C templates/ clean
1111 $(MAKE) -C t/ clean
1112 ifndef NO_TCLTK
1121 - $(RM) gitk-wish
1113 + $(MAKE) -C gitk-git clean
1114 $(MAKE) -C git-gui clean
1115 endif
1116 $(RM) GIT-VERSION-FILE GIT-CFLAGS GIT-GUI-VARS
gitk-git/Makefile new
+29
@@ -0,0 +1,29 @@
1 +# The default target of this Makefile is...
2 +all::
3 +
4 +prefix ?= $(HOME)
5 +bindir ?= $(prefix)/bin
6 +TCLTK_PATH ?= wish
7 +INSTALL ?= install
8 +RM ?= rm -f
9 +
10 +DESTDIR_SQ = $(subst ','\'',$(DESTDIR))
11 +bindir_SQ = $(subst ','\'',$(bindir))
12 +TCLTK_PATH_SQ = $(subst ','\'',$(TCLTK_PATH))
13 +
14 +ifndef V
15 + QUIET = @
16 + QUIET_GEN = $(QUIET)echo ' ' GEN $@ &&
17 +endif
18 +
19 +all:: gitk-wish
20 +install:: all
21 + $(INSTALL) gitk-wish '$(DESTDIR_SQ)$(bindir_SQ)'/gitk
22 +clean::
23 + $(RM) gitk-wish
24 +
25 +gitk-wish: gitk
26 + $(QUIET_GEN)$(RM) $@ $@+ && \
27 + sed -e '1,3s|^exec .* "$$0"|exec $(subst |,'\|',$(TCLTK_PATH_SQ)) "$$0"|' <gitk >$@+ && \
28 + chmod +x $@+ && \
29 + mv -f $@+ $@
gitk-git/gitk renamed