OpenCores
no use no use 1/1 no use no use
[or1ksim #5] Fix out-of-tree builds
by Unknown on Jan 25, 2005
Not available!
Hi,

Matjaz alerted me to fact that the execgen.c rule in the Makefile doesn't handle
out-of-tree builds which prevents us from removeing the generated execgen.c from
cvs. This fixes this problem.

ChangeLog:
* Fix out-of-tree builds.

nog.
-------------- next part --------------
--- cpu/or32/Makefile.am 2002-03-06 16:53:23.000000000 +0100
+++ ../or1ksim-ac/cpu/or32/Makefile.am 2005-01-25 18:34:10.000000000 +0100
@@ -30,7 +30,11 @@
generate_SOURCES = or32.c generate.c
BUILT_SOURCES = execgen.c

-execgen.c: generate insnset.c
- ./generate insnset.c execgen.c
-
+execgen.c: generate $(srcdir)/insnset.c
+ ./generate $(srcdir)/insnset.c execgen.c
+
endif
+
+# If the simulator was first built without --enable-simple and then with it,
+# then also remove these two files
+CLEANFILES=execgen.c generate
[or1ksim #5] Fix out-of-tree builds
by Unknown on Jan 26, 2005
Not available!
Your patch fixes the generation of execgen.c (so that it is taken from
$srcdir) but it seams that execgen.c is also taken from source directory
what is wrong. (since the new one is generated in build dir).


Fixed.

ChangeLog:
* Fix out-of-tree builds.

nog.
-------------- next part --------------
--- cpu/or32/Makefile.am 2002-03-06 16:53:23.000000000 +0100
+++ ../or1ksim-ac/cpu/or32/Makefile.am 2005-01-25 18:34:10.000000000 +0100
@@ -30,7 +30,11 @@
generate_SOURCES = or32.c generate.c
BUILT_SOURCES = execgen.c

-execgen.c: generate insnset.c
- ./generate insnset.c execgen.c
-
+execgen.c: generate $(srcdir)/insnset.c
+ ./generate $(srcdir)/insnset.c execgen.c
+
endif
+
+# If the simulator was first built without --enable-simple and then with it,
+# then also remove these two files
+CLEANFILES=execgen.c generate
--- configure.in 2004-10-20 18:02:14.000000000 +0200
+++ ../or1ksim-ac/configure.in 2005-01-26 20:00:15.000000000 +0100
@@ -108,12 +108,13 @@
AC_MSG_RESULT(${enable_fsim-no})

simple_execution="0"
+INCLUDES="-I\${top_builddir}/cpu/$CPU_ARCH"
AC_MSG_CHECKING(whether to use simple execution)
AC_ARG_ENABLE(simple,
[ --enable-simple compiles sim with simple execution], [
case "$enableval" in
- no) simple_execution="0" ;;
- yes) simple_execution="1" ;;
+ no) INCLUDES="-I\${top_builddir}/cpu/$CPU_ARCH" simple_execution="0" ;;
+ yes) INCLUDES="-I\${top_srcdir}/cpu/$CPU_ARCH" simple_execution="1" ;;
esac
])
AC_MSG_RESULT(${enable_simple-no})
@@ -218,12 +219,12 @@
AC_DEFINE(HAS_DEBUG)

dnl yuck
-INCLUDES="-I\${top_srcdir} -I\${top_srcdir}/cpu/common -I\${top_srcdir}/cpu/or1k \
--I\${top_srcdir}/cpu/$CPU_ARCH -I\${top_srcdir}/cache -I\${top_srcdir}/mmu \
+INCLUDES="$INCLUDES -I\${top_srcdir} -I\${top_srcdir}/cpu/common \
+-I\${top_srcdir}/cpu/or1k -I\${top_srcdir}/cache -I\${top_srcdir}/mmu \
-I\${top_srcdir}/bpb -I\${top_srcdir}/peripheral -I\${top_srcdir}/tick \
--I\${top_srcdir}/peripheral/channels \
--I\${top_srcdir}/pm -I\${top_srcdir}/pic -I\${top_srcdir}/debug \
--I\${top_srcdir}/vapi -I\${top_srcdir}/support -I\${top_srcdir}/cuc"
+-I\${top_srcdir}/peripheral/channels -I\${top_srcdir}/pm -I\${top_srcdir}/pic \
+-I\${top_srcdir}/debug -I\${top_srcdir}/vapi -I\${top_srcdir}/support \
+-I\${top_srcdir}/cuc"
AC_SUBST(INCLUDES)

AC_OUTPUT([Makefile bpb/Makefile cache/Makefile cpu/Makefile

no use no use 1/1 no use no use
© copyright 1999-2026 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.