From: Lucas De Marchi Date: Fri, 6 Sep 2013 14:15:02 +0000 (-0300) Subject: build: remove check for typeof X-Git-Tag: v16~21 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4c2dc16a2ef46cf139f505379927a68fdb798ce9;p=thirdparty%2Fkmod.git build: remove check for typeof It's used in so many places without checking, that's really pointless to check for it in macro.h. Also remove AC_C_TYPEOF from configure.ac since we don't use -ansi. --- diff --git a/configure.ac b/configure.ac index a192c817..e7416f6a 100644 --- a/configure.ac +++ b/configure.ac @@ -28,7 +28,6 @@ AS_IF([test "x$enable_static" = "xyes"], AC_PROG_CC AC_PROG_CC_C99 -AC_C_TYPEOF AM_PROG_CC_C_O AC_PROG_GCC_TRADITIONAL AC_C_BIGENDIAN diff --git a/libkmod/macro.h b/libkmod/macro.h index 10392a33..7969072d 100644 --- a/libkmod/macro.h +++ b/libkmod/macro.h @@ -29,14 +29,8 @@ do { (void) sizeof(char [1 - 2*!(expr)]); } while(0) #endif -#if HAVE_TYPEOF #define check_types_match(expr1, expr2) \ ((typeof(expr1) *)0 != (typeof(expr2) *)0) -#else -/* Without typeof, we can only test the sizes. */ -#define check_types_match(expr1, expr2) \ - assert_cc(sizeof(expr1) == sizeof(expr2)) -#endif /* HAVE_TYPEOF */ #define container_of(member_ptr, containing_type, member) \ ((containing_type *) \