Changeset c59712e for configure


Ignore:
Timestamp:
Aug 3, 2018, 11:25:46 AM (4 years ago)
Author:
Thierry Delisle <tdelisle@…>
Branches:
aaron-thesis, arm-eh, cleanup-dtors, deferred_resn, demangler, enum, forall-pointer-decay, jacob/cs343-translation, jenkins-sandbox, master, new-ast, new-ast-unique-expr, no_list, persistent-indexer, pthread-emulation, qualifiedEnum
Children:
ff1e0f38
Parents:
25a9b5a
Message:

Parent make now seems to properly call libcfa

File:
1 edited

Legend:

Unmodified
Added
Removed
  • configure

    r25a9b5a rc59712e  
    665665CXX
    666666CFA_FLAGS
    667 MACHINE_TYPE
    668 host_os
    669 host_vendor
    670 host_cpu
    671 host
    672 build_os
    673 build_vendor
    674 build_cpu
    675 build
    676667BUILD_IN_TREE_FLAGS
    677668BUILD_IN_TREE_FLAGS_NOLIB
     
    683674CFA_INCDIR
    684675CFA_PREFIX
     676CFA_BACKEND_CC
     677BACKEND_CC
    685678DOendif
    686679DOifskipcompile
    687 BUILD_CONCURRENCY_FALSE
    688 BUILD_CONCURRENCY_TRUE
    689 BUILD_NO_LIB_FALSE
    690 BUILD_NO_LIB_TRUE
    691 BUILD_DEBUG_FALSE
    692 BUILD_DEBUG_TRUE
    693 BUILD_RELEASE_FALSE
    694 BUILD_RELEASE_TRUE
    695 CFA_BACKEND_CC
    696 BACKEND_CC
     680LIBCFA_TARGET_MAKEFILES
     681LIBCFA_TARGET_DIRS
     682TARGET_HOSTS
     683host_os
     684host_vendor
     685host_cpu
     686host
     687build_os
     688build_vendor
     689build_cpu
     690build
    697691CFA_NAME
    698692am__untar
     
    767761enable_silent_rules
    768762with_cfa_name
     763with_target_hosts
    769764with_backend_compiler
    770 enable_target_release
    771 enable_target_debug
    772 enable_threading
    773765enable_dependency_tracking
    774766'
     
    14201412  --enable-silent-rules   less verbose build output (undo: "make V=1")
    14211413  --disable-silent-rules  verbose build output (undo: "make V=0")
    1422   --enable-target-release Build and install the release target
    1423   --enable-target-debug   Build and install the debug target
    1424   --enable-threading      Build and install libcfa with threading support
    1425                           (Enabled by default)
    14261414  --enable-dependency-tracking
    14271415                          do not reject slow dependency extractors
     
    14331421  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
    14341422  --with-cfa-name=NAME     NAME too which cfa will be installed
     1423  --with-target-hosts=HOSTS     HOSTS comma seperated list of hosts to build for, format ARCH:debug|nodebug|nolib
    14351424  --with-backend-compiler=PROGRAM     PROGRAM that performs the final code compilation (must be gcc-compatible)
    14361425
     
    30773066
    30783067
     3068#==============================================================================
    30793069#Trasforming cc1 will break compilation
    30803070if test "${program_transform_name}" = ""; then
     
    30833073fi
    30843074
     3075#Define the new name of the installed command
    30853076
    30863077# Check whether --with-cfa-name was given.
     
    30923083
    30933084
    3094 #Define the new name of the installed command
    30953085CFA_NAME=${cfa_name}
    30963086
     3087
     3088#==============================================================================
     3089# handle the list of hosts to build for
     3090for var in $ac_configure_args
     3091do
     3092        #strip quotes surrouding values
     3093        var=$(echo $var | sed s/\'//g)
     3094        case $var in
     3095                # skip cross compilation related arguments
     3096                --host=*) ;; host_alias=*) ;; --build=*) ;; build_alias=*) ;; --target=*) ;; target_alias=*) ;;
     3097
     3098                # append all other arguments to the sub configure arguments
     3099                *) LIBCFA_GENERAL_ARGS="${LIBCFA_GENERAL_ARGS} $var";;
     3100        esac
     3101done
     3102
     3103echo $LIBCFA_GENERAL_ARGS
     3104
     3105#==============================================================================
     3106# handle the list of hosts to build for
     3107# Make sure we can run config.sub.
     3108$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
     3109  as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
     3110
     3111{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
     3112$as_echo_n "checking build system type... " >&6; }
     3113if ${ac_cv_build+:} false; then :
     3114  $as_echo_n "(cached) " >&6
     3115else
     3116  ac_build_alias=$build_alias
     3117test "x$ac_build_alias" = x &&
     3118  ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
     3119test "x$ac_build_alias" = x &&
     3120  as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
     3121ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
     3122  as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
     3123
     3124fi
     3125{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
     3126$as_echo "$ac_cv_build" >&6; }
     3127case $ac_cv_build in
     3128*-*-*) ;;
     3129*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
     3130esac
     3131build=$ac_cv_build
     3132ac_save_IFS=$IFS; IFS='-'
     3133set x $ac_cv_build
     3134shift
     3135build_cpu=$1
     3136build_vendor=$2
     3137shift; shift
     3138# Remember, the first character of IFS is used to create $*,
     3139# except with old shells:
     3140build_os=$*
     3141IFS=$ac_save_IFS
     3142case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
     3143
     3144
     3145{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
     3146$as_echo_n "checking host system type... " >&6; }
     3147if ${ac_cv_host+:} false; then :
     3148  $as_echo_n "(cached) " >&6
     3149else
     3150  if test "x$host_alias" = x; then
     3151  ac_cv_host=$ac_cv_build
     3152else
     3153  ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
     3154    as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
     3155fi
     3156
     3157fi
     3158{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
     3159$as_echo "$ac_cv_host" >&6; }
     3160case $ac_cv_host in
     3161*-*-*) ;;
     3162*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
     3163esac
     3164host=$ac_cv_host
     3165ac_save_IFS=$IFS; IFS='-'
     3166set x $ac_cv_host
     3167shift
     3168host_cpu=$1
     3169host_vendor=$2
     3170shift; shift
     3171# Remember, the first character of IFS is used to create $*,
     3172# except with old shells:
     3173host_os=$*
     3174IFS=$ac_save_IFS
     3175case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
     3176
     3177
     3178
     3179default_target="${host_cpu}:debug, ${host_cpu}:nodebug"
     3180
     3181# Check whether --with-target-hosts was given.
     3182if test "${with_target_hosts+set}" = set; then :
     3183  withval=$with_target_hosts; target_hosts=$withval
     3184else
     3185  target_hosts=${default_target}
     3186fi
     3187
     3188
     3189TARGET_HOSTS=${target_hosts}
     3190
     3191
     3192for i in $(echo $target_hosts | sed "s/,/ /g")
     3193do
     3194        # call your procedure/other scripts here below
     3195        lib_arch=$(echo $i | sed -r "s/:(.*)//g")
     3196        lib_config=$(echo $i | sed -r "s/(.*)://g")
     3197        lib_dir="libcfa-${lib_arch}-${lib_config}"
     3198
     3199        LIBCFA_TARGET_DIRS="${LIBCFA_TARGET_DIRS} ${lib_dir}"
     3200        LIBCFA_TARGET_MAKEFILES="${LIBCFA_TARGET_MAKEFILES} ${lib_dir}/Makefile"
     3201
     3202        mkdir -p libcfa-${lib_arch}-${lib_config}
     3203        echo -n "${LIBCFA_GENERAL_ARGS} " > libcfa-${lib_arch}-${lib_config}/config.data
     3204        echo -n "--host=${lib_arch} " >> libcfa-${lib_arch}-${lib_config}/config.data
     3205        echo -n "CONFIGURATION=${lib_config}" >> libcfa-${lib_arch}-${lib_config}/config.data
     3206done
     3207
     3208
     3209
     3210
     3211
     3212#==============================================================================
     3213# version information
    30973214
    30983215rm -f version
     
    31463263
    31473264
    3148 # Installation paths
    3149 
     3265#==============================================================================
     3266# HACK to be able to use conditionnals inside makefiles
     3267DOifskipcompile='ifeq ($(skipcompile),yes)
     3268else'
     3269
     3270
     3271
     3272DOendif='endif'
     3273
     3274
     3275
     3276#==============================================================================
     3277# backend compiler implementation
    31503278
    31513279# Check whether --with-backend-compiler was given.
     
    31573285
    31583286if test "x$backendcompiler" != "x"; then
    3159         BACKEND_CC=${backendcompiler}
    3160 else
    3161         # Extract the first word of "gcc", so it can be a program name with args.
     3287       BACKEND_CC=${backendcompiler}
     3288else
     3289       # Extract the first word of "gcc", so it can be a program name with args.
    31623290set dummy gcc; ac_word=$2
    31633291{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
     
    31983326fi
    31993327
    3200         # check gcc installed
    3201         if test "x$BACKEND_CC" = "x"; then
    3202                 as_fn_error $? "some version of gcc is needed. Get it at ftp://ftp.gnu.org" "$LINENO" 5
    3203                 exit 1
    3204         fi
     3328       # check gcc installed
     3329       if test "x$BACKEND_CC" = "x"; then
     3330               as_fn_error $? "some version of gcc is needed. Get it at ftp://ftp.gnu.org" "$LINENO" 5
     3331               exit 1
     3332       fi
    32053333fi
    32063334
     
    32113339
    32123340
    3213 
    3214 
    3215 # Check whether --enable-target-release was given.
    3216 if test "${enable_target_release+set}" = set; then :
    3217   enableval=$enable_target_release;
    3218 fi
    3219 
    3220 # Check whether --enable-target-debug was given.
    3221 if test "${enable_target_debug+set}" = set; then :
    3222   enableval=$enable_target_debug;
    3223 fi
    3224 
    3225 # Check whether --enable-threading was given.
    3226 if test "${enable_threading+set}" = set; then :
    3227   enableval=$enable_threading; case "${enableval}" in
    3228   yes) build_threading="yes" ;;
    3229   no)  build_threading="no" ;;
    3230   *) as_fn_error $? "bad value ${enableval} for --enable-debug" "$LINENO" 5 ;;
    3231 esac
    3232 else
    3233   build_threading="yes"
    3234 fi
    3235 
    3236 
    3237 case "$enable_target_release" in
    3238         yes)
    3239                 case "$enable_target_debug" in
    3240                         yes)
    3241                                 build_release="yes"
    3242                                 build_debug="yes"
    3243                                 ;;
    3244                         no)
    3245                                 build_release="yes"
    3246                                 build_debug="no"
    3247                                 ;;
    3248                         *)
    3249                                 build_release="yes"
    3250                                 build_debug="no"
    3251                                 ;;
    3252                 esac
    3253                 ;;
    3254         no)
    3255                 case "$enable_target_debug" in
    3256                         yes)
    3257                                 build_release="no"
    3258                                 build_debug="yes"
    3259                                 ;;
    3260                         no)
    3261                                 build_release="no"
    3262                                 build_debug="no"
    3263                                 ;;
    3264                         *)
    3265                                 build_release="no"
    3266                                 build_debug="yes"
    3267                                 ;;
    3268                 esac
    3269                 ;;
    3270         *)
    3271                 case "$enable_target_debug" in
    3272                         yes)
    3273                                 build_release="no"
    3274                                 build_debug="yes"
    3275                                 ;;
    3276                         no)
    3277                                 build_release="yes"
    3278                                 build_debug="no"
    3279                                 ;;
    3280                         *)
    3281                                 build_release="yes"
    3282                                 build_debug="yes"
    3283                                 ;;
    3284                 esac
    3285                 ;;
    3286 esac
    3287 
    3288  if test "x$build_release" = "xyes"; then
    3289   BUILD_RELEASE_TRUE=
    3290   BUILD_RELEASE_FALSE='#'
    3291 else
    3292   BUILD_RELEASE_TRUE='#'
    3293   BUILD_RELEASE_FALSE=
    3294 fi
    3295 
    3296  if test "x$build_debug" = "xyes"; then
    3297   BUILD_DEBUG_TRUE=
    3298   BUILD_DEBUG_FALSE='#'
    3299 else
    3300   BUILD_DEBUG_TRUE='#'
    3301   BUILD_DEBUG_FALSE=
    3302 fi
    3303 
    3304  if test "x$build_release$build_debug" = "xnono"; then
    3305   BUILD_NO_LIB_TRUE=
    3306   BUILD_NO_LIB_FALSE='#'
    3307 else
    3308   BUILD_NO_LIB_TRUE='#'
    3309   BUILD_NO_LIB_FALSE=
    3310 fi
    3311 
    3312  if test "x$build_threading" = "xyes"; then
    3313   BUILD_CONCURRENCY_TRUE=
    3314   BUILD_CONCURRENCY_FALSE='#'
    3315 else
    3316   BUILD_CONCURRENCY_TRUE='#'
    3317   BUILD_CONCURRENCY_FALSE=
    3318 fi
    3319 
    3320 
    3321 DOifskipcompile='ifeq ($(skipcompile),yes)
    3322 else'
    3323 
    3324 
    3325 
    3326 DOendif='endif'
    3327 
    3328 
    3329 
     3341#==============================================================================
     3342# Installation paths
    33303343if test "x$prefix" = "xNONE"; then
    33313344        cfa_prefix=${ac_default_prefix}
     
    33803393
    33813394
     3395#==============================================================================
    33823396# Create variables for commonly used targets
    33833397DRIVER_DIR='$(top_builddir)/driver'
     
    34033417
    34043418
     3419#==============================================================================
    34053420# Flag variables needed to build in tree
    34063421LIBCFA_SRC='$(top_srcdir)/libcfa/src'
     
    34113426
    34123427
    3413 # Make sure we can run config.sub.
    3414 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
    3415   as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
    3416 
    3417 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
    3418 $as_echo_n "checking build system type... " >&6; }
    3419 if ${ac_cv_build+:} false; then :
    3420   $as_echo_n "(cached) " >&6
    3421 else
    3422   ac_build_alias=$build_alias
    3423 test "x$ac_build_alias" = x &&
    3424   ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
    3425 test "x$ac_build_alias" = x &&
    3426   as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
    3427 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
    3428   as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
    3429 
    3430 fi
    3431 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
    3432 $as_echo "$ac_cv_build" >&6; }
    3433 case $ac_cv_build in
    3434 *-*-*) ;;
    3435 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
    3436 esac
    3437 build=$ac_cv_build
    3438 ac_save_IFS=$IFS; IFS='-'
    3439 set x $ac_cv_build
    3440 shift
    3441 build_cpu=$1
    3442 build_vendor=$2
    3443 shift; shift
    3444 # Remember, the first character of IFS is used to create $*,
    3445 # except with old shells:
    3446 build_os=$*
    3447 IFS=$ac_save_IFS
    3448 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
    3449 
    3450 
    3451 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
    3452 $as_echo_n "checking host system type... " >&6; }
    3453 if ${ac_cv_host+:} false; then :
    3454   $as_echo_n "(cached) " >&6
    3455 else
    3456   if test "x$host_alias" = x; then
    3457   ac_cv_host=$ac_cv_build
    3458 else
    3459   ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
    3460     as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
    3461 fi
    3462 
    3463 fi
    3464 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
    3465 $as_echo "$ac_cv_host" >&6; }
    3466 case $ac_cv_host in
    3467 *-*-*) ;;
    3468 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
    3469 esac
    3470 host=$ac_cv_host
    3471 ac_save_IFS=$IFS; IFS='-'
    3472 set x $ac_cv_host
    3473 shift
    3474 host_cpu=$1
    3475 host_vendor=$2
    3476 shift; shift
    3477 # Remember, the first character of IFS is used to create $*,
    3478 # except with old shells:
    3479 host_os=$*
    3480 IFS=$ac_save_IFS
    3481 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
    3482 
    3483 
    3484 MACHINE_TYPE=$host_cpu
    3485 
    3486 
    3487 if ! test "$host_cpu" = "$build_cpu"; then
    3488         case $host_cpu in
    3489                 i386)
    3490                         CFLAGS+=" -m32 "
    3491                         CXXFLAGS+=" -m32 "
    3492                         CFAFLAGS+=" -m32 "
    3493                         LDFLAGS+=" -m32 "
    3494                         ;;
    3495                 i686)
    3496                         CFLAGS+=" -m32 "
    3497                   CXXFLAGS+=" -m32 "
    3498                   CFAFLAGS+=" -m32 "
    3499                   LDFLAGS+=" -m32 "
    3500                         ;;
    3501                 x86_64)
    3502                         CFLAGS+=" -m64 "
    3503                         CXXFLAGS+=" -m64 "
    3504                         CFAFLAGS+=" -m64 "
    3505                         LDFLAGS+=" -m64 "
    3506                         ;;
    3507         esac
    3508 fi
    3509 
     3428#==============================================================================
     3429# CAFLAGS
    35103430
    35113431cat >>confdefs.h <<_ACEOF
     
    35163436
    35173437
     3438#==============================================================================
    35183439# Checks for programs.
    35193440ac_ext=cpp
     
    62986219
    62996220
    6300 ac_config_files="$ac_config_files Makefile driver/Makefile src/Makefile benchmark/Makefile tests/Makefile tests/preempt_longrun/Makefile libcfa/prelude/Makefile libcfa/src/Makefile tools/Makefile tools/prettyprinter/Makefile"
     6221#==============================================================================
     6222ac_config_files="$ac_config_files Makefile driver/Makefile src/Makefile benchmark/Makefile tests/Makefile tests/preempt_longrun/Makefile tools/Makefile tools/prettyprinter/Makefile"
    63016223
    63026224
     
    64316353fi
    64326354
    6433 if test -z "${BUILD_RELEASE_TRUE}" && test -z "${BUILD_RELEASE_FALSE}"; then
    6434   as_fn_error $? "conditional \"BUILD_RELEASE\" was never defined.
    6435 Usually this means the macro was only invoked conditionally." "$LINENO" 5
    6436 fi
    6437 if test -z "${BUILD_DEBUG_TRUE}" && test -z "${BUILD_DEBUG_FALSE}"; then
    6438   as_fn_error $? "conditional \"BUILD_DEBUG\" was never defined.
    6439 Usually this means the macro was only invoked conditionally." "$LINENO" 5
    6440 fi
    6441 if test -z "${BUILD_NO_LIB_TRUE}" && test -z "${BUILD_NO_LIB_FALSE}"; then
    6442   as_fn_error $? "conditional \"BUILD_NO_LIB\" was never defined.
    6443 Usually this means the macro was only invoked conditionally." "$LINENO" 5
    6444 fi
    6445 if test -z "${BUILD_CONCURRENCY_TRUE}" && test -z "${BUILD_CONCURRENCY_FALSE}"; then
    6446   as_fn_error $? "conditional \"BUILD_CONCURRENCY\" was never defined.
    6447 Usually this means the macro was only invoked conditionally." "$LINENO" 5
    6448 fi
    64496355if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
    64506356  as_fn_error $? "conditional \"AMDEP\" was never defined.
     
    70676973    "tests/Makefile") CONFIG_FILES="$CONFIG_FILES tests/Makefile" ;;
    70686974    "tests/preempt_longrun/Makefile") CONFIG_FILES="$CONFIG_FILES tests/preempt_longrun/Makefile" ;;
    7069     "libcfa/prelude/Makefile") CONFIG_FILES="$CONFIG_FILES libcfa/prelude/Makefile" ;;
    7070     "libcfa/src/Makefile") CONFIG_FILES="$CONFIG_FILES libcfa/src/Makefile" ;;
    70716975    "tools/Makefile") CONFIG_FILES="$CONFIG_FILES tools/Makefile" ;;
    70726976    "tools/prettyprinter/Makefile") CONFIG_FILES="$CONFIG_FILES tools/prettyprinter/Makefile" ;;
     
    78327736
    78337737
    7834 if test -z "$BUILD_RELEASE_TRUE"; then :
    7835   if test -z "$BUILD_DEBUG_TRUE"; then :
    7836   { $as_echo "$as_me:${as_lineno-$LINENO}: Building libcfa for target: release & debug" >&5
    7837 $as_echo "$as_me: Building libcfa for target: release & debug" >&6;}
    7838 else
    7839   { $as_echo "$as_me:${as_lineno-$LINENO}: Building libcfa for target: release" >&5
    7840 $as_echo "$as_me: Building libcfa for target: release" >&6;}
    7841 fi
    7842 else
    7843   if test -z "$BUILD_DEBUG_TRUE"; then :
    7844   { $as_echo "$as_me:${as_lineno-$LINENO}: Building libcfa for target: debug" >&5
    7845 $as_echo "$as_me: Building libcfa for target: debug" >&6;}
    7846 else
    7847   { $as_echo "$as_me:${as_lineno-$LINENO}: Running cfa without libcfa" >&5
    7848 $as_echo "$as_me: Running cfa without libcfa" >&6;}
    7849 fi
    7850 fi
    7851 
    78527738# Final text
    78537739{ $as_echo "$as_me:${as_lineno-$LINENO}: result: Cforall configuraton completed. Type \"make -j 8 install\"." >&5
Note: See TracChangeset for help on using the changeset viewer.