Index: configure.ac |
=================================================================== |
--- a/configure.ac |
+++ b/configure.ac |
@@ -73,16 +73,38 @@ AC_ARG_ENABLE(m32, |
usem32=false |
;; |
*) |
AC_MSG_ERROR(bad value ${enableval} for --enable-m32) |
;; |
esac], |
[usem32=false]) |
+AC_ARG_ENABLE(processor, |
+ AS_HELP_STRING([--disable-processor], |
+ [Don't build processor library] |
+ [(default is no)]), |
+ [case "${enableval}" in |
+ yes) |
+ disable_processor=false |
+ ;; |
mochalatte
2010/10/05 18:24:08
i think i'm getting lost in the double negatives &
Ted Mielczarek
2010/10/05 18:28:59
Autoconf is sort of awful, but if you pass:
--disa
|
+ no) |
+ disable_processor=true |
+ ;; |
+ *) |
+ AC_MSG_ERROR(bad value ${enableval} for --disable-processor) |
+ ;; |
+ esac], |
+ [disable_processor=false]) |
+AM_CONDITIONAL(DISABLE_PROCESSOR, test x$disable_processor = xtrue) |
+ |
+if test x$LINUX_HOST = xfalse -a x$disable_processor = xtrue; then |
+ AC_MSG_ERROR([--disable-processor was specified, and not building for Linux. Nothing to build!]) |
+fi |
+ |
AC_CHECK_MEMBER(struct sockaddr.sa_len, |
[AC_DEFINE([GET_SA_LEN(X)],[(((struct sockaddr*)&(X))->sa_len)], |
[actual length of specific struct sockaddr])], |
[AC_DEFINE([GET_SA_LEN(X)], |
[(((struct sockaddr*)&(X))->sa_family == AF_INET ? sizeof(struct sockaddr_in) : \ |
((struct sockaddr*)&(X))->sa_family == AF_INET6 ? sizeof(struct sockaddr_in6) : sizeof(struct sockaddr))], |
[actual length of specific struct sockaddr])], |
[#include <sys/socket.h>]) |