* expr.c (operand <case '$'>): Use DOLLAR_AMBIGU rather than flag_mri_m68k
[deliverable/binutils-gdb.git] / opcodes / cgen.sh
index a9483bdb972f476e4f9af9d0fea84d5287ce02ce..1f331be546f81aca043e610f8c777fcb1834fd53 100644 (file)
@@ -1,7 +1,7 @@
 #! /bin/sh
 # CGEN generic assembler support code.
 #
-#  Copyright 2001 Free Software Foundation, Inc.
+#  Copyright 2000, 2003, 2005 Free Software Foundation, Inc.
 #
 #   This file is part of the GNU Binutils and GDB, the GNU debugger.
 #
 #
 #   You should have received a copy of the GNU General Public License along
 #   with this program; if not, write to the Free Software Foundation, Inc.,
-#   59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
+#   51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.  */
 #
 # Generate CGEN opcode files: arch-desc.[ch], arch-opc.[ch],
 # arch-asm.c, arch-dis.c, arch-opinst.c, arch-ibld.[ch].
 #
 # Usage:
-# cgen.sh action srcdir cgen cgendir cgenflags arch prefix options
+# cgen.sh action srcdir cgen cgendir cgenflags arch prefix \
+#         arch-file opc-file options [extrafiles]
 #
 # ACTION is currently always "opcodes". It exists to be consistent with the 
 # simulator.
-# OPTIONS is comma separated list of options:
+# ARCH is the name of the architecture.
+# It is substituted into @arch@ and @ARCH@ in the generated files.
+# PREFIX is both the generated file prefix and is substituted into
+# @prefix@ in the generated files.
+# ARCH-FILE is the name of the .cpu file (including path).
+# OPC-FILE is the name of the .opc file (including path).
+# OPTIONS is comma separated list of options (???).
+# EXTRAFILES is a space separated list (1 arg still) of extra files to build:
 #      - opinst - arch-opinst.c is being made, causes semantic analysis
 #
 # We store the generated files in the source directory until we decide to
@@ -39,16 +47,18 @@ set -e
 
 action=$1
 srcdir=$2
-cgen=$3
+cgen="$3"
 cgendir=$4
 cgenflags=$5
 arch=$6
 prefix=$7
-options=$8
+archfile=$8
+opcfile=$9
+shift ; options=$9
 
 # List of extra files to build.
 # Values: opinst (only 1 extra file at present)
-extrafiles=$9
+shift ; extrafiles=$9
 
 rootdir=${srcdir}/..
 
@@ -83,12 +93,13 @@ opcodes)
        rm -f tmp-dis.c tmp-dis.in1
 
        # Run CGEN.
-       ${cgen} -s ${cgendir}/cgen-opc.scm \
+       ${cgen} ${cgendir}/cgen-opc.scm \
                -s ${cgendir} \
                ${cgenflags} \
                -f "${options}" \
                -m all \
-               -a ${arch} \
+               -a ${archfile} \
+               -OPC ${opcfile} \
                -H tmp-desc.h1 \
                -C tmp-desc.c1 \
                -O tmp-opc.h1 \
This page took 0.023787 seconds and 4 git commands to generate.