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

Fix build on xenial #863

Merged
merged 1 commit into from
Oct 14, 2019
Merged

Fix build on xenial #863

merged 1 commit into from
Oct 14, 2019

Conversation

jagerman
Copy link
Member

  • xenial's cmake version (3.5.1) builds everything fine and test suite
    passes, so lower the minimum to that.

  • add a hack for xenial's kernel header & glibc version breaking if both
    net/if.h and linux/if.h get included. The only thing we actually need
    from net/if.h that linux/if.h doesn't have is if_nametoindex, so
    just hack that definition in for xenial's specific glibc/kernel header
    versions.

This travis-ci build doesn't hit either of these issues because it isn't fully xenial - it's xenial plus updated headers and cmake versions because WTF travis.

CMakeLists.txt Outdated
@@ -1,5 +1,4 @@
# Lowest version - android ndk 3.6.0
cmake_minimum_required(VERSION 3.6.0)
cmake_minimum_required(VERSION 3.5.1)
Copy link
Contributor

@michael-loki michael-loki Oct 11, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you comment why we need this version? 3.5.1 is :(

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I assume you mean in the code? Added a comment to CMakeLists.txt.

- xenial's cmake version (3.5.1) builds everything fine and test suite
  passes, so lower the minimum to that.

- add a hack for xenial's kernel header & glibc version breaking if both
  net/if.h and linux/if.h get included.  The only thing we actually need
  from net/if.h that linux/if.h doesn't have is `if_nametoindex`, so
  just hack that definition in for xenial's specific glibc/kernel header
  versions.
@majestrate majestrate merged commit d52b8bf into oxen-io:dev Oct 14, 2019
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

Successfully merging this pull request may close these issues.

None yet

3 participants