This is the mail archive of the
mailing list for the Cygwin project.
Re: Standard LEX variable doesn't work in Make.
- From: Hans-Bernhard Bröker <HBBroeker at t-online dot de>
- To: cygwin at cygwin dot com
- Date: Mon, 21 Nov 2016 20:09:38 +0100
- Subject: Re: Standard LEX variable doesn't work in Make.
- Authentication-results: sourceware.org; auth=none
- References: <email@example.com>
Am 21.11.2016 um 17:57 schrieb Kaz Kylheku:
I'm changing a FOSS project to rely more on standard Make
vars such as CC and CFLAGS and such: use $(CC) for
the compiler unless told otherwise, incorporate $(CFLAGS)
if it is defined, and so forth. This is friendly toward
distro package maintainers.
Not really. Package maintainers will almost universally expect your
source to have some kind of 'configure' script, which would take of this
and most other such properties for you.
Anyway, even though my Cygwin installation has GNU Flex,
the lex command is nonexistent; thus the $(LEX) Make
It's not $(LEX) that's failing here; it's the way you form expectations
about what $(LEX) is supposed to be. The value of $(LEX) is clearly
documented to default to 'lex' (see "info make implicit implicit").
If the installation has some sort of lex, the
predefined $(LEX) variable should resolve to it.
No. LEX is a modifiable variable, for the express purpose that it be
set to what the system actually needs. Yes, that means _you_ are
supposed to do that (or to set up tools outside make to do it for you).
Morale: Make is not autoconf, nor does it want to be.
One final note: your report is in no way specific to Cygwin, so this is
almost certainly the wrong mailing list to send it to.
Problem reports: http://cygwin.com/problems.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple