From: Junio C Hamano <hidden> Date: 2016-06-15 22:43:02
Eygene Ryabinkin [off-list ref] writes:
Or you meant something different? I am little confused with
the '$PATH' in your example. Was it intended?
Yes, the dollar-sign-in-pathname is pretty much a part of my
pathological example.
quoted
But come to think of it, it lets shell handle $PATH to find wish
anyway, so *unless* we have specific version dependency to wish
that wish binary normally found on user's $PATH is inadequate,
we probably should not even need to be doing any of this path
munging. You might end up discovering the path to wish binary
in your autoconf script, we do not have to use it. ./configure
can just see if there is wish, and set NO_TCLTK appropriately
without any of the path business.
What do you think?
There are problems at least with FreeBSD: it just installs the
wish8.4, wish8.3, wish8.2, etc. It does not provide the bare 'wish'
as the link to one of those.
Then sed -e 's/wish/$(WISH_NAME)/', still letting the shell to
handle the path part, could be a simpler option. I dunno.
Thu, Mar 29, 2007 at 01:35:55AM -0700, Junio C Hamano wrote:
Eygene Ryabinkin [off-list ref] writes:
quoted
Or you meant something different? I am little confused with
the '$PATH' in your example. Was it intended?
Yes, the dollar-sign-in-pathname is pretty much a part of my
pathological example.
Got it. So you mean that the '$' sign should be escaped as well? ;))
Or we can get another _SQ substitution to the script and the
string will look like
exec 'whatever you'\''d written here' "$0" -- "$@"
quoted
quoted
But come to think of it, it lets shell handle $PATH to find wish
anyway, so *unless* we have specific version dependency to wish
that wish binary normally found on user's $PATH is inadequate,
we probably should not even need to be doing any of this path
munging. You might end up discovering the path to wish binary
in your autoconf script, we do not have to use it. ./configure
can just see if there is wish, and set NO_TCLTK appropriately
without any of the path business.
What do you think?
There are problems at least with FreeBSD: it just installs the
wish8.4, wish8.3, wish8.2, etc. It does not provide the bare 'wish'
as the link to one of those.
Then sed -e 's/wish/$(WISH_NAME)/', still letting the shell to
handle the path part, could be a simpler option. I dunno.
Ah, you mean that './configure --with-tcltk=wish8.4' should also
do the trick? It seems to be easy to achieve by just skipping
the 'test -x' part in the configure.ac. So the semantics of
'--with-tcltk=PATH' will be:
"If you're telling me about the path to the interpreter, it is
you who should take care of it. I do not mind if you will give
me something unexecutable, unexistent and so on.". Comments?
--
Eygene
From: Tom Prince <hidden> Date: 2016-06-15 22:43:02
On Thu, Mar 29, 2007 at 12:58:35PM +0400, Eygene Ryabinkin wrote:
Ah, you mean that './configure --with-tcltk=wish8.4' should also
do the trick? It seems to be easy to achieve by just skipping
the 'test -x' part in the configure.ac. So the semantics of
'--with-tcltk=PATH' will be:
"If you're telling me about the path to the interpreter, it is
you who should take care of it. I do not mind if you will give
me something unexecutable, unexistent and so on.". Comments?
Definitely, when cross compiling, or generating packages, you often
don't even have the program installed in the right place, so erroring
out is the wrong thing to do in this case.
Tom
Tom, good day.
Thu, Mar 29, 2007 at 01:12:39PM +0400, Tom Prince wrote:
Definitely, when cross compiling, or generating packages, you often
don't even have the program installed in the right place, so erroring
out is the wrong thing to do in this case.
Do not make the checks on the Tcl/Tk interpreter passed by
'--with-tcltk=/path/to/wish' configure option: user is free to pass
anything.
Signed-off-by: Eygene Ryabinkin <redacted>
---
configure.ac | 2 --
1 files changed, 0 insertions(+), 2 deletions(-)
@@ -102,8 +102,6 @@ if test -z "$NO_TCLTK"; then elif test "$with_tcltk" = "yes"; then # Tcl/Tk check requested. AC_CHECK_PROGS(TCLTK_PATH, [wish], )- elif ! test -x "$with_tcltk"; then- AC_MSG_ERROR([Tcl/Tk interpreter was not found in $with_tcltk]) else AC_MSG_RESULT([Using Tcl/Tk interpreter $with_tcltk]) TCLTK_PATH="$with_tcltk"