Modernize autmake macros