Jamroot 5.38 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60
# -*- coding: iso-8859-1-unix -*-

import os ;
import modules ;

path-constant here : . ;

lua-install-path = [ os.environ LUA_INSTALL_PATH ] ;
if ! $(lua-install-path)
{
  lua-install-path = "$(here)/../../install/lua" ;
}

loop-root-path = [ os.environ LOOP_ROOT_PATH ] ;
if ! $(loop-root-path)
{
  loop-root-path = "$(here)/../loop" ;
}

oil-root-path = [ os.environ OIL_ROOT_PATH ] ;
if ! $(oil-root-path)
{
  oil-root-path = "$(here)/../oil" ;
}

scs-idl-path = [ os.environ SCS_IDL_PATH ] ;
if ! $(scs-idl-path)
{
  scs-idl-path = "$(here)/../scs-idl" ;
}

openbus-idl-path = [ os.environ OPENBUS_IDL_PATH ] ;
if ! $(openbus-idl-path)
{
  openbus-idl-path = "$(here)/../openbus-idl" ;
}

openbus-legacy-idl-path = [ os.environ OPENBUS_LEGACY_IDL_PATH ] ;
if ! $(openbus-legacy-idl-path)
{
  openbus-legacy-idl-path = "$(here)/../openbus-legacy-idl" ;
}

openbus-lib-idl-path = [ os.environ OPENBUS_LIB_IDL_PATH ] ;
if ! $(openbus-lib-idl-path)
{
  openbus-lib-idl-path = "$(here)/../openbus-lib-idl" ;
}

modules.load preloader : : $(loop-root-path) ;
import preloader ; 
using preloader ;

project luaopenbus
  : requirements
    <target-os>windows:<pch>off
    <target-os>windows,<link>shared:<runtime-link>shared
    <target-os>windows,<link>static:<runtime-link>static
    <target-os>windows:<debug-store>database
    <target-os>windows:<define>_CRT_SECURE_NO_WARNINGS
61
    <toolset>msvc-12.0:<cxxflags>/FS
62 63 64 65 66 67 68 69 70 71 72 73 74
    <debug-symbols>on
  ;

make luaopenbus.c
  : lua/openbus/assistant.lua
    lua/openbus/assistant2.lua
    lua/openbus/core/Access.lua
    lua/openbus/core/idl/makeaux.lua
    lua/openbus/core/idl/parsed.lua
    lua/openbus/core/idl.lua
    lua/openbus/core/legacy/idl.lua
    lua/openbus/core/legacy/parsed.lua
    lua/openbus/core/messages.lua
75 76
    lua/openbus/console/costdin.lua
    lua/openbus/console/utils.lua    
77 78 79 80 81 82 83 84 85 86 87 88 89 90
    lua/openbus/idl/parsed.lua
    lua/openbus/idl.lua
    lua/openbus/util/argcheck.lua
    lua/openbus/util/autotable.lua
    lua/openbus/util/database.lua
    lua/openbus/util/except.lua
    lua/openbus/util/logger.lua
    lua/openbus/util/messages.lua
    lua/openbus/util/oo.lua
    lua/openbus/util/sandbox.lua
    lua/openbus/util/server.lua
    lua/openbus/util/sysex.lua
    lua/openbus/util/tickets.lua
    lua/openbus.lua
91 92
    src/lthreadlib.c
    src/lecholib.c
93 94 95 96
  : preloader.pre-compile
  : <search>$(here)
  ;

97 98 99 100 101 102
make luaconsole.c
  : lua/openbus/console.lua
  : preloader.pre-compile
  : <search>$(here)
  ;

103 104 105 106 107 108
modules.load idl2lua : : $(oil-root-path) ;
import idl2lua ; 
using idl2lua ;

make lua/openbus/idl/parsed.lua 
  : $(openbus-lib-idl-path)/src/openbus.idl
109
    $(openbus-lib-idl-path)/src/corba.idl
110 111 112 113 114
    $(openbus-idl-path)/src/openbus_access-2.1.idl
    $(openbus-idl-path)/src/openbus_offers-2.1.idl
    $(openbus-idl-path)/src/openbus_export-2.1.idl
    $(openbus-idl-path)/src/openbus_core-2.1.idl
    $(openbus-idl-path)/src/openbus_creden-2.1.idl
115
    $(scs-idl-path)/src/scs.idl
116 117 118 119 120 121 122
  : idl2lua.compile
  : <include>$(openbus-lib-idl-path)/src
    <include>$(openbus-idl-path)/src
    <include>$(scs-idl-path)/src
  ;

make lua/openbus/core/idl/parsed.lua 
123 124 125 126 127
  : $(openbus-idl-path)/src/openbus_access-2.1.idl
    $(openbus-idl-path)/src/openbus_offers-2.1.idl
    $(openbus-idl-path)/src/openbus_export-2.1.idl
    $(openbus-idl-path)/src/openbus_core-2.1.idl
    $(openbus-idl-path)/src/openbus_creden-2.1.idl
128 129 130
    $(scs-idl-path)/src/scs.idl
  : idl2lua.compile
  : <include>$(openbus-idl-path)/src
131
    <include>$(openbus-legacy-idl-path)/src
132 133 134 135
    <include>$(scs-idl-path)/src
  ;

make lua/openbus/core/legacy/parsed.lua 
136 137 138
  : $(openbus-legacy-idl-path)/src/access_control.idl
    $(openbus-legacy-idl-path)/src/offer_registry.idl
    $(openbus-legacy-idl-path)/src/data_export.idl
139
    $(openbus-legacy-idl-path)/src/core.idl
140
    $(openbus-legacy-idl-path)/src/credential.idl
141
    $(scs-idl-path)/src/scs.idl
142 143 144 145
    $(openbus-idl-path)/src/openbus_legacy-2.1.idl
    $(openbus-idl-path)/src/openbus_access-2.1.idl
    $(openbus-idl-path)/src/openbus_core-2.1.idl
    $(openbus-idl-path)/src/openbus_creden-2.1.idl
146 147
  : idl2lua.compile
  : <include>$(openbus-legacy-idl-path)/src
148
    <include>$(openbus-idl-path)/src
149 150 151 152 153
    <include>$(scs-idl-path)/src
  ;

lib luaopenbus
  : luaopenbus.c
154 155 156
    src/openbuslua.c
    src/lthreadlib.c
    src/lecholib.c
157
    /lua//lua
158 159 160 161 162 163 164 165 166 167 168 169 170
    /luuid//luuid
    /lce//lce
    /luafilesystem//lfs
    /luavararg//luavararg
    /luastruct//luastruct
    /luasocket//luasocket
    /loop//loop
    /loop//luatuple
    /loop//luacothread
    /oil//oil
    /oil//luaidl
    /luascs//luascs
    /luasec//luasec
171
  : <include>src
172
    <include>.
173 174 175
    <target-os>windows,<link>shared:<linkflags>"/def:$(here)/luaopenbus.def"
  :
  : <include>.
176
    <include>src
177 178 179
  ;
explicit luaopenbus ;

180
exe busconsole
181 182 183
  : src/launcher.c
    src/consolelibs.c
    luaconsole.c
184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205
    /lua//lua
    /luuid//luuid
    /lce//lce
    /luafilesystem//lfs
    /luavararg//luavararg
    /luastruct//luastruct
    /luasocket//luasocket
    /loop//loop
    /loop//luatuple
    /loop//luacothread
    /oil//oil
    /oil//luaidl
    /luascs//luascs
    /luaopenbus//luaopenbus    
  : <dependency>/loop//loop
    <dependency>/loop//luatuple
    <dependency>/loop//luacothread
    <dependency>/oil//oil
    <dependency>/oil//luaidl
    <dependency>/lce//lce
    <dependency>/luascs//luascs
    <dependency>/luaopenbus//luaopenbus
206
    <define>OPENBUS_PROGNAME=\\\""busconsole\\\""
207 208 209
;
explicit busconsole ;

210 211
install stage
  : luaopenbus
212
    busconsole
213 214
  : <location>install
  ;