To integrate LYRIC into a project that will use the library’s features with the GNU autoconf and automake tools, a set of M4 macros have been writen and put in the lyric.m4 file. This file was installed in prefix/share/aclocal.
The first step is to copy the lyric.m4 file into your project. Then you will have to integrate it into the acinclude.m4 file for your project. This is usually done with a command like:
It is recommended that you add some rules to distribute lyric.m4 and to have acinclude.m4 be rebuilt automatically in your project’s top level Makefile.am file. These lines read:
Now that you have included the M4 macros to auto-detect LYRIC, you have to add the call to the autoconf functions stored in lyric.m4 in your configure.in file. There are two things to add to your configure.in file:
Some lines to build LYRIC in your project from your configure.in file will read:
Note that both ACTION_IF_FOUND and ACTION_IF_NOT_FOUND are optional. The minimal call to detect LYRIC paths is:
This will auto detect LYRIC with release version being at least 2.1.9.
Finally you must add some rules to your Makefile.am.