source: trunk/SConstruct @ 563

Revision 563, 6.0 KB checked in by acbernst, 13 months ago (diff)

added ZMQ_DISTRIBUTION_SUPPORT flag

  • Property svn:eol-style set to native
Line 
1# -*- Mode:Python -*-
2
3##########################################################################
4#                                                                        #
5# This file is part of AVANGO.                                           #
6#                                                                        #
7# Copyright 1997 - 2010 Fraunhofer-Gesellschaft zur Foerderung der       #
8# angewandten Forschung (FhG), Munich, Germany.                          #
9#                                                                        #
10# AVANGO is free software: you can redistribute it and/or modify         #
11# it under the terms of the GNU Lesser General Public License as         #
12# published by the Free Software Foundation, version 3.                  #
13#                                                                        #
14# AVANGO is distributed in the hope that it will be useful,              #
15# but WITHOUT ANY WARRANTY; without even the implied warranty of         #
16# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the           #
17# GNU General Public License for more details.                           #
18#                                                                        #
19# You should have received a copy of the GNU Lesser General Public       #
20# License along with AVANGO. If not, see <http://www.gnu.org/licenses/>. #
21#                                                                        #
22##########################################################################
23
24import sys
25import os, os.path
26sys.path.insert(0, os.path.join(os.getcwd(), 'avango-build', 'src'))
27
28import avango.build
29import avango.build.oshelper
30
31opts = avango.build.options
32opts.AddOptions(
33    BoolOption('DISTRIBUTION_SUPPORT',
34               'Switch to enable distribution support (requires ensemble module)',
35               False),
36    BoolOption('ZMQ_DISTRIBUTION_SUPPORT',
37               'Switch to enable distribution support with zmq',
38               False),
39    BoolOption('OPENSCENEGRAPH_SUPPORT',
40               'Enable building OpenSceneGraph module',
41               True),
42    BoolOption('OPENSCENEGRAPH_DEBUG',
43               'Use debug version of OpenSceneGraph library',
44               False),
45    BoolOption('SHADE_SUPPORT',
46               'Enable building shade module',
47               False),
48    BoolOption('OPENAL_SUPPORT',
49               'Enable building OpenAL sound module',
50               False),
51    BoolOption('DISPLAY_SUPPORT',
52               'Enable building display setup module (REQUIRED)',
53               True),
54    BoolOption('CONNECT_SUPPORT',
55               'Enable building module to connect mobile devices to AVANGO',
56               False),
57    BoolOption('CONNECT_CSHARP_SUPPORT',
58               'Enable C# support for the connect module',
59               False),
60    BoolOption('VRPN_SUPPORT',
61               'Enable VRPN support for the AvangoDaemon module',
62               False),
63    BoolOption('UTILS_SUPPORT',
64               'Enable building utility module (REQUIRED)',
65               True),
66    )
67
68avango.build.setup()
69
70avango.build.set_config('avango-unittest', avango.build.PlainConfig(libraries = ['avangoUnitTest++']))
71avango.build.set_config('avango-core', avango.build.PlainConfig(libraries = ['avango'], dependencies = ["boost_signals", "boost_thread"]))
72
73avango.build.set_config('avango-python', avango.build.PlainConfig(libraries = ['avangoScript']))
74
75# avango.build.set_config('avango-osg', avango.build.PlainConfig(libraries = ['avangoOsg', 'avangoOsgParticle']))
76avango.build.set_config('avango-osg', avango.build.PlainConfig(libraries = ['avangoOsg'], dependencies = ['osg', 'osgDB', 'osgViewer', 'osgParticle', 'osgText', 'osgUtil']))
77avango.build.set_config('avango-shade', avango.build.PlainConfig(libraries = ['avangoSloow', 'shade']))
78avango.build.set_config('avango-osgparticle', avango.build.PlainConfig(libraries = ['avangoOsgParticle']))
79
80avango.build.set_config('avango-osgviewer', avango.build.PlainConfig(libraries = ['avangoOsgViewer']))
81avango.build.set_config('avango-daemon', avango.build.PlainConfig(libraries = ['avangoDaemon']))
82
83env = avango.build.Environment()
84
85if env['DISTRIBUTION_SUPPORT']:
86    avango.build.Environment.add_search_path('avango-ensemble')
87if env['OPENSCENEGRAPH_DEBUG']:
88    avango.build.set_config_flag("OPENSCENEGRAPH_DEBUG", True)
89
90used_libs = Split("""
91    dl
92    boost_thread
93    boost_signals
94    boost_python
95    osg
96    osgDB
97    osgViewer
98    osgParticle
99    osgText
100    """)
101for lib in used_libs:
102    avango.build.Environment.add_search_path(lib)
103
104
105avango.build.SConscript('avango-unittest/SConscript')
106avango.build.TestEnvironment.add_library('avango-unittest')
107
108# List is ordered by dependency of modules
109avango.build.SConscript('avango-build/SConscript')
110avango.build.SConscript('avango-core/SConscript')
111avango.build.SConscript('avango-python/SConscript')
112if env['OPENSCENEGRAPH_SUPPORT']:
113    avango.build.SConscript('avango-osg/SConscript')
114    if env['SHADE_SUPPORT']:
115        avango.build.SConscript('avango-shade/SConscript')
116    avango.build.SConscript('avango-moving/SConscript')
117    avango.build.SConscript('avango-menu/SConscript')
118    if not avango.build.oshelper.os_is_windows() and \
119         not avango.build.oshelper.os_is_mac(): #FIXME get module running under Windows/MAC
120        avango.build.SConscript('avango-daemon/SConscript')
121if not avango.build.oshelper.os_is_windows() and \
122   not avango.build.oshelper.os_is_mac(): #FIXME get module running under Windows/MAC
123    avango.build.SConscript('avango-sound/SConscript')
124if env['OPENAL_SUPPORT']:
125    avango.build.SConscript('avango-openal/SConscript')
126avango.build.SConscript('avango-tools/SConscript')
127if env['DISPLAY_SUPPORT']:
128    avango.build.SConscript('avango-display/SConscript')
129if env['CONNECT_SUPPORT']:
130    avango.build.SConscript('avango-connect/SConscript')
131if env['UTILS_SUPPORT']:
132    avango.build.SConscript('avango-utils/SConscript')
133avango.build.SConscript('avango-inspector/SConscript')
134avango.build.SConscript('avango-doc/SConscript')
135avango.build.SConscript('examples/SConscript')
Note: See TracBrowser for help on using the repository browser.