summaryrefslogtreecommitdiff
path: root/Makefile
AgeCommit message (Collapse)AuthorFilesLines
2011-05-30Merge branch 'mk/grep-pcre'Libravatar Junio C Hamano1-0/+16
* mk/grep-pcre: git-grep: Fix problems with recently added tests git-grep: Update tests (mainly for -P) Makefile: Pass USE_LIBPCRE down in GIT-BUILD-OPTIONS git-grep: update tests now regexp type is "last one wins" git-grep: do not die upon -F/-P when grep.extendedRegexp is set. git-grep: Bail out when -P is used with -F or -E grep: Add basic tests configure: Check for libpcre git-grep: Learn PCRE grep: Extract compile_regexp_failed() from compile_regexp() grep: Fix a typo in a comment grep: Put calls to fixmatch() and regmatch() into patmatch() contrib/completion: --line-number to git grep Documentation: Add --line-number to git-grep synopsis
2011-05-29Merge branch 'jk/haves-from-alternate-odb'Libravatar Junio C Hamano1-0/+2
* jk/haves-from-alternate-odb: receive-pack: eliminate duplicate .have refs bisect: refactor sha1_array into a generic sha1 list refactor refs_from_alternate_cb to allow passing extra data
2011-05-26Merge branch 'rg/no-gecos-in-pwent'Libravatar Junio C Hamano1-0/+3
* rg/no-gecos-in-pwent: ident: add NO_GECOS_IN_PWENT for systems without pw_gecos in struct passwd Conflicts: Makefile
2011-05-23Merge branch 'ab/i18n-scripts-basic'Libravatar Junio C Hamano1-1/+7
* ab/i18n-scripts-basic: Makefile: add xgettext target for *.sh files git-sh-i18n.sh: add GIT_GETTEXT_POISON support git-sh-i18n.sh: add no-op gettext() and eval_gettext() wrappers git-sh-i18n--envsubst: our own envsubst(1) for eval_gettext()
2011-05-19bisect: refactor sha1_array into a generic sha1 listLibravatar Jeff King1-0/+2
This is a generally useful abstraction, so let's let others make use of it. The refactoring is more or less a straight copy; however, functions and struct members have had their names changed to match string_list, which is the most similar data structure. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2011-05-19Makefile: sort TEST_PROGRAMS listLibravatar Jeff King1-2/+2
We usually keep these lists in sorted order, but the last few entries were just tacked on the end. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2011-05-19ident: add NO_GECOS_IN_PWENT for systems without pw_gecos in struct passwdLibravatar Rafael Gieschke1-0/+3
Allow NO_GECOS_IN_PWENT to be defined in the Makefile for platforms that lack the pw_gecos field in their "struct passwd", in which case the uppercased user name is used instead via the standard '&' replacement mechanism. Signed-off-by: Rafael Gieschke <rafael@gieschke.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2011-05-16Merge branch 'kk/maint-prefix-in-config-mak'Libravatar Junio C Hamano1-9/+9
* kk/maint-prefix-in-config-mak: Honor $(prefix) set in config.mak* when defining ETC_GIT* Revert "Honor $(prefix) set in config.mak* when defining ETC_GIT* and sysconfdir" Honor $(prefix) set in config.mak* when defining ETC_GIT* and sysconfdir
2011-05-16Makefile: Pass USE_LIBPCRE down in GIT-BUILD-OPTIONSLibravatar Junio C Hamano1-0/+1
Otherwise we would fail to rebuild correctly when this option was changed between $(MAKE) invocations, and more importantly, $(MAKE) test would not pass it down and t/test-lib.sh would not set the LIBPCRE prerequisite. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2011-05-14Makefile: add xgettext target for *.sh filesLibravatar Ævar Arnfjörð Bjarmason1-1/+5
Change the "pot" target to also extract strings from our $(SCRIPT_SH) files with xgettext(1). Note that due to Jonathan Nieder's trick of doing "mv $@+ $@" at the end of the target the "pot" target will now warn: $ make pot XGETTEXT po/git.pot po/git.pot+: warning: Charset "CHARSET" is not a portable encoding name. Message conversion to user's charset might not work. This warnings is emitted because xgettext is writing into a non-*.pot file, it's harmless however. The content that's written out is equivalent to what it would be if we were writing directly into an existing POT file with --join-existing. As part of this change I've eliminated the && chain between xgettext calls, this is incompatible with $(QUIET_XGETTEXT), if the && is left in it'll emit: /bin/sh: @echo: not found Since it's redundant (the Makefile will stop if there's an error) I've removed it altogether. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2011-05-14git-sh-i18n.sh: add no-op gettext() and eval_gettext() wrappersLibravatar Ævar Arnfjörð Bjarmason1-0/+1
Add a no-op wrapper library for Git's shell scripts. To split up the gettext series I'm first submitting patches to gettextize the source tree before I add any of the Makefile and Shell library changes needed to actually use them. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2011-05-14git-sh-i18n--envsubst: our own envsubst(1) for eval_gettext()Libravatar Ævar Arnfjörð Bjarmason1-0/+1
Add a git-sh-i18n--envsubst program which is a stripped-down version of the GNU envsubst(1) program that comes with GNU gettext for use in the eval_gettext() fallback. We need a C helper program because implementing eval_gettext() purely in shell turned out to be unworkable. Digging through the Git mailing list archives will reveal two shell implementations of eval_gettext that are almost good enough, but fail on an edge case which is tested for in the tests which are part of this patch. These are the modifications I made to envsubst.c as I turned it into sh-i18n--envsubst.c: * Added our git-compat-util.h header for xrealloc() and friends. * Removed inclusion of gettext-specific headers. * Removed most of main() and replaced it with my own. The modified version only does option parsing for --variables. That's all it needs. * Modified error() invocations to use our error() instead of error(3). * Replaced the gettext XNMALLOC(n, size) macro with just xmalloc(n). Since XNMALLOC() only allocated char's. * Removed the string_list_destroy function. It's redundant (also in the upstream code). * Replaced the use of stdbool.h (a C99 header) by doing the following replacements on the code: * s/bool/unsigned short int/g * s/true/1/g * s/false/0/g Reported-by: Johannes Sixt <j.sixt@viscovery.net> Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2011-05-11Merge branch 'jn/gitweb-dependency'Libravatar Junio C Hamano1-27/+1
* jn/gitweb-dependency: Remove gitweb/gitweb.cgi and other legacy targets from main Makefile git-instaweb: Simplify build dependency on gitweb
2011-05-09git-grep: Learn PCRELibravatar Michał Kiedrowicz1-0/+15
This patch teaches git-grep the --perl-regexp/-P options (naming borrowed from GNU grep) in order to allow specifying PCRE regexes on the command line. PCRE has a number of features which make them more handy to use than POSIX regexes, like consistent escaping rules, extended character classes, ungreedy matching etc. git isn't build with PCRE support automatically. USE_LIBPCRE environment variable must be enabled (like `make USE_LIBPCRE=YesPlease`). Signed-off-by: Michał Kiedrowicz <michal.kiedrowicz@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2011-05-09Honor $(prefix) set in config.mak* when defining ETC_GIT*Libravatar Johannes Sixt1-9/+9
Notice that the prefix specified for the build influenced the definitions of ETC_GITCONFIG and ETC_GITATTRIBUTES only when it was exactly '/usr'. Kacper Kornet noticed that this was furthermore only the case when the build was triggered using 'make prefix=/usr', i.e., the prefix was given on the command line; it did not work when the prefix was specified in config.mak because this file is included much later in the Makefile. To fix this, move the conditional after the inclusion of config.mak. Additionally, it is desirable to specify the etc directory for a build (for example, a build with prefix /usr/local may still want to have the system configuration in /etc/gitconfig). For this purpose, promote the variable 'sysconfdir' from a helper variable to a configuration variable. The prefix check that was moved must now be wrapped so that it does not override sysconfdir setting given in config.mak. Signed-off-by: Johannes Sixt <j6t@kdbg.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2011-05-09Revert "Honor $(prefix) set in config.mak* when defining ETC_GIT* and ↵Libravatar Junio C Hamano1-10/+9
sysconfdir" This reverts commit 2910bf56a4ffc13c398fb04ba32910cb3b724091, as it does not really solve the issue of making $(sysconfigdir) any more useful than it currently is.
2011-05-08Remove gitweb/gitweb.cgi and other legacy targets from main MakefileLibravatar Jakub Narebski1-26/+0
Now that there is gitweb/Makefile, let's leave only "gitweb" and "install-gitweb" targets in main Makefile. Those targets just delegate to gitweb's Makefile. Requested-by: Junio C Hamano <gitster@pobox.com> Signed-off-by: Jakub Narebski <jnareb@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2011-05-08git-instaweb: Simplify build dependency on gitwebLibravatar Jakub Narebski1-1/+1
Since c0cb4ed (git-instaweb: Configure it to work with new gitweb structure, 2010-05-28) git-instaweb does not re-create gitweb.cgi etc., but makes use of installed gitweb. Therefore simplify git-instaweb dependency on gitweb subsystem in main Makefile from 'gitweb/gitweb.cgi gitweb/static/gitweb.css gitweb/static/gitweb.js' to simply 'gitweb'. This is preparation for splitting gitweb.perl script, and for splitting gitweb.js (to be reassembled / combined on build). This way we don't have to duplicate parts of gitweb/Makefile in main Makefile... it is also more correct description of git-instaweb dependency. Reported-by: Junio C Hamano <gitster@pobox.com> Signed-off-by: Jakub Narebski <jnareb@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2011-05-06Merge branch 'js/info-man-path'Libravatar Junio C Hamano1-1/+3
* js/info-man-path: Documentation: clarify meaning of --html-path, --man-path, and --info-path git: add --info-path and --man-path options Conflicts: Makefile
2011-05-01git: add --info-path and --man-path optionsLibravatar Jon Seymour1-1/+3
Similar to the way the --html-path option lets UI programs learn where git has its HTML documentation pages, expose the other two paths used to store the documentation pages of these two types. Signed-off-by: Jon Seymour <jon.seymour@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2011-04-28Merge branch 'mz/rebase'Libravatar Junio C Hamano1-1/+3
* mz/rebase: (34 commits) rebase: define options in OPTIONS_SPEC Makefile: do not install sourced rebase scripts rebase: use @{upstream} if no upstream specified rebase -i: remove unnecessary state rebase-root rebase -i: don't read unused variable preserve_merges git-rebase--am: remove unnecessary --3way option rebase -m: don't print exit code 2 when merge fails rebase -m: remember allow_rerere_autoupdate option rebase: remember strategy and strategy options rebase: remember verbose option rebase: extract code for writing basic state rebase: factor out sub command handling rebase: make -v a tiny bit more verbose rebase -i: align variable names rebase: show consistent conflict resolution hint rebase: extract am code to new source file rebase: extract merge code to new source file rebase: remove $branch as synonym for $orig_head rebase -i: support --stat rebase: factor out call to pre-rebase hook ...
2011-04-28Honor $(prefix) set in config.mak* when defining ETC_GIT* and sysconfdirLibravatar Kacper Kornet1-9/+10
Definitions of ETC_GITCONFIG, ETC_GITATTRIBUTES and sysconfdir depend on value of prefix. As prefix can be changed in config.mak.autogen, all if blocks with conditions based on prefix should be placed after the file is included in Makefile. Signed-off-by: Kacper Kornet <draenog@pld-linux.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2011-04-22sparse: Fix errors due to missing target-specific variablesLibravatar Ramsay Jones1-17/+28
In particular, sparse issues the following errors: attr.c:472:43: error: undefined identifier 'ETC_GITATTRIBUTES' config.c:821:43: error: undefined identifier 'ETC_GITCONFIG' exec_cmd.c:14:37: error: undefined identifier 'PREFIX' exec_cmd.c:83:28: error: undefined identifier 'GIT_EXEC_PATH' builtin/help.c:328:46: error: undefined identifier 'GIT_MAN_PATH' builtin/help.c:374:40: error: undefined identifier 'GIT_INFO_PATH' builtin/help.c:382:45: error: undefined identifier 'GIT_HTML_PATH' git.c:96:42: error: undefined identifier 'GIT_HTML_PATH' git.c:241:35: error: invalid initializer http.c:293:43: error: undefined identifier 'GIT_HTTP_USER_AGENT' which is caused by not passing the target-specific additions to the EXTRA_CPPFLAGS variable to cgcc. In order to fix the problem, we define a new sparse target which depends on a set of non-existent "sparse object" files (*.sp) which correspond to the set of C source files. In addition to the new target, we also provide a new pattern rule for "creating" the sparse object files from the source files by running cgcc. This allows us to add '*.sp' to the rules setting the target-specific EXTRA_CPPFLAGS variable, which is then included in the new pattern rule to run cgcc. Also, we change the 'check' target to re-direct the user to the new sparse target. Signed-off-by: Ramsay Jones <ramsay@ramsay1.demon.co.uk> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2011-04-11sparse: Fix an "symbol 'merge_file' not decared" warningLibravatar Ramsay Jones1-0/+1
In order to fix the warning, we add a new "merge-file.h" header containing the extern declaration of the merge_file() function, and include the header in the source files that require the declaration. Signed-off-by: Ramsay Jones <ramsay@ramsay1.demon.co.uk> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2011-04-11Makefile: Use cgcc rather than sparse in the check targetLibravatar Ramsay Jones1-5/+6
cgcc is the recommended way to run sparse, since it provides many -Defines suitable for the given gcc platform. Using an "cgcc -no-compile" command runs sparse, with all the platform specific definitions provided by cgcc, without also invoking gcc. Signed-off-by: Ramsay Jones <ramsay@ramsay1.demon.co.uk> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2011-04-11Makefile: extract Q_() source strings as ngettext()Libravatar Ævar Arnfjörð Bjarmason1-1/+2
The Q_() wrapper added by 0c9ea33 (i18n: add stub Q_() wrapper for ngettext, 2011-03-09) needs to be noticed by xgettext. Add an appropriate --keyword option to the Makefile, so that "make pot" would notice the strings in the plural form marked with the wrapper. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2011-04-01Merge branch 'sb/sparse-more'Libravatar Junio C Hamano1-1/+1
* sb/sparse-more: Makefile: Cover more files with make check
2011-03-23Merge branch 'jn/maint-c99-format'Libravatar Junio C Hamano1-14/+0
* jn/maint-c99-format: unbreak and eliminate NO_C99_FORMAT mktag: avoid %td in format string
2011-03-21Makefile: Cover more files with make checkLibravatar Stephen Boyd1-1/+1
After the builtin/ move 'make check' doesn't cover the builtin/ directory. We could just add builtin/*.c but lets just use GIT_OBJS instead so we cover future movement of the source files. Signed-off-by: Stephen Boyd <bebarino@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2011-03-20Merge branch 'mr/hpux' into maintLibravatar Junio C Hamano1-0/+1
* mr/hpux: git-compat-util.h: Honor HP C's noreturn attribute Makefile: add NO_FNMATCH_CASEFOLD to HP-UX section
2011-03-20Merge branch 'ae/better-template-failure-report' into maintLibravatar Junio C Hamano1-0/+1
* ae/better-template-failure-report: Improve error messages when temporary file creation fails
2011-03-19Merge branch 'ab/i18n-basic'Libravatar Junio C Hamano1-0/+28
* ab/i18n-basic: i18n: "make distclean" should clean up after "make pot" i18n: Makefile: "pot" target to extract messages marked for translation i18n: add stub Q_() wrapper for ngettext i18n: do not poison translations unless GIT_GETTEXT_POISON envvar is set i18n: add GETTEXT_POISON to simulate unfriendly translator i18n: add no-op _() and N_() wrappers commit, status: use status_printf{,_ln,_more} helpers commit: refer to commit template as s->fp wt-status: add helpers for printing wt-status lines Conflicts: builtin/commit.c
2011-03-17unbreak and eliminate NO_C99_FORMATLibravatar Jonathan Nieder1-14/+0
In the spirit of v1.5.0.2~21 (Check for PRIuMAX rather than NO_C99_FORMAT in fast-import.c, 2007-02-20), use PRIuMAX from git-compat-util.h on all platforms instead of C99-specific formats like %zu with dangerous fallbacks to %u or %lu. So now C99-challenged platforms can build git without provoking warnings or errors from printf, even if pointers do not have the same size as an int or long. The need for a fallback PRIuMAX is detected in git-compat-util.h with "#ifndef PRIuMAX". So while at it, simplify the Makefile and configure script by eliminating the NO_C99_FORMAT knob altogether. Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2011-03-15Merge branch 'mr/hpux'Libravatar Junio C Hamano1-0/+1
* mr/hpux: git-compat-util.h: Honor HP C's noreturn attribute Makefile: add NO_FNMATCH_CASEFOLD to HP-UX section
2011-03-09i18n: "make distclean" should clean up after "make pot"Libravatar Jonathan Nieder1-0/+1
This is in "make distclean" and not "make clean" to avoid needlessly changing the POT-Creation-Date in the following scenario: make clean; # cleaning up after an old build git pull make pot; # regenerate po template if necessary msgmerge po/my_language.po po/git.pot Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2011-03-09i18n: Makefile: "pot" target to extract messages marked for translationLibravatar Ævar Arnfjörð Bjarmason1-0/+16
Add rules to generate a template (po/git.pot) listing messages marked for translation in the C portion of git. To get started translating, just run "make pot". Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2011-03-08i18n: do not poison translations unless GIT_GETTEXT_POISON envvar is setLibravatar Jonathan Nieder1-1/+4
Tweak the GETTEXT_POISON facility so it is activated at run time instead of compile time. If the GIT_GETTEXT_POISON environment variable is set, _(msg) will result in gibberish as before; but if the GIT_GETTEXT_POISON variable is not set, it will return the message for human-readable output. So the behavior of mistranslated and untranslated git can be compared without rebuilding git in between. For simplicity we always set the GIT_GETTEXT_POISON variable in tests. This does not affect builds without the GETTEXT_POISON compile-time option set, so non-i18n git will not be slowed down. Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2011-03-08i18n: add GETTEXT_POISON to simulate unfriendly translatorLibravatar Ævar Arnfjörð Bjarmason1-0/+7
Add a new GETTEXT_POISON compile-time parameter to make _(msg) always return gibberish. So now you can run make GETTEXT_POISON=YesPlease to get a copy of git that functions correctly (one hopes) but produces output that is in nobody's native language at all. This is a debugging aid for people who are working on the i18n part of the system, to make sure that they are not marking plumbing messages that should never be translated with _(). As new strings get marked for translation, naturally a number of tests will be broken in this mode. Tests that depend on output from Porcelain will need to be marked with the new C_LOCALE_OUTPUT test prerequisite. Newly failing tests that do not depend on output from Porcelain would be bugs due to messages that should not have been marked for translation. Note that the string we're using ("# GETTEXT POISON #") intentionally starts the pound sign. Some of Git's tests such as t3404-rebase-interactive.sh rely on interactive editing with a fake editor, and will needlessly break if the message doesn't start with something the interactive editor considers a comment. A future patch will fix fix the underlying cause of that issue by adding "#" characters to the commit advice automatically. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2011-03-08i18n: add no-op _() and N_() wrappersLibravatar Ævar Arnfjörð Bjarmason1-0/+1
The _ function is for translating strings into the user's chosen language. The N_ macro just marks translatable strings for the xgettext(1) tool without translating them; it is intended for use in contexts where a function call cannot be used. So, for example: fprintf(stderr, _("Expansion of alias '%s' failed; " "'%s' is not a git command\n"), cmd, argv[0]); and const char *unpack_plumbing_errors[NB_UNPACK_TREES_ERROR_TYPES] = { /* ERROR_WOULD_OVERWRITE */ N_("Entry '%s' would be overwritten by merge. Cannot merge."), [...] Define such _ and N_ in a new gettext.h and include it in cache.h, so they can be used everywhere. Each just returns its argument for now. _ is a function rather than a macro like N_ to avoid the temptation to use _("foo") as a string literal (which would be a compile-time error once _(s) expands to an expression for the translation of s). Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2011-03-08Makefile: add NO_FNMATCH_CASEFOLD to HP-UX sectionLibravatar Michal Rokos1-0/+1
fnmatch() on HP-UX does not support the GNU FNM_CASEFOLD extension, so set NO_FNMATCH_CASEFOLD to use the internal fnmatch implementation. Signed-off-by: Michal Rokos <michal.rokos@nextsoft.cz> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2011-02-25Makefile: do not install sourced rebase scriptsLibravatar Martin von Zweigbergk1-3/+3
When git-rebase.sh recently started sourcing git-rebase--interactive.sh instead of executing it, executable bit of the latter file should have been turned off and it should have been moved from SCRIPT_SH to SCRIPT_LIB in the Makefile. Its two new siblings, git-rebase--am.sh and git-rebase--merge.sh (whose executable bits are already off) should also be moved to SCRIPT_LIB in the Makefile. Reported-by: Johannes Sixt <j6t@kdbg.org> Helped-by: Jeff King <peff@peff.net> Signed-off-by: Martin von Zweigbergk <martin.von.zweigbergk@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2011-02-10rebase: extract am code to new source fileLibravatar Martin von Zweigbergk1-0/+1
Extract the code for am-based rebase to git-rebase--am.sh. Suggested-by: Johannes Sixt <j6t@kdbg.org> Signed-off-by: Martin von Zweigbergk <martin.von.zweigbergk@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2011-02-10rebase: extract merge code to new source fileLibravatar Martin von Zweigbergk1-0/+1
Extract the code for merge-based rebase to git-rebase--merge.sh. Suggested-by: Johannes Sixt <j6t@kdbg.org> Signed-off-by: Martin von Zweigbergk <martin.von.zweigbergk@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2011-02-09Merge branch 'ae/better-template-failure-report'Libravatar Junio C Hamano1-0/+1
* ae/better-template-failure-report: Improve error messages when temporary file creation fails
2010-12-28Merge branch 'nd/setup'Libravatar Junio C Hamano1-0/+1
* nd/setup: (47 commits) setup_work_tree: adjust relative $GIT_WORK_TREE after moving cwd git.txt: correct where --work-tree path is relative to Revert "Documentation: always respect core.worktree if set" t0001: test git init when run via an alias Remove all logic from get_git_work_tree() setup: rework setup_explicit_git_dir() setup: clean up setup_discovered_git_dir() t1020-subdirectory: test alias expansion in a subdirectory setup: clean up setup_bare_git_dir() setup: limit get_git_work_tree()'s to explicit setup case only Use git_config_early() instead of git_config() during repo setup Add git_config_early() git-rev-parse.txt: clarify --git-dir t1510: setup case #31 t1510: setup case #30 t1510: setup case #29 t1510: setup case #28 t1510: setup case #27 t1510: setup case #26 t1510: setup case #25 ...
2010-12-27setup_work_tree: adjust relative $GIT_WORK_TREE after moving cwdLibravatar Nguyễn Thái Ngọc Duy1-0/+1
When setup_work_tree() is called, it moves cwd to $GIT_WORK_TREE and makes internal copy of $GIT_WORK_TREE absolute. The environt variable, if set by user, remains unchanged. If the variable is relative, it is no longer correct because its base dir has changed. Instead of making $GIT_WORK_TREE absolute too, we just say "." and let subsequent git processes handle it. Reported-by: Michel Briand <michelbriand@free.fr> Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-12-22Makefile: add NO_FNMATCH_CASEFOLD to IRIX sectionsLibravatar Brandon Casey1-0/+2
IRIX's fnmatch() does not support the GNU FNM_CASEFOLD extension, so set NO_FNMATCH_CASEFOLD so that the internal fnmatch implementation will be used. Signed-off-by: Brandon Casey <casey@nrlssc.navy.mil> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-12-21Improve error messages when temporary file creation failsLibravatar Arnout Engelen1-0/+1
Before, when creating a temporary file failed, a generic 'Unable to create temporary file' message was printed. In some cases this could lead to confusion as to which directory should be checked for correct permissions etc. This patch adds the template for the temporary filename to the error message, converting it to an absolute path if needed. A test verifies that the template is indeed printed when pointing to a nonexistent or unwritable directory. A copy of the original template is made in case mkstemp clears the template. Signed-off-by: Arnout Engelen <arnouten@bzzt.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-12-16Merge branch 'rj/msvc-fix'Libravatar Junio C Hamano1-1/+1
* rj/msvc-fix: msvc: Fix macro redefinition warnings msvc: Fix build by adding missing INTMAX_MAX define msvc: git-daemon.exe: Fix linker "unresolved externals" error msvc: Fix compilation errors in compat/win32/sys/poll.c
2010-12-14Merge branch 'maint'Libravatar Junio C Hamano1-0/+4
* maint: Prepare for 1.7.3.4 use persistent memory for rejected paths do not overwrite files in leading path lstat_cache: optionally return match_len add function check_ok_to_remove() t7607: add leading-path tests t7607: use test-lib functions and check MERGE_HEAD Do not link with -lcrypto under NO_OPENSSL Signed-off-by: Junio C Hamano <gitster@pobox.com>