:action depend for D
"Lars Ivar Igesund" <[email protected]>
| Newsgroups | gmane.comp.tools.aap.devel |
|---|---|
| Message-ID | <046d01c39ed5$2ce00f50$0200000a@mesmer> |
I have now created a dependency checker for D (in D). Attached is a diff for d.aap (adds action depend, and an :assertpkg for the dependencychecker). The depend action is tested and works on Windows (no reason it shouldn't work in Linux, but it isn't tested yet). Also attached is a minor doc change to ref-modules, since the DIMPORTS variable is used by the depchecker. And also attached is the depchkd src and a bootscript (I have no idea if it works...) If you don't want to host depchkd, I can do that myself. It might offload you from needing to update depchkd when it changes (and it will change). Lars Ivar Igesund
boot.aap
(application/octet-stream, 592 B) - not displayed
depchkd.d
(application/octet-stream, 9.1 KB) - not displayed
docmod.diff
(application/octet-stream, 1022 B)
Index: ref-modules.sgml
===================================================================
RCS file: /cvsroot/a-a-p/Exec/doc/ref-modules.sgml,v
retrieving revision 1.5
diff -u -r1.5 ref-modules.sgml
--- ref-modules.sgml 18 Oct 2003 15:10:17 -0000 1.5
+++ ref-modules.sgml 29 Oct 2003 16:38:29 -0000
@@ -122,8 +122,10 @@
<entry valign="top"><anchor id="var-dimport"/> $DIMPORT </entry>
<entry valign="top"> user </entry>
<entry valign="top"> Import directories used for the D compiler.
- Always use the "-Idir" form, the tool will convert it to what
- the compiler actually uses.</entry>
+ Always use the "-Ipath" form and don't use it for other
+ switches. A-A-P will convert it to what the compiler actually
+ uses. This variable is also used when checking for dependencies.
+ </entry>
</row>
<row>
<entry valign="top"><anchor id="var-dversion"/> $DVERSION </entry>
d.diff
(application/octet-stream, 1.1 KB)
Index: d.aap
===================================================================
RCS file: /cvsroot/a-a-p/Exec/modules/d.aap,v
retrieving revision 1.6
diff -u -r1.6 d.aap
--- d.aap 18 Oct 2003 15:11:22 -0000 1.6
+++ d.aap 30 Oct 2003 10:49:49 -0000
@@ -5,15 +5,8 @@
# If this file is missing you can find it here: http://www.a-a-p.org/COPYING
#
-# Last Change: 2003 Oct 12
+# Last Change: 2003 Oct 30
-# Info on this module/ TODO:
-
-# :action depend has not been implemented. 2003-09-13
-#
-# Documentation must be written. DMD, DFLAGS, DLINKFLAGS must be mentioned
-# explicitly. 2003-09-21
-#
# See also dmd.py in the tools directory for compiler specific info.
# (1) Filetype recognition
@@ -32,7 +25,16 @@
# The first one found sets $D_COMPILE_ACTION and friends.
:toolsearch dmd
+# (4.5) Check for dependency checker. If not present, download it.
+:assertpkg depchkd
+
# (5) Actions, Rules and Routes
+
+# :do depend
+
+:action depend {recursive}
+ {buildcheck = $DMD $?DFLAGS $?DVERSION $?DDEBUG $?DIMPORT } d
+ :sys depchkd -m $?DIMPORT $source > $target
# :do compile