Changeset 37fe352 for automake/cfa.m4


Ignore:
Timestamp:
Aug 5, 2018, 4:11:41 PM (5 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:
28582b2
Parents:
4dcaed2
Message:

Added proper multi-lib handling, tests still do not work and arm support is broken

File:
1 edited

Legend:

Unmodified
Added
Removed
  • automake/cfa.m4

    r4dcaed2 r37fe352  
    2626
    2727        if test "$libdir" = '${exec_prefix}/lib'; then
    28                 cfa_libdir="${cfa_prefix}/lib/${cfa_name}"
     28                cfa_libdir="${cfa_prefix}/lib/${cfa_name}/${ARCHITECTURE}${CONFIGURATION}"
    2929        else
    30                 cfa_libdir=${libdir}
     30                cfa_libdir="${libdir}/${ARCHITECTURE}${CONFIGURATION}"
    3131        fi
    3232        AC_DEFINE_UNQUOTED(CFA_LIBDIR, "${cfa_libdir}", [Location of cc1 and cfa-cpp commands.])
    3333        AC_SUBST(CFA_LIBDIR, ${cfa_libdir})
    3434])
     35
     36m4_define([M4CFA_PROGRAM_NAME], [
     37        if test "${program_transform_name}" = ""; then
     38        AC_MSG_ERROR([Program transform not supported.
     39                        Use --with-cfa-name='[[Desired name here]]' instead])
     40        fi
     41
     42        #Define the new name of the installed command
     43        AC_ARG_WITH(cfa-name,
     44                [  --with-cfa-name=NAME     NAME too which cfa will be installed],
     45                cfa_name=$withval, cfa_name="cfa")
     46
     47        AC_SUBST(CFA_NAME, ${cfa_name})
     48])
     49
     50AC_DEFUN([M4CFA_CANNON_CPU], [
     51        case $arch_name in
     52                "x64"        ) cannon_arch_name="x64";;
     53                "x86-64"     ) cannon_arch_name="x64";;
     54                "x86_64"     ) cannon_arch_name="x64";;
     55                "x86"        ) cannon_arch_name="x86";;
     56                "i386"       ) cannon_arch_name="x86";;
     57                "i486"       ) cannon_arch_name="x86";;
     58                "i686"       ) cannon_arch_name="x86";;
     59                "Intel 80386") cannon_arch_name="x86";;
     60                "arm"        ) cannon_arch_name="arm";;
     61                "ARM"        ) cannon_arch_name="arm";;
     62                *)
     63                >&2 echo "Unkown architecture " $arch_name;
     64                exit 1
     65                ;;
     66        esac
     67])
Note: See TracChangeset for help on using the changeset viewer.