Sun 31 Mar 2013 11:33:52 AM UTC, comment #11:
Thank you.
|
Sun 31 Mar 2013 07:07:24 AM UTC, comment #10:
Even not completely portable, I've used Nelson's idea. Fixed in git, thanks.
|
Sat 30 Mar 2013 11:30:59 PM UTC, comment #9:
The other suggestion by Nelson H. F. Beebe on the TeX Live builders' mailing list was to use
(and this also works on Solaris)
|
Sat 30 Mar 2013 10:46:04 PM UTC, comment #8:
Just to make sure that it doesn't get too boring. The following fails on Solaris:
Or rather: it doesn't return anything.
The following works however:
and so does
One could do dirty tricks figuring out whether grep is "compliant", or trying to respect user's setting for $GREP (export GREP=ggrep for example), but my suggestion would be to simply split this grep statement into two separate ones. (I'm very sorry for my previous suggestion which broke functionality somewhere else.)
|
Thu 21 Mar 2013 10:09:02 PM UTC, comment #7:
Yes, it works perfect now, thank you very much.
|
Thu 21 Mar 2013 09:59:07 PM UTC, comment #6:
Ah, now I understand. Added to git, please test.
|
Thu 21 Mar 2013 08:51:55 PM UTC, comment #5:
Just a note: I'm not trying to say that I want to use "make" that is not a GNU Make. All I want to say is that numerous systems provide their own make command which might (or might not work), but in many cases there is a command "gmake" installed in addition.
So if make is not a GNU make, it make sense to test if "gmake" exists and works. This is what TeX Live does for example. Note that TeX Live will work out-of-the-box now with this patch (which has already been applied), but it would still be nice if Freetype2 could be compiled out-of-the-box (outside of TeX Live), even without explicitly setting MAKE, when gmake exists.
|
Thu 21 Mar 2013 08:46:05 PM UTC, comment #4:
The make on FreeBSD doesn't seem to be a GNU make.
However I have no clue what type/version exactly that is. I only know that FreeBSD is widespread enough and that it is definitely not the only platform where this is the case.
The same is true for Solaris
Both systems provide gmake as a command and that one is the right one and works fine.
|
Thu 21 Mar 2013 06:48:24 PM UTC, comment #3:
> Is there any chance to also check "gmake" in case
> that neither MAKE not GMAKE are defined and in case
> that "make" doesn't pass the "grep GNU" test?
Before looking more closely, I ask you for your real-world example. What `make' program do you want to use which doesn't pass the `grep GNU' test? This sounds weird.
|
Thu 21 Mar 2013 10:13:25 AM UTC, comment #2:
One more question.
The code currently does
# if GMAKE in not defined
if test "x$MAKE" = x; then
MAKE=make
fi
and later on checks for GNU make:
if test -z "`$MAKE -v 2>/dev/null | grep GNU`"; then
Is there any chance to also check "gmake" in case that neither MAKE not GMAKE are defined and in case that "make" doesn't pass the "grep GNU" test? So something like the following:
# respect GNUMAKE environment variable for backwards compatibility
if test "x$GNUMAKE" = x; then
if test "x$MAKE" = x; then
if test -z "`make -v 2>/dev/null | grep '\(GNU\|makeapp\)'`"; then
# maybe further test if gmake exists at all, so that the script doesn't end up running "-v 2>/dev/null"
MAKE=gmake
else
MAKE=make
fi
fi
else
MAKE=$GNUMAKE
fi
if test -z "`$MAKE -v 2>/dev/null | grep GNU`"; then
if test -z "`$MAKE -v 2>/dev/null | grep makepp`"; then
echo "GNU make (>= 3.80) or makepp (>= 1.19) is required to build FreeType2." >&2
echo "Please try" >&2
echo " \`MAKE=<GNU make command name> $0'." >&2
echo "or >&2"
echo " \`MAKE=\"makepp --norc-substitution\" $0'." >&2
exit 1
fi
fi
Alternatively, keep the first part as is and change the second one to something similar to:
if test -z "`$MAKE -v 2>/dev/null | grep GNU`"; then
if test -z "`$MAKE -v 2>/dev/null | grep makepp`"; then
if test -z "`gmake -v 2>/dev/null | grep 'GNU Make'`"; then
echo "GNU make (>= 3.80) or makepp (>= 1.19) is required to build FreeType2." >&2
echo "Please try" >&2
echo " \`MAKE=<GNU make command name> $0'." >&2
echo "or >&2"
echo " \`MAKE=\"makepp --norc-substitution\" $0'." >&2
exit 1
else
MAKE=gmake
fi
fi
fi
|
Thu 21 Mar 2013 08:08:48 AM UTC, comment #1:
Hello Mojca!
Funny that you are submitting a patch without a patch. The next time please do an ordinary bug report. :-)
The GNUMAKE variable seems to be an old remnant of cygwin support; at least I couldn't find any other hint in the internet.
It should be fixed now in the git repository; please test.
|
Tue 12 Mar 2013 12:10:16 PM UTC, original submission:
When I try to configure the freetype as part of a larger project, it fails with
> ./configure
GNU make (>= 3.80) or makepp (>= 1.19) is required to build FreeType2.
Please try
`GNUMAKE=<GNU make command name> ./configure'.
or >&2
`GNUMAKE="makepp --norc-substitution" ./configure'.
despite having set
export MAKE=gmake
and having a working gmake. I can fix this trivially by setting GNUMAKE=gmake, but it would be very nice if configure was able to find gmake on its own, or at least try to check if the MAKE variable has been set.
A larger project uses the following code:
MAKE=make;
if make -v 2>&1| grep "GNU Make" >/dev/null
then~
echo "Your make is a GNU-make; I will use that"
elif gmake -v >/dev/null 2>&1
then
MAKE=gmake;
export MAKE;
echo "You have a GNU-make installed as gmake; I will use that"
else
echo "I can't find a GNU-make; I'll try to use make and hope that works."~
echo "If it doesn't, please install GNU-make."
fi
it could (and probably will) export GNUMAKE in addition to MAKE to make freetype happy, but it would be a lot better if also freetype would do some checking on existence of gmake and/or MAKE. You could use some parts of the above code.
|