def METHOD_NAME(self):
    """Install symlinks for lex compatibility."""
    dso = dso_suffix
    for dir, flex, lex in (
        (self.prefix.bin, "flex", "lex"),
        (self.prefix.lib, "libfl.a", "libl.a"),
        (self.prefix.lib, "libfl." + dso, "libl." + dso),
        (self.prefix.lib64, "libfl.a", "libl.a"),
        (self.prefix.lib64, "libfl." + dso, "libl." + dso),
    ):
        if os.path.isdir(dir):
            with working_dir(dir):
                if os.path.isfile(flex) and not os.path.lexists(lex):
                    symlink(flex, lex)