[m-rev.] For review: implement library building for Java.

James Goddard goddardjames at yahoo.com
Thu Feb 12 18:21:11 AEDT 2004


Estimated hours taken: 1
Branches: main

compiler/modules.m:
	Implement library building for Java.


Index: modules.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/modules.m,v
retrieving revision 1.290
diff -u -d -r1.290 modules.m
--- modules.m	12 Feb 2004 02:48:32 -0000	1.290
+++ modules.m	12 Feb 2004 04:36:44 -0000
@@ -4791,6 +4791,7 @@
 							SharedLibFileName),
 	module_name_to_lib_file_name("lib", ModuleName,
 		".$(EXT_FOR_SHARED_LIB)", no, MaybeSharedLibFileName),
+	module_name_to_file_name(ModuleName, ".jar", no, JarFileName),
 
 	{ AllInts = [
 		"$(", MakeVarName, ".ints) ",
@@ -4804,7 +4805,7 @@
 		| AllInts
 	] },
 	{ JavaLibRule = [
-		LibTargetName, " : ", "$(", MakeVarName, ".classes) \\\n\t\t"
+		LibTargetName, " : ", JarFileName, " \\\n\t\t"
 		| AllInts
 	] },
 	{ LibRule = [
@@ -4847,6 +4848,12 @@
 		"\t$(AR) $(ALL_ARFLAGS) $(AR_LIBFILE_OPT)", LibFileName, " ",
 			"$(", MakeVarName, ".os) ", All_MLObjsString, "\n",
 		"\t$(RANLIB) $(ALL_RANLIBFLAGS) ", LibFileName, "\n\n"
+	]),
+
+	io__write_strings(DepStream, [
+		JarFileName, " : ", "$(", MakeVarName, ".classes)\n",
+		"\t$(JAR) $(JAR_CREATE_FLAGS) ", JarFileName,
+		" $(", MakeVarName, ".classes)\n"
 	]),
 
 	module_name_to_file_name(ModuleName, ".dep", no, DepFileName),
--------------------------------------------------------------------------
mercury-reviews mailing list
post:  mercury-reviews at cs.mu.oz.au
administrative address: owner-mercury-reviews at cs.mu.oz.au
unsubscribe: Address: mercury-reviews-request at cs.mu.oz.au Message: unsubscribe
subscribe:   Address: mercury-reviews-request at cs.mu.oz.au Message: subscribe
--------------------------------------------------------------------------



More information about the reviews mailing list