Subject: toolchain/18246: .cpp C++ suffix not supported by standard makefiles
To: None <gnats-bugs@gnats.netbsd.org>
From: None <Andrew.E.White@motorola.com>
List: netbsd-bugs
Date: 09/09/2002 19:21:22
>Number:         18246
>Category:       toolchain
>Synopsis:       .cpp C++ suffix not supported by standard makefiles
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    toolchain-manager
>State:          open
>Class:          change-request
>Submitter-Id:   net
>Arrival-Date:   Mon Sep 09 19:22:00 PDT 2002
>Closed-Date:
>Last-Modified:
>Originator:     Andrew White
>Release:        1.5.3
>Organization:
MARC
>Environment:
NetBSD thor 1.5.3 NetBSD 1.5.3 (GENERIC) #0: Tue Aug 27 17:42:36 EST 2002     awhite@thor:/usr/src/sys/usr/src/sys/arch/i386/compile/GENERIC i386
>Description:
On PC/Mac platforms, C++ files tend to use the .cpp file suffix.  This suffix is not supported by the BSD makefiles, which makes porting painful.
>How-To-Repeat:
Try to compile any file using a .cpp suffix using the standard Makefile toolchain.  Note that system rules work, but the special toolchain rules don't.
>Fix:
Change the following files in /usr/share/mk: bsd.dep.mk, bsd.hostprog.mk, bsd.lib.mk, bsd.prog.mk, bsd.sys.mk to add .cpp suffix (and perhaps .cxx) wherever .cc appears.

I note bsd.sys.mk already includes .cpp and .cxx support.
>Release-Note:
>Audit-Trail:
>Unformatted: