From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/10594 Path: news.gmane.org!.POSTED!not-for-mail From: Rich Felker Newsgroups: gmane.comp.version-control.git,gmane.linux.lib.musl.general Subject: Re: Regression: git no longer works with musl libc's regex impl Date: Thu, 6 Oct 2016 15:25:00 -0400 Message-ID: <20161006192500.GS19318@brightrain.aerifal.cx> References: <20161004150848.GA7949@brightrain.aerifal.cx> <20161004152722.ex2nox43oj5ak4yi@sigill.intra.peff.net> <20161004154045.GT19318@brightrain.aerifal.cx> <20161006192339.3yddgxxk7jn7zfqx@sigill.intra.peff.net> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Trace: blaine.gmane.org 1475781948 26629 195.159.176.226 (6 Oct 2016 19:25:48 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Thu, 6 Oct 2016 19:25:48 +0000 (UTC) User-Agent: Mutt/1.5.21 (2010-09-15) Cc: =?utf-8?B?w4Z2YXIgQXJuZmrDtnLDsA==?= Bjarmason , Johannes Schindelin , Git , musl@lists.openwall.com To: Jeff King Original-X-From: git-owner@vger.kernel.org Thu Oct 06 21:25:34 2016 Return-path: Envelope-to: gcvg-git-2@m.gmane.org Original-Received: from vger.kernel.org ([209.132.180.67]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bsEIA-0003Pq-0X for gcvg-git-2@m.gmane.org; Thu, 06 Oct 2016 21:25:18 +0200 Original-Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S934875AbcJFTZS (ORCPT ); Thu, 6 Oct 2016 15:25:18 -0400 Original-Received: from 216-12-86-13.cv.mvl.ntelos.net ([216.12.86.13]:55618 "EHLO brightrain.aerifal.cx" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S934857AbcJFTZQ (ORCPT ); Thu, 6 Oct 2016 15:25:16 -0400 Original-Received: from dalias by brightrain.aerifal.cx with local (Exim 3.15 #2) id 1bsEHs-0004gm-00; Thu, 06 Oct 2016 19:25:00 +0000 Content-Disposition: inline In-Reply-To: <20161006192339.3yddgxxk7jn7zfqx@sigill.intra.peff.net> Original-Sender: git-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org Xref: news.gmane.org gmane.comp.version-control.git:306354 gmane.linux.lib.musl.general:10594 Archived-At: On Thu, Oct 06, 2016 at 03:23:40PM -0400, Jeff King wrote: > On Thu, Oct 06, 2016 at 09:18:29PM +0200, Ævar Arnfjörð Bjarmason wrote: > > > On Tue, Oct 4, 2016 at 6:08 PM, Johannes Schindelin > > wrote: > > > As to making NO_REGEX conditional on REG_STARTEND: you are talking about > > > apples and oranges here. NO_REGEX is a Makefile flag, while REG_STARTEND > > > is a C preprocessor macro. > > > > > > Unless you can convince the rest of the Git developers (you would not > > > convince me) to simulate autoconf by compiling an executable every time > > > `make` is run, to determine whether REG_STARTEND is defined, this is a > > > no-go. > > > > But just to clarify, does anyone have any objection to making our > > configure.ac compile a C program to check for this sort of thing? > > Because that seems like the easiest solution to this class of problem. > > No, I think that is the exact purpose of configure.ac and autoconf. > > It would be neat if we could auto-fallback during the build. Rich > suggested always compiling compat/regex.c, and just having it be a noop > at the preprocessor level. I'm not sure if that would work, though, > because we'd have to include the system "regex.h" to know if we have > REG_STARTEND, at which point it is potentially too late to compile our > own regex routines (we're potentially going to conflict with the system > declarations). If you have autoconf testing for REG_STARTEND at configure time then compat/regex.c can #include "config.h" and test for HAVE_REG_STARTEND rather than for REG_STARTEND, or something like that. Rich