[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: MinGw port of gawkextlib
From: |
Andrew J. Schorr |
Subject: |
Re: MinGw port of gawkextlib |
Date: |
Tue, 17 May 2022 12:41:22 -0400 |
User-agent: |
Mutt/1.5.21 (2010-09-15) |
On Tue, May 17, 2022 at 09:00:30AM -0600, arnold@skeeve.com wrote:
> Eli Zaretskii <eliz@gnu.org> wrote:
>
> > If this means you prefer a separate configure-time option for this
> > MinGW-specific issue, I'm okay with that.
>
> I've only been skimming these discussions, but this looks like the right
> solution to me...
I think the simplest solution is to keep the existing configure option
and add 2 more: --with-gawk-include-dir=DIR that tells us where to find
gawkapi.h and --with-gawk-program=PATH. Does that cover all of our bases?
diff --git a/shared/gawkext.m4 b/shared/gawkext.m4
index 336981f..1a1ede7 100644
--- a/shared/gawkext.m4
+++ b/shared/gawkext.m4
@@ -17,7 +17,7 @@ fi
AC_SUBST([GAWKPROG],"gawk${EXEEXT}")
AC_ARG_WITH(gawk,
- [AS_HELP_STRING([--with-gawk=DIR],[Use gawk in DIR])],
+ [AS_HELP_STRING([--with-gawk=DIR],[Use gawk in DIR, e.g. /usr or
/usr/local])],
[
if test -d "$withval/lib"; then
LDFLAGS="-L${withval}/lib ${LDFLAGS}"
@@ -39,10 +39,24 @@ AC_ARG_WITH(gawk,
]
)
+AC_ARG_WITH(gawk-include-dir,
+ [AS_HELP_STRING([--with-gawk-include-dir=DIR],[Find gawkapi.h in DIR,
e.g. /usr/include or /usr/local/include])],
+ [
+ CPPFLAGS="-I${withval} ${CPPFLAGS}"
+ ]
+)
+
+AC_ARG_WITH(gawk-program,
+ [AS_HELP_STRING([--with-gawk-program=PATH],[Use gawk program binary in
PATH, /usr/bin/gawk])],
+ [
+ AC_SUBST([GAWKPROG],"$withval")
+ ]
+)
+
AC_CHECK_HEADERS(gawkapi.h unistd.h stdlib.h string.h libintl.h)
if test x"$ac_cv_header_gawkapi_h" = x"no" ; then
- AC_MSG_ERROR([Cannot find gawkapi.h. Please use --with-gawk to supply
a location for your gawk build.])
+ AC_MSG_ERROR([Cannot find gawkapi.h. Please use --with-gawk or
--with-gawk-include-dir to supply a location for your gawk build.])
fi
AC_C_INLINE
With this patch in place, the "./configure --help" now says:
--with-gawk=DIR Use gawk in DIR, e.g. /usr or /usr/local
--with-gawk-include-dir=DIR
Find gawkapi.h in DIR, e.g. /usr/include or
/usr/local/include
--with-gawk-program=PATH
Use gawk program binary in PATH, /usr/bin/gawk
Is everyone now happy?
But I think this is serious overkill. Nobody has ever complained about any
of this before, most likely because nobody uses these extensions anyway.
If the front-end installation script does its job properly, then this
entire discussion will be moot. But maybe it will need to use one of
these new hooks for weird installation scenarios.
Regards,
Andy
- Re: MinGw port of gawkextlib, (continued)
- Re: MinGw port of gawkextlib, Andrew J. Schorr, 2022/05/16
- Re: MinGw port of gawkextlib, Manuel Collado, 2022/05/17
- Re: MinGw port of gawkextlib, Eli Zaretskii, 2022/05/17
- Re: MinGw port of gawkextlib, Andrew J. Schorr, 2022/05/17
- Re: MinGw port of gawkextlib, Eli Zaretskii, 2022/05/17
- Re: MinGw port of gawkextlib, Andrew J. Schorr, 2022/05/17
- Re: MinGw port of gawkextlib, Eli Zaretskii, 2022/05/17
- Re: MinGw port of gawkextlib, Manuel Collado, 2022/05/18
- Re: MinGw port of gawkextlib, Eli Zaretskii, 2022/05/18
- Re: MinGw port of gawkextlib, arnold, 2022/05/17
- Re: MinGw port of gawkextlib,
Andrew J. Schorr <=
- Re: MinGw port of gawkextlib, Eli Zaretskii, 2022/05/17
- Re: MinGw port of gawkextlib, Andrew J. Schorr, 2022/05/17
- Re: MinGw port of gawkextlib, Eli Zaretskii, 2022/05/17
- Re: MinGw port of gawkextlib, Andrew J. Schorr, 2022/05/17
- Re: MinGw port of gawkextlib, Eli Zaretskii, 2022/05/17
- Re: MinGw port of gawkextlib, Andrew J. Schorr, 2022/05/17
- Avoid gawkextlib as a separate shared library (was: MinGw port of gawkextlib), Manuel Collado, 2022/05/17
- Re: Avoid gawkextlib as a separate shared library (was: MinGw port of gawkextlib), Eli Zaretskii, 2022/05/17
- Re: Avoid gawkextlib as a separate shared library, Manuel Collado, 2022/05/18
- Re: Avoid gawkextlib as a separate shared library, Eli Zaretskii, 2022/05/18