1 # The default target of this Makefile is...
4 # Define V=1 to have a more verbose compile.
6 # Define SNPRINTF_RETURNS_BOGUS if your are on a system which snprintf()
7 # or vsnprintf() return -1 instead of number of characters which would
8 # have been written to the final string if enough space had been available.
10 # Define FREAD_READS_DIRECTORIES if your are on a system which succeeds
11 # when attempting to read from an fopen'ed directory.
13 # Define NO_OPENSSL environment variable if you do not have OpenSSL.
14 # This also implies MOZILLA_SHA1.
16 # Define NO_CURL if you do not have curl installed. git-http-pull and
17 # git-http-push are not built, and you cannot use http:// and https://
20 # Define CURLDIR=/foo/bar if your curl header and library files are in
21 # /foo/bar/include and /foo/bar/lib directories.
23 # Define NO_EXPAT if you do not have expat installed. git-http-push is
24 # not built, and you cannot push using http:// and https:// transports.
26 # Define NO_D_INO_IN_DIRENT if you don't have d_ino in your struct dirent.
28 # Define NO_D_TYPE_IN_DIRENT if your platform defines DT_UNKNOWN but lacks
29 # d_type in struct dirent (latest Cygwin -- will be fixed soonish).
31 # Define NO_C99_FORMAT if your formatted IO functions (printf/scanf et.al.)
32 # do not support the 'size specifiers' introduced by C99, namely ll, hh,
33 # j, z, t. (representing long long int, char, intmax_t, size_t, ptrdiff_t).
34 # some C compilers supported these specifiers prior to C99 as an extension.
36 # Define NO_STRCASESTR if you don't have strcasestr.
38 # Define NO_MEMMEM if you don't have memmem.
40 # Define NO_STRLCPY if you don't have strlcpy.
42 # Define NO_STRTOUMAX if you don't have strtoumax in the C library.
43 # If your compiler also does not support long long or does not have
44 # strtoull, define NO_STRTOULL.
46 # Define NO_SETENV if you don't have setenv in the C library.
48 # Define NO_UNSETENV if you don't have unsetenv in the C library.
50 # Define NO_MKDTEMP if you don't have mkdtemp in the C library.
52 # Define NO_SYS_SELECT_H if you don't have sys/select.h.
54 # Define NO_SYMLINK_HEAD if you never want .git/HEAD to be a symbolic link.
55 # Enable it on Windows. By default, symrefs are still used.
57 # Define NO_SVN_TESTS if you want to skip time-consuming SVN interoperability
58 # tests. These tests take up a significant amount of the total test time
59 # but are not needed unless you plan to talk to SVN repos.
61 # Define NO_FINK if you are building on Darwin/Mac OS X, have Fink
62 # installed in /sw, but don't want GIT to link against any libraries
63 # installed there. If defined you may specify your own (or Fink's)
64 # include directories and library directories by defining CFLAGS
65 # and LDFLAGS appropriately.
67 # Define NO_DARWIN_PORTS if you are building on Darwin/Mac OS X,
68 # have DarwinPorts installed in /opt/local, but don't want GIT to
69 # link against any libraries installed there. If defined you may
70 # specify your own (or DarwinPort's) include directories and
71 # library directories by defining CFLAGS and LDFLAGS appropriately.
73 # Define PPC_SHA1 environment variable when running make to make use of
74 # a bundled SHA1 routine optimized for PowerPC.
76 # Define ARM_SHA1 environment variable when running make to make use of
77 # a bundled SHA1 routine optimized for ARM.
79 # Define MOZILLA_SHA1 environment variable when running make to make use of
80 # a bundled SHA1 routine coming from Mozilla. It is GPL'd and should be fast
81 # on non-x86 architectures (e.g. PowerPC), while the OpenSSL version (default
82 # choice) has very fast version optimized for i586.
84 # Define NEEDS_SSL_WITH_CRYPTO if you need -lcrypto with -lssl (Darwin).
86 # Define NEEDS_LIBICONV if linking with libc is not enough (Darwin).
88 # Define NEEDS_SOCKET if linking with libc is not enough (SunOS,
91 # Define NO_MMAP if you want to avoid mmap.
93 # Define NO_PREAD if you have a problem with pread() system call (e.g.
94 # cygwin.dll before v1.5.22).
96 # Define NO_FAST_WORKING_DIRECTORY if accessing objects in pack files is
97 # generally faster on your platform than accessing the working directory.
99 # Define NO_TRUSTABLE_FILEMODE if your filesystem may claim to support
100 # the executable mode bit, but doesn't really do so.
102 # Define NO_IPV6 if you lack IPv6 support and getaddrinfo().
104 # Define NO_SOCKADDR_STORAGE if your platform does not have struct
107 # Define NO_ICONV if your libc does not properly support iconv.
109 # Define OLD_ICONV if your library has an old iconv(), where the second
110 # (input buffer pointer) parameter is declared with type (const char **).
112 # Define NO_DEFLATE_BOUND if your zlib does not have deflateBound.
114 # Define NO_R_TO_GCC_LINKER if your gcc does not like "-R/path/lib"
115 # that tells runtime paths to dynamic libraries;
116 # "-Wl,-rpath=/path/lib" is used instead.
118 # Define USE_NSEC below if you want git to care about sub-second file mtimes
119 # and ctimes. Note that you need recent glibc (at least 2.2.4) for this, and
120 # it will BREAK YOUR LOCAL DIFFS! show-diff and anything using it will likely
121 # randomly break unless your underlying filesystem supports those sub-second
122 # times (my ext3 doesn't).
124 # Define USE_STDEV below if you want git to care about the underlying device
125 # change being considered an inode change from the update-index perspective.
127 # Define ASCIIDOC8 if you want to format documentation with AsciiDoc 8
129 # Define DOCBOOK_XSL_172 if you want to format man pages with DocBook XSL v1.72.
131 # Define NO_PERL_MAKEMAKER if you cannot use Makefiles generated by perl's
132 # MakeMaker (e.g. using ActiveState under Cygwin).
134 # Define NO_TCLTK if you do not want Tcl/Tk GUI.
136 # The TCL_PATH variable governs the location of the Tcl interpreter
137 # used to optimize git-gui for your system. Only used if NO_TCLTK
138 # is not set. Defaults to the bare 'tclsh'.
140 # The TCLTK_PATH variable governs the location of the Tcl/Tk interpreter.
141 # If not set it defaults to the bare 'wish'. If it is set to the empty
142 # string then NO_TCLTK will be forced (this is used by configure script).
144 # Define THREADED_DELTA_SEARCH if you have pthreads and wish to exploit
145 # parallel delta searching when packing objects.
147 # Define INTERNAL_QSORT to use Git's implementation of qsort(), which
148 # is a simplified version of the merge sort used in glibc. This is
149 # recommended if Git triggers O(n^2) behavior in your platform's qsort().
152 GIT-VERSION-FILE
: .FORCE-GIT-VERSION-FILE
153 @
$(SHELL_PATH
) .
/GIT-VERSION-GEN
154 -include GIT-VERSION-FILE
156 uname_S
:= $(shell sh
-c
'uname -s 2>/dev/null || echo not')
157 uname_M
:= $(shell sh
-c
'uname -m 2>/dev/null || echo not')
158 uname_O
:= $(shell sh
-c
'uname -o 2>/dev/null || echo not')
159 uname_R
:= $(shell sh
-c
'uname -r 2>/dev/null || echo not')
160 uname_P
:= $(shell sh
-c
'uname -p 2>/dev/null || echo not')
162 # CFLAGS and LDFLAGS are for the users to override from the command line.
164 CFLAGS
= -g
-O2
-Wall
166 ALL_CFLAGS
= $(CFLAGS
)
167 ALL_LDFLAGS
= $(LDFLAGS
)
171 bindir = $(prefix)/bin
172 mandir = $(prefix)/share
/man
173 infodir = $(prefix)/share
/info
174 gitexecdir
= $(bindir)
175 sharedir
= $(prefix)/share
176 template_dir
= $(sharedir
)/git-core
/templates
177 htmldir
=$(sharedir
)/doc
/git-doc
178 ifeq ($(prefix),/usr
)
181 sysconfdir
= $(prefix)/etc
184 ETC_GITCONFIG
= $(sysconfdir
)/gitconfig
187 # default configuration for gitweb
188 GITWEB_CONFIG
= gitweb_config.perl
189 GITWEB_HOME_LINK_STR
= projects
191 GITWEB_PROJECTROOT
= /pub
/git
192 GITWEB_PROJECT_MAXDEPTH
= 2007
194 GITWEB_STRICT_EXPORT
=
197 GITWEB_HOMETEXT
= indextext.html
198 GITWEB_CSS
= gitweb.css
199 GITWEB_LOGO
= git-logo.png
200 GITWEB_FAVICON
= git-favicon.png
204 export prefix bindir gitexecdir sharedir htmldir sysconfdir
216 export TCL_PATH TCLTK_PATH
218 # sparse is architecture-neutral, which means that we need to tell it
219 # explicitly what architecture to check for. Fix this up for yours..
220 SPARSE_FLAGS
= -D__BIG_ENDIAN__
-D__powerpc__
224 ### --- END CONFIGURATION SECTION ---
226 # Those must not be GNU-specific; they are shared with perl/ which may
227 # be built by a different compiler. (Note that this is an artifact now
228 # but it still might be nice to keep that distinction.)
235 git-merge-one-file.sh git-mergetool.sh git-parse-remote.sh \
236 git-pull.sh git-rebase.sh git-rebase--interactive.sh \
237 git-repack.sh git-request-pull.sh \
240 git-merge.sh git-merge-stupid.sh git-merge-octopus.sh \
241 git-merge-resolve.sh \
242 git-lost-found.sh git-quiltimport.sh git-submodule.sh \
243 git-filter-branch.sh \
248 git-add--interactive.perl \
249 git-archimport.perl git-cvsimport.perl git-relink.perl \
250 git-cvsserver.perl git-cvsexportcommit.perl \
251 git-send-email.perl git-svn.perl
253 SCRIPTS
= $(patsubst %.sh
,%,$(SCRIPT_SH
)) \
254 $(patsubst %.perl
,%,$(SCRIPT_PERL
)) \
257 # ... and all the rest that could be moved out of bindir to gitexecdir
260 git-hash-object
$X git-index-pack
$X \
262 git-merge-index
$X git-mktag
$X git-mktree
$X git-patch-id
$X \
264 git-send-pack
$X git-shell
$X \
267 git-update-server-info
$X \
269 git-pack-redundant
$X git-var
$X \
271 $(POSIX_ONLY_PROGRAMS
) \
277 # List built-in command $C whose implementation cmd_$C() is not in
278 # builtin-$C.o but is linked in as part of some other command.
280 git-format-patch
$X git-show
$X git-whatchanged
$X git-cherry
$X \
281 git-get-tar-commit-id
$X git-init
$X git-repo-config
$X \
282 git-fsck-objects
$X git-cherry-pick
$X git-peek-remote
$X git-status
$X \
283 git-merge-subtree
$X \
284 $(patsubst builtin-
%.o
,git-
%$X,$(BUILTIN_OBJS
))
286 # what 'all' will build and 'install' will install, in gitexecdir
287 ALL_PROGRAMS
= $(PROGRAMS
) $(SCRIPTS
)
289 # what 'all' will build but not install in gitexecdir
290 OTHER_PROGRAMS
= git
$X gitweb
/gitweb.cgi
292 # Set paths to tools early so that they can be used for version tests.
297 PERL_PATH
= /usr
/bin
/perl
303 XDIFF_LIB
=xdiff
/lib.a
306 archive.h blob.h cache.h cache-tree.h commit.h csum-file.h delta.h grep.h \
307 diff.h object.h pack.h pkt-line.h quote.h refs.h list-objects.h sideband.h \
308 run-command.h strbuf.h tag.h tree.h git-compat-util.h revision.h \
309 tree-walk.h log-tree.h
dir.h path-list.h unpack-trees.h builtin.h \
310 utf8.h reflog-walk.h patch-ids.h attr.h decorate.h progress.h \
311 mailmap.h remote.h parse-options.h transport.h diffcore.h hash.h ll-merge.h fsck.h \
312 pack-revindex.h compat
/mingw.h
315 diff.o diff-lib.o diffcore-break.o diffcore-order.o \
316 diffcore-pickaxe.o diffcore-rename.o tree-diff.o combine-diff.o \
317 diffcore-delta.o log-tree.o
320 blob.o commit.o connect.o csum-file.o cache-tree.o base85.o \
321 date.o diff-delta.o entry.o exec_cmd.o ident.o \
322 pretty.o interpolate.o hash.o \
325 object.o pack-check.o pack-write.o patch-delta.o path.o pkt-line.o \
326 sideband.o reachable.o reflog-walk.o \
327 quote.o read-cache.o refs.o run-command.o
dir.o \
328 server-info.o setup.o sha1_file.o sha1_name.o strbuf.o \
329 tag.o tree.o usage.o config.o environment.o ctype.o copy.o \
330 revision.o pager.o tree-walk.o xdiff-interface.o \
331 write_or_die.o trace.o list-objects.o grep.o match-trees.o \
332 alloc.o merge-file.o path-list.o help.o unpack-trees.o
$(DIFF_OBJS
) \
333 color.o wt-status.o archive-zip.o archive-tar.o shallow.o utf8.o \
334 convert.o attr.o decorate.o progress.o mailmap.o symlinks.o remote.o \
335 transport.o bundle.o walker.o parse-options.o ws.o archive.o branch.o \
336 ll-merge.o alias.o fsck.o pack-revindex.o
347 builtin-check-attr.o \
349 builtin-checkout-index.o \
350 builtin-check-ref-format.o \
353 builtin-commit-tree.o \
354 builtin-count-objects.o \
357 builtin-diff-files.o \
358 builtin-diff-index.o \
359 builtin-diff-tree.o \
360 builtin-fast-export.o \
362 builtin-fetch-pack.o \
363 builtin-fetch--tool.o \
364 builtin-fmt-merge-msg.o \
365 builtin-for-each-ref.o \
373 builtin-ls-remote.o \
375 builtin-mailsplit.o \
376 builtin-merge-base.o \
377 builtin-merge-file.o \
378 builtin-merge-ours.o \
379 builtin-merge-recursive.o \
382 builtin-pack-objects.o \
384 builtin-prune-packed.o \
386 builtin-read-tree.o \
389 builtin-send-pack.o \
394 builtin-rev-parse.o \
398 builtin-show-branch.o \
399 builtin-stripspace.o \
400 builtin-symbolic-ref.o \
403 builtin-unpack-objects.o \
404 builtin-update-index.o \
405 builtin-update-ref.o \
406 builtin-upload-archive.o \
407 builtin-verify-pack.o \
408 builtin-verify-tag.o \
409 builtin-write-tree.o \
413 GITLIBS
= $(LIB_FILE
) $(XDIFF_LIB
)
417 # Platform specific tweaks
420 # We choose to avoid "if .. else if .. else .. endif endif"
421 # because maintaining the nesting to match is a pain. If
422 # we had "elif" things would have been much nicer...
424 ifeq ($(uname_S
),Linux
)
425 NO_STRLCPY
= YesPlease
427 ifeq ($(uname_S
),GNU
/kFreeBSD
)
428 NO_STRLCPY
= YesPlease
430 ifeq ($(uname_S
),Darwin
)
431 NEEDS_SSL_WITH_CRYPTO
= YesPlease
432 NEEDS_LIBICONV
= YesPlease
433 ifneq ($(shell expr
"$(uname_R)" : '9\.'),2)
434 OLD_ICONV
= UnfortunatelyYes
436 NO_STRLCPY
= YesPlease
437 NO_MEMMEM
= YesPlease
439 ifeq ($(uname_S
),SunOS
)
440 NEEDS_SOCKET
= YesPlease
441 NEEDS_NSL
= YesPlease
442 SHELL_PATH
= /bin
/bash
443 NO_STRCASESTR
= YesPlease
444 NO_MEMMEM
= YesPlease
445 NO_HSTRERROR
= YesPlease
446 NO_MKDTEMP
= YesPlease
447 ifeq ($(uname_R
),5.8)
448 NEEDS_LIBICONV
= YesPlease
449 NO_UNSETENV
= YesPlease
450 NO_SETENV
= YesPlease
451 NO_C99_FORMAT
= YesPlease
452 NO_STRTOUMAX
= YesPlease
454 ifeq ($(uname_R
),5.9)
455 NO_UNSETENV
= YesPlease
456 NO_SETENV
= YesPlease
457 NO_C99_FORMAT
= YesPlease
458 NO_STRTOUMAX
= YesPlease
462 BASIC_CFLAGS
+= -D__EXTENSIONS__
464 ifeq ($(uname_O
),Cygwin
)
465 NO_D_TYPE_IN_DIRENT
= YesPlease
466 NO_D_INO_IN_DIRENT
= YesPlease
467 NO_STRCASESTR
= YesPlease
468 NO_MEMMEM
= YesPlease
469 NO_SYMLINK_HEAD
= YesPlease
470 NEEDS_LIBICONV
= YesPlease
471 NO_FAST_WORKING_DIRECTORY
= UnfortunatelyYes
472 NO_TRUSTABLE_FILEMODE
= UnfortunatelyYes
473 OLD_ICONV
= UnfortunatelyYes
474 # There are conflicting reports about this.
475 # On some boxes NO_MMAP is needed, and not so elsewhere.
476 # Try commenting this out if you suspect MMAP is more efficient
481 ifeq ($(uname_S
),FreeBSD
)
482 NEEDS_LIBICONV
= YesPlease
483 NO_MEMMEM
= YesPlease
484 BASIC_CFLAGS
+= -I
/usr
/local
/include
485 BASIC_LDFLAGS
+= -L
/usr
/local
/lib
486 DIR_HAS_BSD_GROUP_SEMANTICS
= YesPlease
488 ifeq ($(uname_S
),OpenBSD
)
489 NO_STRCASESTR
= YesPlease
490 NO_MEMMEM
= YesPlease
491 NEEDS_LIBICONV
= YesPlease
492 BASIC_CFLAGS
+= -I
/usr
/local
/include
493 BASIC_LDFLAGS
+= -L
/usr
/local
/lib
495 ifeq ($(uname_S
),NetBSD
)
496 ifeq ($(shell expr
"$(uname_R)" : '[01]\.'),2)
497 NEEDS_LIBICONV
= YesPlease
499 BASIC_CFLAGS
+= -I
/usr
/pkg
/include
500 BASIC_LDFLAGS
+= -L
/usr
/pkg
/lib
501 ALL_LDFLAGS
+= -Wl
,-rpath
,/usr
/pkg
/lib
503 ifeq ($(uname_S
),AIX
)
504 NO_STRCASESTR
=YesPlease
505 NO_MEMMEM
= YesPlease
506 NO_STRLCPY
= YesPlease
507 NEEDS_LIBICONV
=YesPlease
509 ifeq ($(uname_S
),GNU
)
513 ifeq ($(uname_S
),IRIX64
)
516 NO_STRCASESTR
=YesPlease
517 NO_MEMMEM
= YesPlease
518 NO_STRLCPY
= YesPlease
519 NO_SOCKADDR_STORAGE
=YesPlease
520 SHELL_PATH
=/usr
/gnu
/bin
/bash
521 BASIC_CFLAGS
+= -DPATH_MAX
=1024
522 # for now, build 32-bit version
523 BASIC_LDFLAGS
+= -L
/usr
/lib32
525 ifeq ($(uname_S
),HP-UX
)
528 NO_STRCASESTR
=YesPlease
529 NO_MEMMEM
= YesPlease
530 NO_STRLCPY
= YesPlease
531 NO_MKDTEMP
= YesPlease
532 NO_UNSETENV
= YesPlease
533 NO_HSTRERROR
= YesPlease
534 NO_SYS_SELECT_H
= YesPlease
536 ifneq (,$(findstring MINGW
,$(uname_S
)))
539 NO_OPENSSL
= YesPlease
541 NO_SYMLINK_HEAD
= YesPlease
543 NO_SETENV
= YesPlease
544 NO_UNSETENV
= YesPlease
545 NO_STRCASESTR
= YesPlease
546 NO_STRLCPY
= YesPlease
547 NO_MEMMEM
= YesPlease
548 NEEDS_LIBICONV
= YesPlease
549 OLD_ICONV
= YesPlease
550 NO_C99_FORMAT
= YesPlease
551 NO_STRTOUMAX
= YesPlease
552 NO_MKDTEMP
= YesPlease
553 NO_SVN_TESTS
= YesPlease
554 NO_PERL_MAKEMAKER
= YesPlease
555 NO_POSIX_ONLY_PROGRAMS
= YesPlease
556 COMPAT_CFLAGS
+= -D__USE_MINGW_ACCESS
-DNOGDI
-Icompat
557 COMPAT_CFLAGS
+= -DSTRIP_EXTENSION
=\".exe
\"
558 COMPAT_OBJS
+= compat
/mingw.o compat
/fnmatch.o compat
/regex.o
561 NOEXECTEMPL
= .noexec
562 template_dir
= ..
/share
/git-core
/templates
/
563 ETC_GITCONFIG
= ..
/etc
/gitconfig
565 ifneq (,$(findstring arm
,$(uname_M
)))
569 -include config.mak.autogen
572 ifeq ($(uname_S
),Darwin
)
574 ifeq ($(shell test -d
/sw
/lib
&& echo y
),y
)
575 BASIC_CFLAGS
+= -I
/sw
/include
576 BASIC_LDFLAGS
+= -L
/sw
/lib
579 ifndef NO_DARWIN_PORTS
580 ifeq ($(shell test -d
/opt
/local
/lib
&& echo y
),y
)
581 BASIC_CFLAGS
+= -I
/opt
/local
/include
582 BASIC_LDFLAGS
+= -L
/opt
/local
/lib
587 ifdef NO_R_TO_GCC_LINKER
588 # Some gcc does not accept and pass -R to the linker to specify
589 # the runtime dynamic library path.
590 CC_LD_DYNPATH
= -Wl
,-rpath
=
596 BASIC_CFLAGS
+= -DNO_CURL
599 # Try "-Wl,-rpath=$(CURLDIR)/$(lib)" in such a case.
600 BASIC_CFLAGS
+= -I
$(CURLDIR
)/include
601 CURL_LIBCURL
= -L
$(CURLDIR
)/$(lib
) $(CC_LD_DYNPATH
)$(CURLDIR
)/$(lib
) -lcurl
603 CURL_LIBCURL
= -lcurl
605 BUILTIN_OBJS
+= builtin-http-fetch.o
606 EXTLIBS
+= $(CURL_LIBCURL
)
607 LIB_OBJS
+= http.o http-walker.o
608 curl_check
:= $(shell (echo
070908; curl-config
--vernum
) |
sort -r | sed
-ne
2p
)
609 ifeq "$(curl_check)" "070908"
611 PROGRAMS
+= git-http-push
$X
615 EXPAT_LIBEXPAT
= -lexpat
620 BASIC_CFLAGS
+= -I
$(ZLIB_PATH
)/include
621 EXTLIBS
+= -L
$(ZLIB_PATH
)/$(lib
) $(CC_LD_DYNPATH
)$(ZLIB_PATH
)/$(lib
)
625 ifndef NO_POSIX_ONLY_PROGRAMS
626 POSIX_ONLY_PROGRAMS
= \
631 OPENSSL_LIBSSL
= -lssl
633 BASIC_CFLAGS
+= -I
$(OPENSSLDIR
)/include
634 OPENSSL_LINK
= -L
$(OPENSSLDIR
)/$(lib
) $(CC_LD_DYNPATH
)$(OPENSSLDIR
)/$(lib
)
639 BASIC_CFLAGS
+= -DNO_OPENSSL
643 ifdef NEEDS_SSL_WITH_CRYPTO
644 LIB_4_CRYPTO
= $(OPENSSL_LINK
) -lcrypto
-lssl
646 LIB_4_CRYPTO
= $(OPENSSL_LINK
) -lcrypto
650 BASIC_CFLAGS
+= -I
$(ICONVDIR
)/include
651 ICONV_LINK
= -L
$(ICONVDIR
)/$(lib
) $(CC_LD_DYNPATH
)$(ICONVDIR
)/$(lib
)
655 EXTLIBS
+= $(ICONV_LINK
) -liconv
663 ifdef NO_D_TYPE_IN_DIRENT
664 BASIC_CFLAGS
+= -DNO_D_TYPE_IN_DIRENT
666 ifdef NO_D_INO_IN_DIRENT
667 BASIC_CFLAGS
+= -DNO_D_INO_IN_DIRENT
670 BASIC_CFLAGS
+= -DNO_C99_FORMAT
672 ifdef SNPRINTF_RETURNS_BOGUS
673 COMPAT_CFLAGS
+= -DSNPRINTF_RETURNS_BOGUS
674 COMPAT_OBJS
+= compat
/snprintf.o
676 ifdef FREAD_READS_DIRECTORIES
677 COMPAT_CFLAGS
+= -DFREAD_READS_DIRECTORIES
678 COMPAT_OBJS
+= compat
/fopen.o
680 ifdef NO_SYMLINK_HEAD
681 BASIC_CFLAGS
+= -DNO_SYMLINK_HEAD
684 COMPAT_CFLAGS
+= -DNO_STRCASESTR
685 COMPAT_OBJS
+= compat
/strcasestr.o
688 COMPAT_CFLAGS
+= -DNO_STRLCPY
689 COMPAT_OBJS
+= compat
/strlcpy.o
692 COMPAT_CFLAGS
+= -DNO_STRTOUMAX
693 COMPAT_OBJS
+= compat
/strtoumax.o
696 COMPAT_CFLAGS
+= -DNO_STRTOULL
699 COMPAT_CFLAGS
+= -DNO_SETENV
700 COMPAT_OBJS
+= compat
/setenv.o
703 COMPAT_CFLAGS
+= -DNO_MKDTEMP
704 COMPAT_OBJS
+= compat
/mkdtemp.o
707 COMPAT_CFLAGS
+= -DNO_UNSETENV
708 COMPAT_OBJS
+= compat
/unsetenv.o
710 ifdef NO_SYS_SELECT_H
711 BASIC_CFLAGS
+= -DNO_SYS_SELECT_H
714 COMPAT_CFLAGS
+= -DNO_MMAP
715 COMPAT_OBJS
+= compat
/mmap.o
718 COMPAT_CFLAGS
+= -DNO_PREAD
719 COMPAT_OBJS
+= compat
/pread.o
721 ifdef NO_FAST_WORKING_DIRECTORY
722 BASIC_CFLAGS
+= -DNO_FAST_WORKING_DIRECTORY
724 ifdef NO_TRUSTABLE_FILEMODE
725 BASIC_CFLAGS
+= -DNO_TRUSTABLE_FILEMODE
728 BASIC_CFLAGS
+= -DNO_IPV6
730 ifdef NO_SOCKADDR_STORAGE
732 BASIC_CFLAGS
+= -Dsockaddr_storage
=sockaddr_in
734 BASIC_CFLAGS
+= -Dsockaddr_storage
=sockaddr_in6
738 LIB_OBJS
+= compat
/inet_ntop.o
741 LIB_OBJS
+= compat
/inet_pton.o
745 BASIC_CFLAGS
+= -DNO_ICONV
749 BASIC_CFLAGS
+= -DOLD_ICONV
752 ifdef NO_DEFLATE_BOUND
753 BASIC_CFLAGS
+= -DNO_DEFLATE_BOUND
757 SHA1_HEADER
= "ppc/sha1.h"
758 LIB_OBJS
+= ppc
/sha1.o ppc
/sha1ppc.o
761 SHA1_HEADER
= "arm/sha1.h"
762 LIB_OBJS
+= arm
/sha1.o arm
/sha1_arm.o
765 SHA1_HEADER
= "mozilla-sha1/sha1.h"
766 LIB_OBJS
+= mozilla-sha1
/sha1.o
768 SHA1_HEADER
= <openssl
/sha.h
>
769 EXTLIBS
+= $(LIB_4_CRYPTO
)
773 ifdef NO_PERL_MAKEMAKER
774 export NO_PERL_MAKEMAKER
777 COMPAT_CFLAGS
+= -DNO_HSTRERROR
778 COMPAT_OBJS
+= compat
/hstrerror.o
781 COMPAT_CFLAGS
+= -DNO_MEMMEM
782 COMPAT_OBJS
+= compat
/memmem.o
785 COMPAT_CFLAGS
+= -DINTERNAL_QSORT
786 COMPAT_OBJS
+= compat
/qsort.o
789 ifdef THREADED_DELTA_SEARCH
790 BASIC_CFLAGS
+= -DTHREADED_DELTA_SEARCH
792 LIB_OBJS
+= thread-utils.o
794 ifdef DIR_HAS_BSD_GROUP_SEMANTICS
795 COMPAT_CFLAGS
+= -DDIR_HAS_BSD_GROUP_SEMANTICS
798 ifeq ($(TCLTK_PATH
),)
802 QUIET_SUBDIR0
= +$(MAKE
) -C
# space to separate -C and subdir
805 ifneq ($(findstring $(MAKEFLAGS
),w
),w
)
806 PRINT_DIR
= --no-print-directory
811 ifneq ($(findstring $(MAKEFLAGS
),s
),s
)
813 QUIET_CC
= @echo
' ' CC
$@
;
814 QUIET_AR
= @echo
' ' AR
$@
;
815 QUIET_LINK
= @echo
' ' LINK
$@
;
816 QUIET_BUILT_IN
= @echo
' ' BUILTIN
$@
;
817 QUIET_GEN
= @echo
' ' GEN
$@
;
818 QUIET_SUBDIR0
= +@subdir
=
819 QUIET_SUBDIR1
= ;$(NO_SUBDIR
) echo
' ' SUBDIR
$$subdir; \
820 $(MAKE
) $(PRINT_DIR
) -C
$$subdir
823 export QUIET_BUILT_IN
831 # Shell quote (do not use $(call) to accommodate ancient setups);
833 SHA1_HEADER_SQ
= $(subst ','\'',$(SHA1_HEADER))
834 ETC_GITCONFIG_SQ = $(subst ','\'',$(ETC_GITCONFIG
))
836 DESTDIR_SQ
= $(subst ','\'',$(DESTDIR))
837 bindir_SQ = $(subst ','\'',$(bindir))
838 mandir_SQ
= $(subst ','\'',$(mandir))
839 infodir_SQ = $(subst ','\'',$(infodir))
840 gitexecdir_SQ
= $(subst ','\'',$(gitexecdir))
841 template_dir_SQ = $(subst ','\'',$(template_dir
))
842 htmldir_SQ
= $(subst ','\'',$(htmldir))
843 prefix_SQ = $(subst ','\'',$(prefix))
845 SHELL_PATH_SQ
= $(subst ','\'',$(SHELL_PATH))
846 PERL_PATH_SQ = $(subst ','\'',$(PERL_PATH
))
847 TCLTK_PATH_SQ
= $(subst ','\'',$(TCLTK_PATH))
849 LIBS = $(GITLIBS) $(EXTLIBS)
851 BASIC_CFLAGS += -DSHA1_HEADER='$(SHA1_HEADER_SQ
)' \
853 LIB_OBJS += $(COMPAT_OBJS)
855 ALL_CFLAGS += $(BASIC_CFLAGS)
856 ALL_LDFLAGS += $(BASIC_LDFLAGS)
858 export TAR INSTALL DESTDIR SHELL_PATH
863 all:: $(ALL_PROGRAMS) $(BUILT_INS) $(OTHER_PROGRAMS) GIT-BUILD-OPTIONS
865 $(foreach p,$(patsubst %$X,%,$(filter %$X,$(ALL_PROGRAMS) $(BUILT_INS) git$X)), $(RM) '$p';)
870 $(QUIET_SUBDIR0)git-gui $(QUIET_SUBDIR1) all
871 $(QUIET_SUBDIR0)gitk-git $(QUIET_SUBDIR1) all
873 $(QUIET_SUBDIR0)perl $(QUIET_SUBDIR1) PERL_PATH='$(PERL_PATH_SQ
)' prefix='$(prefix_SQ
)' all
874 $(QUIET_SUBDIR0)templates $(QUIET_SUBDIR1) NOEXECTEMPL='$(NOEXECTEMPL
)'
876 strip: $(PROGRAMS) git$X
877 $(STRIP) $(STRIP_OPTS) $(PROGRAMS) git$X
879 git.o: git.c common-cmds.h GIT-CFLAGS
880 $(QUIET_CC)$(CC) -DGIT_VERSION='"$(GIT_VERSION)"' \
881 $(ALL_CFLAGS) -c $(filter %.c,$^)
883 git$X: git.o $(BUILTIN_OBJS) $(GITLIBS)
884 $(QUIET_LINK)$(CC) $(ALL_CFLAGS) -o $@ git.o \
885 $(BUILTIN_OBJS) $(ALL_LDFLAGS) $(LIBS)
887 help.o: help.c common-cmds.h GIT-CFLAGS
888 $(QUIET_CC)$(CC) -o $*.o -c $(ALL_CFLAGS) \
889 '-DGIT_HTML_PATH
="$(htmldir_SQ)"' \
890 '-DGIT_MAN_PATH
="$(mandir_SQ)"' \
891 '-DGIT_INFO_PATH
="$(infodir_SQ)"' $<
894 $(QUIET_BUILT_IN)$(RM) $@ && ln git$X $@
896 common-cmds.h: ./generate-cmdlist.sh command-list.txt
898 common-cmds.h: $(wildcard Documentation/git-*.txt)
899 $(QUIET_GEN)./generate-cmdlist.sh > $@+ && mv $@+ $@
901 $(patsubst %.sh,%,$(SCRIPT_SH)) : % : %.sh
902 $(QUIET_GEN)$(RM) $@ $@+ && \
903 sed -e '1s|
#!.*/sh|#!$(SHELL_PATH_SQ)|' \
904 -e
's|@@PERL@@|$(PERL_PATH_SQ)|g' \
905 -e
's/@@GIT_VERSION@@/$(GIT_VERSION)/g' \
906 -e
's/@@NO_CURL@@/$(NO_CURL)/g' \
911 $(patsubst %.perl
,%,$(SCRIPT_PERL
)): perl
/perl.mak
913 perl
/perl.mak
: GIT-CFLAGS perl
/Makefile perl
/Makefile.PL
914 $(QUIET_SUBDIR0
)perl
$(QUIET_SUBDIR1
) PERL_PATH
='$(PERL_PATH_SQ)' prefix='$(prefix_SQ)' $(@F
)
916 $(patsubst %.perl
,%,$(SCRIPT_PERL
)): % : %.perl
917 $(QUIET_GEN
)$(RM
) $@
$@
+ && \
918 INSTLIBDIR
=`MAKEFLAGS= $(MAKE) -C perl -s --no-print-directory instlibdir` && \
920 -e
' s|#!.*perl|#!$(PERL_PATH_SQ)|' \
922 -e
' s=.*=use lib (split(/:/, $$ENV{GITPERLLIB} || "@@INSTLIBDIR@@"));=' \
926 -e
's|@@INSTLIBDIR@@|'"$$INSTLIBDIR"'|g' \
927 -e
's/@@GIT_VERSION@@/$(GIT_VERSION)/g' \
932 gitweb
/gitweb.cgi
: gitweb
/gitweb.perl
933 $(QUIET_GEN
)$(RM
) $@
$@
+ && \
934 sed
-e
'1s|#!.*perl|#!$(PERL_PATH_SQ)|' \
935 -e
's|++GIT_VERSION++|$(GIT_VERSION)|g' \
936 -e
's|++GIT_BINDIR++|$(bindir)|g' \
937 -e
's|++GITWEB_CONFIG++|$(GITWEB_CONFIG)|g' \
938 -e
's|++GITWEB_HOME_LINK_STR++|$(GITWEB_HOME_LINK_STR)|g' \
939 -e
's|++GITWEB_SITENAME++|$(GITWEB_SITENAME)|g' \
940 -e
's|++GITWEB_PROJECTROOT++|$(GITWEB_PROJECTROOT)|g' \
941 -e
's|"++GITWEB_PROJECT_MAXDEPTH++"|$(GITWEB_PROJECT_MAXDEPTH)|g' \
942 -e
's|++GITWEB_EXPORT_OK++|$(GITWEB_EXPORT_OK)|g' \
943 -e
's|++GITWEB_STRICT_EXPORT++|$(GITWEB_STRICT_EXPORT)|g' \
944 -e
's|++GITWEB_BASE_URL++|$(GITWEB_BASE_URL)|g' \
945 -e
's|++GITWEB_LIST++|$(GITWEB_LIST)|g' \
946 -e
's|++GITWEB_HOMETEXT++|$(GITWEB_HOMETEXT)|g' \
947 -e
's|++GITWEB_CSS++|$(GITWEB_CSS)|g' \
948 -e
's|++GITWEB_LOGO++|$(GITWEB_LOGO)|g' \
949 -e
's|++GITWEB_FAVICON++|$(GITWEB_FAVICON)|g' \
950 -e
's|++GITWEB_SITE_HEADER++|$(GITWEB_SITE_HEADER)|g' \
951 -e
's|++GITWEB_SITE_FOOTER++|$(GITWEB_SITE_FOOTER)|g' \
956 git-instaweb
: git-instaweb.sh gitweb
/gitweb.cgi gitweb
/gitweb.css
957 $(QUIET_GEN
)$(RM
) $@
$@
+ && \
958 sed
-e
'1s|#!.*/sh|#!$(SHELL_PATH_SQ)|' \
959 -e
's/@@GIT_VERSION@@/$(GIT_VERSION)/g' \
960 -e
's/@@NO_CURL@@/$(NO_CURL)/g' \
961 -e
'/@@GITWEB_CGI@@/r gitweb/gitweb.cgi' \
962 -e
'/@@GITWEB_CGI@@/d' \
963 -e
'/@@GITWEB_CSS@@/r gitweb/gitweb.css' \
964 -e
'/@@GITWEB_CSS@@/d' \
965 -e
's|@@PERL@@|$(PERL_PATH_SQ)|g' \
970 configure
: configure.ac
971 $(QUIET_GEN
)$(RM
) $@
$<+ && \
972 sed
-e
's/@@GIT_VERSION@@/$(GIT_VERSION)/g' \
974 autoconf
-o
$@
$<+ && \
977 # These can record GIT_VERSION
979 $(patsubst %.sh
,%,$(SCRIPT_SH
)) \
980 $(patsubst %.perl
,%,$(SCRIPT_PERL
)) \
984 $(QUIET_CC
)$(CC
) -o
$*.o
-c
$(ALL_CFLAGS
) $<
986 $(QUIET_CC
)$(CC
) -S
$(ALL_CFLAGS
) $<
988 $(QUIET_CC
)$(CC
) -o
$*.o
-c
$(ALL_CFLAGS
) $<
990 exec_cmd.o
: exec_cmd.c GIT-CFLAGS
991 $(QUIET_CC
)$(CC
) -o
$*.o
-c
$(ALL_CFLAGS
) '-DGIT_EXEC_PATH="$(gitexecdir_SQ)"' $<
992 builtin-init-db.o
: builtin-init-db.c GIT-CFLAGS
993 $(QUIET_CC
)$(CC
) -o
$*.o
-c
$(ALL_CFLAGS
) -DDEFAULT_GIT_TEMPLATE_DIR
='"$(template_dir_SQ)"' $<
995 config.o
: config.c GIT-CFLAGS
996 $(QUIET_CC
)$(CC
) -o
$*.o
-c
$(ALL_CFLAGS
) -DETC_GITCONFIG
='"$(ETC_GITCONFIG_SQ)"' $<
998 http.o
: http.c GIT-CFLAGS
999 $(QUIET_CC
)$(CC
) -o
$*.o
-c
$(ALL_CFLAGS
) -DGIT_USER_AGENT
='"git/$(GIT_VERSION)"' $<
1002 http-walker.o
: http-walker.c http.h GIT-CFLAGS
1003 $(QUIET_CC
)$(CC
) -o
$*.o
-c
$(ALL_CFLAGS
) -DNO_EXPAT
$<
1006 git-
%$X: %.o
$(GITLIBS
)
1007 $(QUIET_LINK
)$(CC
) $(ALL_CFLAGS
) -o
$@
$(ALL_LDFLAGS
) $(filter %.o
,$^
) $(LIBS
)
1009 git-imap-send
$X: imap-send.o
$(LIB_FILE
)
1011 http.o http-walker.o http-push.o transport.o
: http.h
1013 git-http-push
$X: revision.o http.o http-push.o
$(GITLIBS
)
1014 $(QUIET_LINK
)$(CC
) $(ALL_CFLAGS
) -o
$@
$(ALL_LDFLAGS
) $(filter %.o
,$^
) \
1015 $(LIBS
) $(CURL_LIBCURL
) $(EXPAT_LIBEXPAT
)
1017 $(LIB_OBJS
) $(BUILTIN_OBJS
): $(LIB_H
)
1018 $(patsubst git-
%$X,%.o
,$(PROGRAMS
)): $(LIB_H
) $(wildcard */*.h
)
1019 builtin-revert.o wt-status.o
: wt-status.h
1021 $(LIB_FILE
): $(LIB_OBJS
)
1022 $(QUIET_AR
)$(RM
) $@
&& $(AR
) rcs
$@
$(LIB_OBJS
)
1024 XDIFF_OBJS
=xdiff
/xdiffi.o xdiff
/xprepare.o xdiff
/xutils.o xdiff
/xemit.o \
1026 $(XDIFF_OBJS
): xdiff
/xinclude.h xdiff
/xmacros.h xdiff
/xdiff.h xdiff
/xtypes.h \
1027 xdiff
/xutils.h xdiff
/xprepare.h xdiff
/xdiffi.h xdiff
/xemit.h
1029 $(XDIFF_LIB
): $(XDIFF_OBJS
)
1030 $(QUIET_AR
)$(RM
) $@
&& $(AR
) rcs
$@
$(XDIFF_OBJS
)
1034 $(MAKE
) -C Documentation
all
1037 $(MAKE
) -C Documentation
info
1041 $(FIND
) .
-name
'*.[hcS]' -print | xargs etags
-a
1045 $(FIND
) .
-name
'*.[hcS]' -print | xargs ctags
-a
1049 $(FIND
) .
-name
'*.[hcS]' -print | xargs cscope
-b
1051 ### Detect prefix changes
1052 TRACK_CFLAGS
= $(subst ','\'',$(ALL_CFLAGS)):\
1053 $(bindir_SQ):$(gitexecdir_SQ):$(template_dir_SQ):$(prefix_SQ)
1055 GIT-CFLAGS: .FORCE-GIT-CFLAGS
1056 @FLAGS='$(TRACK_CFLAGS
)'; \
1057 if test x"$$FLAGS" != x"`cat GIT-CFLAGS 2>/dev/null`" ; then \
1058 echo 1>&2 " * new build flags or prefix"; \
1059 echo "$$FLAGS" >GIT-CFLAGS; \
1062 GIT-BUILD-OPTIONS: .FORCE-GIT-BUILD-OPTIONS
1063 @echo SHELL_PATH=\''$(SHELL_PATH_SQ
)'\' >$@
1065 ### Detect Tck/Tk interpreter path changes
1067 TRACK_VARS = $(subst ','\'',-DTCLTK_PATH
='$(TCLTK_PATH_SQ)')
1069 GIT-GUI-VARS
: .FORCE-GIT-GUI-VARS
1070 @VARS
='$(TRACK_VARS)'; \
1071 if
test x
"$$VARS" != x
"`cat $@ 2>/dev/null`" ; then \
1072 echo
1>&2 " * new Tcl/Tk interpreter location"; \
1073 echo
"$$VARS" >$@
; \
1076 .PHONY
: .FORCE-GIT-GUI-VARS
1081 TEST_PROGRAMS
= test-chmtime
$X test-genrandom
$X test-date
$X test-delta
$X test-sha1
$X test-match-trees
$X test-absolute-path
$X test-parse-options
$X
1083 all:: $(TEST_PROGRAMS
)
1085 # GNU make supports exporting all variables by "export" without parameters.
1086 # However, the environment gets quite big, and some programs have problems
1094 test-date
$X: date.o ctype.o
1096 test-delta
$X: diff-delta.o patch-delta.o
1098 test-parse-options
$X: parse-options.o
1100 .PRECIOUS
: $(patsubst test-
%$X,test-
%.o
,$(TEST_PROGRAMS
))
1102 test-
%$X: test-
%.o
$(GITLIBS
)
1103 $(QUIET_LINK
)$(CC
) $(ALL_CFLAGS
) -o
$@
$(ALL_LDFLAGS
) $(filter %.o
,$^
) $(LIBS
)
1105 check-sha1
:: test-sha1
$X
1108 check: common-cmds.h
1109 for i in
*.c
; do sparse
$(ALL_CFLAGS
) $(SPARSE_FLAGS
) $$i || exit
; done
1112 .
/fixup-builtins
$(BUILT_INS
)
1114 ### Installation rules
1116 ifeq ($(firstword $(subst /, ,$(template_dir
))),..
)
1117 template_instdir
= $(gitexecdir
)/$(template_dir
)
1119 template_instdir
= $template_dir
1121 export template_instdir
1124 $(INSTALL
) -d
-m
755 '$(DESTDIR_SQ)$(bindir_SQ)'
1125 $(INSTALL
) -d
-m
755 '$(DESTDIR_SQ)$(gitexecdir_SQ)'
1126 $(INSTALL
) $(ALL_PROGRAMS
) '$(DESTDIR_SQ)$(gitexecdir_SQ)'
1127 $(INSTALL
) git
$X '$(DESTDIR_SQ)$(bindir_SQ)'
1128 $(MAKE
) -C templates DESTDIR
='$(DESTDIR_SQ)' install
1129 $(MAKE
) -C perl
prefix='$(prefix_SQ)' DESTDIR
='$(DESTDIR_SQ)' install
1131 $(MAKE
) -C gitk-git
install
1132 $(MAKE
) -C git-gui
install
1134 if
test 'z$(bindir_SQ)' != 'z$(gitexecdir_SQ)'; \
1136 ln
-f
'$(DESTDIR_SQ)$(bindir_SQ)/git$X' \
1137 '$(DESTDIR_SQ)$(gitexecdir_SQ)/git$X' || \
1138 cp
'$(DESTDIR_SQ)$(bindir_SQ)/git$X' \
1139 '$(DESTDIR_SQ)$(gitexecdir_SQ)/git$X'; \
1141 $(foreach p
,$(BUILT_INS
), $(RM
) '$(DESTDIR_SQ)$(gitexecdir_SQ)/$p' && ln
'$(DESTDIR_SQ)$(gitexecdir_SQ)/git$X' '$(DESTDIR_SQ)$(gitexecdir_SQ)/$p' ;)
1143 $(foreach p
,$(patsubst %$X,%,$(filter %$X,$(ALL_PROGRAMS
) $(BUILT_INS
) git
$X)), $(RM
) '$(DESTDIR_SQ)$(gitexecdir_SQ)/$p';)
1147 $(MAKE
) -C Documentation
install
1150 $(MAKE
) -C Documentation install-info
1153 $(MAKE
) -C Documentation quick-install
1157 ### Maintainer's dist rules
1159 git.spec
: git.spec.in
1160 sed
-e
's/@@VERSION@@/$(GIT_VERSION)/g' < $< > $@
+
1163 GIT_TARNAME
=git-
$(GIT_VERSION
)
1164 dist: git.spec git-archive
$(X
) configure
1165 .
/git-archive
--format
=tar \
1166 --prefix=$(GIT_TARNAME
)/ HEAD^
{tree
} > $(GIT_TARNAME
).
tar
1167 @mkdir
-p
$(GIT_TARNAME
)
1168 @cp git.spec configure
$(GIT_TARNAME
)
1169 @echo
$(GIT_VERSION
) > $(GIT_TARNAME
)/version
1170 @
$(MAKE
) -C git-gui TARDIR
=..
/$(GIT_TARNAME
)/git-gui dist-version
1171 $(TAR
) rf
$(GIT_TARNAME
).
tar \
1172 $(GIT_TARNAME
)/git.spec \
1173 $(GIT_TARNAME
)/configure \
1174 $(GIT_TARNAME
)/version \
1175 $(GIT_TARNAME
)/git-gui
/version
1176 @
$(RM
) -r
$(GIT_TARNAME
)
1177 gzip
-f
-9 $(GIT_TARNAME
).
tar
1180 $(RPMBUILD
) -ta
$(GIT_TARNAME
).
tar.gz
1182 htmldocs
= git-htmldocs-
$(GIT_VERSION
)
1183 manpages
= git-manpages-
$(GIT_VERSION
)
1185 $(RM
) -r .doc-tmp-dir
1187 $(MAKE
) -C Documentation WEBDOC_DEST
=..
/.doc-tmp-dir install-webdoc
1188 cd .doc-tmp-dir
&& $(TAR
) cf ..
/$(htmldocs
).
tar .
1189 gzip
-n
-9 -f
$(htmldocs
).
tar
1191 $(RM
) -r .doc-tmp-dir
1192 mkdir
-p .doc-tmp-dir
/man1 .doc-tmp-dir
/man5 .doc-tmp-dir
/man7
1193 $(MAKE
) -C Documentation DESTDIR
=.
/ \
1194 man1dir=..
/.doc-tmp-dir
/man1 \
1195 man5dir=..
/.doc-tmp-dir
/man5 \
1196 man7dir=..
/.doc-tmp-dir
/man7 \
1198 cd .doc-tmp-dir
&& $(TAR
) cf ..
/$(manpages
).
tar .
1199 gzip
-n
-9 -f
$(manpages
).
tar
1200 $(RM
) -r .doc-tmp-dir
1208 $(RM
) *.o mozilla-sha1
/*.o arm
/*.o ppc
/*.o compat
/*.o xdiff
/*.o \
1209 $(LIB_FILE
) $(XDIFF_LIB
)
1210 $(RM
) $(ALL_PROGRAMS
) $(BUILT_INS
) git
$X
1211 $(RM
) $(TEST_PROGRAMS
)
1212 $(RM
) *.spec
*.pyc
*.pyo
*/*.pyc
*/*.pyo common-cmds.h TAGS
tags cscope
*
1213 $(RM
) -r autom4te.cache
1214 $(RM
) config.log config.mak.autogen config.mak.append config.status config.cache
1215 $(RM
) -r
$(GIT_TARNAME
) .doc-tmp-dir
1216 $(RM
) $(GIT_TARNAME
).
tar.gz git-core_
$(GIT_VERSION
)-*.
tar.gz
1217 $(RM
) $(htmldocs
).
tar.gz
$(manpages
).
tar.gz
1218 $(RM
) gitweb
/gitweb.cgi
1219 $(MAKE
) -C Documentation
/ clean
1220 $(MAKE
) -C perl
clean
1221 $(MAKE
) -C templates
/ clean
1224 $(MAKE
) -C gitk-git
clean
1225 $(MAKE
) -C git-gui
clean
1227 $(RM
) GIT-VERSION-FILE GIT-CFLAGS GIT-GUI-VARS GIT-BUILD-OPTIONS
1229 .PHONY
: all install clean strip
1230 .PHONY
: .FORCE-GIT-VERSION-FILE TAGS
tags cscope .FORCE-GIT-CFLAGS
1231 .PHONY
: .FORCE-GIT-BUILD-OPTIONS
1233 ### Check documentation
1236 @
(for v in
$(ALL_PROGRAMS
) $(BUILT_INS
) git gitk
; \
1239 git-merge-octopus | git-merge-ours | git-merge-recursive | \
1240 git-merge-resolve | git-merge-stupid | git-merge-subtree | \
1241 git-fsck-objects | git-init-db | \
1242 git-?
*--?
* ) continue
;; \
1244 test -f
"Documentation/$$v.txt" || \
1245 echo
"no doc: $$v"; \
1246 sed
-e
'/^#/d' command-list.txt | \
1247 grep
-q
"^$$v[ ]" || \
1250 *) echo
"no link: $$v";; \
1256 -e
's/^/listed /' command-list.txt
; \
1257 ls
-1 Documentation
/git
*txt | \
1258 sed
-e
's|Documentation/|documented |' \
1260 ) | while read how cmd
; \
1262 case
"$$how,$$cmd" in \
1266 documented
,gitattributes | \
1267 documented
,gitignore | \
1268 documented
,gitmodules | \
1269 documented
,gitcli | \
1270 documented
,git-tools | \
1271 sentinel
,not
,matching
,is
,ok
) continue
;; \
1273 case
" $(ALL_PROGRAMS) $(BUILT_INS) git gitk " in \
1275 *) echo
"removed but $$how: $$cmd" ;; \
1279 ### Make sure built-ins do not have dups and listed in git.c