Boost logo

Boost-Build :

From: Vladimir Prus (ghost_at_[hidden])
Date: 2004-10-06 03:21:33


Hi ëÏÎÓÔÁÎÔÉÎ,
> Hello, All!
>
> I'm trying to build v2 example using Kylix, but bjam says
>
> D:/Projects/C++/boost/tools/build/v2/build\toolset.jam:29: in using
> rule kylix.init unknown in module toolset.

No wonder. I think nobody was using Kylix with V2 for quite some time, so any
problem I've introduced were not noticed. If you're willing to do some
testing, we can revive the toolset.

> D:/Projects/C++/boost/tools/build/v2/.\user-config.jam:30: in modules.load
> D:/Projects/C++/boost/tools/build/v2\build-system.jam:56: in load
> D:\Projects\C++\boost\tools\build\v2\example\..\kernel\modules.jam:259: in
> import
> D:\Projects\C++\boost\tools\build\v2\example\..\kernel\bootstrap.jam:120:
> in boost-build
> D:\Projects\C++\boost\tools\build\v2\example\boost-build.jam:2: in module
> scope
>
> When I define init rule in kylix.jam in this way:
>
> rule init ( version ? : command * )
> {
> borland.init version : command ;
> }
>
> errors from bjam become more cryptic that I can handle :(((.

I attach a revised version. You'd need to add

using kylix : : command-to-invoke-the-compiler ;

to your user-config.jam. Let me know if it works in any way.

> And second question. I have library that contain version.cpp where I
> define version info and build timestamp. I want to v2 somehow recompile
> version.cpp each time some sources of lib need has to be recompiled.

Alas, we don't have an easy mechanism.

- Volodya
 --Boundary-00=_Ns6YBE5NXXecINY Content-Type: text/plain;
charset="koi8-r";
name="kylix.jam"
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment;
filename="kylix.jam"

# Copyright (C) Vladimir Prus 2002. Permission to copy, use, modify, sell and
# distribute this software is granted provided this copyright notice appears in
# all copies. This software is provided "as is" without express or implied
# warranty, and with no claim as to its suitability for any purpose.

# Support for the Borland's Kylix command line compiler

import toolset ;
import common ;

toolset.register kylix ;
toolset.inherit kylix : borland ;

rule init ( version ? : command * )
{
local condition = [ common.check-init-parameters kylix :
version $(version) ] ;

local command = [ common.get-invocation-command kylix : bc++
: $(command) ] ;

toolset.flags kylix CONFIG_COMMAND $(condition) : $(command) ;

if $(command)
{
command = [ common.get-absolute-tool-path $(command[-1]) ] ;
}
root = $(command:D) ;

toolset.flags kylix.compile STDHDRS $(condition) : $(root)/include/ ;
toolset.flags kylix.link STDLIBPATH $(condition) : $(root)/lib ;
toolset.flags kylix .root $(condition) : $(root)/bin/ ;
}

actions compile.c++
{
$(CONFIG_COMMAND) -j5 -g255 -q -c -P -w -Ve -Vx -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 -w -Ve -Vx -a8 -b- $(OPTIONS) -D$(DEFINES) -I"$(INCLUDES)" -I"$(STDHDRS)" -o"$(<)" "$(>)"
}

actions link bind LIBRARIES
{
$(CONFIG_COMMAND) $(OPTIONS) -q -L$(LINKPATH) -e$(<[1]) $(>) $(LIBRARIES) lib$(FINDLIBS-ST).a lib$(FINDLIBS-SA).so
}

 --Boundary-00=_Ns6YBE5NXXecINY--


Boost-Build list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk