# Copyright 2002-2017 Rene Rivera
# Copyright 2002-2017 Vladimir Prus
# Distributed under the Boost Software License, Version 1.0.
# (See accompanying file LICENSE.txt or copy at
# https://www.bfgroup.xyz/b2/LICENSE.txt)

import "class" : new ;
import generators ;

class prebuilt-lib-generator : generator
{
    rule __init__ ( * : * )
    {
        generator.__init__ $(1) : $(2) : $(3) : $(4) : $(5) : $(6) : $(7) : $(8)
            : $(9) : $(10) : $(11) : $(12) : $(13) : $(14) : $(15) : $(16) :
            $(17) : $(18) : $(19) ;
    }

    rule run ( project name ? : property-set : sources * )
    {
        local f = [ $(property-set).get <file> ] ;
        return $(f) $(sources) ;
    }
}

generators.register
    [ new prebuilt-lib-generator builtin.prebuilt : : LIB : <file> ] ;

generators.override builtin.prebuilt : builtin.lib-generator ;
