m4 does not obey expansion?
I use m4 for a little text preprocessing here, and it behaves in a way I don't understand. This is the portion in question: ifdef(`TEST', define(`O_EXT', `.obj'), define(`O_EXT', `.o')) This macro will always be expanded to .o, regardless whether TEST is defined (m4 -DTEST) or not. What am I doing wrong?
You're not quoting the other arguments to ifdef. Try this: ifdef(`TEST', `define(`O_EXT', `.obj')', `define(`O_EXT', `.o')')
Name of file during compile time in Progress 4gl
Triple conditional check with ifdef in M4
How to process map data from OpenStreetMap with Java?
complex preprocessor symbol for ede project
GNU-C-preprocessing FORTRAN source to change array indices causes recursion whilst expanding macro
indirectly quoting macro in traditional mode
KMP Preprocessing Function
How to detect Apportable with preprocessor flags?
Adjust data vector to have certain variance
Pre-process Laravel 4 view
File iteration with the preprocessor
processing strings of text for neural network input
How to Set Active Target in XCode 4.5+
Preprocessor assertions in arduino
expanding a macro within a macro definition
GNU-M4: Strip empty lines