def METHOD_NAME(self):
    spec = self.spec
    # hsa-rocr-dev wants the directory containing the header files, but
    # libelf adds an extra path (include/libelf) compared to elfutils
    libelf_include = os.path.dirname(
        find_headers("libelf", spec["elf"].prefix.include, recursive=True)[0]
    )
    args = [
        self.define("LIBELF_INCLUDE_DIRS", libelf_include),
        self.define_from_variant("BUILD_SHARED_LIBS", "shared"),
    ]
    if self.spec.satisfies("@3.7.0:"):
        args.append(self.define_from_variant("IMAGE_SUPPORT", "image"))
        # device libs is bundled with llvm-amdgpu (default) or standalone
        if self.spec.satisfies("^rocm-device-libs"):
            bitcode_dir = spec["rocm-device-libs"].prefix.amdgcn.bitcode
        else:
            bitcode_dir = spec["llvm-amdgpu"].prefix.amdgcn.bitcode
        args.append(self.define("BITCODE_DIR", bitcode_dir))
    return args