8000 aeron ping-pong example build should detect sendmmsg · Issue #1595 · aeron-io/aeron · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
aeron ping-pong example build should detect sendmmsg #1595
Open
@vaci

Description

@vaci

The ping_pong_raw example doesn't check the HAVE_SENDMMSG build macro, so it fails to build on my system which lacks that call:

aeron/aeron-samples/src/main/c/raw/ping_pong_raw.c: In function 'aeron_ping_pong_raw_sendmmsg':
aeron/aeron-samples/src/main/c/raw/ping_pong_raw.c:169:26: warning: implicit declaration of function 'sendmmsg'; did you mean 'sendmsg'? [-Wimplicit-function-declaration]
169 | int sendmsg_result = sendmmsg(send_fd, &send_msghdr, 1, 0);
| ^~~~~~~~
| sendmsg
[ 44%] Linking C executable ../../../../binaries/ping_pong_raw
bin/ld: CMakeFiles/ping_pong_raw.dir/raw/ping_pong_raw.c.o: in function aeron_ping_pong_raw_sendmmsg': ping_pong_raw.c:(.text.aeron_ping_pong_raw_sendmmsg+0x55): undefined reference to sendmmsg'
collect2: error: ld returned 1 exit status

I think the code just need an appropriate macro guard and alternative behaviour here:
https://github.com/real-logic/aeron/blob/1.44.1/aeron-samples/src/main/c/raw/ping_pong_raw.c#L169

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0