sim/opcodes: Allow use of out of tree cgen source directory
When configuring with '--enbale-cgen-maint' the default for both the opcodes/ and sim/ directories is to assume that the cgen source is within the binutils-gdb source tree as binutils-gdb/cgen/. In the old cvs days, this worked well, as cgen was just another sub-module of the single cvs repository and could easily be checked out within the binutils-gdb directory, and managed by cvs in the normal way. Now that binutils-gdb is in git, while cgen is still in cvs, placing the cgen respository within the binutils-gdb tree is more troublesome, and it would be nice if the two tools could be kept separate. Luckily there is already some initial code in the configure.ac files for both opcodes/ and sim/ to support having cgen be located outside of the binutils-gdb tree, however, this was speculative code written imagining a future where cgen would be built and installed to some location. Right now there is no install support for cgen, and so the configure code in opcodes/ and sim/ doesn't really do anything useful. In this commit I repurpose this code to allow binutils-gdb to be configured so that it can make use of a cgen source directory that is outside of the binutils-gdb tree. With this commit applied it is now possible to configure and build binutils-gdb like this: /path/to/binutils-gdb/src/configure --enable-cgen-maint=/path/to/cgen/src/cgen/ make all-opcodes make -C opcodes run-cgen-all Just in case anyone is still using cgen inside the binutils-gdb tree, I have left the default behaviour of '--enable-cgen-maint' (with no parameter) unchanged, that is it looks for the cgen directory as 'binutils-gdb/cgen/'. opcodes/ChangeLog: * configure.ac (enable-cgen-maint): Support passing path to cgen source tree. * configure: Regenerate. sim/ChangeLog: * common/acinclude.m4 (enable-cgen-maint): Support passing path to cgen source tree. * cris/configure: Regenerate. * frv/configure: Regenerate. * iq2000/configure: Regenerate. * lm32/configure: Regenerate. * m32r/configure: Regenerate. * or1k/configure: Regenerate. * sh64/configure: Regenerate.
This commit is contained in:
parent
884b49e3a9
commit
7fb45a6895
|
@ -1,3 +1,9 @@
|
||||||
|
2018-12-06 Andrew Burgess <andrew.burgess@embecosm.com>
|
||||||
|
|
||||||
|
* configure.ac (enable-cgen-maint): Support passing path to cgen
|
||||||
|
source tree.
|
||||||
|
* configure: Regenerate.
|
||||||
|
|
||||||
2018-12-06 Andrew Burgess <andrew.burgess@embecosm.com>
|
2018-12-06 Andrew Burgess <andrew.burgess@embecosm.com>
|
||||||
|
|
||||||
* disassembler.c (disassemble_init_for_target): Add RISC-V
|
* disassembler.c (disassemble_init_for_target): Add RISC-V
|
||||||
|
|
|
@ -12574,11 +12574,17 @@ if test "${enable_cgen_maint+set}" = set; then :
|
||||||
yes) cgen_maint=yes ;;
|
yes) cgen_maint=yes ;;
|
||||||
no) cgen_maint=no ;;
|
no) cgen_maint=no ;;
|
||||||
*)
|
*)
|
||||||
# argument is cgen install directory (not implemented yet).
|
# Argument is a directory where cgen can be found. In some
|
||||||
# Having a `share' directory might be more appropriate for the .scm,
|
# future world cgen could be installable, but right now this
|
||||||
# .cpu, etc. files.
|
# is not the case. Instead we assume the directory is a path
|
||||||
|
# to the cgen source tree.
|
||||||
cgen_maint=yes
|
cgen_maint=yes
|
||||||
cgendir=${cgen_maint}/lib/cgen
|
if test -r ${enableval}/iformat.scm; then
|
||||||
|
# This looks like a cgen source tree.
|
||||||
|
cgendir=${enableval}
|
||||||
|
else
|
||||||
|
as_fn_error $? "${enableval} doesn't look like a cgen source tree" "$LINENO" 5
|
||||||
|
fi
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
fi
|
fi
|
||||||
|
|
|
@ -109,11 +109,17 @@ AC_ARG_ENABLE(cgen-maint,
|
||||||
yes) cgen_maint=yes ;;
|
yes) cgen_maint=yes ;;
|
||||||
no) cgen_maint=no ;;
|
no) cgen_maint=no ;;
|
||||||
*)
|
*)
|
||||||
# argument is cgen install directory (not implemented yet).
|
# Argument is a directory where cgen can be found. In some
|
||||||
# Having a `share' directory might be more appropriate for the .scm,
|
# future world cgen could be installable, but right now this
|
||||||
# .cpu, etc. files.
|
# is not the case. Instead we assume the directory is a path
|
||||||
|
# to the cgen source tree.
|
||||||
cgen_maint=yes
|
cgen_maint=yes
|
||||||
cgendir=${cgen_maint}/lib/cgen
|
if test -r ${enableval}/iformat.scm; then
|
||||||
|
# This looks like a cgen source tree.
|
||||||
|
cgendir=${enableval}
|
||||||
|
else
|
||||||
|
AC_MSG_ERROR(${enableval} doesn't look like a cgen source tree)
|
||||||
|
fi
|
||||||
;;
|
;;
|
||||||
esac])dnl
|
esac])dnl
|
||||||
AM_CONDITIONAL(CGEN_MAINT, test x${cgen_maint} = xyes)
|
AM_CONDITIONAL(CGEN_MAINT, test x${cgen_maint} = xyes)
|
||||||
|
|
|
@ -1,3 +1,15 @@
|
||||||
|
2018-12-06 Andrew Burgess <andrew.burgess@embecosm.com>
|
||||||
|
|
||||||
|
* common/acinclude.m4 (enable-cgen-maint): Support passing path to
|
||||||
|
cgen source tree.
|
||||||
|
* cris/configure: Regenerate.
|
||||||
|
* frv/configure: Regenerate.
|
||||||
|
* iq2000/configure: Regenerate.
|
||||||
|
* lm32/configure: Regenerate.
|
||||||
|
* m32r/configure: Regenerate.
|
||||||
|
* or1k/configure: Regenerate.
|
||||||
|
* sh64/configure: Regenerate.
|
||||||
|
|
||||||
2018-10-05 Stafford Horne <shorne@gmail.com>
|
2018-10-05 Stafford Horne <shorne@gmail.com>
|
||||||
|
|
||||||
* or1k/cpu.h: Regenerate.
|
* or1k/cpu.h: Regenerate.
|
||||||
|
|
|
@ -851,11 +851,17 @@ AC_ARG_ENABLE(cgen-maint,
|
||||||
yes) cgen_maint=yes ;;
|
yes) cgen_maint=yes ;;
|
||||||
no) cgen_maint=no ;;
|
no) cgen_maint=no ;;
|
||||||
*)
|
*)
|
||||||
# argument is cgen install directory (not implemented yet).
|
# Argument is a directory where cgen can be found. In some
|
||||||
# Having a `share' directory might be more appropriate for the .scm,
|
# future world cgen could be installable, but right now this
|
||||||
# .cpu, etc. files.
|
# is not the case. Instead we assume the directory is a path
|
||||||
cgendir=${cgen_maint}/lib/cgen
|
# to the cgen source tree.
|
||||||
cgen=guile
|
cgen_maint=yes
|
||||||
|
if test -r ${enableval}/iformat.scm; then
|
||||||
|
# This looks like a cgen source tree.
|
||||||
|
cgendir=${enableval}
|
||||||
|
else
|
||||||
|
AC_MSG_ERROR(${enableval} doesn't look like a cgen source tree)
|
||||||
|
fi
|
||||||
;;
|
;;
|
||||||
esac])dnl
|
esac])dnl
|
||||||
dnl AM_CONDITIONAL(CGEN_MAINT, test x${cgen_maint} != xno)
|
dnl AM_CONDITIONAL(CGEN_MAINT, test x${cgen_maint} != xno)
|
||||||
|
|
|
@ -13912,11 +13912,17 @@ if test "${enable_cgen_maint+set}" = set; then :
|
||||||
yes) cgen_maint=yes ;;
|
yes) cgen_maint=yes ;;
|
||||||
no) cgen_maint=no ;;
|
no) cgen_maint=no ;;
|
||||||
*)
|
*)
|
||||||
# argument is cgen install directory (not implemented yet).
|
# Argument is a directory where cgen can be found. In some
|
||||||
# Having a `share' directory might be more appropriate for the .scm,
|
# future world cgen could be installable, but right now this
|
||||||
# .cpu, etc. files.
|
# is not the case. Instead we assume the directory is a path
|
||||||
cgendir=${cgen_maint}/lib/cgen
|
# to the cgen source tree.
|
||||||
cgen=guile
|
cgen_maint=yes
|
||||||
|
if test -r ${enableval}/iformat.scm; then
|
||||||
|
# This looks like a cgen source tree.
|
||||||
|
cgendir=${enableval}
|
||||||
|
else
|
||||||
|
as_fn_error $? "${enableval} doesn't look like a cgen source tree" "$LINENO" 5
|
||||||
|
fi
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
fi
|
fi
|
||||||
|
|
|
@ -13681,11 +13681,17 @@ if test "${enable_cgen_maint+set}" = set; then :
|
||||||
yes) cgen_maint=yes ;;
|
yes) cgen_maint=yes ;;
|
||||||
no) cgen_maint=no ;;
|
no) cgen_maint=no ;;
|
||||||
*)
|
*)
|
||||||
# argument is cgen install directory (not implemented yet).
|
# Argument is a directory where cgen can be found. In some
|
||||||
# Having a `share' directory might be more appropriate for the .scm,
|
# future world cgen could be installable, but right now this
|
||||||
# .cpu, etc. files.
|
# is not the case. Instead we assume the directory is a path
|
||||||
cgendir=${cgen_maint}/lib/cgen
|
# to the cgen source tree.
|
||||||
cgen=guile
|
cgen_maint=yes
|
||||||
|
if test -r ${enableval}/iformat.scm; then
|
||||||
|
# This looks like a cgen source tree.
|
||||||
|
cgendir=${enableval}
|
||||||
|
else
|
||||||
|
as_fn_error $? "${enableval} doesn't look like a cgen source tree" "$LINENO" 5
|
||||||
|
fi
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
fi
|
fi
|
||||||
|
|
|
@ -13678,11 +13678,17 @@ if test "${enable_cgen_maint+set}" = set; then :
|
||||||
yes) cgen_maint=yes ;;
|
yes) cgen_maint=yes ;;
|
||||||
no) cgen_maint=no ;;
|
no) cgen_maint=no ;;
|
||||||
*)
|
*)
|
||||||
# argument is cgen install directory (not implemented yet).
|
# Argument is a directory where cgen can be found. In some
|
||||||
# Having a `share' directory might be more appropriate for the .scm,
|
# future world cgen could be installable, but right now this
|
||||||
# .cpu, etc. files.
|
# is not the case. Instead we assume the directory is a path
|
||||||
cgendir=${cgen_maint}/lib/cgen
|
# to the cgen source tree.
|
||||||
cgen=guile
|
cgen_maint=yes
|
||||||
|
if test -r ${enableval}/iformat.scm; then
|
||||||
|
# This looks like a cgen source tree.
|
||||||
|
cgendir=${enableval}
|
||||||
|
else
|
||||||
|
as_fn_error $? "${enableval} doesn't look like a cgen source tree" "$LINENO" 5
|
||||||
|
fi
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
fi
|
fi
|
||||||
|
|
|
@ -13678,11 +13678,17 @@ if test "${enable_cgen_maint+set}" = set; then :
|
||||||
yes) cgen_maint=yes ;;
|
yes) cgen_maint=yes ;;
|
||||||
no) cgen_maint=no ;;
|
no) cgen_maint=no ;;
|
||||||
*)
|
*)
|
||||||
# argument is cgen install directory (not implemented yet).
|
# Argument is a directory where cgen can be found. In some
|
||||||
# Having a `share' directory might be more appropriate for the .scm,
|
# future world cgen could be installable, but right now this
|
||||||
# .cpu, etc. files.
|
# is not the case. Instead we assume the directory is a path
|
||||||
cgendir=${cgen_maint}/lib/cgen
|
# to the cgen source tree.
|
||||||
cgen=guile
|
cgen_maint=yes
|
||||||
|
if test -r ${enableval}/iformat.scm; then
|
||||||
|
# This looks like a cgen source tree.
|
||||||
|
cgendir=${enableval}
|
||||||
|
else
|
||||||
|
as_fn_error $? "${enableval} doesn't look like a cgen source tree" "$LINENO" 5
|
||||||
|
fi
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
fi
|
fi
|
||||||
|
|
|
@ -13680,11 +13680,17 @@ if test "${enable_cgen_maint+set}" = set; then :
|
||||||
yes) cgen_maint=yes ;;
|
yes) cgen_maint=yes ;;
|
||||||
no) cgen_maint=no ;;
|
no) cgen_maint=no ;;
|
||||||
*)
|
*)
|
||||||
# argument is cgen install directory (not implemented yet).
|
# Argument is a directory where cgen can be found. In some
|
||||||
# Having a `share' directory might be more appropriate for the .scm,
|
# future world cgen could be installable, but right now this
|
||||||
# .cpu, etc. files.
|
# is not the case. Instead we assume the directory is a path
|
||||||
cgendir=${cgen_maint}/lib/cgen
|
# to the cgen source tree.
|
||||||
cgen=guile
|
cgen_maint=yes
|
||||||
|
if test -r ${enableval}/iformat.scm; then
|
||||||
|
# This looks like a cgen source tree.
|
||||||
|
cgendir=${enableval}
|
||||||
|
else
|
||||||
|
as_fn_error $? "${enableval} doesn't look like a cgen source tree" "$LINENO" 5
|
||||||
|
fi
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
fi
|
fi
|
||||||
|
|
|
@ -13788,11 +13788,17 @@ if test "${enable_cgen_maint+set}" = set; then :
|
||||||
yes) cgen_maint=yes ;;
|
yes) cgen_maint=yes ;;
|
||||||
no) cgen_maint=no ;;
|
no) cgen_maint=no ;;
|
||||||
*)
|
*)
|
||||||
# argument is cgen install directory (not implemented yet).
|
# Argument is a directory where cgen can be found. In some
|
||||||
# Having a `share' directory might be more appropriate for the .scm,
|
# future world cgen could be installable, but right now this
|
||||||
# .cpu, etc. files.
|
# is not the case. Instead we assume the directory is a path
|
||||||
cgendir=${cgen_maint}/lib/cgen
|
# to the cgen source tree.
|
||||||
cgen=guile
|
cgen_maint=yes
|
||||||
|
if test -r ${enableval}/iformat.scm; then
|
||||||
|
# This looks like a cgen source tree.
|
||||||
|
cgendir=${enableval}
|
||||||
|
else
|
||||||
|
as_fn_error $? "${enableval} doesn't look like a cgen source tree" "$LINENO" 5
|
||||||
|
fi
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
fi
|
fi
|
||||||
|
|
|
@ -13678,11 +13678,17 @@ if test "${enable_cgen_maint+set}" = set; then :
|
||||||
yes) cgen_maint=yes ;;
|
yes) cgen_maint=yes ;;
|
||||||
no) cgen_maint=no ;;
|
no) cgen_maint=no ;;
|
||||||
*)
|
*)
|
||||||
# argument is cgen install directory (not implemented yet).
|
# Argument is a directory where cgen can be found. In some
|
||||||
# Having a `share' directory might be more appropriate for the .scm,
|
# future world cgen could be installable, but right now this
|
||||||
# .cpu, etc. files.
|
# is not the case. Instead we assume the directory is a path
|
||||||
cgendir=${cgen_maint}/lib/cgen
|
# to the cgen source tree.
|
||||||
cgen=guile
|
cgen_maint=yes
|
||||||
|
if test -r ${enableval}/iformat.scm; then
|
||||||
|
# This looks like a cgen source tree.
|
||||||
|
cgendir=${enableval}
|
||||||
|
else
|
||||||
|
as_fn_error $? "${enableval} doesn't look like a cgen source tree" "$LINENO" 5
|
||||||
|
fi
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in New Issue