Subject: C++ and host-mkdep
To: None <tech-toolchain@NetBSD.org>
From: Julio M. Merino Vidal <jmmv84@gmail.com>
List: tech-toolchain
Date: 07/08/2007 16:20:31
--Apple-Mail-1--561198595
Content-Transfer-Encoding: 7bit
Content-Type: text/plain;
	charset=US-ASCII;
	delsp=yes;
	format=flowed

Hi,

[ Please CC me any replies. ]

I was trying to add a new host tool (written in C++) to src/tools.   
While doing so, I noticed some build errors because the native  
preprocessor did not recognize the -cxx-isystem option, while our  
build system uses it (or at least that's why I think it failed).   
(This happened with NetBSD-current as the host system, by the way.)

I fixed this issue with the attached patch.  Is it OK to commit?

Let me also size this post to ask something else:  Would it be OK to  
add a C++ host tool to the tools or would this be too painful?  (I  
see that there is already support to build C++ host tools, so it  
doesn't seem like a too strange thing.)

Thanks,

--Apple-Mail-1--561198595
Content-Transfer-Encoding: 7bit
Content-Type: application/octet-stream;
	x-unix-mode=0644;
	name=patch.diff
Content-Disposition: attachment;
	filename=patch.diff

Index: host-mkdep.in
===================================================================
RCS file: /cvsroot/src/tools/host-mkdep/host-mkdep.in,v
retrieving revision 1.16
diff -u -p -r1.16 host-mkdep.in
--- host-mkdep.in	1 Sep 2005 21:51:11 -0000	1.16
+++ host-mkdep.in	8 Jul 2007 14:13:44 -0000
@@ -137,7 +137,7 @@ else
 				shift 2
 				;;
 				
-		-isystem-cxx)
+		-isystem-cxx|-cxx-isystem)
 				CPPFLAGS="$CPPFLAGS -isystem $2"
 				shift 2
 				;;

--Apple-Mail-1--561198595
Content-Transfer-Encoding: 7bit
Content-Type: text/plain;
	charset=US-ASCII;
	format=flowed


-- 
Julio M. Merino Vidal <jmmv84@gmail.com>



--Apple-Mail-1--561198595--