git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jonathan Nieder <jrnieder@gmail.com>
To: "Ævar Arnfjörð Bjarmason" <avarab@gmail.com>
Cc: Joshua Jensen <jjensen@workspacewhiz.com>,
	Johannes Sixt <j6t@kdbg.org>,
	git@vger.kernel.org
Subject: Re: [PATCH 1/6] Add string comparison functions that respect the ignore_case variable.
Date: Mon, 30 Aug 2010 10:05:13 -0500	[thread overview]
Message-ID: <20100830150513.GJ2315@burratino> (raw)
In-Reply-To: <AANLkTikbLtfx6xL6K32o_AXqY+qeqKANN5n2g0oYPoi6@mail.gmail.com>

Ævar Arnfjörð Bjarmason wrote:

> I don't think duplicating the GNU (or *BSD) version into a
> compat/fnmatch.c would be a bad thing. See e.g. compat/snprintf.c.

Maybe meanwhile someone (I guess that means "I") can ask around about
FNM_CASEFOLD going into posix.  I like to imagine the compat/
directory shrinking over time.

>> You added COMPAT_OBJS above, but I think there is no linker
>> guarantee it will pick up compat/fnmatch/fnmatch.o over the C
>> runtime version?  Perhaps the makefile is architected to do so.
>
> It's probably just an artifact of how the Solaris linker works

Isn't the portable way to do something like

 #define fnmatch gitfnmatch

in fnmatch.h?

Meanwhile I guess that no other system header includes fnmatch.h, but
if that were to happen, there would be preprocessor symbol conflicts.
So on systems with fnmatch, ideally one would want to do something
like this:

 #include <fnmatch.h>
 #ifdef FNMATCH_LACKS_CASEFOLD
 # undef FNM_PATHNAME
 # define FNM_PATHNAME	(1 << 0)
 # define FNM_CASEFOLD	(1 << 4)
 # define fnmatch gitfnmatch
 extern int fnmatch(const char *pattern, const char *name, int flags);
 #endif

  reply	other threads:[~2010-08-30 15:07 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-08-16 19:38 [PATCH 0/6] Extensions of core.ignorecase=true support Johannes Sixt
2010-08-16 19:38 ` [PATCH 1/6] Add string comparison functions that respect the ignore_case variable Johannes Sixt
2010-08-18 12:52   ` Ævar Arnfjörð Bjarmason
2010-08-18 12:53     ` Ævar Arnfjörð Bjarmason
2010-08-18 15:52       ` Joshua Jensen
2010-08-18 16:07         ` Ævar Arnfjörð Bjarmason
2010-08-18 18:32           ` Johannes Sixt
2010-08-18 18:58             ` Ævar Arnfjörð Bjarmason
2010-08-29 19:39             ` Ævar Arnfjörð Bjarmason
2010-08-30 14:42               ` Joshua Jensen
2010-08-30 14:51                 ` Ævar Arnfjörð Bjarmason
2010-08-30 15:05                   ` Jonathan Nieder [this message]
2010-08-30 14:52                 ` Jonathan Nieder
2010-08-30 18:40                 ` Johannes Sixt
2010-08-30 19:57                   ` Ævar Arnfjörð Bjarmason
2010-08-30 20:13                     ` Johannes Sixt
2010-08-16 19:38 ` [PATCH 2/6] Case insensitivity support for .gitignore via core.ignorecase Johannes Sixt
2010-08-16 19:38 ` [PATCH 3/6] Add case insensitivity support for directories when using git status Johannes Sixt
2010-08-16 19:38 ` [PATCH 4/6] Add case insensitivity support when using git ls-files Johannes Sixt
2010-08-16 19:38 ` [PATCH 5/6] Support case folding for git add when core.ignorecase=true Johannes Sixt
2010-08-16 19:38 ` [PATCH 6/6] Support case folding in git fast-import " Johannes Sixt
2010-08-17 19:36 ` [PATCH 0/6] Extensions of core.ignorecase=true support Robert Buck
2010-08-17 21:20   ` Johannes Sixt
2010-08-18  2:41     ` Robert Buck
2010-08-18 18:31       ` Johannes Sixt
2010-08-22  7:23 ` Junio C Hamano

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20100830150513.GJ2315@burratino \
    --to=jrnieder@gmail.com \
    --cc=avarab@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=j6t@kdbg.org \
    --cc=jjensen@workspacewhiz.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).