summaryrefslogtreecommitdiff
path: root/nuttx/tools
diff options
context:
space:
mode:
authorpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2012-11-22 21:21:48 +0000
committerpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2012-11-22 21:21:48 +0000
commit5d8459bbc994e69d80127776d82faa185ae42f9c (patch)
treeb1cedf03182e51f612878a90c78bb0d3a65aa1d6 /nuttx/tools
parent6bb69076e50b9dec9f3735fa8f9e168e99f6bba7 (diff)
downloadpx4-nuttx-5d8459bbc994e69d80127776d82faa185ae42f9c.tar.gz
px4-nuttx-5d8459bbc994e69d80127776d82faa185ae42f9c.tar.bz2
px4-nuttx-5d8459bbc994e69d80127776d82faa185ae42f9c.zip
A few more Windows native build fixes for eZ80
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@5383 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'nuttx/tools')
-rwxr-xr-xnuttx/tools/incdir.bat35
1 files changed, 33 insertions, 2 deletions
diff --git a/nuttx/tools/incdir.bat b/nuttx/tools/incdir.bat
index a53afdd47..093c5bd2e 100755
--- a/nuttx/tools/incdir.bat
+++ b/nuttx/tools/incdir.bat
@@ -55,16 +55,34 @@ if "%1"=="" (
echo ERROR: Missing compiler name
goto :Usage
)
+
+set ccpath=%1
shift
-rem Generate the compiler include path directives. Easy since only MinGW is
-rem supported
+set compiler=
+for /F %%i in ("%ccpath%") do set compiler=%%~ni
if "%1"=="" (
echo ERROR: Missing directory paths
goto :Usage
)
+rem Check for some well known, non-GCC Windows native tools that require
+rem a special output format as well as special paths
+
+:GetFormat
+set fmt=std
+if "%compiler%"=="ez8cc" goto :SetZdsFormt
+if "%compiler%"=="zneocc" goto :SetZdsFormt
+if "%compiler%"=="ez80cc" goto :SetZdsFormt
+goto :GeneratePaths
+
+:SetZdsFormt
+set fmt=zds
+
+rem Generate the compiler include path directives.
+
+:GeneratePaths
set response=
:DirLoop
@@ -78,11 +96,24 @@ if not exist %1 (
goto :Usage
)
+if "%fmt%"=="zds" goto :GenerateZdsPath
+
if "%response"=="" (
set response=-I "%1"
) else (
set response=%response% -I "%1"
)
+goto :EndOfDirLoop
+
+:GenerateZdsPath
+
+if "%response"=="" (
+ set response=-usrinc:%1
+) else (
+ set response=%response%;%1
+)
+
+:EndOfDirLoop
shift
goto :DirLoop