From 5593486d72c2e54723cccc768840647245df2ac4 Mon Sep 17 00:00:00 2001 From: idgay Date: Wed, 11 Apr 2007 21:36:53 +0000 Subject: [PATCH] add %P to ncc to stay in line with the storage volume tool --- tools/tinyos/ncc/ncc.1 | 7 ++++--- tools/tinyos/ncc/ncc.in | 1 + 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/tools/tinyos/ncc/ncc.1 b/tools/tinyos/ncc/ncc.1 index f04e1433..25995a82 100644 --- a/tools/tinyos/ncc/ncc.1 +++ b/tools/tinyos/ncc/ncc.1 @@ -85,9 +85,10 @@ If you wish to compile a component Bar.nc to a C file, you can do: ncc -c -o /dev/null -fnesc-cfile=Bar.c Bar.nc .SH SEARCH PATH -\fBncc\fR performs the following substitutions on the directories specified -with the \fB-I\fR option: \fB%T\fR is replaced by the TinyOS directory, -\fB%p\fR is replaced by the selected target, \fB%%\fR is replaced by +\fBncc\fR performs the following substitutions on the directories +specified with the \fB-I\fR option: \fB%T\fR is replaced by the TinyOS +directory, \fB%p\fR is replaced by the selected target, \fB%P\fR is +replaced by the target's platform directory, \fB%%\fR is replaced by \fB%\fR. Except when \fB-nostdinc\fR is specified, the search path for nesC diff --git a/tools/tinyos/ncc/ncc.in b/tools/tinyos/ncc/ncc.in index 7ae3c0a2..2adbaa52 100644 --- a/tools/tinyos/ncc/ncc.in +++ b/tools/tinyos/ncc/ncc.in @@ -262,6 +262,7 @@ sub idir_subst { $rep = "%" if $char eq "%"; $rep = $TOSDIR if $char eq "T"; $rep = $target if $char eq "p"; + $rep = $platform_dir if $char eq "P"; &fail("unknown include-path substitution %" . $char) if !$rep; substr($idir, $idx, 2) = $rep; $idx += length $rep; -- 2.39.2