GNU Autoconf, Automake, and Libtool
by Gary V. Vaughan, Ben Elliston, Tom Tromey, Ian Lance Taylor
5.5. Using Configuration Names
Although feature tests are definitely the best approach, a 'configure' script may occasionally have to make a decision based on a configuration name. This may be necessary if certain code must be compiled differently based on something that cannot be tested using a standard Autoconf feature test. For instance, the expect package needs to find information about the system's 'tty' implementation; this can't reliably be done when cross-compiling without examining the particular configuration name.
It is normally better to test for particular features rather than to test for a particular system type. This is because as Unix and other operating systems evolve, different systems copy features from one another.
When there ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access