Update to 0.5.1rc1
* Compiled but not working properly for me. vmlinux kernel that is built from openrisc.net Linux git repository does not boot. Infinite(?) ERR: 8-bit program load out of memory area: [hexnumer]. * Linux/openrisc does not for me, so network support code is not verified. * For the record, 0.2.0 also does not works for me. Changelog: New in release 0.5.1rc1 ======================= New features (shouldn't be there during a release cycle, but prompted by debug needs elsewhere in the tool chain). New option --trace provides a one line dump of instruction executed and any register or memory location changed after each instruction. A new configuration option "use_nmi" is added to the programmable interrupt controller (PIC). This causes interrupt lines 0 and 1 to be non-maskable, but only in the sense that the corresponding bits in PICMR are hard-wired to 1. New config setting for memory initialization "exitnops" fills memory with "l.nop 1", which will cause the simulator to exit. Good for tracking pointer corruption. New l.nop opcodes to turn instruction tracing on and off. Good for debugging applications. New l.nop opcode to return a random number. Good for applications (like the Linux kernel) which need access to the host entropy to ensure randomness. New l.nop opcode to identify that this is an Or1ksim session. Allows applications to determine if they are running on Or1ksim or hardware. No bugs are fixed. The following bugs are outstanding * Bug 1973: Or1ksim needs PIC tests. * But 1931: Or1ksim needs test for l.nop opcodes. * Bug 1823: Configuration file error line numbers are wrong. * Bug 1822: ATA configuration is broken. Documented in user guide. * Bug 1758: Memory controller issues. Workaround in the user guide. New in release 0.5.0rc3 ======================= No bugs are fixed. The following bugs are outstanding * Bug 1823: Configuration file error line numbers are wrong. * Bug 1822: ATA configuration is broken. Documented in user guide. * Bug 1758: Memory controller issues. Workaround in the user guide. New in release 0.5.0rc2 ======================= No new features. This is purely bug fixes post-0.5.0rc1. The following bugs are fixed. * Bug 1847: Build issues with RSP server (duplicate of 1815). * Bug 1846: Casting errors. * Bug 1824: Memory controller issue (marked as duplicate of Bug 1758). * Bug 1816: Error message when target not set is obscure (duplicate of 1813). * Bug 1815: Build errors with RSP server. * Bug 1813: "make check" fails before installation. The following bugs are outstanding * Bug 1823: Configuration file error line numbers are wrong. * Bug 1822: ATA configuration is broken. Documented in user guide. * Bug 1758: Memory controller issues. Workaround in the user guide. New in release 0.5.0rc1 ======================= The floating point implementation is now based on John Hauser's "softfloat" package, ensuring rigorous compliance with the IEEE 754-2008 standard. The library interface is extended to allow registers and memory to be written directly and processor stalled and unstalled. This is to allow direct integration as a simulator in GDB. Some of the existing library interface functions have different prototypes. The "include" feature of configuration files (which never worked, but no one ever noticed) is dropped. If the configuration file is not found in the local directory, it is searched for in the ${HOME}/.or1ksim directory, then (for backwards compatibility) the ${HOME}/.or1k directory. If no simulation file is specified, then sim.cfg is not searched for as a default. New options are added -q|--quiet, -V|--verbose, -m|--memory and --report-memory-errors. The semantics of --nosrv and --src otpions are changed. There is a configuration option to collect statistics on instruction execution in binary form. In previous versions, Bus exceptions were unique in that they produced an error message on standard output. The default is now for this exception to be handled silently, unless requested by --report-memory-errors. The following feature requests have been accepted. * Feature 393: Integrate Or1ksim in GDB. The following bugs are fixed. * Bug 1821: Reference configuration file has defective debug section. * Bug 1817: Reference configuration file missing from distribution. * Bug 1795: GDB breakpoints do not work with the instruction cache. The following bugs are either cannot be reproduced or will not be fixed. The following bugs are outstanding * Bug 1824: Memory controller issue (probably the same as Bug 1758). * Bug 1823: Configuration file error line numbers are wrong. * Bug 1822: ATA section in configuration file is broken. * Bug 1816: Error message when target not set is obscure. * Bug 1813: "make check" fails before installation. * Bug 1758: Memory controller issues. Workaround in the user guide. New in release 0.4.0 ==================== No new features or bugs. This is the full release based on 0.4.0rc2. New in release 0.4.0rc2 ======================= No new features are provided, pending full release of 0.4.0. The configuration options --enable-arith-flag and --enable-ov-flag have been removed, since they were the source of bugs, notably Bugs 1782, 1783 and 1784. The configuration option --enable-unsigned-xori has been added to allow a conditional solution to Bug 1790. The following bugs are fixed. * Bug 1770: l.div does not set carry or give correct exception. * Bug 1771: l.add* do not correctly set the overflow flag. * Bug 1772: l.fl1 not implemented. * Bug 1773: l.maci not correctly implemented. * Bug 1774: l.mulu not implemented. * Bug 1775: l.jalr and l.jr don't trigger alignment exceptions. * Bug 1776: l.addic is not implemented. * Bug 1777: l.macrc not correctly implemented. * Bug 1778: l.ror and l.rori are not implemented. * Bug 1779: l.mtspr implementation is incorrect. * Bug 1782: Or1ksim setting of overflow flag is wrong. * Bug 1783: Or1ksim definition of overflow is wrong. * Bug 1784: Or1ksim does not trigger overflow exceptions. * Bug 1790: l.xori implementation is incorrect. The following bugs are either cannot be reproduced or will not be fixed. The following bugs are outstanding * Bug 1758: Memory controller issues. Workaround in the user guide. New in release 0.4.0rc1 ======================= The following new features are provided. * testbench now renamed testsuite and fully integrated using DejaGNU. "make check" now works correctly if the OpenRISC toolchain is installed. * New configuration flag --enable-all-tests to enable building of incomplete tests with "make check". * The library offers an interface via modelled JTAG * Single precision floating point is available. The user guide is updated. The following feature requests have been accepted. * Feature 413: ORFPX32 single precision floating point now supported. * Feature 469: Icache tags now intialized as invalid. * Feature 1673: Or1ksim now builds on Mac OS X. * Feature 1678: download, patch and build dirs removed from SVN. The following feature requests have been rejected. * Feature 399: Writeable SR_LEE bit will not be provided. * Feature 409: Separate ELF loader library already exists in binutils. * Feature 586: Ignoring HW breakpoints is already possible. The following bugs are fixed. * Bug 534: Test suite fixed (see above). * Bug 1710: mprofile now handles mode args correctly. * Bug 1723: PS2 keyboard error message clearer if RX file won't open. * Bug 1733: Or1ksim now accepts ELF image when working through RSP. * Bug 1767: l.lws is not recognized as an opcode. The following bugs are either cannot be reproduced or will not be fixed. The following bugs are outstanding * Bug 1758: Memory controller issues. Workaround in the user guide. New in release 0.3.0 ==================== * No new features or bugs. This is the full release based on rc3. New in release 0.3.0rc3 ======================= * Bug 376 fixed: 32 interrupts now supported * Bug 377 fixed: Level triggered interrupts now work correctly * Bug 378 fixed: xterm UART now works with RSP * Bug 379 fixed: RSP performance improved * Bug 380 fixed: GDB 6.8 stepi now works through Or1ksim JTAG interface * Bug 398 fixed: Lack of support for LEE bit in SR documented * Bug 415 fixed: NPC behavior on writing optionally matches real HW * Bug 418 fixed: All library up calls are host-endian * Feature 395 added: Boot from 0xf0000000 now enabled. * Feature 408 added: Image file may be NULL for or1ksim_init. * Feature 410 added: RSP now clears sigval on unstalling the processor. * Feature 417 added: Or1ksim prints out its version on startup. New in release 0.3.0rc2 ======================= * A number of bug fixes * Updates to user guide New in release 0.3.0rc1 ======================= * Numerous bug fixes (see the OpenRISC tracker and the ChangeLog file) * User Guide * Consistent coding style and file naming throughout * Support for external SystemC models
This commit is contained in:
parent
98f0b2c203
commit
f50c54b1d8
19 changed files with 187 additions and 1234 deletions
|
@ -1,37 +1,25 @@
|
|||
# $NetBSD: Makefile,v 1.8 2012/10/03 21:26:15 asau Exp $
|
||||
# $NetBSD: Makefile,v 1.9 2013/10/14 13:00:04 ryo-on Exp $
|
||||
#
|
||||
|
||||
DISTNAME= or1ksim-0.2.0rc3
|
||||
PKGREVISION= 1
|
||||
VER= 0.5.1rc1
|
||||
DISTNAME= or1ksim-or1ksim-${VER}
|
||||
PKGNAME= ${DISTNAME:S/or1ksim-or1ksim-/or1ksim-/}
|
||||
CATEGORIES= emulators
|
||||
MASTER_SITES= http://www.opencores.org/projects.cgi/web/or1k/
|
||||
MASTER_SITES= -https://github.com/openrisc/or1ksim/archive/or1ksim-${VER}.tar.gz
|
||||
|
||||
MAINTAINER= pkgsrc-users@NetBSD.org
|
||||
HOMEPAGE= http://www.opencores.org/projects.cgi/web/or1k/architectural_simulator
|
||||
COMMENT= OpenRISC 1000 (OR1K) architecture simulator
|
||||
HOMEPAGE= http://opencores.org/or1k/Or1ksim
|
||||
COMMENT= OpenRISC emulator
|
||||
|
||||
PKG_INSTALLATION_TYPES= overwrite pkgviews
|
||||
FETCH_USING= curl
|
||||
|
||||
GNU_CONFIGURE= yes
|
||||
CONFIGURE_ARGS+= --enable-execution=simple
|
||||
INSTALLATION_DIRS= bin share/examples/or1ksim share/doc/or1ksim
|
||||
USE_TOOLS+= gmake
|
||||
|
||||
USE_GNU_READLINE= yes # uses rl_event_hook
|
||||
INFO_FILES= yes
|
||||
|
||||
post-build:
|
||||
mv ${WRKSRC}/sim.cfg ${WRKSRC}/or1ksim.cfg
|
||||
|
||||
do-install:
|
||||
${INSTALL_PROGRAM} ${WRKSRC}/or1ksim ${DESTDIR}${PREFIX}/bin
|
||||
${INSTALL_DATA} ${WRKSRC}/or1ksim.cfg ${DESTDIR}${PREFIX}/share/examples/${PKGBASE}
|
||||
${INSTALL_DATA} ${WRKSRC}/virtex.tim ${DESTDIR}${PREFIX}/share/examples/${PKGBASE}
|
||||
${INSTALL_DATA} ${WRKSRC}/AUTHORS ${DESTDIR}${PREFIX}/share/doc/${PKGBASE}
|
||||
${INSTALL_DATA} ${WRKSRC}/COPYING ${DESTDIR}${PREFIX}/share/doc/${PKGBASE}
|
||||
${INSTALL_DATA} ${WRKSRC}/ChangeLog ${DESTDIR}${PREFIX}/share/doc/${PKGBASE}
|
||||
${INSTALL_DATA} ${WRKSRC}/INSTALL ${DESTDIR}${PREFIX}/share/doc/${PKGBASE}
|
||||
${INSTALL_DATA} ${WRKSRC}/NEWS ${DESTDIR}${PREFIX}/share/doc/${PKGBASE}
|
||||
${INSTALL_DATA} ${WRKSRC}/README ${DESTDIR}${PREFIX}/share/doc/${PKGBASE}
|
||||
${INSTALL_DATA} ${WRKSRC}/README.gdb ${DESTDIR}${PREFIX}/share/doc/${PKGBASE}
|
||||
GNU_CONFIGURE= yes
|
||||
CONFIGURE_ARGS+= --target=or32
|
||||
|
||||
# rl_event_hook
|
||||
.include "../../devel/readline/buildlink3.mk"
|
||||
.include "../../mk/bsd.pkg.mk"
|
||||
|
|
|
@ -1,11 +1,7 @@
|
|||
@comment $NetBSD: PLIST,v 1.4 2009/10/11 10:45:03 thomasklausner Exp $
|
||||
bin/or1ksim
|
||||
share/doc/or1ksim/AUTHORS
|
||||
share/doc/or1ksim/COPYING
|
||||
share/doc/or1ksim/ChangeLog
|
||||
share/doc/or1ksim/INSTALL
|
||||
share/doc/or1ksim/NEWS
|
||||
share/doc/or1ksim/README
|
||||
share/doc/or1ksim/README.gdb
|
||||
share/examples/or1ksim/or1ksim.cfg
|
||||
share/examples/or1ksim/virtex.tim
|
||||
@comment $NetBSD: PLIST,v 1.5 2013/10/14 13:00:04 ryo-on Exp $
|
||||
bin/or32-mprofile
|
||||
bin/or32-profile
|
||||
bin/or32-sim
|
||||
include/or1ksim.h
|
||||
info/or1ksim.info
|
||||
lib/libsim.la
|
||||
|
|
|
@ -1,18 +1,8 @@
|
|||
$NetBSD: distinfo,v 1.3 2006/02/25 19:21:56 kheinz Exp $
|
||||
$NetBSD: distinfo,v 1.4 2013/10/14 13:00:04 ryo-on Exp $
|
||||
|
||||
SHA1 (or1ksim-0.2.0rc3.tar.gz) = c70ce0422ea5af78f25c148c2b9356f1f7ccaedc
|
||||
RMD160 (or1ksim-0.2.0rc3.tar.gz) = 8a6b1c776ddc89aa8c52318a153eae50b4f68467
|
||||
Size (or1ksim-0.2.0rc3.tar.gz) = 655579 bytes
|
||||
SHA1 (patch-aa) = cd64f4970f15c44983682130f90d97e59cf03059
|
||||
SHA1 (patch-ac) = db290aebd331d0820f4d8275219e7b8943a4eeca
|
||||
SHA1 (patch-ad) = ee8df3a365d1b85f4c1dcefbb1d3e631d7066e07
|
||||
SHA1 (patch-ae) = b8c0952e2007a10c9c9a65f9dc732241377172ff
|
||||
SHA1 (patch-af) = 39a4fbe706fe9ff440685f25ae5b6bfe1167262c
|
||||
SHA1 (patch-aj) = 2240ff6de5777404d8f070c3263023a3e47df4f0
|
||||
SHA1 (patch-ak) = 5ef9dea95a41d47ee9320d20c842c6b482941423
|
||||
SHA1 (patch-al) = f05b2840cfbe4e29dd5ba28c25172773d5dc8a4b
|
||||
SHA1 (patch-am) = a7e4ad717f156d53c9f2a002f5d7fe456009824b
|
||||
SHA1 (patch-an) = be7c2c33c43265e7a7ce72bfbd41ea8f5bf13a5a
|
||||
SHA1 (patch-ao) = 5651b7474e99ccddf57b07eba8dadafaf8c3e2e6
|
||||
SHA1 (patch-ap) = 1554047e240a34738c91fcaba555f4711cd13c21
|
||||
SHA1 (patch-aq) = ca1c94e42186a8b6dabeb3aea120410f738bf526
|
||||
SHA1 (or1ksim-or1ksim-0.5.1rc1.tar.gz) = ce4720211af1d0421e277698d37ff61d1b536166
|
||||
RMD160 (or1ksim-or1ksim-0.5.1rc1.tar.gz) = 24aefc2431b94f2d1ae4a348e2eb21ab8b4bb824
|
||||
Size (or1ksim-or1ksim-0.5.1rc1.tar.gz) = 2256456 bytes
|
||||
SHA1 (patch-peripheral_atadevice.c) = fd3302b9ea6c7b59aaea007cd2f7a722e569b8b4
|
||||
SHA1 (patch-peripheral_eth.c) = eff5a065858fb40dd3f29d315453e41738cb5e4e
|
||||
SHA1 (patch-peripheral_eth.h) = 7c88dd70dd2a0cc13486d8b5a2327b4bb58a3cf1
|
||||
|
|
|
@ -1,882 +0,0 @@
|
|||
$NetBSD: patch-aa,v 1.3 2006/02/25 19:21:56 kheinz Exp $
|
||||
--- configure.orig 2005-09-29 00:54:55.000000000 +0200
|
||||
+++ configure
|
||||
@@ -1835,15 +1835,7 @@ SIMVERSION=1.2
|
||||
|
||||
|
||||
|
||||
-case "$target_cpu" in
|
||||
-or32*) CPU_ARCH=or32;
|
||||
- ARCH_ISA=OR32;;
|
||||
-dlx*) CPU_ARCH=dlx;
|
||||
- ARCH_ISA=DLX;;
|
||||
-*) { { echo "$as_me:$LINENO: error: Unknown target architechture $target_cpu" >&5
|
||||
-echo "$as_me: error: Unknown target architechture $target_cpu" >&2;}
|
||||
- { (exit 1); exit 1; }; };;
|
||||
-esac
|
||||
+CPU_ARCH=or32;
|
||||
|
||||
|
||||
# We want these before the checks, so the checks can modify their values.
|
||||
@@ -4789,31 +4781,30 @@ fi
|
||||
|
||||
done
|
||||
|
||||
-echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
|
||||
-echo $ECHO_N "checking whether byte ordering is bigendian... $ECHO_C" >&6
|
||||
-if test "${ac_cv_c_bigendian+set}" = set; then
|
||||
+
|
||||
+for ac_header in sys/types.h
|
||||
+do
|
||||
+as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
|
||||
+if eval "test \"\${$as_ac_Header+set}\" = set"; then
|
||||
+ echo "$as_me:$LINENO: checking for $ac_header" >&5
|
||||
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
|
||||
+if eval "test \"\${$as_ac_Header+set}\" = set"; then
|
||||
echo $ECHO_N "(cached) $ECHO_C" >&6
|
||||
+fi
|
||||
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
|
||||
+echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
|
||||
else
|
||||
- # See if sys/param.h defines the BYTE_ORDER macro.
|
||||
+ # Is the header compilable?
|
||||
+echo "$as_me:$LINENO: checking $ac_header usability" >&5
|
||||
+echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
|
||||
cat >conftest.$ac_ext <<_ACEOF
|
||||
/* confdefs.h. */
|
||||
_ACEOF
|
||||
cat confdefs.h >>conftest.$ac_ext
|
||||
cat >>conftest.$ac_ext <<_ACEOF
|
||||
/* end confdefs.h. */
|
||||
-#include <sys/types.h>
|
||||
-#include <sys/param.h>
|
||||
-
|
||||
-int
|
||||
-main ()
|
||||
-{
|
||||
-#if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
|
||||
- bogus endian macros
|
||||
-#endif
|
||||
-
|
||||
- ;
|
||||
- return 0;
|
||||
-}
|
||||
+$ac_includes_default
|
||||
+#include <$ac_header>
|
||||
_ACEOF
|
||||
rm -f conftest.$ac_objext
|
||||
if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
|
||||
@@ -4837,84 +4828,133 @@ if { (eval echo "$as_me:$LINENO: \"$ac_c
|
||||
ac_status=$?
|
||||
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
(exit $ac_status); }; }; then
|
||||
- # It does; now see whether it defined to BIG_ENDIAN or not.
|
||||
+ ac_header_compiler=yes
|
||||
+else
|
||||
+ echo "$as_me: failed program was:" >&5
|
||||
+sed 's/^/| /' conftest.$ac_ext >&5
|
||||
+
|
||||
+ac_header_compiler=no
|
||||
+fi
|
||||
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
|
||||
+echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
|
||||
+echo "${ECHO_T}$ac_header_compiler" >&6
|
||||
+
|
||||
+# Is the header present?
|
||||
+echo "$as_me:$LINENO: checking $ac_header presence" >&5
|
||||
+echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
|
||||
cat >conftest.$ac_ext <<_ACEOF
|
||||
/* confdefs.h. */
|
||||
_ACEOF
|
||||
cat confdefs.h >>conftest.$ac_ext
|
||||
cat >>conftest.$ac_ext <<_ACEOF
|
||||
/* end confdefs.h. */
|
||||
-#include <sys/types.h>
|
||||
-#include <sys/param.h>
|
||||
-
|
||||
-int
|
||||
-main ()
|
||||
-{
|
||||
-#if BYTE_ORDER != BIG_ENDIAN
|
||||
- not big endian
|
||||
-#endif
|
||||
-
|
||||
- ;
|
||||
- return 0;
|
||||
-}
|
||||
+#include <$ac_header>
|
||||
_ACEOF
|
||||
-rm -f conftest.$ac_objext
|
||||
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
|
||||
- (eval $ac_compile) 2>conftest.er1
|
||||
+if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
|
||||
+ (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
|
||||
ac_status=$?
|
||||
grep -v '^ *+' conftest.er1 >conftest.err
|
||||
rm -f conftest.er1
|
||||
cat conftest.err >&5
|
||||
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
- (exit $ac_status); } &&
|
||||
- { ac_try='test -z "$ac_c_werror_flag"
|
||||
- || test ! -s conftest.err'
|
||||
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||
- (eval $ac_try) 2>&5
|
||||
- ac_status=$?
|
||||
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
- (exit $ac_status); }; } &&
|
||||
- { ac_try='test -s conftest.$ac_objext'
|
||||
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||
- (eval $ac_try) 2>&5
|
||||
- ac_status=$?
|
||||
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
- (exit $ac_status); }; }; then
|
||||
- ac_cv_c_bigendian=yes
|
||||
+ (exit $ac_status); } >/dev/null; then
|
||||
+ if test -s conftest.err; then
|
||||
+ ac_cpp_err=$ac_c_preproc_warn_flag
|
||||
+ ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
|
||||
+ else
|
||||
+ ac_cpp_err=
|
||||
+ fi
|
||||
+else
|
||||
+ ac_cpp_err=yes
|
||||
+fi
|
||||
+if test -z "$ac_cpp_err"; then
|
||||
+ ac_header_preproc=yes
|
||||
else
|
||||
echo "$as_me: failed program was:" >&5
|
||||
sed 's/^/| /' conftest.$ac_ext >&5
|
||||
|
||||
-ac_cv_c_bigendian=no
|
||||
+ ac_header_preproc=no
|
||||
fi
|
||||
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
|
||||
+rm -f conftest.err conftest.$ac_ext
|
||||
+echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
|
||||
+echo "${ECHO_T}$ac_header_preproc" >&6
|
||||
+
|
||||
+# So? What about this header?
|
||||
+case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
|
||||
+ yes:no: )
|
||||
+ { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
|
||||
+echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
|
||||
+ { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
|
||||
+echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
|
||||
+ ac_header_preproc=yes
|
||||
+ ;;
|
||||
+ no:yes:* )
|
||||
+ { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
|
||||
+echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
|
||||
+ { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
|
||||
+echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
|
||||
+ { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
|
||||
+echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
|
||||
+ { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
|
||||
+echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
|
||||
+ { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
|
||||
+echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
|
||||
+ { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
|
||||
+echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
|
||||
+ (
|
||||
+ cat <<\_ASBOX
|
||||
+## ------------------------------------------ ##
|
||||
+## Report this to the AC_PACKAGE_NAME lists. ##
|
||||
+## ------------------------------------------ ##
|
||||
+_ASBOX
|
||||
+ ) |
|
||||
+ sed "s/^/$as_me: WARNING: /" >&2
|
||||
+ ;;
|
||||
+esac
|
||||
+echo "$as_me:$LINENO: checking for $ac_header" >&5
|
||||
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
|
||||
+if eval "test \"\${$as_ac_Header+set}\" = set"; then
|
||||
+ echo $ECHO_N "(cached) $ECHO_C" >&6
|
||||
else
|
||||
- echo "$as_me: failed program was:" >&5
|
||||
-sed 's/^/| /' conftest.$ac_ext >&5
|
||||
+ eval "$as_ac_Header=\$ac_header_preproc"
|
||||
+fi
|
||||
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
|
||||
+echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
|
||||
|
||||
-# It does not; compile a test program.
|
||||
-if test "$cross_compiling" = yes; then
|
||||
- # try to guess the endianness by grepping values into an object file
|
||||
- ac_cv_c_bigendian=unknown
|
||||
- cat >conftest.$ac_ext <<_ACEOF
|
||||
+fi
|
||||
+if test `eval echo '${'$as_ac_Header'}'` = yes; then
|
||||
+ cat >>confdefs.h <<_ACEOF
|
||||
+#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
|
||||
+_ACEOF
|
||||
+
|
||||
+fi
|
||||
+
|
||||
+done
|
||||
+
|
||||
+
|
||||
+for ac_header in sys/socket.h
|
||||
+do
|
||||
+as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
|
||||
+if eval "test \"\${$as_ac_Header+set}\" = set"; then
|
||||
+ echo "$as_me:$LINENO: checking for $ac_header" >&5
|
||||
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
|
||||
+if eval "test \"\${$as_ac_Header+set}\" = set"; then
|
||||
+ echo $ECHO_N "(cached) $ECHO_C" >&6
|
||||
+fi
|
||||
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
|
||||
+echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
|
||||
+else
|
||||
+ # Is the header compilable?
|
||||
+echo "$as_me:$LINENO: checking $ac_header usability" >&5
|
||||
+echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
|
||||
+cat >conftest.$ac_ext <<_ACEOF
|
||||
/* confdefs.h. */
|
||||
_ACEOF
|
||||
cat confdefs.h >>conftest.$ac_ext
|
||||
cat >>conftest.$ac_ext <<_ACEOF
|
||||
/* end confdefs.h. */
|
||||
-short ascii_mm[] = { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
|
||||
-short ascii_ii[] = { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
|
||||
-void _ascii () { char *s = (char *) ascii_mm; s = (char *) ascii_ii; }
|
||||
-short ebcdic_ii[] = { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
|
||||
-short ebcdic_mm[] = { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
|
||||
-void _ebcdic () { char *s = (char *) ebcdic_mm; s = (char *) ebcdic_ii; }
|
||||
-int
|
||||
-main ()
|
||||
-{
|
||||
- _ascii (); _ebcdic ();
|
||||
- ;
|
||||
- return 0;
|
||||
-}
|
||||
+$ac_includes_default
|
||||
+#include <$ac_header>
|
||||
_ACEOF
|
||||
rm -f conftest.$ac_objext
|
||||
if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
|
||||
@@ -4938,61 +4978,450 @@ if { (eval echo "$as_me:$LINENO: \"$ac_c
|
||||
ac_status=$?
|
||||
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
(exit $ac_status); }; }; then
|
||||
- if grep BIGenDianSyS conftest.$ac_objext >/dev/null ; then
|
||||
- ac_cv_c_bigendian=yes
|
||||
-fi
|
||||
-if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
|
||||
- if test "$ac_cv_c_bigendian" = unknown; then
|
||||
- ac_cv_c_bigendian=no
|
||||
- else
|
||||
- # finding both strings is unlikely to happen, but who knows?
|
||||
- ac_cv_c_bigendian=unknown
|
||||
- fi
|
||||
-fi
|
||||
+ ac_header_compiler=yes
|
||||
else
|
||||
echo "$as_me: failed program was:" >&5
|
||||
sed 's/^/| /' conftest.$ac_ext >&5
|
||||
|
||||
+ac_header_compiler=no
|
||||
fi
|
||||
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
|
||||
-else
|
||||
- cat >conftest.$ac_ext <<_ACEOF
|
||||
+echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
|
||||
+echo "${ECHO_T}$ac_header_compiler" >&6
|
||||
+
|
||||
+# Is the header present?
|
||||
+echo "$as_me:$LINENO: checking $ac_header presence" >&5
|
||||
+echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
|
||||
+cat >conftest.$ac_ext <<_ACEOF
|
||||
/* confdefs.h. */
|
||||
_ACEOF
|
||||
cat confdefs.h >>conftest.$ac_ext
|
||||
cat >>conftest.$ac_ext <<_ACEOF
|
||||
/* end confdefs.h. */
|
||||
-int
|
||||
-main ()
|
||||
-{
|
||||
- /* Are we little or big endian? From Harbison&Steele. */
|
||||
- union
|
||||
- {
|
||||
- long l;
|
||||
- char c[sizeof (long)];
|
||||
- } u;
|
||||
- u.l = 1;
|
||||
- exit (u.c[sizeof (long) - 1] == 1);
|
||||
-}
|
||||
+#include <$ac_header>
|
||||
_ACEOF
|
||||
-rm -f conftest$ac_exeext
|
||||
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
|
||||
- (eval $ac_link) 2>&5
|
||||
- ac_status=$?
|
||||
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
- (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
|
||||
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||
- (eval $ac_try) 2>&5
|
||||
+if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
|
||||
+ (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
|
||||
ac_status=$?
|
||||
+ grep -v '^ *+' conftest.er1 >conftest.err
|
||||
+ rm -f conftest.er1
|
||||
+ cat conftest.err >&5
|
||||
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
- (exit $ac_status); }; }; then
|
||||
- ac_cv_c_bigendian=no
|
||||
+ (exit $ac_status); } >/dev/null; then
|
||||
+ if test -s conftest.err; then
|
||||
+ ac_cpp_err=$ac_c_preproc_warn_flag
|
||||
+ ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
|
||||
+ else
|
||||
+ ac_cpp_err=
|
||||
+ fi
|
||||
else
|
||||
- echo "$as_me: program exited with status $ac_status" >&5
|
||||
-echo "$as_me: failed program was:" >&5
|
||||
+ ac_cpp_err=yes
|
||||
+fi
|
||||
+if test -z "$ac_cpp_err"; then
|
||||
+ ac_header_preproc=yes
|
||||
+else
|
||||
+ echo "$as_me: failed program was:" >&5
|
||||
sed 's/^/| /' conftest.$ac_ext >&5
|
||||
|
||||
-( exit $ac_status )
|
||||
+ ac_header_preproc=no
|
||||
+fi
|
||||
+rm -f conftest.err conftest.$ac_ext
|
||||
+echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
|
||||
+echo "${ECHO_T}$ac_header_preproc" >&6
|
||||
+
|
||||
+# So? What about this header?
|
||||
+case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
|
||||
+ yes:no: )
|
||||
+ { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
|
||||
+echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
|
||||
+ { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
|
||||
+echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
|
||||
+ ac_header_preproc=yes
|
||||
+ ;;
|
||||
+ no:yes:* )
|
||||
+ { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
|
||||
+echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
|
||||
+ { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
|
||||
+echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
|
||||
+ { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
|
||||
+echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
|
||||
+ { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
|
||||
+echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
|
||||
+ { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
|
||||
+echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
|
||||
+ { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
|
||||
+echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
|
||||
+ (
|
||||
+ cat <<\_ASBOX
|
||||
+## ------------------------------------------ ##
|
||||
+## Report this to the AC_PACKAGE_NAME lists. ##
|
||||
+## ------------------------------------------ ##
|
||||
+_ASBOX
|
||||
+ ) |
|
||||
+ sed "s/^/$as_me: WARNING: /" >&2
|
||||
+ ;;
|
||||
+esac
|
||||
+echo "$as_me:$LINENO: checking for $ac_header" >&5
|
||||
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
|
||||
+if eval "test \"\${$as_ac_Header+set}\" = set"; then
|
||||
+ echo $ECHO_N "(cached) $ECHO_C" >&6
|
||||
+else
|
||||
+ eval "$as_ac_Header=\$ac_header_preproc"
|
||||
+fi
|
||||
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
|
||||
+echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
|
||||
+
|
||||
+fi
|
||||
+if test `eval echo '${'$as_ac_Header'}'` = yes; then
|
||||
+ cat >>confdefs.h <<_ACEOF
|
||||
+#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
|
||||
+_ACEOF
|
||||
+
|
||||
+fi
|
||||
+
|
||||
+done
|
||||
+
|
||||
+
|
||||
+for ac_header in net/if.h
|
||||
+do
|
||||
+as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
|
||||
+echo "$as_me:$LINENO: checking for $ac_header" >&5
|
||||
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
|
||||
+if eval "test \"\${$as_ac_Header+set}\" = set"; then
|
||||
+ echo $ECHO_N "(cached) $ECHO_C" >&6
|
||||
+else
|
||||
+ cat >conftest.$ac_ext <<_ACEOF
|
||||
+/* confdefs.h. */
|
||||
+_ACEOF
|
||||
+cat confdefs.h >>conftest.$ac_ext
|
||||
+cat >>conftest.$ac_ext <<_ACEOF
|
||||
+/* end confdefs.h. */
|
||||
+#if HAVE_SYS_TYPES_H
|
||||
+# include <sys/types.h>
|
||||
+#endif
|
||||
+#if HAVE_SYS_SOCKET_H
|
||||
+# include <sys/socket.h>
|
||||
+#endif
|
||||
+
|
||||
+
|
||||
+#include <$ac_header>
|
||||
+_ACEOF
|
||||
+rm -f conftest.$ac_objext
|
||||
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
|
||||
+ (eval $ac_compile) 2>conftest.er1
|
||||
+ ac_status=$?
|
||||
+ grep -v '^ *+' conftest.er1 >conftest.err
|
||||
+ rm -f conftest.er1
|
||||
+ cat conftest.err >&5
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); } &&
|
||||
+ { ac_try='test -z "$ac_c_werror_flag"
|
||||
+ || test ! -s conftest.err'
|
||||
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||
+ (eval $ac_try) 2>&5
|
||||
+ ac_status=$?
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); }; } &&
|
||||
+ { ac_try='test -s conftest.$ac_objext'
|
||||
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||
+ (eval $ac_try) 2>&5
|
||||
+ ac_status=$?
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); }; }; then
|
||||
+ eval "$as_ac_Header=yes"
|
||||
+else
|
||||
+ echo "$as_me: failed program was:" >&5
|
||||
+sed 's/^/| /' conftest.$ac_ext >&5
|
||||
+
|
||||
+eval "$as_ac_Header=no"
|
||||
+fi
|
||||
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
|
||||
+fi
|
||||
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
|
||||
+echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
|
||||
+if test `eval echo '${'$as_ac_Header'}'` = yes; then
|
||||
+ cat >>confdefs.h <<_ACEOF
|
||||
+#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
|
||||
+_ACEOF
|
||||
+
|
||||
+fi
|
||||
+
|
||||
+done
|
||||
+
|
||||
+
|
||||
+for ac_header in net/if_ether.h
|
||||
+do
|
||||
+as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
|
||||
+echo "$as_me:$LINENO: checking for $ac_header" >&5
|
||||
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
|
||||
+if eval "test \"\${$as_ac_Header+set}\" = set"; then
|
||||
+ echo $ECHO_N "(cached) $ECHO_C" >&6
|
||||
+else
|
||||
+ cat >conftest.$ac_ext <<_ACEOF
|
||||
+/* confdefs.h. */
|
||||
+_ACEOF
|
||||
+cat confdefs.h >>conftest.$ac_ext
|
||||
+cat >>conftest.$ac_ext <<_ACEOF
|
||||
+/* end confdefs.h. */
|
||||
+#if HAVE_SYS_TYPES_H
|
||||
+# include <sys/types.h>
|
||||
+#endif
|
||||
+#if HAVE_SYS_SOCKET_H
|
||||
+# include <sys/socket.h>
|
||||
+#endif
|
||||
+#if HAVE_NET_IF_H
|
||||
+# include <net/if.h>
|
||||
+#endif
|
||||
+
|
||||
+
|
||||
+#include <$ac_header>
|
||||
+_ACEOF
|
||||
+rm -f conftest.$ac_objext
|
||||
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
|
||||
+ (eval $ac_compile) 2>conftest.er1
|
||||
+ ac_status=$?
|
||||
+ grep -v '^ *+' conftest.er1 >conftest.err
|
||||
+ rm -f conftest.er1
|
||||
+ cat conftest.err >&5
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); } &&
|
||||
+ { ac_try='test -z "$ac_c_werror_flag"
|
||||
+ || test ! -s conftest.err'
|
||||
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||
+ (eval $ac_try) 2>&5
|
||||
+ ac_status=$?
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); }; } &&
|
||||
+ { ac_try='test -s conftest.$ac_objext'
|
||||
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||
+ (eval $ac_try) 2>&5
|
||||
+ ac_status=$?
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); }; }; then
|
||||
+ eval "$as_ac_Header=yes"
|
||||
+else
|
||||
+ echo "$as_me: failed program was:" >&5
|
||||
+sed 's/^/| /' conftest.$ac_ext >&5
|
||||
+
|
||||
+eval "$as_ac_Header=no"
|
||||
+fi
|
||||
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
|
||||
+fi
|
||||
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
|
||||
+echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
|
||||
+if test `eval echo '${'$as_ac_Header'}'` = yes; then
|
||||
+ cat >>confdefs.h <<_ACEOF
|
||||
+#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
|
||||
+_ACEOF
|
||||
+
|
||||
+fi
|
||||
+
|
||||
+done
|
||||
+
|
||||
+echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
|
||||
+echo $ECHO_N "checking whether byte ordering is bigendian... $ECHO_C" >&6
|
||||
+if test "${ac_cv_c_bigendian+set}" = set; then
|
||||
+ echo $ECHO_N "(cached) $ECHO_C" >&6
|
||||
+else
|
||||
+ # See if sys/param.h defines the BYTE_ORDER macro.
|
||||
+cat >conftest.$ac_ext <<_ACEOF
|
||||
+/* confdefs.h. */
|
||||
+_ACEOF
|
||||
+cat confdefs.h >>conftest.$ac_ext
|
||||
+cat >>conftest.$ac_ext <<_ACEOF
|
||||
+/* end confdefs.h. */
|
||||
+#include <sys/types.h>
|
||||
+#include <sys/param.h>
|
||||
+
|
||||
+int
|
||||
+main ()
|
||||
+{
|
||||
+#if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
|
||||
+ bogus endian macros
|
||||
+#endif
|
||||
+
|
||||
+ ;
|
||||
+ return 0;
|
||||
+}
|
||||
+_ACEOF
|
||||
+rm -f conftest.$ac_objext
|
||||
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
|
||||
+ (eval $ac_compile) 2>conftest.er1
|
||||
+ ac_status=$?
|
||||
+ grep -v '^ *+' conftest.er1 >conftest.err
|
||||
+ rm -f conftest.er1
|
||||
+ cat conftest.err >&5
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); } &&
|
||||
+ { ac_try='test -z "$ac_c_werror_flag"
|
||||
+ || test ! -s conftest.err'
|
||||
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||
+ (eval $ac_try) 2>&5
|
||||
+ ac_status=$?
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); }; } &&
|
||||
+ { ac_try='test -s conftest.$ac_objext'
|
||||
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||
+ (eval $ac_try) 2>&5
|
||||
+ ac_status=$?
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); }; }; then
|
||||
+ # It does; now see whether it defined to BIG_ENDIAN or not.
|
||||
+cat >conftest.$ac_ext <<_ACEOF
|
||||
+/* confdefs.h. */
|
||||
+_ACEOF
|
||||
+cat confdefs.h >>conftest.$ac_ext
|
||||
+cat >>conftest.$ac_ext <<_ACEOF
|
||||
+/* end confdefs.h. */
|
||||
+#include <sys/types.h>
|
||||
+#include <sys/param.h>
|
||||
+
|
||||
+int
|
||||
+main ()
|
||||
+{
|
||||
+#if BYTE_ORDER != BIG_ENDIAN
|
||||
+ not big endian
|
||||
+#endif
|
||||
+
|
||||
+ ;
|
||||
+ return 0;
|
||||
+}
|
||||
+_ACEOF
|
||||
+rm -f conftest.$ac_objext
|
||||
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
|
||||
+ (eval $ac_compile) 2>conftest.er1
|
||||
+ ac_status=$?
|
||||
+ grep -v '^ *+' conftest.er1 >conftest.err
|
||||
+ rm -f conftest.er1
|
||||
+ cat conftest.err >&5
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); } &&
|
||||
+ { ac_try='test -z "$ac_c_werror_flag"
|
||||
+ || test ! -s conftest.err'
|
||||
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||
+ (eval $ac_try) 2>&5
|
||||
+ ac_status=$?
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); }; } &&
|
||||
+ { ac_try='test -s conftest.$ac_objext'
|
||||
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||
+ (eval $ac_try) 2>&5
|
||||
+ ac_status=$?
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); }; }; then
|
||||
+ ac_cv_c_bigendian=yes
|
||||
+else
|
||||
+ echo "$as_me: failed program was:" >&5
|
||||
+sed 's/^/| /' conftest.$ac_ext >&5
|
||||
+
|
||||
+ac_cv_c_bigendian=no
|
||||
+fi
|
||||
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
|
||||
+else
|
||||
+ echo "$as_me: failed program was:" >&5
|
||||
+sed 's/^/| /' conftest.$ac_ext >&5
|
||||
+
|
||||
+# It does not; compile a test program.
|
||||
+if test "$cross_compiling" = yes; then
|
||||
+ # try to guess the endianness by grepping values into an object file
|
||||
+ ac_cv_c_bigendian=unknown
|
||||
+ cat >conftest.$ac_ext <<_ACEOF
|
||||
+/* confdefs.h. */
|
||||
+_ACEOF
|
||||
+cat confdefs.h >>conftest.$ac_ext
|
||||
+cat >>conftest.$ac_ext <<_ACEOF
|
||||
+/* end confdefs.h. */
|
||||
+short ascii_mm[] = { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
|
||||
+short ascii_ii[] = { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
|
||||
+void _ascii () { char *s = (char *) ascii_mm; s = (char *) ascii_ii; }
|
||||
+short ebcdic_ii[] = { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
|
||||
+short ebcdic_mm[] = { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
|
||||
+void _ebcdic () { char *s = (char *) ebcdic_mm; s = (char *) ebcdic_ii; }
|
||||
+int
|
||||
+main ()
|
||||
+{
|
||||
+ _ascii (); _ebcdic ();
|
||||
+ ;
|
||||
+ return 0;
|
||||
+}
|
||||
+_ACEOF
|
||||
+rm -f conftest.$ac_objext
|
||||
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
|
||||
+ (eval $ac_compile) 2>conftest.er1
|
||||
+ ac_status=$?
|
||||
+ grep -v '^ *+' conftest.er1 >conftest.err
|
||||
+ rm -f conftest.er1
|
||||
+ cat conftest.err >&5
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); } &&
|
||||
+ { ac_try='test -z "$ac_c_werror_flag"
|
||||
+ || test ! -s conftest.err'
|
||||
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||
+ (eval $ac_try) 2>&5
|
||||
+ ac_status=$?
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); }; } &&
|
||||
+ { ac_try='test -s conftest.$ac_objext'
|
||||
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||
+ (eval $ac_try) 2>&5
|
||||
+ ac_status=$?
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); }; }; then
|
||||
+ if grep BIGenDianSyS conftest.$ac_objext >/dev/null ; then
|
||||
+ ac_cv_c_bigendian=yes
|
||||
+fi
|
||||
+if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
|
||||
+ if test "$ac_cv_c_bigendian" = unknown; then
|
||||
+ ac_cv_c_bigendian=no
|
||||
+ else
|
||||
+ # finding both strings is unlikely to happen, but who knows?
|
||||
+ ac_cv_c_bigendian=unknown
|
||||
+ fi
|
||||
+fi
|
||||
+else
|
||||
+ echo "$as_me: failed program was:" >&5
|
||||
+sed 's/^/| /' conftest.$ac_ext >&5
|
||||
+
|
||||
+fi
|
||||
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
|
||||
+else
|
||||
+ cat >conftest.$ac_ext <<_ACEOF
|
||||
+/* confdefs.h. */
|
||||
+_ACEOF
|
||||
+cat confdefs.h >>conftest.$ac_ext
|
||||
+cat >>conftest.$ac_ext <<_ACEOF
|
||||
+/* end confdefs.h. */
|
||||
+int
|
||||
+main ()
|
||||
+{
|
||||
+ /* Are we little or big endian? From Harbison&Steele. */
|
||||
+ union
|
||||
+ {
|
||||
+ long l;
|
||||
+ char c[sizeof (long)];
|
||||
+ } u;
|
||||
+ u.l = 1;
|
||||
+ exit (u.c[sizeof (long) - 1] == 1);
|
||||
+}
|
||||
+_ACEOF
|
||||
+rm -f conftest$ac_exeext
|
||||
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
|
||||
+ (eval $ac_link) 2>&5
|
||||
+ ac_status=$?
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
|
||||
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||
+ (eval $ac_try) 2>&5
|
||||
+ ac_status=$?
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); }; }; then
|
||||
+ ac_cv_c_bigendian=no
|
||||
+else
|
||||
+ echo "$as_me: program exited with status $ac_status" >&5
|
||||
+echo "$as_me: failed program was:" >&5
|
||||
+sed 's/^/| /' conftest.$ac_ext >&5
|
||||
+
|
||||
+( exit $ac_status )
|
||||
ac_cv_c_bigendian=yes
|
||||
fi
|
||||
rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
|
||||
@@ -7119,6 +7548,136 @@ _ACEOF
|
||||
|
||||
|
||||
|
||||
+echo "$as_me:$LINENO: checking for library containing tgetent" >&5
|
||||
+echo $ECHO_N "checking for library containing tgetent... $ECHO_C" >&6
|
||||
+if test "${ac_cv_search_tgetent+set}" = set; then
|
||||
+ echo $ECHO_N "(cached) $ECHO_C" >&6
|
||||
+else
|
||||
+ ac_func_search_save_LIBS=$LIBS
|
||||
+ac_cv_search_tgetent=no
|
||||
+cat >conftest.$ac_ext <<_ACEOF
|
||||
+/* confdefs.h. */
|
||||
+_ACEOF
|
||||
+cat confdefs.h >>conftest.$ac_ext
|
||||
+cat >>conftest.$ac_ext <<_ACEOF
|
||||
+/* end confdefs.h. */
|
||||
+
|
||||
+/* Override any gcc2 internal prototype to avoid an error. */
|
||||
+#ifdef __cplusplus
|
||||
+extern "C"
|
||||
+#endif
|
||||
+/* We use char because int might match the return type of a gcc2
|
||||
+ builtin and then its argument prototype would still apply. */
|
||||
+char tgetent ();
|
||||
+int
|
||||
+main ()
|
||||
+{
|
||||
+tgetent ();
|
||||
+ ;
|
||||
+ return 0;
|
||||
+}
|
||||
+_ACEOF
|
||||
+rm -f conftest.$ac_objext conftest$ac_exeext
|
||||
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
|
||||
+ (eval $ac_link) 2>conftest.er1
|
||||
+ ac_status=$?
|
||||
+ grep -v '^ *+' conftest.er1 >conftest.err
|
||||
+ rm -f conftest.er1
|
||||
+ cat conftest.err >&5
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); } &&
|
||||
+ { ac_try='test -z "$ac_c_werror_flag"
|
||||
+ || test ! -s conftest.err'
|
||||
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||
+ (eval $ac_try) 2>&5
|
||||
+ ac_status=$?
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); }; } &&
|
||||
+ { ac_try='test -s conftest$ac_exeext'
|
||||
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||
+ (eval $ac_try) 2>&5
|
||||
+ ac_status=$?
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); }; }; then
|
||||
+ ac_cv_search_tgetent="none required"
|
||||
+else
|
||||
+ echo "$as_me: failed program was:" >&5
|
||||
+sed 's/^/| /' conftest.$ac_ext >&5
|
||||
+
|
||||
+fi
|
||||
+rm -f conftest.err conftest.$ac_objext \
|
||||
+ conftest$ac_exeext conftest.$ac_ext
|
||||
+if test "$ac_cv_search_tgetent" = no; then
|
||||
+ for ac_lib in termcap termlib curses ncurses tinfo; do
|
||||
+ LIBS="-l$ac_lib $ac_func_search_save_LIBS"
|
||||
+ cat >conftest.$ac_ext <<_ACEOF
|
||||
+/* confdefs.h. */
|
||||
+_ACEOF
|
||||
+cat confdefs.h >>conftest.$ac_ext
|
||||
+cat >>conftest.$ac_ext <<_ACEOF
|
||||
+/* end confdefs.h. */
|
||||
+
|
||||
+/* Override any gcc2 internal prototype to avoid an error. */
|
||||
+#ifdef __cplusplus
|
||||
+extern "C"
|
||||
+#endif
|
||||
+/* We use char because int might match the return type of a gcc2
|
||||
+ builtin and then its argument prototype would still apply. */
|
||||
+char tgetent ();
|
||||
+int
|
||||
+main ()
|
||||
+{
|
||||
+tgetent ();
|
||||
+ ;
|
||||
+ return 0;
|
||||
+}
|
||||
+_ACEOF
|
||||
+rm -f conftest.$ac_objext conftest$ac_exeext
|
||||
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
|
||||
+ (eval $ac_link) 2>conftest.er1
|
||||
+ ac_status=$?
|
||||
+ grep -v '^ *+' conftest.er1 >conftest.err
|
||||
+ rm -f conftest.er1
|
||||
+ cat conftest.err >&5
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); } &&
|
||||
+ { ac_try='test -z "$ac_c_werror_flag"
|
||||
+ || test ! -s conftest.err'
|
||||
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||
+ (eval $ac_try) 2>&5
|
||||
+ ac_status=$?
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); }; } &&
|
||||
+ { ac_try='test -s conftest$ac_exeext'
|
||||
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||
+ (eval $ac_try) 2>&5
|
||||
+ ac_status=$?
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); }; }; then
|
||||
+ ac_cv_search_tgetent="-l$ac_lib"
|
||||
+break
|
||||
+else
|
||||
+ echo "$as_me: failed program was:" >&5
|
||||
+sed 's/^/| /' conftest.$ac_ext >&5
|
||||
+
|
||||
+fi
|
||||
+rm -f conftest.err conftest.$ac_objext \
|
||||
+ conftest$ac_exeext conftest.$ac_ext
|
||||
+ done
|
||||
+fi
|
||||
+LIBS=$ac_func_search_save_LIBS
|
||||
+fi
|
||||
+echo "$as_me:$LINENO: result: $ac_cv_search_tgetent" >&5
|
||||
+echo "${ECHO_T}$ac_cv_search_tgetent" >&6
|
||||
+if test "$ac_cv_search_tgetent" != no; then
|
||||
+ test "$ac_cv_search_tgetent" = "none required" || LIBS="$ac_cv_search_tgetent $LIBS"
|
||||
+
|
||||
+else
|
||||
+ { { echo "$as_me:$LINENO: error: no relevant library found containing tgetent" >&5
|
||||
+echo "$as_me: error: no relevant library found containing tgetent" >&2;}
|
||||
+ { (exit 1); exit 1; }; }
|
||||
+fi
|
||||
+
|
||||
|
||||
echo "$as_me:$LINENO: checking for add_history in -lreadline" >&5
|
||||
echo $ECHO_N "checking for add_history in -lreadline... $ECHO_C" >&6
|
|
@ -1,12 +0,0 @@
|
|||
$NetBSD: patch-ac,v 1.2 2006/02/25 18:06:55 kheinz Exp $
|
||||
--- peripheral/ethernet_i.h.orig 2005-03-31 18:13:27.000000000 +0200
|
||||
+++ peripheral/ethernet_i.h
|
||||
@@ -36,6 +36,8 @@
|
||||
*/
|
||||
#if HAVE_NET_ETHERNET_H
|
||||
# include <net/ethernet.h>
|
||||
+#elif HAVE_NET_IF_ETHER_H
|
||||
+# include <net/if_ether.h>
|
||||
#elif HAVE_SYS_ETHERNET_H
|
||||
# include <sys/ethernet.h>
|
||||
#ifndef ETHER_ADDR_LEN
|
|
@ -1,12 +0,0 @@
|
|||
$NetBSD: patch-ad,v 1.2 2006/02/25 18:06:55 kheinz Exp $
|
||||
--- sim-cmd.c.orig 2005-11-06 17:21:05.000000000 +0100
|
||||
+++ sim-cmd.c
|
||||
@@ -148,7 +148,7 @@ static int sim_cmd_help(int argc, char *
|
||||
PRINTF("dh <fromaddr> [<toaddr>] - dumps memory as hex code (use redirect)\n");
|
||||
PRINTF("<cmd> > <filename> - redirect simulator stdout to <filename> (and not emulated PRINTF)\n");
|
||||
PRINTF("setdbch - toggles debug channels on/off\n");
|
||||
- PRINTF("set <section> <item> = <param> - set configuration. See sim.cfg for more information.\n");
|
||||
+ PRINTF("set <section> <item> = <param> - set configuration. See or1ksim.cfg for more information.\n");
|
||||
PRINTF("debug - toggles simulator debug mode\n");
|
||||
mp_help ();
|
||||
prof_help ();
|
|
@ -1,21 +0,0 @@
|
|||
$NetBSD: patch-ae,v 1.2 2006/02/25 18:06:55 kheinz Exp $
|
||||
--- toplevel.c.orig 2006-01-07 18:12:27.000000000 +0100
|
||||
+++ toplevel.c
|
||||
@@ -345,7 +345,7 @@ int main(argc, argv)
|
||||
PRINTF(" -i enable interactive command prompt\n");
|
||||
PRINTF(" --nosrv do not launch JTAG proxy server\n"); /* (CZ) */
|
||||
PRINTF(" --srv <n> launch JTAG proxy server on port <n>; [random]\n"); /* (CZ) */
|
||||
- PRINTF(" -f or --file load script file [sim.cfg]\n");
|
||||
+ PRINTF(" -f or --file load script file [or1ksim.cfg]\n");
|
||||
PRINTF(" -d <debug config> Enable debug channels\n");
|
||||
PRINTF(" --enable-profile enable profiling.\n");
|
||||
PRINTF(" --enable-mprofile enable memory profiling.\n");
|
||||
@@ -358,7 +358,7 @@ int main(argc, argv)
|
||||
|
||||
/* Read configuration file. */
|
||||
if (!runtime.sim.script_file_specified)
|
||||
- read_script_file ("sim.cfg");
|
||||
+ read_script_file ("or1ksim.cfg");
|
||||
|
||||
/* Overide parameters with command line ones */
|
||||
if (runtime.simcmd.profile) config.sim.profile = 1;
|
|
@ -1,12 +0,0 @@
|
|||
$NetBSD: patch-af,v 1.2 2006/02/25 18:06:55 kheinz Exp $
|
||||
--- sim-config.c.orig 2005-11-06 17:09:08.000000000 +0100
|
||||
+++ sim-config.c
|
||||
@@ -641,7 +641,7 @@ void read_script_file (char *filename)
|
||||
int local = 1;
|
||||
cur_section = NULL;
|
||||
|
||||
- sprintf(ctmp, "%s/.or1k/%s", home, filename);
|
||||
+ sprintf(ctmp, "%s/.or1ksim/%s", home, filename);
|
||||
if ((f = fopen (filename, "rt")) || (home && (f = fopen (ctmp, "rt")))) {
|
||||
if (config.sim.verbose)
|
||||
PRINTF ("Reading script file from '%s'...\n", local ? filename : ctmp);
|
|
@ -1,56 +0,0 @@
|
|||
$NetBSD: patch-aj,v 1.2 2006/02/25 19:21:56 kheinz Exp $
|
||||
--- configure.in.orig 2005-09-29 00:54:55.000000000 +0200
|
||||
+++ configure.in
|
||||
@@ -17,14 +17,7 @@ SIMVERSION=1.2
|
||||
dnl make sure we are using a recent autoconf version
|
||||
AC_PREREQ(2.59)
|
||||
|
||||
-dnl yuck
|
||||
-case "$target_cpu" in
|
||||
-or32*) CPU_ARCH=or32;
|
||||
- ARCH_ISA=OR32;;
|
||||
-dlx*) CPU_ARCH=dlx;
|
||||
- ARCH_ISA=DLX;;
|
||||
-*) AC_MSG_ERROR(Unknown target architechture $target_cpu);;
|
||||
-esac
|
||||
+CPU_ARCH=or32;
|
||||
AC_SUBST(CPU_ARCH)
|
||||
|
||||
# We want these before the checks, so the checks can modify their values.
|
||||
@@ -60,6 +53,27 @@ AC_CHECK_HEADERS(unistd.h stdlib.h varar
|
||||
sys/ptem.h sys/pte.h sys/stream.h sys/stropts.h sys/select.h \
|
||||
termcap.h termios.h termio.h sys/file.h locale.h\
|
||||
net/ethernet.h sys/ethernet.h malloc.h inttypes.h)
|
||||
+AC_CHECK_HEADERS([sys/types.h])
|
||||
+AC_CHECK_HEADERS([sys/socket.h])
|
||||
+AC_CHECK_HEADERS([net/if.h], [], [],
|
||||
+[#if HAVE_SYS_TYPES_H
|
||||
+# include <sys/types.h>
|
||||
+#endif
|
||||
+#if HAVE_SYS_SOCKET_H
|
||||
+# include <sys/socket.h>
|
||||
+#endif
|
||||
+])
|
||||
+AC_CHECK_HEADERS([net/if_ether.h], [], [],
|
||||
+[#if HAVE_SYS_TYPES_H
|
||||
+# include <sys/types.h>
|
||||
+#endif
|
||||
+#if HAVE_SYS_SOCKET_H
|
||||
+# include <sys/socket.h>
|
||||
+#endif
|
||||
+#if HAVE_NET_IF_H
|
||||
+# include <net/if.h>
|
||||
+#endif
|
||||
+])
|
||||
AC_C_BIGENDIAN
|
||||
|
||||
dnl check for "long long" (added by Erez)
|
||||
@@ -75,6 +89,8 @@ AC_CHECK_SIZEOF(int, 1)
|
||||
AC_CHECK_SIZEOF(long, 1)
|
||||
|
||||
dnl check for GNU readline
|
||||
+AC_SEARCH_LIBS(tgetent, [termcap termlib curses ncurses tinfo], [],
|
||||
+ AC_MSG_ERROR([no relevant library found containing tgetent]))
|
||||
AC_CHECK_LIB(readline, add_history)
|
||||
|
||||
dnl yuck
|
|
@ -1,13 +0,0 @@
|
|||
$NetBSD: patch-ak,v 1.1 2006/02/25 18:06:55 kheinz Exp $
|
||||
--- config.h.in.orig 2005-09-29 00:54:55.000000000 +0200
|
||||
+++ config.h.in
|
||||
@@ -62,6 +62,9 @@
|
||||
/* Define to 1 if you have the <ndir.h> header file, and it defines `DIR'. */
|
||||
#undef HAVE_NDIR_H
|
||||
|
||||
+/* Define to 1 if you have the <net/if_ether.h> header file. */
|
||||
+#undef HAVE_NET_IF_ETHER_H
|
||||
+
|
||||
/* Define to 1 if you have the <net/ethernet.h> header file. */
|
||||
#undef HAVE_NET_ETHERNET_H
|
||||
|
|
@ -1,23 +0,0 @@
|
|||
$NetBSD: patch-al,v 1.1 2006/02/25 18:06:55 kheinz Exp $
|
||||
--- Makefile.am.orig 2005-02-09 19:18:47.000000000 +0100
|
||||
+++ Makefile.am
|
||||
@@ -6,15 +6,15 @@
|
||||
|
||||
SUBDIRS = cpu bpb support cache mmu peripheral tick pm pic debug vapi cuc port
|
||||
|
||||
-bin_PROGRAMS = sim
|
||||
+bin_PROGRAMS = or1ksim
|
||||
|
||||
-sim_SOURCES = toplevel.c sim-config.c sim-config.h profiler.c \
|
||||
+or1ksim_SOURCES = toplevel.c sim-config.c sim-config.h profiler.c \
|
||||
mprofiler.c profiler.h mprofiler.h sim-cmd.c
|
||||
-sim_LDADD = cpu/common/libcommon.a cpu/$(CPU_ARCH)/libarch.a \
|
||||
+or1ksim_LDADD = cpu/common/libcommon.a cpu/$(CPU_ARCH)/libarch.a \
|
||||
cpu/or1k/libor1k.a support/libsupport.a mmu/libmmu.a \
|
||||
bpb/libbpb.a cache/libcache.a peripheral/libperipheral.a \
|
||||
peripheral/channels/libchannels.a \
|
||||
tick/libtick.a pm/libpm.a pic/libpic.a debug/libdebug.a \
|
||||
vapi/libvapi.a cuc/libcuc.a port/libport.a
|
||||
|
||||
-sim_LDFLAGS = -lm #-lreadline
|
||||
+or1ksim_LDFLAGS = -lm #-lreadline
|
|
@ -1,80 +0,0 @@
|
|||
$NetBSD: patch-am,v 1.1 2006/02/25 18:06:55 kheinz Exp $
|
||||
--- Makefile.in.orig 2005-09-29 00:54:55.000000000 +0200
|
||||
+++ Makefile.in
|
||||
@@ -20,7 +20,7 @@
|
||||
#
|
||||
#
|
||||
|
||||
-SOURCES = $(sim_SOURCES)
|
||||
+SOURCES = $(or1ksim_SOURCES)
|
||||
|
||||
srcdir = @srcdir@
|
||||
top_srcdir = @top_srcdir@
|
||||
@@ -45,7 +45,7 @@ POST_UNINSTALL = :
|
||||
build_triplet = @build@
|
||||
host_triplet = @host@
|
||||
target_triplet = @target@
|
||||
-bin_PROGRAMS = sim$(EXEEXT)
|
||||
+bin_PROGRAMS = or1ksim$(EXEEXT)
|
||||
DIST_COMMON = README $(am__configure_deps) $(srcdir)/Makefile.am \
|
||||
$(srcdir)/Makefile.in $(srcdir)/config.h.in \
|
||||
$(top_srcdir)/configure AUTHORS COPYING ChangeLog INSTALL NEWS \
|
||||
@@ -64,10 +64,10 @@ CONFIG_CLEAN_FILES =
|
||||
am__installdirs = "$(DESTDIR)$(bindir)"
|
||||
binPROGRAMS_INSTALL = $(INSTALL_PROGRAM)
|
||||
PROGRAMS = $(bin_PROGRAMS)
|
||||
-am_sim_OBJECTS = toplevel.$(OBJEXT) sim-config.$(OBJEXT) \
|
||||
+am_or1ksim_OBJECTS = toplevel.$(OBJEXT) sim-config.$(OBJEXT) \
|
||||
profiler.$(OBJEXT) mprofiler.$(OBJEXT) sim-cmd.$(OBJEXT)
|
||||
-sim_OBJECTS = $(am_sim_OBJECTS)
|
||||
-sim_DEPENDENCIES = cpu/common/libcommon.a cpu/$(CPU_ARCH)/libarch.a \
|
||||
+or1ksim_OBJECTS = $(am_or1ksim_OBJECTS)
|
||||
+or1ksim_DEPENDENCIES = cpu/common/libcommon.a cpu/$(CPU_ARCH)/libarch.a \
|
||||
cpu/or1k/libor1k.a support/libsupport.a mmu/libmmu.a \
|
||||
bpb/libbpb.a cache/libcache.a peripheral/libperipheral.a \
|
||||
peripheral/channels/libchannels.a tick/libtick.a pm/libpm.a \
|
||||
@@ -80,8 +80,8 @@ COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUD
|
||||
$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
|
||||
CCLD = $(CC)
|
||||
LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
|
||||
-SOURCES = $(sim_SOURCES)
|
||||
-DIST_SOURCES = $(sim_SOURCES)
|
||||
+SOURCES = $(or1ksim_SOURCES)
|
||||
+DIST_SOURCES = $(or1ksim_SOURCES)
|
||||
RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
|
||||
html-recursive info-recursive install-data-recursive \
|
||||
install-exec-recursive install-info-recursive \
|
||||
@@ -203,17 +203,17 @@ target_cpu = @target_cpu@
|
||||
target_os = @target_os@
|
||||
target_vendor = @target_vendor@
|
||||
SUBDIRS = cpu bpb support cache mmu peripheral tick pm pic debug vapi cuc port
|
||||
-sim_SOURCES = toplevel.c sim-config.c sim-config.h profiler.c \
|
||||
+or1ksim_SOURCES = toplevel.c sim-config.c sim-config.h profiler.c \
|
||||
mprofiler.c profiler.h mprofiler.h sim-cmd.c
|
||||
|
||||
-sim_LDADD = cpu/common/libcommon.a cpu/$(CPU_ARCH)/libarch.a \
|
||||
+or1ksim_LDADD = cpu/common/libcommon.a cpu/$(CPU_ARCH)/libarch.a \
|
||||
cpu/or1k/libor1k.a support/libsupport.a mmu/libmmu.a \
|
||||
bpb/libbpb.a cache/libcache.a peripheral/libperipheral.a \
|
||||
peripheral/channels/libchannels.a \
|
||||
tick/libtick.a pm/libpm.a pic/libpic.a debug/libdebug.a \
|
||||
vapi/libvapi.a cuc/libcuc.a port/libport.a
|
||||
|
||||
-sim_LDFLAGS = -lm #-lreadline
|
||||
+or1ksim_LDFLAGS = -lm #-lreadline
|
||||
all: config.h
|
||||
$(MAKE) $(AM_MAKEFLAGS) all-recursive
|
||||
|
||||
@@ -292,9 +292,9 @@ uninstall-binPROGRAMS:
|
||||
|
||||
clean-binPROGRAMS:
|
||||
-test -z "$(bin_PROGRAMS)" || rm -f $(bin_PROGRAMS)
|
||||
-sim$(EXEEXT): $(sim_OBJECTS) $(sim_DEPENDENCIES)
|
||||
- @rm -f sim$(EXEEXT)
|
||||
- $(LINK) $(sim_LDFLAGS) $(sim_OBJECTS) $(sim_LDADD) $(LIBS)
|
||||
+or1ksim$(EXEEXT): $(or1ksim_OBJECTS) $(or1ksim_DEPENDENCIES)
|
||||
+ @rm -f or1ksim$(EXEEXT)
|
||||
+ $(LINK) $(or1ksim_LDFLAGS) $(or1ksim_OBJECTS) $(or1ksim_LDADD) $(LIBS)
|
||||
|
||||
mostlyclean-compile:
|
||||
-rm -f *.$(OBJEXT)
|
|
@ -1,31 +0,0 @@
|
|||
$NetBSD: patch-an,v 1.1 2006/02/25 18:06:55 kheinz Exp $
|
||||
--- sim.cfg.orig 2005-07-05 08:33:24.000000000 +0200
|
||||
+++ sim.cfg
|
||||
@@ -1,4 +1,4 @@
|
||||
-/* sim.cfg -- Simulator configuration script file
|
||||
+/* or1ksim.cfg -- Simulator configuration script file
|
||||
Copyright (C) 2001-2002, Marko Mlinar, markom@opencores.org
|
||||
|
||||
This file is part of OpenRISC 1000 Architectural Simulator.
|
||||
@@ -26,9 +26,9 @@ Foundation, Inc., 675 Mass Ave, Cambridg
|
||||
like this one. The user can switch between configurations at startup by
|
||||
specifying the required configuration file with the -f <filename.cfg> option.
|
||||
If no configuration file is specified or1ksim searches for the default
|
||||
- configuration file sim.cfg. First it searches for './sim.cfg'. If this
|
||||
- file is not found, it searches for '~/or1k/sim.cfg'. If this file is
|
||||
- not found too, it reverts to the built-in default configuration.
|
||||
+ configuration file or1ksim.cfg. First it searches for './or1ksim.cfg'. If
|
||||
+ this file is not found, it searches for '~/.or1ksim/or1ksim.cfg'. If this
|
||||
+ file is not found too, it reverts to the built-in default configuration.
|
||||
|
||||
NOTE: Users should not rely on the built-in configuration, since the
|
||||
default configuration may differ between version.
|
||||
@@ -715,7 +715,7 @@ section ethernet
|
||||
baseaddr = 0x92000000
|
||||
dma = 0
|
||||
irq = 4
|
||||
- rtx_type = 1
|
||||
+ rtx_type = 0
|
||||
tx_channel = 0
|
||||
rx_channel = 1
|
||||
rxfile = "eth0.rx"
|
|
@ -1,13 +0,0 @@
|
|||
$NetBSD: patch-ao,v 1.1 2006/02/25 18:06:55 kheinz Exp $
|
||||
|
||||
--- cpu/common/parse.c.orig 2006-01-04 10:44:23.000000000 +0100
|
||||
+++ cpu/common/parse.c
|
||||
@@ -44,7 +44,7 @@ Foundation, Inc., 675 Mass Ave, Cambridg
|
||||
#include "labels.h"
|
||||
#include "debug.h"
|
||||
|
||||
-#define MEMORY_LEN 0x100000000
|
||||
+#define MEMORY_LEN 0x100000000LL
|
||||
#define MAXLINE_LEN 18000
|
||||
|
||||
/* Whether to do immediate statistics */
|
|
@ -1,13 +0,0 @@
|
|||
$NetBSD: patch-ap,v 1.1 2006/02/25 18:06:55 kheinz Exp $
|
||||
|
||||
--- peripheral/channels/file.c.orig 2004-02-03 15:35:05.000000000 +0100
|
||||
+++ peripheral/channels/file.c
|
||||
@@ -35,6 +35,8 @@ Foundation, Inc., 675 Mass Ave, Cambridg
|
||||
#include <errno.h> /* errno */
|
||||
#include <unistd.h> /* close() */
|
||||
|
||||
+#include "port.h"
|
||||
+
|
||||
#include "channel.h" /* struct channel_ops */
|
||||
#include "fd.h" /* struct fd_channel, fd_read(), fd_write() */
|
||||
|
|
@ -1,13 +0,0 @@
|
|||
$NetBSD: patch-aq,v 1.1 2006/02/25 19:20:14 kheinz Exp $
|
||||
|
||||
--- cpu/or32/simpl32_defs.h.orig 2005-03-31 18:03:28.000000000 +0200
|
||||
+++ cpu/or32/simpl32_defs.h
|
||||
@@ -54,7 +54,7 @@ extern void l_sfges PARAMS((struct iqueu
|
||||
extern void l_sflts PARAMS((struct iqueue_entry *));
|
||||
extern void l_sfles PARAMS((struct iqueue_entry *));
|
||||
extern void l_sfgtu PARAMS((struct iqueue_entry *));
|
||||
-extern void l_sfgeu PARAMS()(struct iqueue_entry *);
|
||||
+extern void l_sfgeu PARAMS((struct iqueue_entry *));
|
||||
extern void l_sfltu PARAMS((struct iqueue_entry *));
|
||||
extern void l_sfleu PARAMS((struct iqueue_entry *));
|
||||
extern void l_extbs PARAMS((struct iqueue_entry *));
|
15
or1ksim/patches/patch-peripheral_atadevice.c
Normal file
15
or1ksim/patches/patch-peripheral_atadevice.c
Normal file
|
@ -0,0 +1,15 @@
|
|||
$NetBSD: patch-peripheral_atadevice.c,v 1.1 2013/10/14 13:00:08 ryo-on Exp $
|
||||
|
||||
--- peripheral/atadevice.c.orig 2011-04-08 10:59:34.000000000 +0000
|
||||
+++ peripheral/atadevice.c
|
||||
@@ -35,6 +35,10 @@
|
||||
#define bswap_16(x) OSSwapInt16(x)
|
||||
#define bswap_32(x) OSSwapInt32(x)
|
||||
#define bswap_64(x) OSSwapInt64(x)
|
||||
+#elif defined(__NetBSD__)
|
||||
+#include <sys/types.h>
|
||||
+#include <machine/bswap.h>
|
||||
+#define bswap_16 bswap16
|
||||
#else
|
||||
#include <byteswap.h>
|
||||
#endif
|
87
or1ksim/patches/patch-peripheral_eth.c
Normal file
87
or1ksim/patches/patch-peripheral_eth.c
Normal file
|
@ -0,0 +1,87 @@
|
|||
$NetBSD: patch-peripheral_eth.c,v 1.1 2013/10/14 13:00:08 ryo-on Exp $
|
||||
|
||||
--- peripheral/eth.c.orig 2011-04-08 10:59:34.000000000 +0000
|
||||
+++ peripheral/eth.c
|
||||
@@ -45,8 +45,18 @@
|
||||
#include <unistd.h>
|
||||
#include <errno.h>
|
||||
|
||||
+#if defined(__linux__)
|
||||
#include <linux/if.h>
|
||||
#include <linux/if_tun.h>
|
||||
+#elif defined(__NetBSD__)
|
||||
+# include <sys/param.h>
|
||||
+# include <sys/sockio.h>
|
||||
+# include <net/if.h>
|
||||
+# include <net/if_tap.h>
|
||||
+# include <net/if_ether.h>
|
||||
+# include <net/if_bridgevar.h>
|
||||
+# include <net/if_tun.h>
|
||||
+#endif
|
||||
|
||||
/* Package includes */
|
||||
#include "arch.h"
|
||||
@@ -959,7 +969,6 @@ eth_open_file_if (struct eth_device *eth
|
||||
}
|
||||
} /* eth_open_file_if () */
|
||||
|
||||
-
|
||||
/* -------------------------------------------------------------------------- */
|
||||
/*!Open the external TAP interface to the Ethernet
|
||||
|
||||
@@ -974,6 +983,7 @@ eth_open_file_if (struct eth_device *eth
|
||||
static void
|
||||
eth_open_tap_if (struct eth_device *eth)
|
||||
{
|
||||
+#if defined(__linux__)
|
||||
struct ifreq ifr;
|
||||
|
||||
/* We don't support re-opening. If it's open, it stays open. */
|
||||
@@ -1010,6 +1020,47 @@ eth_open_tap_if (struct eth_device *eth)
|
||||
#if ETH_DEBUG
|
||||
PRINTF ("Opened TAP %s\n", ifr.ifr_name);
|
||||
#endif
|
||||
+#elif defined(__NetBSD__)
|
||||
+ struct ifreq ifr;
|
||||
+
|
||||
+ /* We don't support re-opening. If it's open, it stays open. */
|
||||
+ if (eth->rtx_fd >= 0)
|
||||
+ {
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
+ /* Open the TUN/TAP device */
|
||||
+ eth->rtx_fd = open ("/dev/tun", O_RDWR);
|
||||
+ if( eth->rtx_fd < 0 )
|
||||
+ {
|
||||
+ fprintf (stderr, "Warning: Failed to open TUN/TAP device: %s\n",
|
||||
+ strerror (errno));
|
||||
+ eth->rtx_fd = -1;
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
+ /* Turn it into a specific TAP device. If we haven't specified a specific
|
||||
+ (persistent) device, one will be created, but that requires superuser, or
|
||||
+ at least CAP_NET_ADMIN capabilities. */
|
||||
+ memset (&ifr, 0, sizeof(ifr));
|
||||
+
|
||||
+ if (ioctl(eth->rtx_fd, TAPGIFNAME, &ifr) < 0)
|
||||
+ return;
|
||||
+
|
||||
+ strncpy (ifr.ifr_name, eth->tap_dev, IFNAMSIZ);
|
||||
+
|
||||
+ if (ioctl (eth->rtx_fd, TUNSIFHEAD, (void *) &ifr) < 0)
|
||||
+ {
|
||||
+ fprintf (stderr, "Warning: Failed to set TAP device %s: %s\n",
|
||||
+ eth->tap_dev, strerror (errno));
|
||||
+ close (eth->rtx_fd);
|
||||
+ eth->rtx_fd = -1;
|
||||
+ return;
|
||||
+ }
|
||||
+#if ETH_DEBUG
|
||||
+ PRINTF ("Opened TAP %s\n", ifr.ifr_name);
|
||||
+#endif
|
||||
+#endif /* linux, NetBSD */
|
||||
} /* eth_open_tap_if () */
|
||||
|
||||
|
58
or1ksim/patches/patch-peripheral_eth.h
Normal file
58
or1ksim/patches/patch-peripheral_eth.h
Normal file
|
@ -0,0 +1,58 @@
|
|||
$NetBSD: patch-peripheral_eth.h,v 1.1 2013/10/14 13:00:09 ryo-on Exp $
|
||||
|
||||
--- peripheral/eth.h.orig 2011-04-08 10:59:34.000000000 +0000
|
||||
+++ peripheral/eth.h
|
||||
@@ -196,19 +196,27 @@
|
||||
#define ETH_HLEN 14
|
||||
#endif /* __CYGWIN__ */
|
||||
|
||||
+#ifndef ETH_HLEN
|
||||
+#define ETH_HLEN 14
|
||||
+#endif
|
||||
+
|
||||
#define ETH_ALEN 6
|
||||
|
||||
+#if !defined(__NetBSD__)
|
||||
struct ether_addr
|
||||
{
|
||||
u_int8_t ether_addr_octet[ETH_ALEN];
|
||||
};
|
||||
+#endif
|
||||
|
||||
+#if !defined(__NetBSD__)
|
||||
struct ether_header
|
||||
{
|
||||
u_int8_t ether_dhost[ETH_ALEN]; /* destination eth addr */
|
||||
u_int8_t ether_shost[ETH_ALEN]; /* source ether addr */
|
||||
u_int16_t ether_type; /* packet type ID field */
|
||||
};
|
||||
+#endif
|
||||
|
||||
/* Ethernet protocol ID's */
|
||||
#define ETHERTYPE_PUP 0x0200 /* Xerox PUP */
|
||||
@@ -216,12 +224,14 @@ struct ether_header
|
||||
#define ETHERTYPE_ARP 0x0806 /* Address resolution */
|
||||
#define ETHERTYPE_REVARP 0x8035 /* Reverse ARP */
|
||||
|
||||
+#if !defined(__NetBSD__)
|
||||
#define ETHER_ADDR_LEN ETH_ALEN /* size of ethernet addr */
|
||||
#define ETHER_TYPE_LEN 2 /* bytes in type field */
|
||||
#define ETHER_CRC_LEN 4 /* bytes in CRC field */
|
||||
#define ETHER_HDR_LEN ETH_HLEN /* total octets in header */
|
||||
#define ETHER_MIN_LEN (ETH_ZLEN + ETHER_CRC_LEN) /* min packet length */
|
||||
#define ETHER_MAX_LEN (ETH_FRAME_LEN + ETHER_CRC_LEN) /* max packet length */
|
||||
+#endif
|
||||
|
||||
/* make sure ethenet length is valid */
|
||||
#define ETHER_IS_VALID_LEN(foo) \
|
||||
@@ -235,8 +245,10 @@ struct ether_header
|
||||
#define ETHERTYPE_TRAIL 0x1000 /* Trailer packet */
|
||||
#define ETHERTYPE_NTRAILER 16
|
||||
|
||||
+#if !defined(__NetBSD__)
|
||||
#define ETHERMTU ETH_DATA_LEN
|
||||
#define ETHERMIN (ETHER_MIN_LEN-ETHER_HDR_LEN-ETHER_CRC_LEN)
|
||||
+#endif
|
||||
|
||||
#endif /* HAVE_NET_ETHERNET_H */
|
||||
|
Loading…
Reference in a new issue