source: libcfa/configure.ac@ 2a75572

ADT aaron-thesis arm-eh ast-experimental cleanup-dtors deferred_resn enum forall-pointer-decay jacob/cs343-translation jenkins-sandbox new-ast new-ast-unique-expr no_list persistent-indexer pthread-emulation qualifiedEnum
Last change on this file since 2a75572 was 2b3d6ff, checked in by Thierry Delisle <tdelisle@…>, 7 years ago

Moved ar_flags due to libtool

  • Property mode set to 100644
File size: 2.2 KB
RevLine 
[c59712e]1# -*- Autoconf -*-
2# Process this file with autoconf to produce a configure script.
3
4AC_PREREQ([2.68])
5AC_INIT([cfa-cc],[1.0.0.0],[cforall@plg.uwaterloo.ca])
[38d12e7]6AC_CONFIG_AUX_DIR([automake])
7AC_CONFIG_MACRO_DIRS([automake])
[575a6e5]8AM_SILENT_RULES([yes])
[c59712e]9
[37fe352]10m4_include([../automake/cfa.m4])
11
[c59712e]12AM_INIT_AUTOMAKE([subdir-objects])
13
[575a6e5]14# don't use the default CFLAGS as they unconditonnaly add -O2
15: ${CFLAGS=""}
16
[2b3d6ff]17# define this to override
18AR_FLAGS="cr"
19
[c59712e]20# Allow program name tansformation
21# will fill program_transform_name with appropriate sed regex
22AC_ARG_PROGRAM
23
[37fe352]24AC_ARG_VAR(ARCHITECTURE, [The architecture to use when building libcfa])
[c59712e]25AC_ARG_VAR(CONFIGURATION, [The configuration to use when building libcfa, options are: deubg, nodebug, nolib (prelude-only)])
[ff1e0f38]26AC_ARG_VAR(DRIVER_DIR, [The path to the cforall driver directory])
[c6bbcdb]27AC_ARG_VAR(CFA_VERSION, [The long version of cfa])
[ff1e0f38]28
29CFACC=${DRIVER_DIR}cfa
30CFACPP=${DRIVER_DIR}cfa-cpp
31AC_SUBST(CFACC)
32AC_SUBST(CFACPP)
[c6bbcdb]33AC_SUBST(CFA_VERSION)
[ff1e0f38]34
[575a6e5]35#==============================================================================
36#Handle specific flags
[37fe352]37case $ARCHITECTURE in
38 "x64" ) ARCH_FLAGS="-m64";;
39 "x86" ) ARCH_FLAGS="-m32";;
40 "arm" ) ARCH_FLAGS="";;
41esac
[ff1e0f38]42
[37fe352]43AC_SUBST(ARCH_FLAGS)
[ff1e0f38]44
[575a6e5]45case $CONFIGURATION in
46 "debug" )
47 CONFIG_CFLAGS="-O0 -g"
48 CONFIG_CFAFLAGS="-debug"
[e523b07]49 CONFIG_BUILDLIB="yes"
[575a6e5]50 ;;
51 "nodebug" )
52 CONFIG_CFLAGS="-O2 -s"
53 CONFIG_CFAFLAGS="-nodebug"
[e523b07]54 CONFIG_BUILDLIB="yes"
[575a6e5]55 ;;
56 "nolib" )
[e523b07]57 CONFIG_CFLAGS="-O2 -s"
58 CONFIG_CFAFLAGS="-nodebug"
59 CONFIG_BUILDLIB="no"
[575a6e5]60 ;;
61esac
62
63AC_SUBST(CONFIG_CFLAGS)
64AC_SUBST(CONFIG_CFAFLAGS)
[e523b07]65AC_SUBST(CONFIG_BUILDLIB)
66
67AM_CONDITIONAL([BUILDLIB], [test "x${CONFIG_BUILDLIB}" = "xyes"])
[575a6e5]68
[37fe352]69#==============================================================================
70#Trasforming cc1 will break compilation
71M4CFA_PROGRAM_NAME
[ff1e0f38]72
[37fe352]73#==============================================================================
74# Installation paths
75M4CFA_PARSE_PREFIX
[c59712e]76
77# Checks for programs.
[38d12e7]78LT_INIT
79
[c59712e]80AC_PROG_CXX
81AC_PROG_CC
82AM_PROG_AS
83AC_PROG_INSTALL
84AC_PROG_MAKE_SET
85
86AC_CONFIG_FILES([
87 Makefile
88 src/Makefile
89 prelude/Makefile
90 ])
91
92AC_OUTPUT()
93
94# Final text
95AC_MSG_RESULT(Cforall library configuraton completed. Type "make -j 8 install".)
Note: See TracBrowser for help on using the repository browser.