| 1 | # -*- Mode:Python -*- |
|---|
| 2 | |
|---|
| 3 | ########################################################################## |
|---|
| 4 | # # |
|---|
| 5 | # This file is part of AVANGO. # |
|---|
| 6 | # # |
|---|
| 7 | # Copyright 1997 - 2009 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 | |
|---|
| 24 | import avango.build |
|---|
| 25 | |
|---|
| 26 | avango.build.Environment.prepend_include_path(Dir('include').abspath) |
|---|
| 27 | local_env = avango.build.Environment() |
|---|
| 28 | |
|---|
| 29 | # Substitutions |
|---|
| 30 | local_env['SUBST'] = { |
|---|
| 31 | 'PREFIX': avango.build.get_prefix().abspath, |
|---|
| 32 | 'AVANGO_DEBUG': int(local_env['DEBUG']), |
|---|
| 33 | 'AVANGO_LOG_LEVEL': local_env['LOG_LEVEL'], |
|---|
| 34 | 'AVANGO_DISTRIBUTION_SUPPORT': int(local_env['DISTRIBUTION_SUPPORT']), |
|---|
| 35 | 'AVANGO_ZMQ_DISTRIBUTION_SUPPORT': int(local_env['ZMQ_DISTRIBUTION_SUPPORT']), |
|---|
| 36 | 'PKG_CONFIG_REQUIRES': '', |
|---|
| 37 | 'AVANGO_VERSION': '1.90.0', |
|---|
| 38 | 'AVANGO_VERSION_MAJOR': '1', |
|---|
| 39 | 'AVANGO_VERSION_MINOR': '90', |
|---|
| 40 | 'AVANGO_VERSION_MAINT': '0', |
|---|
| 41 | } |
|---|
| 42 | if local_env['DISTRIBUTION_SUPPORT']: |
|---|
| 43 | local_env['SUBST']['PKG_CONFIG_REQUIRES'] = 'avango-ensemble' |
|---|
| 44 | |
|---|
| 45 | avango_osg_pc = local_env.Subst('dist/pkg-config/avango-core.pc.in') |
|---|
| 46 | Alias('core', avango_osg_pc) |
|---|
| 47 | local_env.Alias('install-core', local_env.Install(avango.build.get_pkgconfig_path(), avango_osg_pc)) |
|---|
| 48 | |
|---|
| 49 | config_h = local_env.Subst('include/avango/Config.h.in') |
|---|
| 50 | Alias('core', config_h) |
|---|
| 51 | local_env.Alias('install-core', local_env.Install(avango.build.get_include_path('avango'), config_h)) |
|---|
| 52 | |
|---|
| 53 | Alias('all', Alias('core')) |
|---|
| 54 | Alias('check', Alias('check-core')) |
|---|
| 55 | Alias('install', Alias('install-core')) |
|---|
| 56 | |
|---|
| 57 | # Subdirs |
|---|
| 58 | |
|---|
| 59 | SConscript ([ |
|---|
| 60 | 'include/avango/SConscript', |
|---|
| 61 | 'src/avango/SConscript', |
|---|
| 62 | ]) |
|---|
| 63 | |
|---|
| 64 | avango.build.make_vcproject(local_env, 'avango-core', 'core') |
|---|