X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=configure.in;h=3ea7098dc204d7d8a959c42ae70a171fe6bf219a;hb=2ebe47be924ec18a1e154fe50707aa18d43542c0;hp=6e174afec5166692d0877c092b5d4a0220df3ca3;hpb=a4e862781f6c0ccab87da15034cb997ab2385c89;p=ghc-hetmet.git diff --git a/configure.in b/configure.in index 6e174af..3ea7098 100644 --- a/configure.in +++ b/configure.in @@ -168,6 +168,11 @@ i[[3456]]86-*-mingw32*) HostVendor_CPP='unknown' HostOS_CPP='mingw32' exeext='.exe' + # We assume you're using mingw32 via the gcc that comes + # with cygwin, and not the native port, so let's augment + # the gcc command-line used here with -mno-cygwin to + # arrange for good things to happen. + CFLAGS="-mno-cygwin $CFLAGS" ;; m68k-next-nextstep2) HostPlatform_CPP='m68k_next_nextstep2' @@ -303,16 +308,16 @@ dnl use either is considered a Feature. dnl ** What command to use to compile compiler sources ? dnl -------------------------------------------------------------- -AC_ARG_WITH(ghc-hc, -[ --with-ghc-hc= - Use a command different from 'ghc-2.10' to compile up the GHC compiler sources. - (no claims currently made that this will work with a compiler other than a - recent version of GHC, but you could always try...) +AC_ARG_WITH(hc, +[ --with-hc= + Use a command different from 'ghc' to compile up Haskell code. + (no claims currently made that this will work with a compiler other than a + recent version of GHC, but you could always try...) ], -[WithGhcHc="$withval"], -[WithGhcHc="ghc"] +[WithHc="$withval"], +[WithHc="ghc"] ) -AC_SUBST(WithGhcHc) +AC_SUBST(WithHc) dnl ** Which gcc to use? dnl -------------------------------------------------------------- @@ -338,6 +343,30 @@ AC_ARG_ENABLE(hc-boot, AC_SUBST(BootingFromHc) +dnl ** Enable the construction of Win32 DLLs? +dnl -------------------------------------------------------------- +AC_ARG_ENABLE(win32-dlls, +[ --enable-win32-dlls + If on a Win32 platform running mingw32/cygwin, enable the + construction of DLLs containing ghc-compiled code. +], +[ +case $HostOS_CPP in +cygwin32) ;; +mingw32) ;; +*) echo "Unrecognised win32 platform: $HostPlatform" + exit 1 + ;; +esac +EnableWin32DLLs=YES +], +[EnableWin32DLLs=NO] +) +AC_SUBST(EnableWin32DLLs) +if test x"$EnableWin32DLLs" = "xYES" ; then + AC_DEFINE(HAVE_WIN32_DLL_SUPPORT) +fi + dnl -------------------------------------------------------------- dnl End of configure script option section dnl -------------------------------------------------------------- @@ -373,7 +402,6 @@ FPTOOLS_HAVE_GCC dnl ** figure out how to invoke cpp directly (gcc -E is no good) AC_PROG_CPP -FPTOOLS_PROG_GNUCPP dnl ** figure out how to do context diffs FPTOOLS_PROG_DIFF @@ -446,7 +474,7 @@ dnl ** check for full ANSI header (.h) files AC_HEADER_STDC dnl ** check for specific header (.h) files that we are interested in -AC_CHECK_HEADERS(Files.h assert.h console.h ctype.h dirent.h errno.h fcntl.h float.h ftw.h grp.h ieee754.h malloc.h memory.h nlist.h pascal.h pwd.h sgtty.h siginfo.h signal.h stat.h stdlib.h stdarg.h string.h sys/fault.h sys/file.h sys/ioctl.h sys/limits.h sys/mman.h sys/param.h sys/procfs.h sys/resource.h sys/signal.h sys/socket.h netinet/tcp.h sys/stat.h sys/syscall.h sys/time.h sys/timeb.h sys/timers.h sys/times.h sys/types.h sys/utsname.h sys/vadvise.h sys/wait.h termio.h termios.h time.h types.h unistd.h utime.h values.h vfork.h readline/readline.h bfd.h) +AC_CHECK_HEADERS(Files.h assert.h console.h ctype.h dirent.h errno.h fcntl.h float.h ftw.h grp.h ieee754.h malloc.h memory.h nlist.h pascal.h pwd.h sgtty.h siginfo.h signal.h stat.h stdlib.h stdarg.h string.h sys/fault.h sys/file.h sys/ioctl.h sys/limits.h sys/mman.h sys/param.h sys/procfs.h sys/resource.h sys/signal.h sys/socket.h netinet/tcp.h sys/stat.h sys/syscall.h sys/time.h sys/timeb.h sys/timers.h sys/times.h sys/types.h sys/utsname.h sys/vadvise.h sys/wait.h termio.h termios.h time.h types.h unistd.h utime.h values.h vfork.h readline/readline.h readline/history.h bfd.h winsock.h) dnl ** check for DOS include files AC_CHECK_HEADERS(dos.h conio.h io.h std.h) @@ -586,6 +614,20 @@ dnl the order of these tests matters: bfd needs liberty AC_CHECK_LIB(iberty, xmalloc) AC_CHECK_LIB(bfd, bfd_init) +dnl ** check for readline, for Hugs +AC_CHECK_LIB(readline, readline, +[ +AC_DEFINE(HAVE_LIBREADLINE,1) +HaveLibReadline=YES +], +[ +AC_DEFINE(HAVE_LIBREADLINE,0) +HaveLibReadline=NO +], +-ltermcap) +AC_SUBST(HaveLibReadline) + + dnl ################################################################ dnl Check for libraries dnl ################################################################