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

Compilation issues in Arch (struct timeval missing, segfault at __strlen_avx2) #55

Open
dessaya opened this issue Dec 24, 2018 · 0 comments

Comments

@dessaya
Copy link

dessaya commented Dec 24, 2018

I'm compiling in my Arch Linux box, and I ran into a few issues. I managed to work around them as shown below.

client.c: In function ‘send_msg’:
client.c:104:17: error: storage size of ‘timeout’ isn’t known
  struct timeval timeout;
                 ^~~~~~~

This is fixed by replacing #include <time.h> with #include <sys/time.h> in rftg.h and comm.h. I don't know if that would break other platforms but it works in my setup.

  1. Segfault in read_campaign():
#0  0x00007ffff6c8a715 in __strlen_avx2 () at /usr/lib/libc.so.6
#1  0x000055555557fb1a in read_campaign () at init.c:798
#2  0x00005555555b56f7 in main (argc=5, argv=0x7fffffffe5c8) at gui.c:14291

Apparently strdup() needs a #define to be correctly declared. So my workaround was to compile with:

make CFLAGS='-D_SVID_SOURCE'
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

1 participant