(self, verbose=False)
| 94 | return found |
| 95 | |
| 96 | def is_compatible(self, verbose=False): |
| 97 | # Check for the existence of libaio by using distutils |
| 98 | # to compile and link a test program that calls io_submit, |
| 99 | # which is a function provided by libaio that is used in the async_io op. |
| 100 | # If needed, one can define -I and -L entries in CFLAGS and LDFLAGS |
| 101 | # respectively to specify the directories for libaio.h and libaio.so. |
| 102 | aio_compatible = self.has_function('io_submit', ('aio', )) |
| 103 | if verbose and not aio_compatible: |
| 104 | self.warning(f"{self.NAME} requires the dev libaio .so object and headers but these were not found.") |
| 105 | |
| 106 | # Check for the libaio package via known package managers |
| 107 | # to print suggestions on which package to install. |
| 108 | self.check_for_libaio_pkg() |
| 109 | |
| 110 | self.warning( |
| 111 | "If libaio is already installed (perhaps from source), try setting the CFLAGS and LDFLAGS environment variables to where it can be found." |
| 112 | ) |
| 113 | return super().is_compatible(verbose) and aio_compatible |
nothing calls this directly
no test coverage detected