From 186b5a0aef6617d46acaf9acca1b57b2c16d8bf4 Mon Sep 17 00:00:00 2001 From: pancake Date: Wed, 13 Apr 2011 16:39:44 +0200 Subject: [PATCH] * Add untested support to compile on GNU/HURD --- configure | 7 +++++-- configure.acr | 5 ++++- libr/include/r_types.h | 2 +- 3 files changed, 10 insertions(+), 4 deletions(-) diff --git a/configure b/configure index bd0e638336..1ee6caa9b2 100755 --- a/configure +++ b/configure @@ -298,7 +298,7 @@ echo "ERROR: ${CC} cannot create executables" >&2 ; exit 1 ; fi printf "checking for dynamic library... " HAVE_LIB_DL=0 -for OS in linux syllable sunos darwin beos solaris gnu/kfreebsd ; do +for OS in linux syllable sunos darwin beos solaris ; do if [ "${HOST_OS}" = "${OS}" ]; then HAVE_LIB_DL=1 break; @@ -365,6 +365,9 @@ if [ "$USEROSTYPE" = "auto" ]; then if [ "$HOST_OS" = "linux" ]; then USEROSTYPE="gnulinux" else +if [ "$HOST_OS" = "gnu" ]; then +USEROSTYPE="gnulinux" +else if [ "$HOST_OS" = "gnu/kfreebsd" ]; then USEROSTYPE="gnulinux" else @@ -378,7 +381,7 @@ if [ "$HOST_OS" = "openbsd" ]; then USEROSTYPE="gnulinux" else if [ "$HOST_OS" = "darwin" ]; then -USEROSTYPE="darwin"; fi; fi; fi; fi; fi; fi; fi +USEROSTYPE="darwin"; fi; fi; fi; fi; fi; fi; fi; fi SEDFLAGS=" -e '" COUNT=0 for A in ${ENVWORDS} ; do diff --git a/configure.acr b/configure.acr index 0054b1b79f..585b3c77df 100644 --- a/configure.acr +++ b/configure.acr @@ -39,6 +39,9 @@ IFEQ USEROSTYPE auto ; { IFEQ HOST_OS linux ; { USEROSTYPE = gnulinux ; }{ + IFEQ HOST_OS gnu ; { + USEROSTYPE = gnulinux ; + }{ IFEQ HOST_OS gnu/kfreebsd ; { USEROSTYPE = gnulinux ; }{ @@ -53,7 +56,7 @@ IFEQ USEROSTYPE auto ; { }{ IFEQ HOST_OS darwin ; { USEROSTYPE = darwin ; - } } } } } } + } } } } } } } } ARG_WITHOUT WITHPIC pic do not build libr as a program independent location ; diff --git a/libr/include/r_types.h b/libr/include/r_types.h index b36d7a9827..2156147533 100644 --- a/libr/include/r_types.h +++ b/libr/include/r_types.h @@ -72,7 +72,7 @@ typedef void (*PrintfCallback)(const char *str, ...); #undef __UNIX__ #undef __WINDOWS__ -#if defined(__linux__) || defined(__APPLE__) +#if defined(__linux__) || defined(__APPLE__) || defined(__GNU__) #define __BSD__ 0 #define __UNIX__ 1 #endif