Hi William,

Recommended title: "net/ixgbe: build on Windows".

2021-10-01 17:33 (UTC-0700), William Tu:
> This patch enables building the ixgbe driver for Windows.
> It also enables its dependencies on security and cryptodev.
> I tested on AWS using ixgbe VF device, using dpdk-testpmd.
> 
> Signed-off-by: William Tu <u9012...@gmail.com>

I'm getting this error when building with MinGW:

        ../drivers/net/ixgbe/ixgbe_ethdev.c:6416:29: error: ‘IPPROTO_SCTP’
        undeclared (first use in this function); did you mean ‘IPPROTO_TCP’?

Can be fixed by defining IPPROTO_SCTP in e.g. ixgbe_osdep.h if not defined.
Note that rte_os_shim.h cannot be used even in ixgbe_ethdev.c, because it
defines `read()` macro, which causes another error:

        ../drivers/net/ixgbe/ixgbe_ethdev.c:4097:37: error: macro "read"
        passed 4 arguments, but takes just 3
         4097 |  if (mbx->ops.read(hw, &in_msg, 1, 0))

> [...]
> diff --git a/drivers/net/ixgbe/base/meson.build 
> b/drivers/net/ixgbe/base/meson.build
> index 22972c6b56..51a58a3183 100644
> --- a/drivers/net/ixgbe/base/meson.build
> +++ b/drivers/net/ixgbe/base/meson.build
> @@ -28,7 +28,14 @@ foreach flag: error_cflags
>      endif
>  endforeach
>  
> +inc = []
> +inc += include_directories('../../../../lib/net')
> +inc += include_directories('../../../../lib/mbuf')
> +inc += include_directories('../../../../lib/mempool')
> +inc += include_directories('../../../../lib/ring')
> +
>  base_lib = static_library('ixgbe_base', sources,
>      dependencies: static_rte_eal,
> +    include_directories: inc,
>      c_args: c_args)
>  base_objs = base_lib.extract_all_objects(recursive: true)

Looks messy, you could just do this:

    dependencies: [static_rte_eal, static_rte_net]

This works because all drivers/net have a standard dependency on lib/ethdev,
which pulls lib/net in its turn.

Reply via email to