Browse Source

Android compilation fixes

pull/259/head
emanuele-f 4 years ago
parent
commit
f5804db2b0
  1. 2
      android/edge_android.c
  2. 2
      android/tuntap_android.c
  3. 2
      include/portable_endian.h
  4. 2
      src/edge_utils.c
  5. 4
      src/speck.c

2
android/edge_android.c

@ -16,7 +16,7 @@
*
*/
#include "../n2n.h"
#include "n2n.h"
#ifdef __ANDROID_NDK__
#include <edge_jni/edge_jni.h>

2
android/tuntap_android.c

@ -15,7 +15,7 @@
* along with this program; if not, see <http://www.gnu.org/licenses/>
*/
#include "../n2n.h"
#include "n2n.h"
#ifdef __ANDROID_NDK__
#include <tun2tap/tun2tap.h>

2
include/portable_endian.h

@ -31,7 +31,7 @@
# include <endian.h>
# include <features.h>
/* See http://linux.die.net/man/3/endian */
# if defined(htobe16) && defined(htole16) && defined(be16toh) && defined(le16toh) && defined(htobe32) && defined(htole32) && defined(be32toh) && defined(htole32) && defined(htobe64) && defined(htole64) && defined(be64) && defined(le64)
# if defined(htobe16) && defined(htole16) && defined(be16toh) && defined(le16toh) && defined(htobe32) && defined(htole32) && defined(be32toh) && defined(htole32) && defined(htobe64) && defined(htole64) && defined(htobe64) && defined(be64toh) && defined(htole64) && defined(le64toh)
/* Do nothing. The macros we need already exist. */
# elif !defined(__GLIBC__) || !defined(__GLIBC_MINOR__) || ((__GLIBC__ < 2) || ((__GLIBC__ == 2) && (__GLIBC_MINOR__ < 9)))
# include <arpa/inet.h>

2
src/edge_utils.c

@ -2559,5 +2559,5 @@ int quick_edge_init(char *device_name, char *community_name,
/* ************************************** */
#ifdef __ANDROID_NDK__
#include "android/edge_android.c"
#include "../android/edge_android.c"
#endif

4
src/speck.c

@ -5,8 +5,6 @@
#include <stdlib.h>
#include "portable_endian.h"
#ifndef __ANDROID_NDK__
#include "speck.h"
#if defined (__AVX2__) // AVX support ----------------------------------------------------
@ -786,5 +784,3 @@ int main (int argc, char* argv[]) {
fprintf (stdout, "SPECK SELF TEST RESULT: %u\n", speck_test (0,NULL));
}
*/
#endif
Loading…
Cancel
Save