/usr/share/boost-build/src/tools
NameSizeModeActions
doxygen/-0755rm
features/-0755rm
generators/-0755rm
types/-0755rm
xsltproc/-0755rm
acc.jam48000644editdlrm
asciidoctor.jam64800644editdlrm
auto-index.jam83240644editdlrm
bison.jam5890644editdlrm
boostbook-config.jam3890644editdlrm
boostbook.jam240560644editdlrm
borland.jam99920644editdlrm
builtin.jam30370644editdlrm
bzip2.jam80660644editdlrm
cast.jam32370644editdlrm
clang-darwin.jam67130644editdlrm
clang-linux.jam99840644editdlrm
clang-vxworks.jam40260644editdlrm
clang-win.jam60940644editdlrm
clang.jam23100644editdlrm
common.jam316790644editdlrm
como-linux.jam35280644editdlrm
como-win.jam42370644editdlrm
como.jam20630644editdlrm
convert.jam19870644editdlrm
cray.jam411280644editdlrm
cw-config.jam12830644editdlrm
cw.jam95490644editdlrm
cygwin.jam4030644editdlrm
darwin.jam221650644editdlrm
diab.jam43070644editdlrm
dmc.jam60940644editdlrm
docutils.jam34440644editdlrm
doxproc.py366210644editdlrm
doxygen-config.jam3880644editdlrm
doxygen.jam247450644editdlrm
embarcadero.jam214870644editdlrm
emscripten.jam37790644editdlrm
flags.jam45700644editdlrm
fop.jam16930644editdlrm
fortran.jam19890644editdlrm
gcc.jam552880644editdlrm
generate.jam33390644editdlrm
gettext.jam76630644editdlrm
gfortran.jam10080644editdlrm
hpfortran.jam9020644editdlrm
hp_cxx.jam80890644editdlrm
ifort.jam14950644editdlrm
intel-darwin.jam97850644editdlrm
intel-linux.jam91930644editdlrm
intel-vxworks.jam70850644editdlrm
intel-win.jam163960644editdlrm
intel.jam26260644editdlrm
lex.jam5590644editdlrm
libjpeg.jam73620644editdlrm
libpng.jam71040644editdlrm
libtiff.jam72080644editdlrm
link.jam150210644editdlrm
lzma.jam32770644editdlrm
make.jam22660644editdlrm
mc.jam13110644editdlrm
message.jam16670644editdlrm
midl.jam53670644editdlrm
mipspro.jam52910644editdlrm
mpi.jam218260644editdlrm
msvc-config.jam3930644editdlrm
msvc.jam846720644editdlrm
notfile.jam16540644editdlrm
openssl.jam36130644editdlrm
package.jam92810644editdlrm
pathscale.jam66290644editdlrm
pch.jam27190644editdlrm
pgi.jam48790644editdlrm
pkg-config.jam134430644editdlrm
python-config.jam8360644editdlrm
python.jam436790644editdlrm
qcc.jam108360644editdlrm
qt.jam5300644editdlrm
qt3.jam68100644editdlrm
qt4.jam239740644editdlrm
qt5.jam265170644editdlrm
quickbook-config.jam12660644editdlrm
quickbook.jam132770644editdlrm
rc.jam53640644editdlrm
sass.jam57020644editdlrm
saxonhe.jam13290644editdlrm
stage.jam285130644editdlrm
stlport.jam118800644editdlrm
sun.jam80540644editdlrm
symlink.jam43510644editdlrm
testing-aux.jam102380644editdlrm
testing.jam278890644editdlrm
unix.jam58470644editdlrm
vacpp.jam57250644editdlrm
vmsdecc.jam201850644editdlrm
whale.jam32530644editdlrm
xlcpp.jam61210644editdlrm
xlf.jam9000644editdlrm
xsltproc-config.jam8380644editdlrm
xsltproc.jam56030644editdlrm
zlib.jam69760644editdlrm
zstd.jam24460644editdlrm
Edit: /usr/share/boost-build/src/tools/cw.jam (9549B)
# Copyright (C) Reece H Dunn 2004 # Distributed under the Boost Software License, Version 1.0. # (See accompanying file LICENSE_1_0.txt or copy at # http://www.boost.org/LICENSE_1_0.txt) #| tag::doc[] [[bbv2.reference.tools.compiler.cw]] = Code Warrior The `cw` module support CodeWarrior compiler, originally produced by Metrowerks and presently developed by Freescale. B2 supports only the versions of the compiler that target x86 processors. All such versions were released by Metrowerks before acquisition and are not sold any longer. The last version known to work is 9.4. The module is initialized using the following syntax: ---- using cw : [version] : [c++-compile-command] : [compiler options] ; ---- This statement may be repeated several times, if you want to configure several versions of the compiler. If the command is not specified, B2 will search for a binary named `mwcc` in default installation paths and in PATH. The following options can be provided, using _`option-value syntax`_: `cflags`:: Specifies additional compiler flags that will be used when compiling C sources. `cxxflags`:: Specifies additional compiler flags that will be used when compiling C++ sources. `compileflags`:: Specifies additional compiler flags that will be used when compiling both C and C++ sources. `linkflags`:: Specifies additional command line options that will be passed to the linker. `setup`:: The command that sets up environment variables prior to invoking the compiler. If not specified, `cwenv.bat` alongside the compiler binary will be used. `compiler`:: The command that compiles C and C++ sources. If not specified, `mwcc` will be used. The command will be invoked after the setup script was executed and adjusted the PATH variable. `linker`:: The command that links executables and dynamic libraries. If not specified, `mwld` will be used. The command will be invoked after the setup script was executed and adjusted the PATH variable. |# # end::doc[] # based on the msvc.jam toolset import property ; import generators ; import os ; import type ; import toolset : flags ; import errors : error ; import feature : feature get-values ; import path ; import sequence : unique ; import common ; if [ MATCH (--debug-configuration) : [ modules.peek : ARGV ] ] { .debug-configuration = true ; } feature.extend toolset : cw ; toolset.add-requirements cw,shared:multi ; nl = " " ; rule init ( version ? : command * : options * ) { # TODO: fix the $(command[1]) = $(compiler) issue setup = [ get-values : $(options) ] ; setup ?= cwenv.bat ; compiler = [ get-values : $(options) ] ; compiler ?= mwcc ; linker = [ get-values : $(options) ] ; linker ?= mwld ; local condition = [ common.check-init-parameters cw : version $(version) ] ; command = [ common.get-invocation-command cw : mwcc.exe : $(command) : [ default-paths $(version) ] ] ; common.handle-options cw : $(condition) : $(command) : $(options) ; local root = [ feature.get-values : $(options) ] ; if $(command) { command = [ common.get-absolute-tool-path $(command[-1]) ] ; } local tool-root = $(command) ; setup = $(tool-root)\\$(setup) ; # map the batch file in setup so it can be executed other-tools = $(tool-root:D) ; root ?= $(other-tools:D) ; flags cw.link RUN_PATH $(condition) : "$(root)\\Win32-x86 Support\\Libraries\\Runtime" "$(root)\\Win32-x86 Support\\Libraries\\Runtime\\Libs\\MSL_All-DLLs" ; setup = "set \"CWFOLDER="$(root)"\" && call \""$(setup)"\" > nul " ; if [ os.name ] = NT { setup = $(setup)" " ; } else { setup = "cmd /S /C "$(setup)" \"&&\" " ; } # bind the setup command to the tool so it can be executed before the # command local prefix = $(setup) ; flags cw.compile .CC $(condition) : $(prefix)$(compiler) ; flags cw.link .LD $(condition) : $(prefix)$(linker) ; flags cw.archive .LD $(condition) : $(prefix)$(linker) ; if [ MATCH "^([89]\\.)" : $(version) ] { if [ os.name ] = NT { # The runtime libraries flags cw.compile CFLAGS static/single/off : -runtime ss ; flags cw.compile CFLAGS static/single/on : -runtime ssd ; flags cw.compile CFLAGS static/multi/off : -runtime sm ; flags cw.compile CFLAGS static/multi/on : -runtime smd ; flags cw.compile CFLAGS shared/off : -runtime dm ; flags cw.compile CFLAGS shared/on : -runtime dmd ; } } } local rule default-paths ( version ? ) # FIXME { local possible-paths ; local ProgramFiles = [ common.get-program-files-dir ] ; # TODO: add support for cw8 and cw9 detection local version-6-path = $(ProgramFiles)"\\Metrowerks\\CodeWarrior" ; possible-paths += $(version-6-path) ; # perform post-processing possible-paths = $(possible-paths)"\\Other Metrowerks Tools\\Command Line Tools" ; possible-paths += [ modules.peek : PATH Path path ] ; return $(possible-paths) ; } ## declare generators generators.register-c-compiler cw.compile.c++ : CPP : OBJ : cw ; generators.register-c-compiler cw.compile.c : C : OBJ : cw ; generators.register-linker cw.link : OBJ SEARCHED_LIB STATIC_LIB IMPORT_LIB : EXE : cw ; generators.register-linker cw.link.dll : OBJ SEARCHED_LIB STATIC_LIB IMPORT_LIB : SHARED_LIB IMPORT_LIB : cw ; generators.register-archiver cw.archive : OBJ : STATIC_LIB : cw ; ## compilation phase flags cw WHATEVER ; flags cw.compile CFLAGS on : -g ; flags cw.compile CFLAGS off : -O0 ; flags cw.compile CFLAGS speed : -O4,p ; flags cw.compile CFLAGS space : -O4,s ; flags cw.compile CFLAGS off : -inline off ; flags cw.compile CFLAGS on : -inline on ; flags cw.compile CFLAGS full : -inline all ; flags cw.compile CFLAGS off : -Cpp_exceptions off ; flags cw.compile CFLAGS on : -RTTI on ; flags cw.compile CFLAGS off : -RTTI off ; flags cw.compile CFLAGS on : -w on ; flags cw.compile CFLAGS off : -w off ; flags cw.compile CFLAGS all : -w all ; flags cw.compile CFLAGS extra : -w all ; flags cw.compile CFLAGS pedantic : -w all ; flags cw.compile CFLAGS on : -w error ; flags cw.compile USER_CFLAGS : ; flags cw.compile.c++ USER_CFLAGS : ; flags cw.compile DEFINES ; flags cw.compile UNDEFS ; flags cw.compile INCLUDES ; actions compile.c { $(.CC) -c -cwd include -lang c -U$(UNDEFS) $(CFLAGS) $(USER_CFLAGS) -I- -o "$(<)" @"@($(<[1]:W).rsp:E=$(nl)"$(>)" $(nl)-D$(DEFINES) $(nl)"-I$(INCLUDES)")" } actions compile.c++ { $(.CC) -c -cwd include -lang c++ -U$(UNDEFS) $(CFLAGS) $(USER_CFLAGS) -I- -o "$(<)" @"@($(<[1]:W).rsp:E=$(nl)"$(>)" $(nl)-D$(DEFINES) $(nl)"-I$(INCLUDES)")" } ## linking phase flags cw.link DEF_FILE ; flags cw LINKFLAGS : -search ; flags cw LINKFLAGS on : -g ; flags cw LINKFLAGS console : -subsystem console ; flags cw LINKFLAGS gui : -subsystem windows ; flags cw LINKFLAGS wince : -subsystem wince ; flags cw LINKFLAGS native : -subsystem native ; flags cw LINKFLAGS auto : -subsystem auto ; flags cw LINKFLAGS LIB/static : -library ; flags cw.link USER_LINKFLAGS ; flags cw.link LINKPATH ; flags cw.link FINDLIBS_ST ; flags cw.link FINDLIBS_SA ; flags cw.link LIBRARY_OPTION cw : "" : unchecked ; flags cw.link LIBRARIES_MENTIONED_BY_FILE : ; rule link.dll ( targets + : sources * : properties * ) { DEPENDS $(<) : [ on $(<) return $(DEF_FILE) ] ; } if [ os.name ] in NT { actions archive { if exist "$(<[1])" DEL "$(<[1])" $(.LD) -library -o "$(<[1])" @"@($(<[1]:W).rsp:E=$(nl)"$(>)" $(nl)$(LIBRARIES_MENTIONED_BY_FILE) $(nl)"$(LIBRARY_OPTION)$(FINDLIBS_ST:S=.lib)" $(nl)"$(LIBRARY_OPTION)$(FINDLIBS_SA:S=.lib)")" } } else # cygwin { actions archive { _bbv2_out_="$(<)" if test -f "$_bbv2_out_" ; then _bbv2_existing_="$(<:W)" fi $(.LD) -library -o "$(<:W)" $_bbv2_existing_ @"@($(<[1]:W).rsp:E=$(nl)"$(>)" $(nl)$(LIBRARIES_MENTIONED_BY_FILE) $(nl)"$(LIBRARY_OPTION)$(FINDLIBS_ST:S=.lib)" $(nl)"$(LIBRARY_OPTION)$(FINDLIBS_SA:S=.lib)")" } } actions link bind DEF_FILE { $(.LD) -o "$(<[1]:W)" -L"$(LINKPATH)" $(LINKFLAGS) $(USER_LINKFLAGS) @"@($(<[1]:W).rsp:E=$(nl)"$(>)" $(nl)$(LIBRARIES_MENTIONED_BY_FILE) $(nl)"$(LIBRARY_OPTION)$(FINDLIBS_ST:S=.lib)" $(nl)"$(LIBRARY_OPTION)$(FINDLIBS_SA:S=.lib)")" } actions link.dll bind DEF_FILE { $(.LD) -shared -o "$(<[1]:W)" -implib "$(<[2]:W)" -L"$(LINKPATH)" $(LINKFLAGS) -f"$(DEF_FILE)" $(USER_LINKFLAGS) @"@($(<[1]:W).rsp:E=$(nl)"$(>)" $(nl)$(LIBRARIES_MENTIONED_BY_FILE) $(nl)"$(LIBRARY_OPTION)$(FINDLIBS_ST:S=.lib)" $(nl)"$(LIBRARY_OPTION)$(FINDLIBS_SA:S=.lib)")" }