Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build failed on OpenBSD 6.5 #30

Open
ligurio opened this issue Jan 18, 2020 · 9 comments
Open

Build failed on OpenBSD 6.5 #30

ligurio opened this issue Jan 18, 2020 · 9 comments

Comments

@ligurio
Copy link
Contributor

ligurio commented Jan 18, 2020

packetdrill 296fb3f

uname -sr: OpenBSD 6.5

$ ./configure
$ make

cc -g -Wall -Werror  -c packetdrill.c
In file included from packetdrill.c:25:
In file included from ./types.h:43:
./platforms.h:49:9: error: unknown type name 'u8'
typedef u8 __u8;
        ^
./platforms.h:50:9: error: unknown type name 'u16'
typedef u16 __u16;
        ^
./platforms.h:51:9: error: unknown type name 'u32'
typedef u32 __u32;
        ^
./platforms.h:52:9: error: unknown type name 'u64'
typedef u64 __u64;
        ^
./platforms.h:55:9: error: unknown type name 'u16'
typedef u16 __le16;
        ^
./platforms.h:56:9: error: unknown type name 'u16'
typedef u16 __be16;
        ^
./platforms.h:57:9: error: unknown type name 'u32'
typedef u32 __le32;
        ^
./platforms.h:58:9: error: unknown type name 'u32'
typedef u32 __be32;
        ^
./platforms.h:59:9: error: unknown type name 'u64'
typedef u64 __le64;
        ^
./platforms.h:60:9: error: unknown type name 'u64'
typedef u64 __be64;
        ^
./platforms.h:62:9: error: unknown type name 'u16'
typedef u16 __sum16;
        ^
./platforms.h:63:9: error: unknown type name 'u32'
typedef u32 __wsum;
        ^
In file included from packetdrill.c:25:
In file included from ./types.h:43:
In file included from ./platforms.h:97:
./fmemopen.h:33:14: error: conflicting types for 'fmemopen'
extern FILE *fmemopen(char *buf, size_t size, const char *mode);
             ^
/usr/include/stdio.h:330:7: note: previous declaration is here
FILE    *fmemopen(void *, size_t, const char *);
         ^
In file included from packetdrill.c:35:
In file included from ./run.h:71:
In file included from ./so_testing.h:28:
./packetdrill.h:37:10: fatal error: 'sys/epoll.h' file not found
#include <sys/epoll.h>
         ^~~~~~~~~~~~~
14 errors generated.
*** Error 1 in /home/sergeyb/source/packetdrill/gtests/net/packetdrill (<sys.mk>:87 'packetdrill.o')
@tuexen
Copy link
Contributor

tuexen commented Feb 2, 2020

Does https://github.com/nplab/packetdrill build and run on OpenBSD? It works von FreeBSD and compiles on NetBSD. Haven't tested it on OpenBSD.

@ligurio
Copy link
Contributor Author

ligurio commented Feb 3, 2020

Does https://github.com/nplab/packetdrill build and run on OpenBSD?

No, at least on 6.5 release. OpenBSD has its own specific in comparison to NetBSD and FreeBSD.
I'll try to port packetdrill to OpenBSD.

@tuexen
Copy link
Contributor

tuexen commented Feb 3, 2020

Where is it breaking? I guess at least some of the fixes for FreeBSD and NetBSD apply also to OpenBSD...

@ligurio
Copy link
Contributor Author

ligurio commented Feb 3, 2020

@tuexen
Copy link
Contributor

tuexen commented Feb 3, 2020

I just tested https://github.com/nplab/packetdrill and with two minor tweaks which are committed now, it build and runs if one not using blocking system calls.

@ligurio
Copy link
Contributor Author

ligurio commented Feb 4, 2020

I just tested https://github.com/nplab/packetdrill and with two minor tweaks which are committed now, it build and runs if one not using blocking system calls.

This issue is for original packetdrill. Actually I'm interested in a single packetdrill version with all features and supported platforms but as @nealcardwell said it is no possible now. Well, I'll check your fork on latest OpenBSD (6.6) and report about status here.

@tuexen
Copy link
Contributor

tuexen commented Feb 4, 2020

Just to be clear: I don't want to compete... Just saying that work for porting packetdrill to other platforms has been done and you can check it out. I guess the changes would also be necessary for the original version of packetdrill. So you can look around. However, if I remember it correctly, the required changes were more than fixing compile issues.

@ligurio
Copy link
Contributor Author

ligurio commented Feb 4, 2020

@tuexen packetdrill fork by nplab (https://github.com/nplab/packetdrill) works fine on OpenBSD 6.6 amd64
commit id 250a35fcc19565a928d0b20e07bf4061673b4cb2

@tuexen
Copy link
Contributor

tuexen commented Feb 4, 2020

Thanks for testing and reporting. Blocking system calls are not yet working on NetBSD and OpenBSD, since an implementation of is_thread_sleeping(pid_t process_id, pid_t thread_id) is still needed for NetBSD and OpenBSD. Right now, it is only implemented for Linux, FreeBSD, and Mac OS.

dcaratti pushed a commit to dcaratti/packetdrill that referenced this issue Jan 27, 2021
mptcp: add fastclose test cases episode two
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants