~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to configure.ac

  • Committer: Brian Aker
  • Date: 2008-11-03 21:00:47 UTC
  • mfrom: (520.9.5 devel)
  • Revision ID: brian@tangent.org-20081103210047-wfkeyyefrfl2vh4l
Merge from Monty

Show diffs side-by-side

added added

removed removed

Lines of Context:
336
336
 
337
337
dnl TODO: Can _ISOC99_SOURCE be defined on all platforms and remove the 
338
338
dnl       Need for all of this? 
339
 
case "$target_os" in
340
 
  *solaris*)
341
 
  dnl Do we need both of these? 
342
 
  CXXFLAGS="${CXXFLAGS} -D__C99FEATURES__"
343
 
  CFLAGS="${CFLAGS} -D_XOPEN_SOURCE=600"
344
 
  ;;
345
 
esac
346
 
 
 
339
if test "$GCC" = "yes"
 
340
then
 
341
  case "$target_os" in
 
342
    *solaris*)
 
343
    CFLAGS="${CFLAGS} -D_XOPEN_SOURCE=600"
 
344
    CXXFLAGS="${CXXFLAGS} -D__C99FEATURES__"
 
345
    ;;
 
346
  esac
 
347
fi
347
348
 
348
349
# We use libtool
349
350
#AC_LIBTOOL_WIN32_DLL
415
416
  dnl I'm cheating here and sticking C99 support in SYMBOLS_FLAGS
416
417
  SYMBOLS_FLAGS=""
417
418
  DEBUG_OPTIMIZE_CC=""
418
 
  #OPTIMIZE_CFLAGS="-xO4 -xlibmil -xdepend -Xa -xstrconst -mt -D_FORTEC_"
419
419
  OPTIMIZE_CFLAGS="-xO4 -xlibmil -xdepend -Xa -mt -xstrconst -D_FORTEC_"
420
420
  DEBUG_OPTIMIZE_CXX=""
421
 
  OPTIMIZE_CXXFLAGS="-xO4 -xlibmil -library=stlport4 -mt -D_FORTEC_ -xlang=c99 -compat=5"
 
421
  #Put back in once isnan is figured out
 
422
  OPTIMIZE_CXXFLAGS="-xO4 -xlibmil -mt -D_FORTEC_ -xlang=c99 -compat=5 -library=stlport4"
422
423
fi
423
424
 
424
425
dnl TODO: Remove this define once we are using 2.61 across the board.
487
488
 
488
489
AC_MSG_CHECKING(for Google Protocol Buffers)
489
490
AC_ARG_WITH(protobuf,
490
 
  [AS_HELP_STRING([--with-protobuf],
491
 
       [Use protobuf directory])],
 
491
  [AS_HELP_STRING([--with-protobuf@<:@=DIR@:>@],
 
492
       [search for protobuf in DIR/include and DIR/lib])],
492
493
  [ with_protobuf=$withval ],
493
494
  [ with_protobuf=yes ])
494
495
 
556
557
 
557
558
AC_MSG_CHECKING(for libevent)
558
559
AC_ARG_WITH(libevent,
559
 
  [AS_HELP_STRING([--with-libevent],
560
 
       [Use libevent build directory])],
 
560
  [AS_HELP_STRING([--with-libevent@<:@=DIR@:>@],
 
561
       [Use libevent in DIR])],
561
562
  [ with_libevent=$withval ],
562
563
  [ with_libevent=yes ])
563
564
 
573
574
    AC_CHECK_LIB(event, event_loop, [], [AC_MSG_ERROR(could not find libevent)])
574
575
    LIBEVENT_LIBS="${LIBS}"
575
576
    LIBS="${my_save_LIBS}"
576
 
    LIBEVENT_CFLAGS=""
 
577
    LIBEVENT_CPPFLAGS=""
577
578
else
578
579
    AC_MSG_RESULT($withval)
579
580
    if test -f $withval/event.h -a -f $withval/libevent.a; then
580
581
       owd=`pwd`
581
582
       if cd $withval; then withval=`pwd`; cd $owd; fi
582
 
       LIBEVENT_CFLAGS="-I$withval"
 
583
       LIBEVENT_CPPFLAGS="-I$withval"
583
584
       LIBEVENT_LIBS="-L$withval -levent"
584
585
    elif test -f $withval/include/event.h -a -f $withval/lib/libevent.a; then
585
586
       owd=`pwd`
586
587
       if cd $withval; then withval=`pwd`; cd $owd; fi
587
 
       LIBEVENT_CFLAGS="-I$withval/include"
 
588
       LIBEVENT_CPPFLAGS="-I$withval/include"
588
589
       LIBEVENT_LIBS="-L$withval/lib -levent"
589
590
    else
590
591
       AC_MSG_ERROR([event.h or libevent.a not found in $withval])
591
592
    fi
592
593
fi
593
594
 
594
 
AC_SUBST(LIBEVENT_CFLAGS)
 
595
AC_SUBST(LIBEVENT_CPPFLAGS)
595
596
AC_SUBST(LIBEVENT_LIBS)
596
597
 
597
598
AC_CACHE_CHECK([for bufferevent in libevent], ac_libevent_works, [
598
 
  save_CFLAGS="$CFLAGS"
 
599
  save_CPPFLAGS="$CPPFLAGS"
599
600
  save_LIBS="$LIBS"
600
 
  CFLAGS="$LIBEVENT_CFLAGS"
 
601
  CPPFLAGS="$LIBEVENT_CPPFLAGS"
601
602
  LIBS="$LIBEVENT_LIBS"
602
603
  AC_TRY_LINK([
603
604
#include <sys/types.h>
611
612
        check http://www.monkey.org/~provos/libevent/])
612
613
  ])
613
614
 
614
 
  CFLAGS="$save_CFLAGS"
 
615
  CPPFLAGS="$save_CPPFLAGS"
615
616
  LIBS="$save_LIBS"
616
617
])
617
618