aboutsummaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorPalmer Dabbelt <palmer.dabbelt@eecs.berkeley.edu>2015-03-03 11:07:51 -0800
committerPalmer Dabbelt <palmer.dabbelt@eecs.berkeley.edu>2015-03-03 12:00:44 -0800
commitc7ce3794605d2472e5841c40b01beb1d5f51a73b (patch)
tree2f3502b9485c03b60fec8b76a13e4c787cace632 /configure.ac
parenta55f252d1090e02878bef8132d91b2b3290c105f (diff)
downloadriscv-gnu-toolchain-c7ce3794605d2472e5841c40b01beb1d5f51a73b.zip
riscv-gnu-toolchain-c7ce3794605d2472e5841c40b01beb1d5f51a73b.tar.gz
riscv-gnu-toolchain-c7ce3794605d2472e5841c40b01beb1d5f51a73b.tar.bz2
Add "--with-xlen" to autoconf
This allows users to set the register bitwidth via an autoconf option rather than an environment variable.
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac7
1 files changed, 7 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index 6bc2458..185239f 100644
--- a/configure.ac
+++ b/configure.ac
@@ -47,6 +47,13 @@ AS_IF([test "x$enable_linux" != xno],
[AC_SUBST(default_target, linux)],
[AC_SUBST(default_target, newlib)])
+AC_ARG_WITH(xlen,
+ [AS_HELP_STRING([--with-xlen=XLEN],
+ [Set XLEN, the X-register bit width (default is 64)])],
+ AC_SUBST(XLEN, $withval),
+ AC_SUBST(XLEN, 64)
+ )
+
AC_CONFIG_FILES([Makefile])
AC_CONFIG_FILES([scripts/wrapper/awk], [chmod +x scripts/wrapper/awk])
AC_CONFIG_FILES([scripts/wrapper/sed], [chmod +x scripts/wrapper/sed])