From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (from majordomo@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id LAA27131; Thu, 4 Jul 2002 11:15:26 +0200 (MET DST) X-Authentication-Warning: pauillac.inria.fr: majordomo set sender to owner-caml-list@pauillac.inria.fr using -f Received: (from weis@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id LAA27029 for caml-list@pauillac.inria.fr; Thu, 4 Jul 2002 11:15:26 +0200 (MET DST) Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id CAA21042 for ; Thu, 4 Jul 2002 02:17:05 +0200 (MET DST) Received: from sarg.ryerson.ca (sarg.ryerson.ca [141.117.18.117]) by nez-perce.inria.fr (8.11.1/8.11.1) with ESMTP id g640H4H17710 for ; Thu, 4 Jul 2002 02:17:04 +0200 (MET DST) Received: from sarg.ryerson.ca (dmason@localhost) by sarg.ryerson.ca (8.11.2/8.11.2) with ESMTP id g640H1p30536; Wed, 3 Jul 2002 20:17:01 -0400 Message-Id: <200207040017.g640H1p30536@sarg.ryerson.ca> To: caml-list@inria.fr, dmason@sarg.ryerson.ca Subject: [Caml-list] The CDK looks marvelous... but... User-Agent: EMH/1.10.0 SEMI/1.13.7 (Awazu) CLIME/1.13.6 (=?ISO-2022-JP?B?GyRCQ2YlTj4xGyhC?=) MULE XEmacs/21.1 (patch 14) (Cuyahoga Valley) (alpha-redhat-linux) MIME-Version: 1.0 (generated by SEMI 1.13.7 - "Awazu") Content-Type: text/plain; charset=US-ASCII Date: Wed, 03 Jul 2002 20:17:01 -0400 From: Dave Mason Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk Hi, First off, the CDK is looking good. There is a bunch of really cool stuff happening there. But it needs some cleanup (which I don't think would be all that difficult to do, for someone familiar with it). Let me give you the scenario of my last couple of hours. (I may omit some of the frustrations, but you'll get the sense of it. If you get bored, skip to after point 9.) 1) I want to use the stuff in cdk/network, so I check out that subdirectory. I try a make. It dies in an ugly way, indirectly saying that it needs the config directory. 2) I go up a level and say `cvs update -d config', then go there and run configure. But it's trying to put something into camlimages, which doesn't exist, so it dies again. I go get camlimages, and some other directory and eventually everything is cool, so I go back to network and try make again. It wants cdk_config. It's not in the config directory - too obvious. 3) I go and poke around in the browsable CVS tree. I find it in tools. So I go up a level again and say `cvs update -d tools', then go there and say make. It wants OCAML_SRC/boot/ocamlyacc. But I don't have the ocaml source installed, I installed from the RPM. I track down that it's in cdk/Makefile.generic in the dependency for TMPSOURCES, so I edit that line, and do a make in the tools directory. Everything is cool again, except it tries to copy the cdk_config binary into cdk/bin, but I don't have that directory, so I mkdir it, and run make again.... it doesn't copy the file... and it wouldn't matter anyway because the cdk/bin directory isn't in my PATH. So I fix it, go back to network and try again. No-go - it wants unix2.. so I get it. 4) Make doesn't work in unix2... 5) Somewhere there were compiles that needed .cmi files, but there was no dependency in the Makefile, so I compiled them all by hand. (Unix2 is one of these). 6) The makefiles use features of tools that presumably exist in the CVS version of the compiler, but not in the current release version (like -subdir for ocamlc.opt and ocamldep). 7) Many of the directories in CDK don't even have README files to give a hint what they might be useful for. 8) I give up and download the whole cdk. I go to the cdk directory and type make. No go... tools wants to install ocaml from some tar file! (I figure out that ``make .depend byte opt'' will do close to what I want, without that stage.) 9) All of this pain was on Linux, for heaven's sake! God forbid I was trying it on Windows... (not that I'm a fan... but in this case being able to build on Windows was one of the reasons I was trying to use CDK in the first place) Sigh. There is *so* much potential here.... we're getting close to a critical mass of code. But I can't even *try* to use a particular piece of the CDK. It's NOT unreasonable for there to be some dependencies between parts of the CDK, but it *is* unreasonable for me to have to (a) (re-)install ocaml from the CVS version; (b) install all of the CDK, or (c) have the build process die in ugly ways at every turn if I try to do it incrementally. I have some specific suggestions for whoever is overall responsible for the CDK. 1) Let's assume gmake. I assume it's available for Windows. 2) Have the config directory not try to modify files outside itself. Put cdk_config in the config directory. 3) At the beginning of every makefile put a line like: DEPENDS_ON=unit1 unit2 ... Follow this with an include of Makefile code that loops through DEPENDS_ON and checks for a file called ../unit1/.built, ../unit2/.built, etc. and gives a reasonable error for anything missing. (It could even offer to load it if there is a ../CVS directory - it could `cd ..;cvs update -d unit1;cd unit1;make'). 4) That makefile should have `all' depend on `.built', and the current dependencies for `all' should instead depend on .built, and the recipe for .built should touch the file. (Or add a recipe for `all' that touches it, and use `all' instead of `.built' in suggestion 3.) 5) Make sure everything possible builds with the current ocaml. There may be a few parts that don't but they better not be in many dependency trees. 6) Periodically, try removing all the cdk subdirectories except for config and the one under test and try a make. Minimize the gratuitous dependencies. If nobody else is responsible for this and/or willing to do it, I wouldn't mind working on it. This isn't quite the PTAN model of down-loadable components, but it would be a step in that direction. ../Dave ------------------- To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/ Beginner's list: http://groups.yahoo.com/group/ocaml_beginners