aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile8
-rw-r--r--blob.c2
-rw-r--r--cache.h9
-rw-r--r--commit.c2
-rw-r--r--debian/.gitignore6
-rw-r--r--debian/changelog242
-rw-r--r--debian/compat1
-rw-r--r--debian/control63
-rw-r--r--debian/copyright24
-rw-r--r--debian/docs1
-rw-r--r--debian/git-arch.files2
-rw-r--r--debian/git-core.doc-base13
-rw-r--r--debian/git-core.files1
-rw-r--r--debian/git-cvs.files2
-rw-r--r--debian/git-doc.files4
-rw-r--r--debian/git-email.files2
-rw-r--r--debian/git-svn.files2
-rw-r--r--debian/git-tk.files2
-rwxr-xr-xdebian/rules109
-rw-r--r--describe.c2
-rw-r--r--git-compat-util.h8
-rwxr-xr-xgit-cvsexportcommit.perl12
-rwxr-xr-xgit-cvsimport.perl1
-rwxr-xr-xgit-format-patch.sh6
-rwxr-xr-xgit-prune.sh3
-rwxr-xr-xgit-revert.sh1
-rw-r--r--ls-files.c2
-rw-r--r--mailsplit.c5
-rw-r--r--object.c2
-rw-r--r--object.h2
-rw-r--r--receive-pack.c2
-rwxr-xr-xt/t2001-checkout-cache-clash.sh2
-rw-r--r--tag.c2
-rw-r--r--tar-tree.c2
-rw-r--r--tree.c2
-rw-r--r--unpack-objects.c2
36 files changed, 47 insertions, 504 deletions
diff --git a/Makefile b/Makefile
index 1b6caf85b..c9c15b5ff 100644
--- a/Makefile
+++ b/Makefile
@@ -496,12 +496,6 @@ dist: git.spec git-tar-tree
rpm: dist
$(RPMBUILD) -ta $(GIT_TARNAME).tar.gz
-deb: dist
- rm -rf $(GIT_TARNAME)
- $(TAR) zxf $(GIT_TARNAME).tar.gz
- dpkg-source -b $(GIT_TARNAME)
- cd $(GIT_TARNAME) && fakeroot debian/rules binary
-
### Cleaning rules
clean:
@@ -511,8 +505,6 @@ clean:
rm -f *.spec *.pyc *.pyo */*.pyc */*.pyo
rm -rf $(GIT_TARNAME)
rm -f $(GIT_TARNAME).tar.gz git-core_$(GIT_VERSION)-*.tar.gz
- rm -f git-core_$(GIT_VERSION)-*.dsc
- rm -f git-*_$(GIT_VERSION)-*.deb
$(MAKE) -C Documentation/ clean
$(MAKE) -C templates clean
$(MAKE) -C t/ clean
diff --git a/blob.c b/blob.c
index ea52ad5c9..84ec1212e 100644
--- a/blob.c
+++ b/blob.c
@@ -1,5 +1,5 @@
-#include "blob.h"
#include "cache.h"
+#include "blob.h"
#include <stdlib.h>
const char *blob_type = "blob";
diff --git a/cache.h b/cache.h
index a99fb3ce7..29c9e819d 100644
--- a/cache.h
+++ b/cache.h
@@ -81,7 +81,7 @@ struct cache_entry {
unsigned int ce_size;
unsigned char sha1[20];
unsigned short ce_flags;
- char name[0];
+ char name[FLEX_ARRAY]; /* more */
};
#define CE_NAMEMASK (0x0fff)
@@ -259,7 +259,7 @@ extern int checkout_entry(struct cache_entry *ce, struct checkout *state);
extern struct alternate_object_database {
struct alternate_object_database *next;
char *name;
- char base[0]; /* more */
+ char base[FLEX_ARRAY]; /* more */
} *alt_odb_list;
extern void prepare_alt_odb(void);
@@ -273,7 +273,8 @@ extern struct packed_git {
unsigned int pack_use_cnt;
int pack_local;
unsigned char sha1[20];
- char pack_name[0]; /* something like ".git/objects/pack/xxxxx.pack" */
+ /* something like ".git/objects/pack/xxxxx.pack" */
+ char pack_name[FLEX_ARRAY]; /* more */
} *packed_git;
struct pack_entry {
@@ -288,7 +289,7 @@ struct ref {
unsigned char new_sha1[20];
unsigned char force;
struct ref *peer_ref; /* when renaming */
- char name[0];
+ char name[FLEX_ARRAY]; /* more */
};
extern int git_connect(int fd[2], char *url, const char *prog);
diff --git a/commit.c b/commit.c
index e9a29caa2..56efc69f1 100644
--- a/commit.c
+++ b/commit.c
@@ -1,6 +1,6 @@
+#include "cache.h"
#include "tag.h"
#include "commit.h"
-#include "cache.h"
int save_commit_buffer = 1;
diff --git a/debian/.gitignore b/debian/.gitignore
deleted file mode 100644
index 335ce9c59..000000000
--- a/debian/.gitignore
+++ /dev/null
@@ -1,6 +0,0 @@
-git-core
-git-tk
-*.debhelper
-*.substvars
-build-stamp
-files
diff --git a/debian/changelog b/debian/changelog
deleted file mode 100644
index d7f759107..000000000
--- a/debian/changelog
+++ /dev/null
@@ -1,242 +0,0 @@
-git-core (1.0.GIT-0) unstable; urgency=low
-
- * Post GIT 1.0 development track.
-
- -- Junio C Hamano <junkio@cox.net> Wed, 21 Dec 2005 22:28:33 -0800
-
-git-core (1.0.0.GIT-0) unstable; urgency=low
-
- * Post GIT 1.0.0 development track.
-
- -- Junio C Hamano <junkio@cox.net> Wed, 21 Dec 2005 12:12:05 -0800
-
-git-core (1.0.4-0) unstable; urgency=low
-
- * GIT 1.0.4.
-
- -- Junio C Hamano <junkio@cox.net> Sat, 24 Dec 2005 00:01:20 -0800
-
-git-core (1.0.3-0) unstable; urgency=low
-
- * GIT 1.0.3 maintenance release.
-
- -- Junio C Hamano <junkio@cox.net> Thu, 22 Dec 2005 18:13:33 -0800
-
-git-core (1.0.0b-0) unstable; urgency=low
-
- * GIT 1.0.0b to include two more fixes.
-
- -- Junio C Hamano <junkio@cox.net> Wed, 21 Dec 2005 13:50:21 -0800
-
-git-core (1.0.0a-0) unstable; urgency=low
-
- * GIT 1.0.0a to include the following fixes:
-
- - Avoid misleading success message on error (Johannes)
- - objects/info/packs: work around bug in http-fetch.c::fetch_indices()
- - http-fetch.c: fix objects/info/pack parsing.
- - An off-by-one bug found by valgrind (Pavel)
-
- -- Junio C Hamano <junkio@cox.net> Wed, 21 Dec 2005 13:17:17 -0800
-
-git-core (1.0.0-0) unstable; urgency=low
-
- * GIT 1.0.0
-
- -- Junio C Hamano <junkio@cox.net> Wed, 21 Dec 2005 00:01:00 -0800
-
-git-core (0.99.9n-0) unstable; urgency=low
-
- * GIT 0.99.9n aka 1.0rc6
-
- -- Junio C Hamano <junkio@cox.net> Wed, 14 Dec 2005 17:27:08 -0800
-
-git-core (0.99.9m-0) unstable; urgency=low
-
- * GIT 0.99.9m aka 1.0rc5
-
- -- Junio C Hamano <junkio@cox.net> Sun, 11 Dec 2005 16:48:06 -0800
-
-git-core (0.99.9l-0) unstable; urgency=low
-
- * GIT 0.99.9l aka 1.0rc4
-
- -- Junio C Hamano <junkio@cox.net> Sat, 3 Dec 2005 23:45:23 -0800
-
-git-core (0.99.9k-0) unstable; urgency=low
-
- * GIT 0.99.9k but not 1.0rc yet.
-
- -- Junio C Hamano <junkio@cox.net> Fri, 25 Nov 2005 16:33:11 -0800
-
-git-core (0.99.9j-0) unstable; urgency=low
-
- * GIT 0.99.9j aka 1.0rc3
-
- -- Junio C Hamano <junkio@cox.net> Wed, 16 Nov 2005 20:39:55 -0800
-
-git-core (0.99.9i-0) unstable; urgency=low
-
- * GIT 0.99.9i aka 1.0rc2
-
- -- Junio C Hamano <junkio@cox.net> Mon, 14 Nov 2005 18:38:27 -0800
-
-git-core (0.99.9h-0) unstable; urgency=low
-
- * GIT 0.99.9h
-
- -- Junio C Hamano <junkio@cox.net> Fri, 11 Nov 2005 22:33:18 -0800
-
-git-core (0.99.9g-0) unstable; urgency=low
-
- * GIT 0.99.9g
-
- -- Junio C Hamano <junkio@cox.net> Wed, 9 Nov 2005 21:01:55 -0800
-
-git-core (0.99.9f-0) unstable; urgency=low
-
- * GIT 0.99.9f
-
- -- Junio C Hamano <junkio@cox.net> Tue, 8 Nov 2005 01:21:52 -0800
-
-git-core (0.99.9e-0) unstable; urgency=low
-
- * GIT 0.99.9e
-
- -- Junio C Hamano <junkio@cox.net> Sun, 6 Nov 2005 18:37:18 -0800
-
-git-core (0.99.9d-0) unstable; urgency=low
-
- * GIT 0.99.9d
-
- -- Junio C Hamano <junkio@cox.net> Sat, 5 Nov 2005 11:46:37 -0800
-
-git-core (0.99.9c-0) unstable; urgency=low
-
- * GIT 0.99.9c
-
- -- Junio C Hamano <junkio@cox.net> Thu, 3 Nov 2005 15:44:54 -0800
-
-git-core (0.99.9b-0) unstable; urgency=low
-
- * GIT 0.99.9b
-
- -- Junio C Hamano <junkio@cox.net> Tue, 1 Nov 2005 21:39:39 -0800
-
-git-core (0.99.9a-0) unstable; urgency=low
-
- * GIT 0.99.9a
-
- -- Junio C Hamano <junkio@cox.net> Sun, 30 Oct 2005 15:03:32 -0800
-
-git-core (0.99.9.GIT-2) unstable; urgency=low
-
- * Build Dependency did not include libexpat-dev.
-
- -- Junio C Hamano <junkio@cox.net> Sun, 13 Nov 2005 01:55:34 -0800
-
-git-core (0.99.9.GIT-1) unstable; urgency=low
-
- * Do not scatter txt and html documentation into feature
- subpackages. Do place man pages into them.
- * Capture more cvs stuff into git-cvs package.
-
- -- Junio C Hamano <junkio@cox.net> Tue, 8 Nov 2005 01:19:06 -0800
-
-git-core (0.99.9.GIT-0) unstable; urgency=low
-
- * Test Build.
-
- -- Junio C Hamano <junkio@cox.net> Sat, 5 Nov 2005 11:18:13 -0800
-
-git-core (0.99.9-1) unstable; urgency=low
-
- * Split the git-core binary package into core, doc, and foreign SCM
- interoperability modules.
-
- -- Junio C Hamano <junkio@cox.net> Sat, 5 Nov 2005 11:18:13 -0800
-
-git-core (0.99.9-0) unstable; urgency=low
-
- * GIT 0.99.9
-
- -- Junio C Hamano <junkio@cox.net> Sat, 29 Oct 2005 14:34:30 -0700
-
-git-core (0.99.8-0) unstable; urgency=low
-
- * GIT 0.99.8
-
- -- Junio C Hamano <junkio@cox.net> Sun, 2 Oct 2005 12:54:26 -0700
-
-git-core (0.99.7-0) unstable; urgency=low
-
- * GIT 0.99.7
-
- -- Junio C Hamano <junkio@cox.net> Sat, 10 Sep 2005 18:36:39 -0700
-
-git-core (0.99.6-0) unstable; urgency=low
-
- * GIT 0.99.6
-
- -- Junio C Hamano <junkio@cox.net> Wed, 24 Aug 2005 23:09:35 -0700
-
-git-core (0.99.5-1) unstable; urgency=low
-
- * Enable git-send-email on Debian. There is no reason to shy
- away from it, since we have the necessary Perl modules available.
-
- -- Junio C Hamano <junkio@cox.net> Thu, 25 Aug 2005 14:16:59 -0700
-
-git-core (0.99.5-0) unstable; urgency=low
-
- * GIT 0.99.5
-
- -- Junio C Hamano <junkio@cox.net> Wed, 10 Aug 2005 22:05:00 -0700
-
-git-core (0.99.4-4) unstable; urgency=low
-
- * Mark git-tk as architecture neutral.
-
- -- Junio C Hamano <junkio@cox.net> Fri, 12 Aug 2005 13:25:00 -0700
-
-git-core (0.99.4-3) unstable; urgency=low
-
- * Split off gitk.
- * Do not depend on diff which is an essential package.
- * Use dh_movefiles, not dh_install, to stage two subpackages.
-
- -- Matthias Urlichs <smurf@debian.org> Thu, 11 Aug 2005 01:43:24 +0200
-
-git-core (0.99.4-2) unstable; urgency=low
-
- * Git 0.99.4 official release.
-
- -- Junio C Hamano <junkio@cox.net> Wed, 10 Aug 2005 15:00:00 -0700
-
-git-core (0.99.4-1) unstable; urgency=low
-
- * Pass prefix down to the submake when building.
-
- -- Junio C Hamano <junkio@cox.net> Sat, 6 Aug 2005 13:00:00 -0700
-
-git-core (0.99-2) unstable; urgency=low
-
- * Conflict with the GNU Interactive Tools package, which also installs
- /usr/bin/git.
- * Use the Mozilla SHA1 code and/or the PPC assembly in preference to
- OpenSSL. This is only a partial fix for the license issues with OpenSSL.
- * Minor tweaks to the Depends.
-
- -- Ryan Anderson <ryan@michonline.com> Sat, 23 Jul 2005 14:15:00 -0400
-
-git-core (0.99-1) unstable; urgency=low
-
- * Update deb package support to build correctly.
-
- -- Ryan Anderson <ryan@michonline.com> Thu, 21 Jul 2005 02:03:32 -0400
-
-git-core (0.99-0) unstable; urgency=low
-
- * Initial deb package support
-
- -- Eric Biederman <ebiederm@xmission.com> Tue, 12 Jul 2005 10:57:51 -0600
diff --git a/debian/compat b/debian/compat
deleted file mode 100644
index b8626c4cf..000000000
--- a/debian/compat
+++ /dev/null
@@ -1 +0,0 @@
-4
diff --git a/debian/control b/debian/control
deleted file mode 100644
index ded0a576d..000000000
--- a/debian/control
+++ /dev/null
@@ -1,63 +0,0 @@
-Source: git-core
-Section: devel
-Priority: optional
-Maintainer: Junio C Hamano <junkio@cox.net>
-Build-Depends-Indep: libz-dev, libssl-dev, libcurl3-dev|libcurl3-gnutls-dev|libcurl3-openssl-dev, asciidoc (>= 7), xmlto, debhelper (>= 4.0.0), bc, libexpat-dev
-Standards-Version: 3.6.1
-
-Package: git-core
-Architecture: any
-Depends: ${shlibs:Depends}, ${perl:Depends}, ${misc:Depends}, rcs
-Recommends: rsync, curl, ssh, python (>= 2.4.0), less
-Suggests: cogito, patch
-Conflicts: git, cogito (<< 0.13)
-Description: The git content addressable filesystem
- GIT comes in two layers. The bottom layer is merely an extremely fast
- and flexible filesystem-based database designed to store directory trees
- with regard to their history. The top layer is a SCM-like tool which
- enables human beings to work with the database in a manner to a degree
- similar to other SCM tools.
-
-Package: git-doc
-Architecture: all
-Depends: ${shlibs:Depends}, ${misc:Depends}, git-core
-Description: The git content addressable filesystem, Documentation
- This package contains documentation for GIT.
-
-Package: git-tk
-Architecture: all
-Depends: ${shlibs:Depends}, ${misc:Depends}, git-core, tk8.4
-Description: The git content addressable filesystem, GUI add-on
- This package contains 'gitk', the git revision tree visualizer.
-
-Package: git-svn
-Architecture: all
-Depends: ${shlibs:Depends}, ${misc:Depends}, ${perl:Depends}, git-core, libsvn-core-perl (>= 1.2.1)
-Suggests: subversion
-Description: The git content addressable filesystem, SVN interoperability
- This package contains 'git-svnimport', to import development history from
- SVN repositories.
-
-Package: git-arch
-Architecture: all
-Depends: ${shlibs:Depends}, ${misc:Depends}, ${perl:Depends}, git-core
-Suggests: tla, bazaar
-Description: The git content addressable filesystem, GNUArch interoperability
- This package contains 'git-archimport', to import development history from
- GNUArch repositories.
-
-Package: git-cvs
-Architecture: all
-Depends: ${shlibs:Depends}, ${misc:Depends}, ${perl:Depends}, git-core, cvsps (>= 2.1)
-Suggests: cvs
-Description: The git content addressable filesystem, CVS interoperability
- This package contains 'git-cvsimport', to import development history from
- CVS repositories.
-
-Package: git-email
-Architecture: all
-Depends: ${shlibs:Depends}, ${misc:Depends}, git-core, libmail-sendmail-perl, libemail-valid-perl
-Description: The git content addressable filesystem, e-mail add-on
- This package contains 'git-send-email', to send a series of patch e-mails.
-
-
diff --git a/debian/copyright b/debian/copyright
deleted file mode 100644
index ea61effc4..000000000
--- a/debian/copyright
+++ /dev/null
@@ -1,24 +0,0 @@
-This package was downloaded from ftp.kernel.org:/pub/software/scm/git/.
-
-Upstream Author: Linus Torvalds and many others
-
-Copyright:
-
- Copyright 2005, Linus Torvalds and others.
-
- This package is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; version 2 dated June, 1991.
-
- This package is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this package; if not, write to the Free Software
- Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
- 02111-1307, USA.
-
-On Debian GNU/Linux systems, the complete text of the GNU General
-Public License can be found in `/usr/share/common-licenses/GPL'.
diff --git a/debian/docs b/debian/docs
deleted file mode 100644
index e845566c0..000000000
--- a/debian/docs
+++ /dev/null
@@ -1 +0,0 @@
-README
diff --git a/debian/git-arch.files b/debian/git-arch.files
deleted file mode 100644
index d7449540c..000000000
--- a/debian/git-arch.files
+++ /dev/null
@@ -1,2 +0,0 @@
-/usr/bin/git-arch*
-/usr/share/man/*/git-arch*
diff --git a/debian/git-core.doc-base b/debian/git-core.doc-base
deleted file mode 100644
index eff1a9523..000000000
--- a/debian/git-core.doc-base
+++ /dev/null
@@ -1,13 +0,0 @@
-Document: git-core
-Title: git reference
-Abstract: This manual describes git
-Section: Devel
-
-Format: HTML
-Index: /usr/share/doc/git-core/git.html
-Files: /usr/share/doc/git-core/*.html
- /usr/share/doc/git-core/*/*.html
-
-Format: text
-Files: /usr/share/doc/git-core/*.txt
- /usr/share/doc/git-core/*/*.txt
diff --git a/debian/git-core.files b/debian/git-core.files
deleted file mode 100644
index 74e4e23b0..000000000
--- a/debian/git-core.files
+++ /dev/null
@@ -1 +0,0 @@
-/usr
diff --git a/debian/git-cvs.files b/debian/git-cvs.files
deleted file mode 100644
index a6b40ff9e..000000000
--- a/debian/git-cvs.files
+++ /dev/null
@@ -1,2 +0,0 @@
-/usr/bin/git-cvs*
-/usr/share/man/*/git-cvs*
diff --git a/debian/git-doc.files b/debian/git-doc.files
deleted file mode 100644
index 0daf545ad..000000000
--- a/debian/git-doc.files
+++ /dev/null
@@ -1,4 +0,0 @@
-/usr/share/doc/git-core/*.txt
-/usr/share/doc/git-core/*.html
-/usr/share/doc/git-core/*/*.html
-/usr/share/doc/git-core/*/*.txt
diff --git a/debian/git-email.files b/debian/git-email.files
deleted file mode 100644
index 2d6a51fc3..000000000
--- a/debian/git-email.files
+++ /dev/null
@@ -1,2 +0,0 @@
-/usr/bin/git-send-email
-/usr/share/man/*/git-send-email.*
diff --git a/debian/git-svn.files b/debian/git-svn.files
deleted file mode 100644
index eea8d83f6..000000000
--- a/debian/git-svn.files
+++ /dev/null
@@ -1,2 +0,0 @@
-/usr/bin/git-svn*
-/usr/share/man/*/git-svn*
diff --git a/debian/git-tk.files b/debian/git-tk.files
deleted file mode 100644
index 478ec9440..000000000
--- a/debian/git-tk.files
+++ /dev/null
@@ -1,2 +0,0 @@
-/usr/bin/gitk
-/usr/share/man/man1/gitk.*
diff --git a/debian/rules b/debian/rules
deleted file mode 100755
index 4ab221ce9..000000000
--- a/debian/rules
+++ /dev/null
@@ -1,109 +0,0 @@
-#!/usr/bin/make -f
-# -*- makefile -*-
-
-# Uncomment this to turn on verbose mode.
-#export DH_VERBOSE=1
-
-CFLAGS = -g -Wall
-ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
- CFLAGS += -O0
-else
- CFLAGS += -O2
-endif
-export CFLAGS
-
-#
-# On PowerPC we compile against the hand-crafted assembly, on all
-# other architectures we compile against GPL'ed sha1 code lifted
-# from Mozilla. OpenSSL is strangely licensed and best avoided
-# in Debian.
-#
-HOST_ARCH=$(shell dpkg-architecture -qDEB_HOST_ARCH)
-ifeq (${HOST_ARCH},powerpc)
- export PPC_SHA1=YesPlease
-else
- export MOZILLA_SHA1=YesPlease
-endif
-
-# We do have the requisite perl modules in the mainline, and
-# have no reason to shy away from this script.
-export WITH_SEND_EMAIL=YesPlease
-
-PREFIX := /usr
-MANDIR := /usr/share/man/
-
-SRC := ./
-DOC := Documentation/
-DESTDIR := $(CURDIR)/debian/tmp
-DOC_DESTDIR := $(DESTDIR)/usr/share/doc/git-core/
-MAN_DESTDIR := $(DESTDIR)/$(MANDIR)
-
-build: debian/build-stamp
-debian/build-stamp:
- dh_testdir
- $(MAKE) prefix=$(PREFIX) PYTHON_PATH=/usr/bin/python2.4 all test doc
- touch debian/build-stamp
-
-debian-clean:
- dh_testdir
- dh_testroot
- rm -f debian/build-stamp
- dh_clean
-
-clean: debian-clean
- $(MAKE) clean
-
-install: build
- dh_testdir
- dh_testroot
- dh_clean -k
- dh_installdirs
-
- make DESTDIR=$(DESTDIR) prefix=$(PREFIX) mandir=$(MANDIR) \
- install install-doc
-
- make -C Documentation DESTDIR=$(DESTDIR) prefix=$(PREFIX) \
- WEBDOC_DEST=$(DOC_DESTDIR) install-webdoc
-
- dh_movefiles -p git-arch
- dh_movefiles -p git-cvs
- dh_movefiles -p git-svn
- dh_movefiles -p git-tk
- dh_movefiles -p git-email
- dh_movefiles -p git-doc
- dh_movefiles -p git-core
- find debian/tmp -type d -o -print | sed -e 's/^/? /'
-
-binary-arch: build install
- dh_testdir
- dh_testroot
- dh_installchangelogs -a
- dh_installdocs -a
- dh_strip -a
- dh_compress -a
- dh_fixperms -a
- dh_perl -a
- dh_makeshlibs -a
- dh_installdeb -a
- dh_shlibdeps -a
- dh_gencontrol -a
- dh_md5sums -a
- dh_builddeb -a
-
-binary-indep: build install
- dh_testdir
- dh_testroot
- dh_installchangelogs -i
- dh_installdocs -i
- dh_compress -i
- dh_fixperms -i
- dh_makeshlibs -i
- dh_installdeb -i
- dh_shlibdeps -i
- dh_gencontrol -i
- dh_md5sums -i
- dh_builddeb -i
-
-binary: binary-arch binary-indep
-
-.PHONY: build clean binary install clean debian-clean
diff --git a/describe.c b/describe.c
index 00fa02adc..a0180f548 100644
--- a/describe.c
+++ b/describe.c
@@ -18,7 +18,7 @@ static int names = 0, allocs = 0;
static struct commit_name {
const struct commit *commit;
int prio; /* annotated tag = 2, tag = 1, head = 0 */
- char path[];
+ char path[FLEX_ARRAY]; /* more */
} **name_array = NULL;
static struct commit_name *match(struct commit *cmit)
diff --git a/git-compat-util.h b/git-compat-util.h
index c353b276f..12ce6590b 100644
--- a/git-compat-util.h
+++ b/git-compat-util.h
@@ -1,6 +1,14 @@
#ifndef GIT_COMPAT_UTIL_H
#define GIT_COMPAT_UTIL_H
+#ifndef FLEX_ARRAY
+#if defined(__GNUC__) && (__GNUC__ < 3)
+#define FLEX_ARRAY 0
+#else
+#define FLEX_ARRAY /* empty */
+#endif
+#endif
+
#include <unistd.h>
#include <stdio.h>
#include <sys/stat.h>
diff --git a/git-cvsexportcommit.perl b/git-cvsexportcommit.perl
index 5a8c01180..d5fbee7ba 100755
--- a/git-cvsexportcommit.perl
+++ b/git-cvsexportcommit.perl
@@ -103,8 +103,16 @@ undef @files; # don't need it anymore
# check that the files are clean and up to date according to cvs
my $dirty;
-foreach my $f (@afiles, @mfiles, @dfiles) {
- # TODO:we need to handle removed in cvs and/or new (from git)
+foreach my $f (@afiles) {
+ my $status = `cvs -q status "$f" | grep '^File: '`;
+
+ unless ($status =~ m/Status: Unknown$/) {
+ $dirty = 1;
+ warn "File $f is already known in your CVS checkout!\n";
+ }
+}
+foreach my $f (@mfiles, @dfiles) {
+ # TODO:we need to handle removed in cvs
my $status = `cvs -q status "$f" | grep '^File: '`;
unless ($status =~ m/Status: Up-to-date$/) {
diff --git a/git-cvsimport.perl b/git-cvsimport.perl
index 08a890c2b..8619e7d18 100755
--- a/git-cvsimport.perl
+++ b/git-cvsimport.perl
@@ -649,6 +649,7 @@ my $commit = sub {
my($xtag) = $tag;
$xtag =~ s/\s+\*\*.*$//; # Remove stuff like ** INVALID ** and ** FUNKY **
$xtag =~ tr/_/\./ if ( $opt_u );
+ $xtag =~ s/[\/]/$opt_s/g;
my $pid = open2($in, $out, 'git-mktag');
print $out "object $cid\n".
diff --git a/git-format-patch.sh b/git-format-patch.sh
index 818059f24..d3979d763 100755
--- a/git-format-patch.sh
+++ b/git-format-patch.sh
@@ -9,8 +9,10 @@ one file per patch, for e-mail submission. Each output file is
numbered sequentially from 1, and uses the first line of the commit
message (massaged for pathname safety) as the filename.
-When -o is specified, output files are created in that directory; otherwise in
-the current working directory.
+There are three output modes. By default, output files are created in
+the current working directory; when -o is specified, they are created
+in that directory instead; when --stdout is specified, they are spit
+on standard output, and can be piped to git-am.
When -n is specified, instead of "[PATCH] Subject", the first line is formatted
as "[PATCH N/M] Subject", unless you have only one patch.
diff --git a/git-prune.sh b/git-prune.sh
index 7b61d05c4..c5a5d29aa 100755
--- a/git-prune.sh
+++ b/git-prune.sh
@@ -33,8 +33,7 @@ sed -ne '/unreachable /{
git-prune-packed $dryrun
-redundant=$(git-pack-redundant --all)
-if test "" != "$redundant"
+if redundant=$(git-pack-redundant --all 2>/dev/null) && test "" != "$redundant"
then
if test "" = "$dryrun"
then
diff --git a/git-revert.sh b/git-revert.sh
index 63d201be1..2c5870684 100755
--- a/git-revert.sh
+++ b/git-revert.sh
@@ -93,6 +93,7 @@ revert)
cherry-pick)
pick_author_script='
/^author /{
+ s/'\''/'\''\\'\'\''/g
h
s/^author \([^<]*\) <[^>]*> .*$/\1/
s/'\''/'\''\'\'\''/g
diff --git a/ls-files.c b/ls-files.c
index b29fe1be7..6af3b091b 100644
--- a/ls-files.c
+++ b/ls-files.c
@@ -209,7 +209,7 @@ static int excluded(const char *pathname)
struct nond_on_fs {
int len;
- char name[0];
+ char name[FLEX_ARRAY]; /* more */
};
static struct nond_on_fs **dir;
diff --git a/mailsplit.c b/mailsplit.c
index eb58b1ebe..14c135873 100644
--- a/mailsplit.c
+++ b/mailsplit.c
@@ -169,8 +169,11 @@ int main(int argc, const char **argv)
if ( !f )
die ("cannot open mbox %s", file);
- if (fgets(buf, sizeof(buf), f) == NULL)
+ if (fgets(buf, sizeof(buf), f) == NULL) {
+ if (f == stdin)
+ break; /* empty stdin is OK */
die("cannot read mbox %s", file);
+ }
while (!file_done) {
sprintf(name, "%s/%0*d", dir, nr_prec, ++nr);
diff --git a/object.c b/object.c
index cf5931a94..1577f7428 100644
--- a/object.c
+++ b/object.c
@@ -1,8 +1,8 @@
+#include "cache.h"
#include "object.h"
#include "blob.h"
#include "tree.h"
#include "commit.h"
-#include "cache.h"
#include "tag.h"
struct object **objs;
diff --git a/object.h b/object.h
index 336d986b5..0e7618283 100644
--- a/object.h
+++ b/object.h
@@ -9,7 +9,7 @@ struct object_list {
struct object_refs {
unsigned count;
- struct object *ref[0];
+ struct object *ref[FLEX_ARRAY]; /* more */
};
struct object {
diff --git a/receive-pack.c b/receive-pack.c
index e79de917b..f847ec2b5 100644
--- a/receive-pack.c
+++ b/receive-pack.c
@@ -37,7 +37,7 @@ struct command {
const char *error_string;
unsigned char old_sha1[20];
unsigned char new_sha1[20];
- char ref_name[0];
+ char ref_name[FLEX_ARRAY]; /* more */
};
static struct command *commands = NULL;
diff --git a/t/t2001-checkout-cache-clash.sh b/t/t2001-checkout-cache-clash.sh
index b1c5263a9..0dcab8f1d 100755
--- a/t/t2001-checkout-cache-clash.sh
+++ b/t/t2001-checkout-cache-clash.sh
@@ -74,7 +74,7 @@ test_debug 'show_files $tree3'
test_expect_success \
'read previously written tree and checkout.' \
'git-read-tree $tree2 && git-checkout-index -f -a'
-test_debug show_files $tree2
+test_debug 'show_files $tree2'
test_expect_success \
'checking out conflicting path with -f' \
diff --git a/tag.c b/tag.c
index 61ac434d6..ac0e57398 100644
--- a/tag.c
+++ b/tag.c
@@ -1,5 +1,5 @@
-#include "tag.h"
#include "cache.h"
+#include "tag.h"
const char *tag_type = "tag";
diff --git a/tar-tree.c b/tar-tree.c
index 96bd1438d..f749d4b86 100644
--- a/tar-tree.c
+++ b/tar-tree.c
@@ -433,7 +433,7 @@ int main(int argc, char **argv)
archive_time = time(NULL);
if (basedir)
write_header((unsigned char *)"0", TYPEFLAG_DIR, NULL, NULL,
- basedir, 040755, NULL, 0);
+ basedir, 040777, NULL, 0);
traverse_tree(buffer, size, NULL);
free(buffer);
write_trailer();
diff --git a/tree.c b/tree.c
index e7a7b7190..dc1c41e93 100644
--- a/tree.c
+++ b/tree.c
@@ -1,8 +1,8 @@
+#include "cache.h"
#include "tree.h"
#include "blob.h"
#include "commit.h"
#include "tag.h"
-#include "cache.h"
#include <stdlib.h>
const char *tree_type = "tree";
diff --git a/unpack-objects.c b/unpack-objects.c
index 5c5cb12f6..4b5b5cb3e 100644
--- a/unpack-objects.c
+++ b/unpack-objects.c
@@ -269,6 +269,8 @@ int main(int argc, char **argv)
setup_git_directory();
+ quiet = !isatty(2);
+
for (i = 1 ; i < argc; i++) {
const char *arg = argv[i];