Home My Page Projects Code Snippets Project Openings diderot
Summary Activity Tracker Tasks SCM

SCM Repository

[diderot] Diff of /branches/vis12-cl/configure.ac
ViewVC logotype

Diff of /branches/vis12-cl/configure.ac

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

trunk/configure.ac revision 123, Mon Jun 28 18:05:04 2010 UTC branches/vis12-cl/configure.ac revision 2729, Thu Sep 25 13:43:53 2014 UTC
# Line 1  Line 1 
1  dnl Process this file with autoconf to produce a configure script.  dnl Process this file with autoconf to produce a configure script.
2  dnl  dnl
3  dnl COPYRIGHT (c) 2010 The Diderot Project  dnl COPYRIGHT (c) 2014 The Diderot Project
4  dnl All rights reserved.  dnl All rights reserved.
5  dnl  dnl
6    
 dnl NOTE: MANTICORE_DIST_VERSION is an M4 variable defined in config/aclocal.m4  
 dnl  
7  AC_INIT(diderot,0.1,)  AC_INIT(diderot,0.1,)
8    
9  AC_PREREQ(2.60)  AC_PREREQ(2.60)
10  AC_COPYRIGHT([[COPYRIGHT (c) 2010 The Diderot Project]])  AC_COPYRIGHT([[COPYRIGHT (c) 2014 The Diderot Project (http://diderot-language.cs.uchicago.edu)]])
11  AC_CONFIG_SRCDIR(src/dnorm/dnorm.c)  AC_CONFIG_SRCDIR(src/compiler/driver/main.sml)
12  AC_CONFIG_AUX_DIR(config)  AC_CONFIG_AUX_DIR(config)
13  AC_CONFIG_MACRO_DIR(config)  AC_CONFIG_MACRO_DIR(config)
14    
# Line 20  Line 18 
18  sinclude(config/acx_pthread.m4)  sinclude(config/acx_pthread.m4)
19  sinclude(config/check_smlnj.m4)  sinclude(config/check_smlnj.m4)
20  sinclude(config/check_smlnj_heap_suffix.m4)  sinclude(config/check_smlnj_heap_suffix.m4)
21    sinclude(config/ax_check_framework.m4)
22    
23  dnl  dnl
24  dnl get host information  dnl get host information
# Line 29  Line 27 
27    
28  dnl check for standard programs  dnl check for standard programs
29  dnl  dnl
30  AC_PROG_CC_C99  AC_PROG_CC([clang gcc cc])
31  AC_PROG_CPP  AC_PROG_CPP
32  AC_PROG_INSTALL  AC_PROG_INSTALL
33  AC_PROG_MAKE_SET  AC_PROG_MAKE_SET
34    
35    dnl FIXME: this works for now, but we should probably switch to libtool
36    dnl
37    AC_PATH_PROG(LD, [ld], [none])
38    if test x$LD = xnone ; then
39      AC_MSG_ERROR([cannot find ld command])
40    fi
41    AC_SUBST(LD)
42    
43    dnl check for c99 support
44    dnl
45    AC_PROG_CC_C99
46    if test x"$ac_cv_prog_cc_c99" = xno ; then
47      AC_MSG_ERROR([Diderot requires c99 support])
48    fi
49    
50    AC_ARG_ENABLE([32-bit],
51      AC_HELP_STRING([--enable-32-bit], [configure Diderot to produce 32-bit executables]),
52      [CFLAG_MXX="-m32"],
53      [CFLAG_MXX="-m64"])
54    
55    dnl extra C compiler options
56    dnl
57    CFLAGS=""
58    CFLAGS_BASE="-Wformat -Wreturn-type -Wuninitialized"
59    AC_SUBST(CFLAG_MXX)
60    AC_SUBST(CFLAGS_BASE)
61    
62    dnl
63    dnl standard headers
64    dnl
65    AC_HEADER_STDBOOL
66    
67  dnl  dnl
68  dnl If we are on Mac OS X, check for the presence of macports and/or fink  dnl check for pthreads support
69  dnl  dnl
70  NEEDS_MACPORTS=no  ACX_PTHREAD
71  NEEDS_FINK=no  
72    dnl
73    dnl Look for NVIDIA's nvcc compiler
74    dnl
75    AC_MSG_NOTICE([checking for CUDA and nvcc])
76    AC_PATH_PROG(NVCC, nvcc, no, $PATH)
77    if test x"$NVCC" = xno ; then
78      AC_MSG_WARN([nvcc not found])
79      CUDA_ENABLED=false
80      NVCC=":"
81    else
82      AC_MSG_RESULT([$NVCC])
83      CUDA_ENABLED=true
84    fi
85    AC_SUBST(NVCC)
86    AC_SUBST(CUDA_ENABLED)
87    
88    dnl
89    dnl check for OpenCL support
90    dnl
91    LIBS_CL="none"
92  case "$host_os" in  case "$host_os" in
93    darwin*) # On Mac OS X we check for installed frameworks    darwin*) # On Mac OS X we check for installed frameworks
94        AX_CHECK_FRAMEWORK([OpenCL], [LIBS_CL="-framework OpenCL"], [])
95      ;;
96      *)
97        AC_CHECK_LIB([OpenCL],[clGetPlatformIDs],[LIBS_CL="-lOpenCL"])
98      ;;
99    esac
100    if test x"$LIBS_CL" = xnone ; then
101      AC_MSG_WARN([no OpenCL library found])
102      CL_ENABLED=false
103      CL_VERSION=0
104    else
105      CL_ENABLED=true
106      CPPFLAGS_CL=""
107      CL_HEADER=""
108      AC_CHECK_HEADERS([CL/cl.h OpenCL/cl.h], [HAVE_CL_H="yes"; CL_HEADER="$ac_header"; break], [HAVE_CL_H="no"])
109      if test x"$HAVE_CL_H" = xno ; then
110        # check for AMD's SDK
111        AC_MSG_CHECKING([for cl.h in AMD's SDK])
112        if test -d /opt/AMDAPP/include/CL ; then
113          HAVE_CL_H="yes"
114          CL_HEADER="/opt/AMDAPP/include/CL/cl.h"
115          AC_DEFINE([HAVE_CL_CL_H])
116          CPPFLAGS_CL="-I/opt/AMDAPP/include"
117        fi
118        AC_MSG_RESULT([$HAVE_CL_H])
119      fi
120      if test x"$HAVE_CL_H" = xno ; then
121        # check for NVIDIA's SDK
122        AC_MSG_CHECKING([for NVIDIA's SDK cl.h])
123        if test -d /usr/local/cuda/include/CL ; then
124          HAVE_CL_H="yes"
125          AC_DEFINE([HAVE_CL_CL_H])
126          CPPFLAGS_CL="-I/usr/local/cuda/include"
127        fi
128        AC_MSG_RESULT([$HAVE_CL_H])
129      fi
130      if test x"$HAVE_CL_H" = xno ; then
131        AC_MSG_WARN([no cl.h found])
132        CL_ENABLED=false
133        CL_VERSION=0
134        SIZEOF_CL_INT=0
135        SIZEOF_CL_LONG=0
136        SIZEOF_CL_FLOAT=0
137        SIZEOF_CL_DOUBLE=0
138      else
139        # check the cl.h header for which version of OpenCL is supported
140        AC_LANG([C])
141        save_CPPFLAGS=$CPPFLAGS
142        CPPFLAGS="$CPPFLAGS_CL $CPPFLAGS"
143        AC_LINK_IFELSE([AC_LANG_PROGRAM([[
144    #include <stdio.h>
145    # ifdef HAVE_CL_CL_H
146    #   include <CL/cl.h>
147    # elif defined(HAVE_OPENCL_CL_H)
148    #   include <OpenCL/cl.h>
149    # else
150    #   error no cl.h
151    # endif]],
152    [[#if defined(CL_VERSION_1_2)
153      printf("12000\n");
154    #elif defined(CL_VERSION_1_1)
155      printf("11000\n");
156    #elif defined(CL_VERSION_1_0)
157      printf("10000\n");
158    #else
159      printf("0\n");
160    #endif
161          ]])],
162          [CL_VERSION=`./conftest$EXEEXT`], [CL_VERSION=0])
163    dnl
164    dnl check to see how we access the host-side vector types.  For OpenCL 1.1,
165    dnl the specification specifies the behavior, but it was unspecified in 1.0.
166    dnl
167        AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
168    #include "$CL_HEADER"
169    ]],
170          [[cl_float4 x; x[0] = 0.0;]])],
171          [AC_DEFINE([CL_HOST_VECTORS_ARE_ARRAYS],[1],[host vector types are arrays])],
172    dnl
173    dnl not arrays, so try the OpenCL 1.1 structure representation
174    dnl
175          [AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
176    #include "$CL_HEADER"
177    ]],
178          [[cl_float4 x; x.s[0] = 0.0;]])],
179          [AC_DEFINE([CL_HOST_VECTORS_ARE_STRUCTS],[1],[host vector types are structs])],
180          [AC_MSG_ERROR([unable to figure out host types for OpenCL vectors])])])
181      # restore saved CPPFLAGS
182        CPPFLAGS=$save_CPPFLAGS
183      # substitutions
184        AC_SUBST(LIBS_CL)
185        AC_SUBST(CPPFLAGS_CL)
186      #
187      # determine the sizes of the host-side OpenCL types
188      AC_CHECK_SIZEOF([cl_int], [], [#include "$CL_HEADER"])
189      SIZEOF_CL_INT=$ac_cv_sizeof_cl_int
190      AC_CHECK_SIZEOF([cl_long], [], [#include "$CL_HEADER"])
191      SIZEOF_CL_LONG=$ac_cv_sizeof_cl_long
192      AC_CHECK_SIZEOF([cl_float], [], [#include "$CL_HEADER"])
193      SIZEOF_CL_FLOAT=$ac_cv_sizeof_cl_float
194      AC_CHECK_SIZEOF([cl_double], [], [#include "$CL_HEADER"])
195      SIZEOF_CL_DOUBLE=$ac_cv_sizeof_cl_double
196      fi
197    fi
198    AC_SUBST(CL_ENABLED)
199    AC_SUBST(CL_VERSION)
200    
201    AC_SUBST(SIZEOF_CL_INT)
202    AC_SUBST(SIZEOF_CL_LONG)
203    AC_SUBST(SIZEOF_CL_FLOAT)
204    AC_SUBST(SIZEOF_CL_DOUBLE)
205    
206    dnl
207    dnl check for various library routines etc.
208    dnl
209    AC_CHECK_FUNCS(posix_memalign)
210    if test x"$ac_cv_func_posix_memalign" != xyes ; then
211      AC_CHECK_FUNCS(memalign)
212      if test x"$ac_cv_func_posix_memalign" != xyes ; then
213        AC_CHECK_FUNCS(valloc)
214      fi
215    fi
216    
217    AC_CHECK_FUNCS(mach_absolute_time)
218    AC_CHECK_TYPES([struct timespec])
219    AC_CHECK_FUNCS(pthread_barrier_init)
220    
221    dnl
222    dnl check for clock_gettime.  On Linux, this requires librt.
223    dnl
224    save_LIBS=$LIBS
225    LIBS="-lrt $LIBS"
226    AC_MSG_CHECKING([for clock_gettime])
227    AC_LINK_IFELSE(
228      [AC_LANG_PROGRAM(
229        [[#include <time.h>]],
230        [[struct timespec t; clock_gettime(CLOCK_REALTIME, &t); ]])],
231      [ ac_cv_func_clock_gettime=yes;
232        AC_DEFINE(HAVE_CLOCK_GETTIME, [1], [is clock_gettime available?])],
233      [ac_cv_func_clock_gettime=no])
234    AC_MSG_RESULT($ac_cv_func_clock_gettime)
235    if test "$ac_cv_func_clock_gettime" = "no" ; then
236      LIBS=$save_LIBS
237    fi
238    
239    AC_CHECK_FUNCS(pthread_getcpuclockid)
240    AC_CHECK_FUNCS(sigtimedwait nanosleep)
241    
242    dnl
243    dnl check for sched_setaffinity
244    dnl
245    AC_CHECK_FUNCS(sched_setaffinity)
246    
247    dnl
248    dnl check for pthread_setaffinity_np
249    dnl
250    save_LIBS=$LIBS
251    save_CFLAGS=$CFLAGS
252    LIBS="$PTHREAD_LIBS $LIBS"
253    CFLAGS="$PTHREAD_CFLAGS $CFLAGS"
254    AC_MSG_CHECKING([for pthread_setaffinity_np])
255    AC_LINK_IFELSE(
256      [AC_LANG_PROGRAM(
257        [[#include <pthread.h>]],
258        [[cpu_set_t s; pthread_setaffinity_np(pthread_self(), sizeof(s), &s); ]])],
259      [ ac_cv_func_pthread_setaffinity_np=yes;
260        AC_DEFINE(HAVE_PTHREAD_SETAFFINITY_NP, [1], [is pthread_setaffinity_np available?])],
261      [ac_cv_func_pthread_setaffinity_np=no])
262    AC_MSG_RESULT($ac_cv_func_pthread_setaffinity_np)
263    LIBS=$save_LIBS
264    CFLAGS=$save_CFLAGS
265    
266    dnl
267    dnl check for Linux NUMA support (libnuma)
268    dnl
269    AC_CHECK_LIB(numa,numa_available)
270    if test "$ac_cv_lib_numa_numa_available" = "yes" ; then
271      PTHREAD_LIBS="$PTHREAD_LIBS -lnuma"
272    fi
273    
274    dnl check for /proc/cpuinfo
275    dnl
276    AC_CHECK_FILES(/proc/cpuinfo)
277    
278    dnl
279    dnl OS-specific linking issues
280    dnl
281    LD_NEEDS_RPATH=false;
282    LIBM=""
283    case "$host_os" in
284      darwin*) # On Mac OS X we check for the presence of macports and/or fink
285      if test -x /opt/local/bin/port ; then      if test -x /opt/local/bin/port ; then
286        HAS_MACPORTS=yes        HAS_MACPORTS=yes
287      else      else
# Line 52  Line 293 
293        HAS_FINK=no        HAS_FINK=no
294      fi      fi
295    ;;    ;;
296      linux*) # On Linux we include the -rpath option to pick up dynamically-loaded libraries
297        LD_NEEDS_RPATH=true
298        LIBM="-lm"
299      ;;
300  esac  esac
301    
302  if test x"$HAS_MACPORTS" = xyes ; then  if test x"$HAS_MACPORTS" = xyes ; then
# Line 62  Line 307 
307    LDPATHS=""    LDPATHS=""
308  fi  fi
309  AC_SUBST(LDPATHS)  AC_SUBST(LDPATHS)
310    AC_SUBST(LD_NEEDS_RPATH)
311    AC_SUBST(LIBM)
312    
313  dnl  dnl
314  dnl get the path to the TEEM installation  dnl get the path to the TEEM installation.  We need this to build the Diderot
315    dnl runtime code and we use the path when searching for teem in the Diderot
316    dnl compiler.
317  dnl  dnl
318  AC_ARG_WITH(teem,  AC_ARG_WITH(teem,
319    AC_HELP_STRING([--with-teem=<path>], [specify path to teem installation]),    AC_HELP_STRING([--with-teem=<path>], [specify path to teem installation]),
# Line 79  Line 328 
328    esac    esac
329    if test -x $ac_cv_use_teem ; then    if test -x $ac_cv_use_teem ; then
330      TEEM_DIR=$ac_cv_use_teem      TEEM_DIR=$ac_cv_use_teem
331      AC_MSG_RESULT([ okay])      # check that TEEM_DIR actually points to something that looks like teem
332        if test -f $TEEM_DIR/include/teem/nrrd.h ; then
333          AC_MSG_RESULT([yes])
334        else
335          TEEM_DIR=none
336          AC_MSG_RESULT([no])
337        fi
338    else    else
339      TEEM_DIR=none      TEEM_DIR=none
340      AC_MSG_RESULT([ invalid])      AC_MSG_RESULT([no])
341    fi    fi
342  fi  fi
343  if test x"$TEEM_DIR" = xnone ; then  if test x"$TEEM_DIR" = xnone ; then
344    AC_MSG_ERROR([unable to find teem])    AC_MSG_ERROR([unable to find teem; use --with-teem option to specify location])
345    fi
346    dnl
347    dnl check that unu supports the dnorm command
348    dnl
349    if test x"$TEEM_DIR" != xnone ; then
350      AC_MSG_CHECKING([that \"unu dnorm\" works])
351      if test -x $TEEM_DIR/bin/unu ; then
352        $TEEM_DIR/bin/unu dnorm > /dev/null 2> /dev/null
353        if test $? -eq 0 ; then
354          AC_MSG_RESULT([yes])
355        else
356          AC_MSG_ERROR([\"unu dnorm\" is not supported; please update your teem installation])
357        fi
358      else
359        AC_MSG_ERROR([unable to find unu executable in $TEEM_DIR/bin"])
360      fi
361  fi  fi
362  AC_SUBST(TEEM_DIR)  AC_SUBST(TEEM_DIR)
363    
# Line 97  Line 368 
368  dnl  dnl
369  CHECK_SMLNJ([AC_MSG_ERROR([unable to find SML/NJ installation; check your PATH or set SMLNJ_CMD])])  CHECK_SMLNJ([AC_MSG_ERROR([unable to find SML/NJ installation; check your PATH or set SMLNJ_CMD])])
370  if test $SMLNJ_MAJOR_VERSION -lt 110 \  if test $SMLNJ_MAJOR_VERSION -lt 110 \
371    -o $SMLNJ_MINOR_VERSION -lt 72    -o $SMLNJ_MINOR_VERSION -lt 77
372  then  then
373    AC_MSG_ERROR([installation requires SML/NJ version 110.72+])    AC_MSG_ERROR([installation requires SML/NJ version 110.77+ (available from smlnj.org)])
374  fi  fi
375  AC_SUBST(SMLNJ_VERSION)  AC_SUBST(SMLNJ_VERSION)
376    
# Line 130  Line 401 
401  fi  fi
402  AC_SUBST(ML_BUILD)  AC_SUBST(ML_BUILD)
403    
404    dnl ******************** Documentation tools ********************
405    
406    dnl check for doxygen
407    dnl
408    AC_ARG_WITH([doxygen],
409      [AS_HELP_STRING([--with-doxygen=PATH], [specify location of doxygen executable])],
410      [DOXYGEN=$with_doxygen],
411      [DOXYGEN=none])
412    if test x$DOXYGEN = xnone ; then
413      # see if we can find doxygen in the user's path
414      AC_PATH_PROG(DOXYGEN, [doxygen], [none])
415    fi
416    if test x$with_doxygen = xyes -o x$with_doxygen = xno ; then
417      AC_MSG_ERROR([--with-doxygen option must specify directory argument])
418    elif test x$DOXYGEN != xnone -a ! -x $DOXYGEN ; then
419      AC_MSG_ERROR([doxygen not found at $DOXYGEN])
420    elif test x$DOXYGEN != xnone ; then
421    dnl
422    dnl verify that $DOXYGEN is an absolute path
423    dnl
424      case $DOXYGEN in
425        /*) ;;
426        *) AC_MSG_ERROR([--with-doxygen path must be absolute]) ;;
427      esac
428    fi
429    if test $DOXYGEN = xnone ; then
430      DOXYGEN=:
431    fi
432    AC_SUBST(DOXYGEN)
433    
434    dnl check for asciidoc and related tools
435    dnl
436    AC_PATH_PROGS([ASCIIDOC], [asciidoc], [none])
437    AC_PATH_PROGS([A2X], [a2x], [none])
438    AC_PATH_PROGS([HIGHLIGHTER], [pygmentize], [none])
439    AC_PATH_PROGS([DBLATEX], [dblatex], [none])
440    
441    dnl
442    dnl get the path to the asciidoc cofiguration files
443    dnl
444    if test x"$ASCIIDOC" != xnone ; then
445      AC_MSG_CHECKING([path to asciidoc configuration files])
446      ASCIIDOC_CONF_DIR=`$ASCIIDOC -v /dev/null 2>&1 | head -n 1 | sed 's|.*reading: \(.*\)/asciidoc.conf|\1|'`
447      AC_MSG_RESULT([$ASCIIDOC_CONF_DIR])
448    fi
449    AC_SUBST(ASCIIDOC)
450    AC_SUBST(A2X)
451    AC_SUBST(ASCIIDOC_CONF_DIR)
452    AC_SUBST(HIGHLIGHTER)
453    AC_SUBST(DBLATEX)
454    
455    
456  dnl ******************** Paths ********************  dnl ******************** Paths ********************
457    
458  DIDEROT_ROOT=`pwd`  DIDEROT_ROOT=`pwd`
# Line 152  Line 475 
475  AC_SUBST(INSTALL_SMLNJ_WRAPPER)  AC_SUBST(INSTALL_SMLNJ_WRAPPER)
476    
477  dnl  dnl
478    dnl ******************** C compiler properties ********************
479    dnl
480    
481    dnl
482    dnl run the compiler tests in 64-bit mode
483    dnl
484    save_CFLAGS=$CFLAGS
485    CFLAGS="$CFLAGS $CFLAG_MXX"
486    
487    dnl
488    dnl check for gcc builtin atomic operations
489    dnl
490    AC_MSG_CHECKING([for builtin atomic operations])
491    AC_LINK_IFELSE(
492       [AC_LANG_PROGRAM([], [int foo1; int foo2 = __sync_fetch_and_add(&foo1, 1);])],
493       AC_MSG_RESULT(yes)
494       AC_DEFINE(
495        [HAVE_BUILTIN_ATOMIC_OPS], 1,
496        [Define to 1 if gcc compiler provides atomic operations.]),
497       AC_MSG_RESULT(no))
498    
499    AC_C_BIGENDIAN
500    
501    #
502    # determine the sizes of the standard C types
503    AC_CHECK_SIZEOF([int])
504    SIZEOF_C_INT=$ac_cv_sizeof_int
505    AC_CHECK_SIZEOF([long])
506    SIZEOF_C_LONG=$ac_cv_sizeof_long
507    AC_CHECK_SIZEOF([float])
508    SIZEOF_C_FLOAT=$ac_cv_sizeof_float
509    AC_CHECK_SIZEOF([double])
510    SIZEOF_C_DOUBLE=$ac_cv_sizeof_double
511    
512    AC_SUBST(SIZEOF_C_INT)
513    AC_SUBST(SIZEOF_C_LONG)
514    AC_SUBST(SIZEOF_C_FLOAT)
515    AC_SUBST(SIZEOF_C_DOUBLE)
516    
517    dnl
518    dnl restore CFLAGS
519    dnl
520    CFLAGS=$save_CFLAGS
521    
522    dnl
523    dnl ******************** config.h stuff ********************
524    dnl
525    
526    AC_DEFINE_UNQUOTED(DIDEROT_INCLUDE_PATH,["$DIDEROT_SRCDIR/include"], [path for Diderot header files])
527    
528    AH_TOP([
529    /*
530     * COPYRIGHT (c) 2011 Diderot project. (http://diderot-language.cs.uchicago.edu)
531     * All rights reserved.
532     */
533    
534    #ifndef _DIDEROT_CONFIG_H_
535    #define _DIDEROT_CONFIG_H_
536    
537    ])
538    AH_BOTTOM([
539    
540    #ifdef NDEBUG
541    #define STATIC_INLINE   static inline
542    #else
543    #define STATIC_INLINE   static
544    #endif
545    
546    #endif /* !_DIDEROT_CONFIG_H_ */
547    ])
548    
549    dnl
550  dnl ******************** write output ********************  dnl ******************** write output ********************
551  dnl  dnl
552    
 dnl ***** Makefiles *****  
553  AC_CONFIG_FILES(  AC_CONFIG_FILES(
554    src/dnorm/Makefile  dnl
555    dnl ***** Makefiles *****
556      Makefile
557      doc/Makefile
558      doc/man/Makefile
559      src/clinfo/Makefile
560    src/compiler/Makefile    src/compiler/Makefile
561      src/lib/build/Makefile
562      src/lib/build/mk/build.gmk:src/lib/build/mk/build_gmk.in
563      test/MIP/Makefile
564      test/probe/Makefile
565      test/iso2d-polyline/Makefile
566      test/vr-lite-cam/Makefile
567      test/hlic/Makefile
568    dnl
569    dnl ***** SML source files *****
570      src/compiler/nrrd/run-dnorm.sml:src/compiler/nrrd/run-dnorm_sml.in
571      src/compiler/common/paths.sml:src/compiler/common/paths_sml.in
572      src/compiler/common/size-of.sml:src/compiler/common/size-of_sml.in
573  )  )
574    
575    AC_CONFIG_HEADERS(src/include/Diderot/config.h:config/config_h.in)
576    
577  dnl  dnl
578  dnl shell scripts  dnl shell scripts
579  dnl  dnl
580  AC_CONFIG_FILES([  AC_CONFIG_FILES([
581    bin/install-sml-wrapper.sh:config/install-sml-wrapper_sh.in    bin/install-sml-wrapper.sh:config/install-sml-wrapper_sh.in
582  ], [chmod +x bin/install-sml-wrapper.sh])  ], [chmod +x bin/install-sml-wrapper.sh])
583    AC_CONFIG_FILES([
584      src/compiler/gen/file2str/file2str.sh:src/compiler/gen/file2str/file2str_sh.in
585    ], [chmod +x src/compiler/gen/file2str/file2str.sh])
586    AC_CONFIG_FILES([
587      rtest/scripts/run.sh:rtest/scripts/run_sh.in
588    ], [chmod +x rtest/scripts/run.sh])
589    AC_CONFIG_FILES([
590      rtest/scripts/run-one.sh:rtest/scripts/run-one_sh.in
591    ], [chmod +x rtest/scripts/run-one.sh])
592    
593    dnl
594    dnl generate makefiles for runtime library builds
595    dnl
596    dnl usage: MK_BUILD_DIR(<build-dir>, <target-platform>, <options>)
597    dnl
598    AC_DEFUN([MK_BUILD_DIR], [
599        if test ! -d src/lib/build/$1 ; then
600          mkdir src/lib/build/$1
601        fi
602        [sed -e 's,@BUILD_TARGET@,$1,g' \
603          -e 's,@TARGET_PLATFORM@,$2,g' \
604          -e 's,@BUILD_OPTIONS@,$3,g' \
605          src/lib/build/mk/Makefile.in \
606            > src/lib/build/$1/Makefile.in]
607        AC_CONFIG_FILES(src/lib/build/$1/Makefile)
608      ])
609    
610    MK_BUILD_DIR(rt-c-f, c, [float])
611    MK_BUILD_DIR(rt-c-d, c, [double])
612    MK_BUILD_DIR(rt-c-f-debug, c, [float debug])
613    MK_BUILD_DIR(rt-c-d-debug, c, [double debug])
614    MK_BUILD_DIR(rt-c-f-par, parallel, [parallel float])
615    MK_BUILD_DIR(rt-c-d-par, parallel, [parallel double])
616    MK_BUILD_DIR(rt-c-f-par-debug, parallel, [parallel float debug])
617    MK_BUILD_DIR(rt-c-d-par-debug, parallel, [parallel double debug])
618    
619    if test x"$CL_ENABLED" = xtrue ; then
620      MK_BUILD_DIR(rt-cl-f, cl, [float])
621      MK_BUILD_DIR(rt-cl-d, cl, [double])
622      MK_BUILD_DIR(rt-cl-f-debug, cl, [float debug])
623      MK_BUILD_DIR(rt-cl-d-debug, cl, [double debug])
624    fi
625    
626  AC_OUTPUT  AC_OUTPUT

Legend:
Removed from v.123  
changed lines
  Added in v.2729

root@smlnj-gforge.cs.uchicago.edu
ViewVC Help
Powered by ViewVC 1.0.0