aboutsummaryrefslogtreecommitdiff
path: root/config.mak.in
Commit message (Collapse)AuthorAge
* Merge branch 'jc/remove-export-from-config-mak-in'Junio C Hamano2013-04-01
|\ | | | | | | | | | | | | | | | | | | | | Stop exporting mandir that used to be exported only when config.mak.autogen was used. It would have broken installation of manpages (but not other documentation formats). * jc/remove-export-from-config-mak-in: Fix `make install` when configured with autoconf Makefile: do not export mandir/htmldir/infodir config.mak.in: remove unused definitions
| * Fix `make install` when configured with autoconfKirill Smelkov2013-03-05
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Commit d8cf908c (config.mak.in: remove unused definitions) removed exec_prefix = @exec_prefix@ from config.mak.in, because nobody directly used ${exec_prefix}, but overlooked that other autoconf definitions could indirectly expand that variable. For example the following snippet from config.mak.in prefix = @prefix@ bindir = @bindir@ gitexecdir = @libexecdir@/git-core datarootdir = @datarootdir@ template_dir = @datadir@/git-core/templates sysconfdir = @sysconfdir@ is expanded to prefix = /home/kirr/local/git bindir = ${exec_prefix}/bin <-- HERE gitexecdir = ${exec_prefix}/libexec/git-core <-- datarootdir = ${prefix}/share template_dir = ${datarootdir}/git-core/templates sysconfdir = ${prefix}/etc on my system, after `configure --prefix=$HOME/local/git` and withot exec_prefix being defined there I get an error on install: install -d -m 755 '/bin' install -d -m 755 '/libexec/git-core' install: cannot create directory `/libexec': Permission denied Makefile:2292: recipe for target `install' failed Fix it. Signed-off-by: Kirill Smelkov <kirr@mns.spb.ru> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * config.mak.in: remove unused definitionsJunio C Hamano2013-02-03
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When 5566771 (autoconf: Use autoconf to write installation directories to config.mak.autogen, 2006-07-03) introduced support for autoconf generated config.mak file, it added an "export" for a few common makefile variables, in addition to definitions of srcdir and VPATH. The "export" logically does not belong there. The make variables like mandir, prefix, etc, should be exported to submakes for people who use config.mak and people who use config.mak.autogen the same way; if we want to get these exported, that should be in the main Makefile. We do use mandir and htmldir in Documentation/Makefile, so let's add export for them in the main Makefile instead. We may eventually want to support VPATH, and srcdir may turn out to be useful for that purpose, but right now nobody uses it, so it is useless to define them in this file. Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | Merge branch 'ct/autoconf-htmldir'Junio C Hamano2013-02-25
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | An earlier change to config.mak.autogen broke a build driven by the ./configure script when --htmldir is not specified on the command line of ./configure. * ct/autoconf-htmldir: Bugfix: undefined htmldir in config.mak.autogen
| * | Bugfix: undefined htmldir in config.mak.autogenJiang Xin2013-02-19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Html documents will be installed to root dir (/) no matter what prefix is set, if run these commands before `make` and `make install-html`: $ make configure $ ./configure --prefix=<PREFIX> After the installation, all the html documents will copy to rootdir (/), and: $ git --html-path <PREFIX> $ git help -w something fatal: '<PREFIX>': not a documentation directory. This is because the variable "htmldir" points to a undefined variable "$(docdir)" in file "config.mak.autogen", which is generated by running `./configure`. By default $(docdir) generated by configure is supposed be set this way: datarootdir='${prefix}/share' htmldir='${docdir}' docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' but since fc1c5415d69d (Honor configure's htmldir switch, 2013-02-02), we only set and export htmldir without doing so for PACKAGE_TARNAME (which is set to 'git' by the configure script). Add the required two variables "PACKAGE_TARNAME" and "docdir" to file "config.mak.in" will work this issue around. Signed-off-by: Jiang Xin <worldhello.net@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | Merge branch 'ct/autoconf-htmldir'Junio C Hamano2013-02-08
|\ \ \ | |/ / | | | | | | | | | | | | | | | | | | The autoconf subsystem passed --mandir down to generated config.mak.autogen but forgot to do the same for --htmldir. * ct/autoconf-htmldir: Honor configure's htmldir switch
| * | Honor configure's htmldir switchChristoph J. Thompson2013-02-02
| |/ | | | | | | | | | | | | | | Honor autoconf's --htmldir switch. This allows relocating HTML docs straight from the configure script. Signed-off-by: Christoph J. Thompson <cjsthompson@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | Makefile: whitespace style fixes in macro definitionsStefano Lattarini2012-12-10
| | | | | | | | | | | | | | | | | | Consistently use a single space before and after the "=" (or ":=", "+=", etc.) in assignments to make macros. Granted, this was not a big deal, but I did find the needless inconsistency quite distracting. Signed-off-by: Stefano Lattarini <stefano.lattarini@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | build: don't duplicate substitution of make variablesStefano Lattarini2012-09-11
|/ | | | | | | | | | | | | | | Thanks to our 'GIT_CONF_SUBST' layer in configure.ac, a make variable 'VAR' can be defined to a value 'VAL' at ./configure runtime in our build system simply by using "GIT_CONF_SUBST([VAR], [VAL])" in configure.ac, rather than having both to call "AC_SUBST([VAR], [VAL])" in configure.ac and adding the 'VAR = @VAR@' definition in config.mak.in. Less duplication, less margin for error, less possibility of confusion. While at it, fix some formatting issues in configure.ac that unnecessarily obscured the code flow. Signed-off-by: Stefano Lattarini <stefano.lattarini@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* docs: drop asciidoc7compatible flagJeff King2012-05-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When we made the switch to supporting asciidoc 8 in 4c7100a (Documentation: adjust to AsciiDoc 8, 2007-06-14), we were able to leave most of the documentation intact by defining asciidoc7compatible. Since commit 6cf378f (docs: stop using asciidoc no-inline-literal, 2012-04-26), we don't support versions of asciidoc older than 8.4.1, which is when inline literals were introduced. Therefore there is not much point in keeping our documentation compatible with asciidoc 7. So we are now free to drop the asciidoc7compatible flag and update the documentation itself to assume asciidoc8. Fortunately, doing the latter is very easy; we weren't using any of the constructs impacted by asciidoc7compatible, so there are no changes to make. The reason is somewhat subtle. The asciidoc7compatible affects only super/sub-scripts ("^" and "~") and index terms. We don't use the latter at all. Nor we do we use the former, but we did have to protect them from accidental expansion in constructs like "rev^1". However, all of our uses of "~" and "^" are either in code blocks (which are rendered literally), or inside backticks. Prior to 6cf378f, backticks were not inline literals, and needed proper quoting. But post-6cf378f, we don't have to worry whether we are using the old or new rules, as those characters are not interpreted at all in either case. I verified that the result of "make install-html install-man" is identical before and after this patch on asciidoc 8.6.7. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* Makefile: introduce CHARSET_LIB to link with -lcharsetДилян Палаузов2012-02-13
| | | | | | | | | | | | On some systems, the function locale_charset() may not be exported from libiconv but is available from libcharset, and we need -lcharset when linking. Introduce a make variable CHARSET_LIB that can be set to -lcharsetlib on such systems. Also autodetect this in the configure script by first looking for the symbol in libiconv, and then libcharset. Signed-off-by: Дилян Палаузов <dilyan.palauzov@aegee.org>
* i18n: add infrastructure for translating Git with gettextÆvar Arnfjörð Bjarmason2011-12-05
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change the skeleton implementation of i18n in Git to one that can show localized strings to users for our C, Shell and Perl programs using either GNU libintl or the Solaris gettext implementation. This new internationalization support is enabled by default. If gettext isn't available, or if Git is compiled with NO_GETTEXT=YesPlease, Git falls back on its current behavior of showing interface messages in English. When using the autoconf script we'll auto-detect if the gettext libraries are installed and act appropriately. This change is somewhat large because as well as adding a C, Shell and Perl i18n interface we're adding a lot of tests for them, and for those tests to work we need a skeleton PO file to actually test translations. A minimal Icelandic translation is included for this purpose. Icelandic includes multi-byte characters which makes it easy to test various edge cases, and it's a language I happen to understand. The rest of the commit message goes into detail about various sub-parts of this commit. = Installation Gettext .mo files will be installed and looked for in the standard $(prefix)/share/locale path. GIT_TEXTDOMAINDIR can also be set to override that, but that's only intended to be used to test Git itself. = Perl Perl code that's to be localized should use the new Git::I18n module. It imports a __ function into the caller's package by default. Instead of using the high level Locale::TextDomain interface I've opted to use the low-level (equivalent to the C interface) Locale::Messages module, which Locale::TextDomain itself uses. Locale::TextDomain does a lot of redundant work we don't need, and some of it would potentially introduce bugs. It tries to set the $TEXTDOMAIN based on package of the caller, and has its own hardcoded paths where it'll search for messages. I found it easier just to completely avoid it rather than try to circumvent its behavior. In any case, this is an issue wholly internal Git::I18N. Its guts can be changed later if that's deemed necessary. See <AANLkTilYD_NyIZMyj9dHtVk-ylVBfvyxpCC7982LWnVd@mail.gmail.com> for a further elaboration on this topic. = Shell Shell code that's to be localized should use the git-sh-i18n library. It's basically just a wrapper for the system's gettext.sh. If gettext.sh isn't available we'll fall back on gettext(1) if it's available. The latter is available without the former on Solaris, which has its own non-GNU gettext implementation. We also need to emulate eval_gettext() there. If neither are present we'll use a dumb printf(1) fall-through wrapper. = About libcharset.h and langinfo.h We use libcharset to query the character set of the current locale if it's available. I.e. we'll use it instead of nl_langinfo if HAVE_LIBCHARSET_H is set. The GNU gettext manual recommends using langinfo.h's nl_langinfo(CODESET) to acquire the current character set, but on systems that have libcharset.h's locale_charset() using the latter is either saner, or the only option on those systems. GNU and Solaris have a nl_langinfo(CODESET), FreeBSD can use either, but MinGW and some others need to use libcharset.h's locale_charset() instead. =Credits This patch is based on work by Jeff Epler <jepler@unpythonic.net> who did the initial Makefile / C work, and a lot of comments from the Git mailing list, including Jonathan Nieder, Jakub Narebski, Johannes Sixt, Erik Faye-Lund, Peter Krefting, Junio C Hamano, Thomas Rast and others. [jc: squashed a small Makefile fix from Ramsay] Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Ramsay Jones <ramsay@ramsay1.demon.co.uk> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* Merge branch 'kk/maint-prefix-in-config-mak'Junio C Hamano2011-05-31
|\ | | | | | | | | * kk/maint-prefix-in-config-mak: config.mak.in: allow "configure --sysconfdir=/else/where"
| * config.mak.in: allow "configure --sysconfdir=/else/where"Junio C Hamano2011-05-27
| | | | | | | | | | | | | | | | We do allow vanilla Makefile users to say make sysconfdir=/else/where and config.mak can also be tweaked manually for the same effect. Give the same configurablity to ./configure users as well. Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | configure: Check for libpcreMichał Kiedrowicz2011-05-09
| | | | | | | | | | | | | | | | This patch adds checks for libpcre to configure. By default libpcre is disabled, --with-libpcre enables it (if it works). Signed-off-by: Michał Kiedrowicz <michal.kiedrowicz@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | unbreak and eliminate NO_C99_FORMATJonathan Nieder2011-03-17
|/ | | | | | | | | | | | | | | | | | 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>
* Merge branch 'jk/asciidoc-update'Junio C Hamano2010-12-12
|\ | | | | | | | | * jk/asciidoc-update: docs: default to more modern toolset
| * docs: default to more modern toolsetJeff King2010-11-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | When the ASCIIDOC8 and ASCIIDOC_NO_ROFF knobs were built, many people were still on asciidoc 7 and using older versions of docbook-xsl. These days, even the almost 2-year-old Debian stable needs these knobs turned. So let's turn them by default. The new knobs ASCIIDOC7 and ASCIIDOC_ROFF can be used to get the old behavior if people are on older systems. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | Merge branch 'jj/icase-directory'Junio C Hamano2010-12-03
|\ \ | |/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * jj/icase-directory: Support case folding in git fast-import when core.ignorecase=true Support case folding for git add when core.ignorecase=true Add case insensitivity support when using git ls-files Add case insensitivity support for directories when using git status Case insensitivity support for .gitignore via core.ignorecase Add string comparison functions that respect the ignore_case variable. Makefile & configure: add a NO_FNMATCH_CASEFOLD flag Makefile & configure: add a NO_FNMATCH flag Conflicts: Makefile config.mak.in configure.ac fast-import.c
| * Makefile & configure: add a NO_FNMATCH_CASEFOLD flagÆvar Arnfjörð Bjarmason2010-10-06
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On some platforms (like Solaris) there is a fnmatch, but it doesn't support the GNU FNM_CASEFOLD extension that's used by the jj/icase-directory series' fnmatch_icase wrapper. Change the Makefile so that it's now possible to set NO_FNMATCH_CASEFOLD=YesPlease on those systems, and add a configure probe for it. Unlike the NO_REGEX check we don't add AC_INCLUDES_DEFAULT to our headers. This is because on a GNU system the definition of FNM_CASEFOLD in fnmatch.h is guarded by: #if !defined _POSIX_C_SOURCE || _POSIX_C_SOURCE < 2 || defined _GNU_SOURCE One of the headers AC_INCLUDES_DEFAULT includes ends up defining one of those, so if we'd use it we'd always get NO_FNMATCH_CASEFOLD=YesPlease on GNU systems, even though they have FNM_CASEFOLD. When checking the flags we use: ifdef NO_FNMATCH ... else ifdef NO_FNMATCH_CASEFOLD ... endif endif The "else" so that we don't link against compat/fnmatch/fnmatch.o twice if both NO_FNMATCH and NO_FNMATCH_CASEFOLD are defined. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * Makefile & configure: add a NO_FNMATCH flagÆvar Arnfjörð Bjarmason2010-10-06
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Windows and MinGW both lack fnmatch() in their C library and needed compat/fnmatch, but they had duplicate code for adding the compat function, and there was no Makefile flag or configure check for fnmatch. Change the Makefile it so that it's now possible to compile the compat function with a NO_FNMATCH=YesPlease flag, and add a configure probe for it. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | Merge branch 'ab/compat-regex'Junio C Hamano2010-09-03
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * ab/compat-regex: Fix compat/regex ANSIfication on MinGW autoconf: regex library detection typofix autoconf: don't use platform regex if it lacks REG_STARTEND t/t7008-grep-binary.sh: un-TODO a test that needs REG_STARTEND compat/regex: get rid of old-style definition compat/regex: define out variables only used under RE_ENABLE_I18N Change regerror() declaration from K&R style to ANSI C (C89) compat/regex: get the gawk regex engine to compile within git compat/regex: use the regex engine from gawk for compat Conflicts: compat/regex/regex.c
| * | autoconf: don't use platform regex if it lacks REG_STARTENDJonathan Nieder2010-08-19
| |/ | | | | | | | | | | | | | | | | | | | | If the platform regex cannot match null bytes, we might as well use the glibc version instead. Cc: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Cc: René Scharfe <rene.scharfe@lsrfire.ath.cx> Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Tested-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | compat: add strtok_r()Jonathan Nieder2010-08-14
|/ | | | | | | | | | | | | Windows does not have strtok_r (and while it does have an identical strtok_s, but it is not obvious how to use it). Grab an implementation from glibc. The svn-fe tool uses strtok_r to parse paths. Acked-by: Johannes Sixt <j6t@kdbg.org> Helped-by: Jakub Narebski <jnareb@gmail.com> Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* Merge branch 'gv/portable'Junio C Hamano2010-06-21
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * gv/portable: test-lib: use DIFF definition from GIT-BUILD-OPTIONS build: propagate $DIFF to scripts Makefile: Tru64 portability fix Makefile: HP-UX 10.20 portability fixes Makefile: HPUX11 portability fixes Makefile: SunOS 5.6 portability fix inline declaration does not work on AIX Allow disabling "inline" Some platforms lack socklen_t type Make NO_{INET_NTOP,INET_PTON} configured independently Makefile: some platforms do not have hstrerror anywhere git-compat-util.h: some platforms with mmap() lack MAP_FAILED definition test_cmp: do not use "diff -u" on platforms that lack one fixup: do not unconditionally disable "diff -u" tests: use "test_cmp", not "diff", when verifying the result Do not use "diff" found on PATH while building and installing enums: omit trailing comma for portability Makefile: -lpthread may still be necessary when libc has only pthread stubs Rewrite dynamic structure initializations to runtime assignment Makefile: pass CPPFLAGS through to fllow customization Conflicts: Makefile wt-status.h
| * Allow disabling "inline"Gary V. Vaughan2010-05-31
| | | | | | | | | | | | | | | | | | | | Compiler support for inline is sometimes buggy, and occasionally missing entirely. This patch adds a test for inline support, and redefines the keyword with the preprocessor if necessary at compile time. Signed-off-by: Gary V. Vaughan <gary@thewrittenword.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * Some platforms lack socklen_t typeGary V. Vaughan2010-05-31
| | | | | | | | | | | | | | Some platforms do not have a socklen_t type declaration. Signed-off-by: Gary V. Vaughan <gary@thewrittenword.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * Make NO_{INET_NTOP,INET_PTON} configured independentlyGary V. Vaughan2010-05-31
| | | | | | | | | | | | | | | | | | Being careful not to overwrite the results of testing for hstrerror in libresolv, also test whether inet_ntop/inet_pton are available from that library. Signed-off-by: Gary V. Vaughan <gary@thewrittenword.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * Makefile: some platforms do not have hstrerror anywhereGary V. Vaughan2010-05-31
| | | | | | | | | | | | | | | | | | This patch improves the logic of the test for hstrerror, not to blindly assume that if there is no hstrerror in libc that it must exist in libresolv. Signed-off-by: Gary V. Vaughan <gary@thewrittenword.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * Do not use "diff" found on PATH while building and installingGary V. Vaughan2010-05-31
| | | | | | | | | | | | | | | | Some of the flags used with the first diff found in PATH cause the vendor diff to choke. Signed-off-by: Gary V. Vaughan <gary@thewrittenword.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * Makefile: -lpthread may still be necessary when libc has only pthread stubsGary V. Vaughan2010-05-31
| | | | | | | | | | | | | | | | | | | | | | | | | | Without this patch, systems that provide stubs for pthread functions in libc, but which still require libpthread for full the pthread implementation are not detected correctly. Also, some systems require -pthread in CFLAGS for each compilation unit for a successful link of an mt binary, which is also addressed by this patch. Signed-off-by: Gary V. Vaughan <gary@thewrittenword.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * Makefile: pass CPPFLAGS through to fllow customizationGary V. Vaughan2010-05-31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Without this patch there is no straight forward way to pass additional CPPFLAGS at configure-time. At TWW, everything non-vendor package is installed to its own subdirectory, so we need the following to show the preprocessor where the headers for the libraries we will link later can be found: $SHELL ./configure \ CPPFLAGS="-I${SB_VAR_CURL_INC}\ -I${SB_VAR_LIBEXPAT_INC}\ -I${SB_VAR_LIBZ_INC}\ ${CPPFLAGS+ $CPPFLAGS}" <<...>> Signed-off-by: Gary V. Vaughan <gary@thewrittenword.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | autoconf: Check if <paths.h> exists and set HAVE_PATHS_HJakub Narebski2010-04-15
|/ | | | | Signed-off-by: Jakub Narebski <jnareb@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* Make NO_PTHREADS the sole thread configuration variableDan McGee2010-01-31
| | | | | | | | | | | When the first piece of threaded code was introduced in commit 8ecce684, it came with its own THREADED_DELTA_SEARCH Makefile option. Since this time, more threaded code has come into the codebase and a NO_PTHREADS option has also been added. Get rid of the original option as the newer, more generic option covers everything we need. Signed-off-by: Dan McGee <dpmcgee@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* configure.ac: rework/fix the NEEDS_RESOLV and NEEDS_LIBGEN testsBrandon Casey2009-07-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | The "action" parameters for these two tests were supplied incorrectly for the way the tests were implemented. The tests check whether a program which calls hstrerror() or basename() successfully links when -lresolv or -lgen are used, respectively. A successful linking would result in NEEDS_RESOLV or NEEDS_LIBGEN being unset, and failure would result in setting the respective variable. Aside from that issue, the tests did not handle the case where neither library was necessary for accessing the functions in question. So solve both of these issues by re-working the two tests so that their form is like the NEEDS_SOCKET test which attempts to link with just the c library, and if it fails then assumes that the additional library is necessary and sets the appropriate variable. Also an entry in the config.mak.in file is necessary for the NEEDS_LIBGEN variable to appear in the config.mak.autogen file with the value assigned by the configure script. Without it, the generated shell script would contain a snippet like this: for ac_lib in ; do ... which is incorrect. Signed-off-by: Brandon Casey <drafnel@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* Merge branch 'bc/solaris'Junio C Hamano2009-06-13
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * bc/solaris: configure: test whether -lresolv is needed Makefile: insert SANE_TOOL_PATH to PATH before /bin or /usr/bin git-compat-util.h: avoid using c99 flex array feature with Sun compiler 5.8 Makefile: add section for SunOS 5.7 Makefile: introduce SANE_TOOL_PATH for prepending required elements to PATH Makefile: define __sun__ on SunOS git-compat-util.h: tweak the way _XOPEN_SOURCE is set on Solaris On Solaris choose the OLD_ICONV iconv() declaration based on the UNIX spec Makefile: add NEEDS_RESOLV to optionally add -lresolv to compile arguments Makefile: use /usr/ucb/install on SunOS platforms rather than ginstall Conflicts: Makefile
| * configure: test whether -lresolv is neededRalf Wildenhues2009-06-10
| | | | | | | | | | | | | | | | Check if -lresolv is needed for hstrerror; set NEEDS_RESOLV accordingly, and substitute in config.mak.in. Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | compat: add a basename() compatibility functionDavid Aguilar2009-05-31
| | | | | | | | | | | | | | | | | | | | | | Some systems such as Windows lack libgen.h so provide a basename() implementation for cross-platform use. This introduces the NO_LIBGEN_H construct to the Makefile and autoconf scripts. Signed-off-by: David Aguilar <davvid@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | compat: add a mkstemps() compatibility functionDavid Aguilar2009-05-31
|/ | | | | | | | | mkstemps() is a BSD extension so provide an implementation for cross-platform use. Signed-off-by: David Aguilar <davvid@gmail.com> Tested-by: Johannes Sixt <j6t@kdbg.org> (Windows) Signed-off-by: Junio C Hamano <gitster@pobox.com>
* config.mak.in: define paths without trailing slashPascal Obry2009-02-05
| | | | | | | | The main Makefile defines gitexecdir and template_dir without trailing slash. config.mak.in should do the same to be consistent. Signed-off-by: Pascal Obry <pascal@obry.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* autoconf: Enable threaded delta search when pthreads are supportedDavid M. Syzdek2008-12-02
| | | | | | | | Automatically set THREADED_DELTA_SEARCH when autoconf test detects support for pthreads on the platform. This will change the default for some platforms that did not enable threaded delta search previously. Signed-off-by: Junio C Hamano <gitster@pobox.com>
* Makefile: introduce NO_PTHREADSJunio C Hamano2008-12-02
| | | | | | | | | | | | | This introduces make variable NO_PTHREADS for platforms that lack the support for pthreads library or people who do not want to use it for whatever reason. When defined, it makes the multi-threaded index preloading into a no-op, and also disables threaded delta searching by pack-objects. Signed-off-by: Junio C Hamano <gitster@pobox.com> Signed-off-by: Mike Ralphson <mike@abacus.co.uk> Tested-by: Johannes Sixt <j6t@kdbg.org> (AIX 4.3.x) Signed-off-by: Junio C Hamano <gitster@pobox.com>
* Add autoconf tests for pthreadsDavid M. Syzdek2008-11-09
| | | | | | | | Set the value of PTHREAD_LIBS to the correct flags for linking pthreads on the current environment. Signed-off-by: David M. Syzdek <david.syzdek@acsalaska.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* Build: add NO_UINTMAX_T to support ancient systemsDavid M. Syzdek2008-11-02
| | | | | | | | This adds NO_UINTMAX_T for ancient systems, such as FreeBSD 4.9-SECURITY. If NO_UINTMAX_T is defined, then uintmax_t is defined as uint32_t. Signed-off-by: David M. Syzdek <david.syzdek@acsalaska.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* Merge branch 'jc/cc-ld-dynpath'Junio C Hamano2008-09-07
|\ | | | | | | | | | | | | | | | | | | * jc/cc-ld-dynpath: configure: auto detect dynamic library path switches Makefile: Allow CC_LD_DYNPATH to be overriden Conflicts: Makefile config.mak.in
| * configure: auto detect dynamic library path switchesGiovanni Funchal2008-08-17
| | | | | | | | | | | | | | | | | | | | | | | | Most systems (e.g. Linux gcc) use "-Wl,-rpath," to pass to the linker the runtime dynamic library paths. Some other systems (e.g. Sun, some BSD) use "-R" etc. This patch adds tests in configure for the three most common switches (to my best knowledge) which should cover all current platforms where Git is used. Signed-Off-By: Giovanni Funchal <gafunchal@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | config.mak.in: Pass on LDFLAGS from configureNeil Roberts2008-08-21
|/ | | | | | | | | | The configure script allows you to specify flags to pass to the linker step in the LDFLAGS environment variable but this was being ignored in the Makefile. Now a make variable gets set to the value passed down from the configure script. Signed-off-by: Neil Roberts <bpeeluk@yahoo.co.uk> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* Move all dashed-form commands to libexecdirNguyễn Thái Ngọc Duy2008-06-19
| | | | | Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* autoconf: Test FREAD_READS_DIRECTORIESMichal Rokos2008-03-11
| | | | | | | | | | | | | | | | | | | Add test for FREAD_READS_DIRECTORIES to detect when fread() reads fopen'ed directory. Tested on these platforms: AIX 5.3 - FREAD_READS_DIRECTORIES=UnfortunatelyYes HP-UX B.11.11 - FREAD_READS_DIRECTORIES=UnfortunatelyYes HP-UX B.11.23 - FREAD_READS_DIRECTORIES=UnfortunatelyYes Linux 2.6.25-rc4 - FREAD_READS_DIRECTORIES= Tru64 V5.1 - FREAD_READS_DIRECTORIES=UnfortunatelyYes Windows - FREAD_READS_DIRECTORIES= Signed-off-by: Michal Rokos <michal.rokos@nextsoft.cz> Tested-by: Mike Ralphson <mike@abacus.co.uk> Tested-by: Johannes Schindelin <Johannes.Schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* Add compat/snprintf.c for systems that return bogusMichal Rokos2008-03-05
| | | | | | | | | | | | | Some systems (namely HPUX and Windows) return -1 when maxsize in snprintf() and in vsnprintf() is reached. So replace snprintf() and vsnprintf() functions with our own ones that return correct value upon overflow. [jc: verified that review comments by J6t have been incorporated, and tightened the check to verify the resulting buffer contents, suggested by Wayne Davison] Signed-off-by: Michal Rokos <michal.rokos@nextsoft.cz> Signed-off-by: Junio C Hamano <gitster@pobox.com>