2
0
mirror of https://github.com/boostorg/build.git synced 2026-02-14 00:32:11 +00:00

Don't pass command line options which bcc32c can not handle.

This commit is contained in:
Edward Diener
2020-02-17 13:25:19 -05:00
parent a76e5a6c6f
commit 7c1ae7d6b1

View File

@@ -9,9 +9,10 @@
[[bbv2.reference.tools.compiler.borland]]
= Borland C++ Compiler
The `borland` module supports the command line C++ compiler included in
http://www.borland.com/us/products/cbuilder/index.html[C++ Builder 2006]
product and earlier version of it, running on Microsoft Windows.
The `borland` module supports the 32-bit command line C++ compilers
running on Microsoft Windows. This is the bcc32 executable for all
versions of Borland C++ and C++ Builder, as well as the command line
compatible compiler bcc32c on later versions of C++ Builder.
The supported products are listed below. The version reported by the
command lines tools is also listed for reference.:
@@ -51,6 +52,10 @@ and C++ sources.
`linkflags`::
Specifies additional command line options that will be passed to the linker.
`user-interface`::
Specifies the user interface for applications. Valid choices are `console`
for a console applicatiuon and `gui` for a Windows application.
|# # end::doc[]
# Support for the Borland's command line compiler
@@ -68,13 +73,16 @@ feature.extend toolset : borland ;
rule init ( version ? : command * : options * )
{
local condition = [ common.check-init-parameters borland :
version $(version) ] ;
local command = [ common.get-invocation-command borland : bcc32.exe
: $(command) ] ;
common.handle-options borland : $(condition) : $(command) : $(options) ;
common.handle-options borland : $(condition) : $(command) : $(options) ;
local just_bcc32 = [ MATCH ".*(bcc32)([^a-z0-9]|$)" : $(command:L) ] ;
if $(command)
{
@@ -101,6 +109,11 @@ rule init ( version ? : command * : options * )
{
init-later-releases $(condition) ;
}
if $(just_bcc32) && ( $(just_bcc32[1]) = bcc32 )
{
flags borland.compile OPTIONS $(condition) : -g255 -Vx- -Ve- ;
}
}
local rule init-earlier-releases ( condition )
@@ -204,13 +217,13 @@ flags borland NEED_IMPLIB <main-target-type>LIB/<link>shared : "" ;
actions compile.c++
{
"$(CONFIG_COMMAND)" -j5 -g255 -q -c -P -a8 -Vx- -Ve- -b- $(OPTIONS) -D$(DEFINES) -I"$(INCLUDES)" -I"$(STDHDRS)" -o"$(<)" "$(>)"
"$(CONFIG_COMMAND)" -j5 -q -c -P -a8 -b- $(OPTIONS) -D$(DEFINES) -I"$(INCLUDES)" -I"$(STDHDRS)" -o"$(<)" "$(>)"
}
# For C, we don't pass -P flag
actions compile.c
{
"$(CONFIG_COMMAND)" -j5 -g255 -q -c -a8 -Vx- -Ve- -b- $(OPTIONS) -D$(DEFINES) -I"$(INCLUDES)" -I"$(STDHDRS)" -o"$(<)" "$(>)"
"$(CONFIG_COMMAND)" -j5 -q -c -a8 -b- $(OPTIONS) -D$(DEFINES) -I"$(INCLUDES)" -I"$(STDHDRS)" -o"$(<)" "$(>)"
}