This is the mail archive of the
java-patches@gcc.gnu.org
mailing list for the Java project.
Patch: set java.ext.dirs property
- From: Anthony Green <green at redhat dot com>
- To: java-patches at gcc dot gnu dot org
- Date: Wed, 19 May 2004 09:52:55 -0700
- Subject: Patch: set java.ext.dirs property
- Organization: Red Hat, Inc.
This patch sets the java.ext.dirs property to the same directory gcj
uses to find extensions.
A follow-on patch will actually add the contents of the java.ext.dirs to
java.class.path, but for now - is this OK?
2004-05-19 Anthony Green <green@redhat.com>
* Makefile.am: Define JAVA_EXT_DIRS.
* Makefile.in: Rebuilt.
* java/lang/natRuntime.cc (insertSystemProperties): Set
java.ext.dirs property.
Index: Makefile.am
===================================================================
RCS file: /cvs/gcc/gcc/libjava/Makefile.am,v
retrieving revision 1.375
diff -c -u -p -r1.375 Makefile.am
--- Makefile.am 6 May 2004 10:25:01 -0000 1.375
+++ Makefile.am 19 May 2004 16:49:50 -0000
@@ -113,7 +113,8 @@ AM_CXXFLAGS = -fno-rtti -fnon-call-excep
-Wswitch-enum \
@LIBGCJ_CXXFLAGS@ @X_CFLAGS@ $(WARNINGS) -D_GNU_SOURCE \
-DPREFIX="\"$(prefix)\"" -DLIBDIR="\"$(libdir)\"" \
- -DBOOT_CLASS_PATH="\"$(jardir)/$(jar_DATA)\""
+ -DBOOT_CLASS_PATH="\"$(jardir)/$(jar_DATA)\"" \
+ -DJAVA_EXT_DIRS="\"$(jardir)/ext\""
if USING_GCC
AM_CFLAGS = @LIBGCJ_CFLAGS@ $(WARNINGS)
else
Index: java/lang/natRuntime.cc
===================================================================
RCS file: /cvs/gcc/gcc/libjava/java/lang/natRuntime.cc,v
retrieving revision 1.40
diff -c -u -p -r1.40 natRuntime.cc
--- java/lang/natRuntime.cc 16 Dec 2003 21:48:23 -0000 1.40
+++ java/lang/natRuntime.cc 19 May 2004 16:49:55 -0000
@@ -592,6 +592,9 @@ java::lang::Runtime::insertSystemPropert
// The name used to invoke this process (argv[0] in C).
SET ("gnu.gcj.progname", _Jv_GetSafeArg (0));
+ // The the java extensions directory.
+ SET ("java.ext.dirs", JAVA_EXT_DIRS);
+
// Allow platform specific settings and overrides.
_Jv_platform_initProperties (newprops);
AG
--
Anthony Green <green@redhat.com>
Red Hat, Inc.