19/02/2023 11:01, Thomas Monjalon: > 09/12/2022 10:33, fengchengwen: > > The hns3 and idpf both use static_library to build advanced vector (e.g. > > SVE for hns3 and AVX512 for idpf). > > The static-library is still compiled even the PMD is not compiled, and this > > lead to the compile fail problem. > > > > Although the following could solve the problem, but is there a better > > plan? > > +if dpdk_conf.get('RTE_IOVA_AS_PA') == 0 > > + build = false > > + reason = 'driver does not support disabling IOVA as PA mode' > > + subdir_done() > > +endif > > Yes there is a better plan: fix drivers/meson.build. > We must move the "continue" to skip the driver as soon as possible.
Scratch that, it's a stupid idea. The problem is generating sub-libraries inside the driver in order to map some specific compiler options with some files. Looks like we must disable the build inside the driver: +if not get_option('enable_iova_as_pa') + subdir_done() +endif No need to give reason or disable build as it will be done anyway in drivers/meson.build.