summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrian Jones <cbj@gnu.org>2000-11-28 00:16:15 +0000
committerBrian Jones <cbj@gnu.org>2000-11-28 00:16:15 +0000
commit466c6d811d514503622d2dd79b662d3d80b7026d (patch)
tree2a83891c78593e69d64a03d29c6b947386351205
parent78e85bd6bcbdc31ec042c2cf173827b18af0249f (diff)
downloadclasspath-466c6d811d514503622d2dd79b662d3d80b7026d.tar.gz
* acconfig.h: added DEBUG
* configure.in: Add Configuration.java to CONFIG_FILES. Set LIBGCJDEBUG substitution if --enable-libgcj-debug is specified * gnu/Makefile.am: added classpath to SUBDIRS * gnu/classpath/.cvsignore: New file * gnu/classpath/Configuration.java.in: New file * gnu/classpath/Makefile.am: New file
-rw-r--r--acconfig.h3
-rw-r--r--configure.in22
-rw-r--r--gnu/Makefile.am2
-rw-r--r--gnu/classpath/.cvsignore2
-rw-r--r--gnu/classpath/Configuration.java.in41
-rw-r--r--gnu/classpath/Makefile.am5
6 files changed, 74 insertions, 1 deletions
diff --git a/acconfig.h b/acconfig.h
index 73c3c9a25..fcde42237 100644
--- a/acconfig.h
+++ b/acconfig.h
@@ -18,6 +18,9 @@
/* #undef PACKAGE */
/* #undef VERSION */
+/* Define as 1 if building with debugging code included, this is not -g */
+#define DEBUG 0
+
/************************************************************************
* Leave the blank line there, required by autoheader.
************************************************************************/
diff --git a/configure.in b/configure.in
index e84e88c6f..e378db17d 100644
--- a/configure.in
+++ b/configure.in
@@ -195,6 +195,26 @@ AC_SUBST(DEVEL)
dnl -----------------------------------------------------------
+
+dnl -----------------------------------------------------------
+dnl Enable debugging statements at compile time. By default
+dnl these statements should be optimized out of the bytecode
+dnl produced by an optimizing Java compiler and not hinder
+dnl performance.
+dnl -----------------------------------------------------------
+LIBGCJDEBUG="false"
+AC_ARG_ENABLE(libgcj-debug,
+[ --enable-libgcj-debug enable runtime debugging code],
+ if test "$enable_libgcj_debug" = yes; then
+ AC_DEFINE(DEBUG)
+ LIBGCJDEBUG="true"
+ fi)
+]
+AC_SUBST(LIBGCJDEBUG)
+
+dnl -----------------------------------------------------------
+
+
dnl -----------------------------------------------------------
dnl This takes care of autodetecting our preferred VM when one
dnl isn't specified explicitly.
@@ -265,6 +285,8 @@ com/sun/Makefile
com/sun/javadoc/Makefile
doc/Makefile
gnu/Makefile
+gnu/classpath/Makefile
+gnu/classpath/Configuration.java
gnu/java/Makefile
gnu/java/awt/Makefile
gnu/java/awt/image/Makefile
diff --git a/gnu/Makefile.am b/gnu/Makefile.am
index 05b120b07..fd8524d75 100644
--- a/gnu/Makefile.am
+++ b/gnu/Makefile.am
@@ -1,4 +1,4 @@
## Input file for automake to generate the Makefile.in used by configure
-SUBDIRS = java tools
+SUBDIRS = classpath java tools
diff --git a/gnu/classpath/.cvsignore b/gnu/classpath/.cvsignore
new file mode 100644
index 000000000..282522db0
--- /dev/null
+++ b/gnu/classpath/.cvsignore
@@ -0,0 +1,2 @@
+Makefile
+Makefile.in
diff --git a/gnu/classpath/Configuration.java.in b/gnu/classpath/Configuration.java.in
new file mode 100644
index 000000000..5b9781cdd
--- /dev/null
+++ b/gnu/classpath/Configuration.java.in
@@ -0,0 +1,41 @@
+/* gnu.classpath.Configuration
+ Copyright (C) 1998 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+02111-1307 USA.
+
+As a special exception, if you link this library with other files to
+produce an executable, this library does not by itself cause the
+resulting executable to be covered by the GNU General Public License.
+This exception does not however invalidate any other reasons why the
+executable file might be covered by the GNU General Public License. */
+
+package gnu.classpath;
+
+/**
+ * This file defines compile-time constants that can be accessed by
+ * java code. It is pre-processed by configure.
+ */
+public interface Configuration
+{
+ // The value of DEBUG is substituted according to whether the
+ // "--enable-libgcj-debug" argument was passed to configure. Code
+ // which is made conditional based on the value of this flag will
+ // be removed by the optimizer in a non-debug build.
+
+ boolean DEBUG = @LIBGCJDEBUG@;
+}
diff --git a/gnu/classpath/Makefile.am b/gnu/classpath/Makefile.am
new file mode 100644
index 000000000..ef33ebd4b
--- /dev/null
+++ b/gnu/classpath/Makefile.am
@@ -0,0 +1,5 @@
+## Input file for automake to generate the Makefile.in used by configure
+
+EXTRA_DIST = \
+Configuration.java.in
+