I define my project version number in a plain text file instead of configure.ac for some reasons. I would like to create a statement that would read the version number and s
Try:
AC_INIT([my program], m4_esyscmd([tr -d '\n' < VERSION]))
Edited with fixes suggested in the comments.
I was also able to remove the non-portable tr invocation using:
AC_INIT([my program], [m4_translit(m4_esyscmd([cat VERSION]),m4_newline)])
which seems to work just as well, as does the solution suggested by Enrico in the comments below:
AC_INIT([my program], [m4_esyscmd_s([cat VERSION])])