merge after FrOSCon
(added lib implementations for Doxygen and GCH builder, fix Lenny compatibility)
This commit is contained in:
commit
bed1dffd69
6 changed files with 706 additions and 60 deletions
107
SConstruct
107
SConstruct
|
|
@ -21,13 +21,6 @@
|
|||
# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
#####################################################################
|
||||
|
||||
import sys
|
||||
sys.path.append("./admin/scons")
|
||||
|
||||
import os
|
||||
from Buildhelper import *
|
||||
from LumieraEnvironment import *
|
||||
|
||||
|
||||
#-----------------------------------Configuration
|
||||
OPTIONSCACHEFILE = 'optcache'
|
||||
|
|
@ -37,6 +30,7 @@ BINDIR = 'bin'
|
|||
TESTDIR = 'tests'
|
||||
ICONDIR = 'icons'
|
||||
VERSION = '0.1+pre.01'
|
||||
TOOLDIR = './admin/scons'
|
||||
SVGRENDERER = 'admin/render-icon'
|
||||
#-----------------------------------Configuration
|
||||
|
||||
|
|
@ -47,6 +41,14 @@ SVGRENDERER = 'admin/render-icon'
|
|||
|
||||
|
||||
|
||||
import os
|
||||
import sys
|
||||
|
||||
sys.path.append(TOOLDIR)
|
||||
|
||||
from Buildhelper import *
|
||||
from LumieraEnvironment import *
|
||||
|
||||
|
||||
#####################################################################
|
||||
|
||||
|
|
@ -57,7 +59,10 @@ def setupBasicEnvironment():
|
|||
EnsureSConsVersion(0,96,90)
|
||||
|
||||
opts = defineCmdlineOptions()
|
||||
env = LumieraEnvironment(options=opts)
|
||||
env = LumieraEnvironment(options=opts
|
||||
,toolpath = [TOOLDIR]
|
||||
,tools = ["default", "BuilderGCH", "BuilderDoxygen"]
|
||||
)
|
||||
|
||||
env.Append ( CCCOM=' -std=gnu99') # workaround for a bug: CCCOM currently doesn't honor CFLAGS, only CCFLAGS
|
||||
env.Replace( VERSION=VERSION
|
||||
|
|
@ -102,8 +107,7 @@ def handleNoBugSwitches(env):
|
|||
level = env['BUILDLEVEL']
|
||||
if level in ['ALPHA', 'BETA']:
|
||||
if not env['DEBUG']:
|
||||
print 'NoBug: ALPHA or BETA builds without DEBUG not possible, exiting.'
|
||||
Exit(1)
|
||||
print 'Warning: NoBug ALPHA or BETA builds requires DEBUG=yes, switching DEBUG on!'
|
||||
env.Replace( DEBUG = 1 )
|
||||
env.Append(CPPDEFINES = 'EBUG_'+level)
|
||||
elif level == 'RELEASE':
|
||||
|
|
@ -169,24 +173,21 @@ def configurePlatform(env):
|
|||
# run all configuration checks in the given env
|
||||
|
||||
# Perform checks for prerequisites --------------------------------------------
|
||||
problems = []
|
||||
if not conf.TryAction('pkg-config --version > $TARGET')[0]:
|
||||
print 'We need pkg-config for including library configurations, exiting.'
|
||||
Exit(1)
|
||||
problems.append('We need pkg-config for including library configurations, exiting.')
|
||||
|
||||
if not conf.CheckLibWithHeader('m', 'math.h','C'):
|
||||
print 'Did not find math.h / libm, exiting.'
|
||||
Exit(1)
|
||||
problems.append('Did not find math.h / libm.')
|
||||
|
||||
if not conf.CheckLibWithHeader('dl', 'dlfcn.h', 'C'):
|
||||
print 'Functions for runtime dynamic loading not available, exiting.'
|
||||
Exit(1)
|
||||
problems.append('Functions for runtime dynamic loading not available.')
|
||||
|
||||
if not conf.CheckLibWithHeader('nobugmt', 'nobug.h', 'C'):
|
||||
print 'Did not find NoBug [http://www.pipapo.org/pipawiki/NoBug], exiting.'
|
||||
Exit(1)
|
||||
problems.append('Did not find NoBug [http://www.pipapo.org/pipawiki/NoBug].')
|
||||
|
||||
if not conf.CheckLibWithHeader('pthread', 'pthread.h', 'C'):
|
||||
print 'Did not find the pthread lib or pthread.h, exiting.'
|
||||
problems.append('Did not find the pthread lib or pthread.h.')
|
||||
else:
|
||||
conf.env.Append(CPPFLAGS = ' -DHAVE_PTHREAD')
|
||||
conf.env.Append(CCFLAGS = ' -pthread')
|
||||
|
|
@ -198,57 +199,56 @@ def configurePlatform(env):
|
|||
conf.env.Append(CPPFLAGS = ' -DHAS_VALGRIND_VALGIND_H')
|
||||
|
||||
if not conf.CheckCXXHeader('tr1/memory'):
|
||||
print 'We rely on the std::tr1 proposed standard extension for shared_ptr.'
|
||||
Exit(1)
|
||||
problems.append('We rely on the std::tr1 proposed standard extension for shared_ptr.')
|
||||
|
||||
if not conf.CheckCXXHeader('boost/config.hpp'):
|
||||
print 'We need the C++ boost-lib.'
|
||||
Exit(1)
|
||||
problems.append('We need the C++ boost-lib.')
|
||||
else:
|
||||
if not conf.CheckCXXHeader('boost/shared_ptr.hpp'):
|
||||
print 'We need boost::shared_ptr (shared_ptr.hpp).'
|
||||
Exit(1)
|
||||
problems.append('We need boost::shared_ptr (shared_ptr.hpp).')
|
||||
if not conf.CheckLibWithHeader('boost_program_options-mt','boost/program_options.hpp','C++'):
|
||||
print 'We need boost::program_options (including binary lib for linking).'
|
||||
Exit(1)
|
||||
problems.append('We need boost::program_options (including binary lib for linking).')
|
||||
if not conf.CheckLibWithHeader('boost_regex-mt','boost/regex.hpp','C++'):
|
||||
print 'We need the boost regular expression lib (incl. binary lib for linking).'
|
||||
Exit(1)
|
||||
problems.append('We need the boost regular expression lib (incl. binary lib for linking).')
|
||||
|
||||
# if not conf.CheckLibWithHeader('gavl', ['gavlconfig.h', 'gavl/gavl.h'], 'C'):
|
||||
|
||||
if not conf.CheckPkgConfig('gavl', 1.0):
|
||||
print 'Did not find Gmerlin Audio Video Lib [http://gmerlin.sourceforge.net/gavl.html], exiting.'
|
||||
Exit(1)
|
||||
problems.append('Did not find Gmerlin Audio Video Lib [http://gmerlin.sourceforge.net/gavl.html].')
|
||||
else:
|
||||
conf.env.mergeConf('gavl')
|
||||
|
||||
if not conf.CheckPkgConfig('gtkmm-2.4', 2.8):
|
||||
print 'Unable to configure GTK--, exiting.'
|
||||
Exit(1)
|
||||
|
||||
problems.append('Unable to configure GTK--, exiting.')
|
||||
|
||||
if not conf.CheckPkgConfig('glibmm-2.4', '2.16'):
|
||||
print 'Unable to configure Lib glib--, exiting.'
|
||||
Exit(1)
|
||||
problems.append('Unable to configure Lib glib--, exiting.')
|
||||
|
||||
if not conf.CheckPkgConfig('cairomm-1.0', 0.6):
|
||||
print 'Unable to configure Cairo--, exiting.'
|
||||
Exit(1)
|
||||
problems.append('Unable to configure Cairo--, exiting.')
|
||||
|
||||
if not conf.CheckPkgConfig('gdl-1.0', '0.6.1'):
|
||||
print 'Unable to configure the GNOME DevTool Library, exiting.'
|
||||
Exit(1)
|
||||
problems.append('Unable to configure the GNOME DevTool Library, exiting.')
|
||||
|
||||
if not conf.CheckPkgConfig('librsvg-2.0', '2.18.1'):
|
||||
print 'Need rsvg Library for rendering icons.'
|
||||
Exit(1)
|
||||
|
||||
if not conf.CheckPkgConfig('xv'): Exit(1)
|
||||
problems.append('Need rsvg Library for rendering icons.')
|
||||
|
||||
if not conf.CheckPkgConfig('xv'): problems.append('Need lib xv')
|
||||
# if not conf.CheckPkgConfig('xext'): Exit(1)
|
||||
# if not conf.CheckPkgConfig('sm'): Exit(1)
|
||||
#
|
||||
# obviously not needed?
|
||||
|
||||
|
||||
# report missing dependencies
|
||||
if problems:
|
||||
print "*** unable to build due to the following problems:"
|
||||
for isue in problems:
|
||||
print " * %s" % isue
|
||||
print
|
||||
print "build aborted."
|
||||
Exit(1)
|
||||
|
||||
print "** Gathered Library Info: %s" % conf.env.libInfo.keys()
|
||||
|
||||
|
||||
|
|
@ -278,6 +278,10 @@ def defineBuildTargets(env, artifacts):
|
|||
setup sub-environments with special build options if necessary.
|
||||
We use a custom function to declare a whole tree of srcfiles.
|
||||
"""
|
||||
# use PCH to speed up building
|
||||
# env['GCH'] = ( env.PrecompiledHeader('$SRCDIR/pre.hpp')
|
||||
# + env.PrecompiledHeader('$SRCDIR/pre_a.hpp')
|
||||
# )
|
||||
|
||||
objback = srcSubtree(env,'$SRCDIR/backend')
|
||||
objproc = srcSubtree(env,'$SRCDIR/proc')
|
||||
|
|
@ -293,7 +297,7 @@ def defineBuildTargets(env, artifacts):
|
|||
|
||||
artifacts['lumiera'] = env.Program('$BINDIR/lumiera', ['$SRCDIR/main.cpp']+ core )
|
||||
artifacts['plugins'] = env.SharedLibrary('$BINDIR/lumiera-plugin', objplug)
|
||||
|
||||
|
||||
# the Lumiera GTK GUI
|
||||
envgtk = env.Clone().mergeConf(['gtkmm-2.4','cairomm-1.0','gdl-1.0','librsvg-2.0','xv','xext','sm'])
|
||||
objgui = srcSubtree(envgtk,'$SRCDIR/gui')
|
||||
|
|
@ -332,16 +336,9 @@ def definePostBuildTargets(env, artifacts):
|
|||
env.Clean ('build', [ 'scache.conf', '.sconf_temp', '.sconsign.dblite', 'config.log' ])
|
||||
env.Clean ('build', [ '$SRCDIR/pre.gch' ])
|
||||
|
||||
# Doxygen documentation
|
||||
# Note: at the moment we only depend on Doxyfile
|
||||
# obviousely, we should depend on all sourcefiles
|
||||
# real Doxygen builder for scons is under developement for 0.97
|
||||
# so for the moment I prefere not to bother
|
||||
doxyfile = File('doc/devel/Doxyfile')
|
||||
env.NoClean(doxyfile)
|
||||
doxydoc = artifacts['doxydoc'] = [ Dir('doc/devel/html'), Dir('doc/devel/latex') ]
|
||||
env.Command(doxydoc, doxyfile, "doxygen Doxyfile 2>&1 |tee ,doxylog", chdir='doc/devel')
|
||||
env.Clean ('doc/devel', doxydoc + ['doc/devel/,doxylog'])
|
||||
doxydoc = artifacts['doxydoc'] = env.Doxygen('doc/devel/Doxyfile')
|
||||
env.Alias ('doxydoc', doxydoc)
|
||||
env.Clean ('doxydoc', doxydoc + ['doc/devel/,doxylog','doc/devel/warnings.txt'])
|
||||
|
||||
|
||||
def defineInstallTargets(env, artifacts):
|
||||
|
|
|
|||
230
admin/scons/BuilderDoxygen.py
Normal file
230
admin/scons/BuilderDoxygen.py
Normal file
|
|
@ -0,0 +1,230 @@
|
|||
# -*- python -*-
|
||||
##
|
||||
## BuilderDoxygen.py - SCons builder for generating Doxygen documentation
|
||||
##
|
||||
|
||||
#
|
||||
# Astxx, the Asterisk C++ API and Utility Library.
|
||||
# Copyright (C) 2005, 2006 Matthew A. Nicholson
|
||||
# Copyright (C) 2006 Tim Blechmann
|
||||
#
|
||||
# This library is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU Lesser General Public
|
||||
# License version 2.1 as published by the Free Software Foundation.
|
||||
#
|
||||
# This library is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
# Lesser General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU Lesser General Public License
|
||||
# along with this library; if not, see http://www.gnu.org/licenses/
|
||||
#####################################################################
|
||||
|
||||
# history: 8/2008 adapted for Lumiera build system
|
||||
# added patch for Doxyfile in subdirectory
|
||||
# see http://www.scons.org/wiki/DoxygenBuilder
|
||||
|
||||
|
||||
import os
|
||||
import os.path
|
||||
import glob
|
||||
from fnmatch import fnmatch
|
||||
|
||||
|
||||
def DoxyfileParse(file_contents):
|
||||
"""
|
||||
Parse a Doxygen source file and return a dictionary of all the values.
|
||||
Values will be strings and lists of strings.
|
||||
"""
|
||||
data = {}
|
||||
|
||||
import shlex
|
||||
lex = shlex.shlex(instream = file_contents, posix = True)
|
||||
lex.wordchars += "*+./-:"
|
||||
lex.whitespace = lex.whitespace.replace("\n", "")
|
||||
lex.escape = ""
|
||||
|
||||
lineno = lex.lineno
|
||||
token = lex.get_token()
|
||||
key = token # the first token should be a key
|
||||
last_token = ""
|
||||
key_token = False
|
||||
next_key = False
|
||||
new_data = True
|
||||
|
||||
def append_data(data, key, new_data, token):
|
||||
if new_data or len(data[key]) == 0:
|
||||
data[key].append(token)
|
||||
else:
|
||||
data[key][-1] += token
|
||||
|
||||
while token:
|
||||
if token in ['\n']:
|
||||
if last_token not in ['\\']:
|
||||
key_token = True
|
||||
elif token in ['\\']:
|
||||
pass
|
||||
elif key_token:
|
||||
key = token
|
||||
key_token = False
|
||||
else:
|
||||
if token == "+=":
|
||||
if not data.has_key(key):
|
||||
data[key] = list()
|
||||
elif token == "=":
|
||||
data[key] = list()
|
||||
else:
|
||||
append_data( data, key, new_data, token )
|
||||
new_data = True
|
||||
|
||||
last_token = token
|
||||
token = lex.get_token()
|
||||
|
||||
if last_token == '\\' and token != '\n':
|
||||
new_data = False
|
||||
append_data( data, key, new_data, '\\' )
|
||||
|
||||
# compress lists of len 1 into single strings
|
||||
for (k, v) in data.items():
|
||||
if len(v) == 0:
|
||||
data.pop(k)
|
||||
|
||||
# items in the following list will be kept as lists and not converted to strings
|
||||
if k in ["INPUT", "FILE_PATTERNS", "EXCLUDE_PATTERNS"]:
|
||||
continue
|
||||
|
||||
if len(v) == 1:
|
||||
data[k] = v[0]
|
||||
|
||||
return data
|
||||
|
||||
def DoxySourceScan(node, env, path):
|
||||
"""
|
||||
Doxygen Doxyfile source scanner. This should scan the Doxygen file and add
|
||||
any files used to generate docs to the list of source files.
|
||||
"""
|
||||
default_file_patterns = [
|
||||
'*.c', '*.cc', '*.cxx', '*.cpp', '*.c++', '*.java', '*.ii', '*.ixx',
|
||||
'*.ipp', '*.i++', '*.inl', '*.h', '*.hh ', '*.hxx', '*.hpp', '*.h++',
|
||||
'*.idl', '*.odl', '*.cs', '*.php', '*.php3', '*.inc', '*.m', '*.mm',
|
||||
'*.py',
|
||||
]
|
||||
|
||||
default_exclude_patterns = [
|
||||
'*~',
|
||||
]
|
||||
|
||||
sources = []
|
||||
|
||||
data = DoxyfileParse(node.get_contents())
|
||||
|
||||
if data.get("RECURSIVE", "NO") == "YES":
|
||||
recursive = True
|
||||
else:
|
||||
recursive = False
|
||||
|
||||
file_patterns = data.get("FILE_PATTERNS", default_file_patterns)
|
||||
exclude_patterns = data.get("EXCLUDE_PATTERNS", default_exclude_patterns)
|
||||
|
||||
#
|
||||
# We're running in the top-level directory, but the doxygen
|
||||
# configuration file is in the same directory as node; this means
|
||||
# that relative pathnames in node must be adjusted before they can
|
||||
# go onto the sources list
|
||||
conf_dir = os.path.dirname(str(node))
|
||||
|
||||
for node in data.get("INPUT", []):
|
||||
if not os.path.isabs(node):
|
||||
node = os.path.join(conf_dir, node)
|
||||
if os.path.isfile(node):
|
||||
sources.append(node)
|
||||
elif os.path.isdir(node):
|
||||
if recursive:
|
||||
for root, dirs, files in os.walk(node):
|
||||
for f in files:
|
||||
filename = os.path.join(root, f)
|
||||
|
||||
pattern_check = reduce(lambda x, y: x or bool(fnmatch(filename, y)), file_patterns, False)
|
||||
exclude_check = reduce(lambda x, y: x and fnmatch(filename, y), exclude_patterns, True)
|
||||
|
||||
if pattern_check and not exclude_check:
|
||||
sources.append(filename)
|
||||
else:
|
||||
for pattern in file_patterns:
|
||||
sources.extend(glob.glob("/".join([node, pattern])))
|
||||
|
||||
sources = map( lambda path: env.File(path), sources )
|
||||
return sources
|
||||
|
||||
|
||||
def DoxySourceScanCheck(node, env):
|
||||
"""Check if we should scan this file"""
|
||||
return os.path.isfile(node.path)
|
||||
|
||||
def DoxyEmitter(source, target, env):
|
||||
"""Doxygen Doxyfile emitter"""
|
||||
# possible output formats and their default values and output locations
|
||||
output_formats = {
|
||||
"HTML": ("YES", "html"),
|
||||
"LATEX": ("YES", "latex"),
|
||||
"RTF": ("NO", "rtf"),
|
||||
"MAN": ("NO", "man"),
|
||||
"XML": ("NO", "xml"),
|
||||
}
|
||||
|
||||
data = DoxyfileParse(source[0].get_contents())
|
||||
|
||||
targets = []
|
||||
out_dir = data.get("OUTPUT_DIRECTORY", ".")
|
||||
|
||||
# add our output locations
|
||||
for (k, v) in output_formats.items():
|
||||
if data.get("GENERATE_" + k, v[0]) == "YES":
|
||||
targets.append(env.Dir( os.path.join(out_dir, data.get(k + "_OUTPUT", v[1]))) )
|
||||
|
||||
# don't clobber targets
|
||||
for node in targets:
|
||||
env.Precious(node)
|
||||
|
||||
# set up cleaning stuff
|
||||
for node in targets:
|
||||
env.Clean(node, node)
|
||||
|
||||
return (targets, source)
|
||||
|
||||
|
||||
def generate(env):
|
||||
"""
|
||||
Add builders and construction variables for the
|
||||
Doxygen tool. This is currently for Doxygen 1.4.6.
|
||||
"""
|
||||
doxyfile_scanner = env.Scanner(
|
||||
DoxySourceScan,
|
||||
"DoxySourceScan",
|
||||
scan_check = DoxySourceScanCheck,
|
||||
)
|
||||
|
||||
import SCons.Builder
|
||||
doxyfile_builder = SCons.Builder.Builder(
|
||||
action = "cd ${SOURCE.dir} && (${DOXYGEN} ${SOURCE.file} 2>&1 |tee ,doxylog)",
|
||||
emitter = DoxyEmitter,
|
||||
target_factory = env.fs.Entry,
|
||||
single_source = True,
|
||||
source_scanner = doxyfile_scanner,
|
||||
)
|
||||
|
||||
env.Append(BUILDERS = {
|
||||
'Doxygen': doxyfile_builder,
|
||||
})
|
||||
|
||||
env.AppendUnique(
|
||||
DOXYGEN = 'doxygen',
|
||||
)
|
||||
|
||||
def exists(env):
|
||||
"""
|
||||
Make sure doxygen exists.
|
||||
"""
|
||||
return env.Detect("doxygen")
|
||||
|
||||
110
admin/scons/BuilderGCH.py
Normal file
110
admin/scons/BuilderGCH.py
Normal file
|
|
@ -0,0 +1,110 @@
|
|||
# -*- python -*-
|
||||
##
|
||||
## BuilderGCH.py - SCons builder for gcc's precompiled headers
|
||||
##
|
||||
|
||||
# Copyright (C) scons.org/wiki/GchBuilder
|
||||
# 2006 Tim Blechmann
|
||||
# 2008 Hermann Vosseler <Ichthyostega@web.de>
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License as
|
||||
# published by the Free Software Foundation; either version 2 of
|
||||
# the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, see http://www.gnu.org/licenses/
|
||||
#####################################################################
|
||||
|
||||
# history: 8/2008 adapted for Lumiera build system
|
||||
# changed to accept a list of precompiled header defs
|
||||
|
||||
|
||||
from types import ListType
|
||||
|
||||
import SCons.Action
|
||||
import SCons.Builder
|
||||
import SCons.Scanner.C
|
||||
import SCons.Util
|
||||
import SCons.Script
|
||||
|
||||
SCons.Script.EnsureSConsVersion(0,96,92)
|
||||
|
||||
GchAction = SCons.Action.Action('$GCHCOM', '$GCHCOMSTR')
|
||||
GchShAction = SCons.Action.Action('$GCHSHCOM', '$GCHSHCOMSTR')
|
||||
|
||||
def gen_suffix(env, sources):
|
||||
return sources[0].get_suffix() + env['GCHSUFFIX']
|
||||
|
||||
|
||||
GchShBuilder = SCons.Builder.Builder(action = GchShAction,
|
||||
source_scanner = SCons.Scanner.C.CScanner(),
|
||||
suffix = gen_suffix)
|
||||
|
||||
GchBuilder = SCons.Builder.Builder(action = GchAction,
|
||||
source_scanner = SCons.Scanner.C.CScanner(),
|
||||
suffix = gen_suffix)
|
||||
|
||||
def setup_dependency(target,source,env, key):
|
||||
scanner = SCons.Scanner.C.CScanner()
|
||||
path = scanner.path(env)
|
||||
deps = scanner(source[0], env, path)
|
||||
|
||||
if env.has_key(key) and env[key]:
|
||||
for header in env[key]:
|
||||
header_path = header.path.strip('.gch')
|
||||
if header_path in [x.path for x in deps]:
|
||||
print "Precompiled header(%s) %s \t <--- %s" % (key,header_path,source[0])
|
||||
env.Depends(target, header)
|
||||
|
||||
|
||||
def static_pch_emitter(target,source,env):
|
||||
SCons.Defaults.StaticObjectEmitter( target, source, env )
|
||||
setup_dependency(target,source,env, key='GCH')
|
||||
return (target, source)
|
||||
|
||||
def shared_pch_emitter(target,source,env):
|
||||
SCons.Defaults.SharedObjectEmitter( target, source, env )
|
||||
setup_dependency(target,source,env, key='GCH-sh')
|
||||
return (target, source)
|
||||
|
||||
def generate(env):
|
||||
"""
|
||||
Add builders and construction variables for the Gch builder.
|
||||
"""
|
||||
env.Append(BUILDERS = {
|
||||
'gch': env.Builder(
|
||||
action = GchAction,
|
||||
target_factory = env.fs.File,
|
||||
),
|
||||
'gchsh': env.Builder(
|
||||
action = GchShAction,
|
||||
target_factory = env.fs.File,
|
||||
),
|
||||
})
|
||||
|
||||
try:
|
||||
bld = env['BUILDERS']['GCH']
|
||||
bldsh = env['BUILDERS']['GCH-sh']
|
||||
except KeyError:
|
||||
bld = GchBuilder
|
||||
bldsh = GchShBuilder
|
||||
env['BUILDERS']['PrecompiledHeader'] = bld
|
||||
env['BUILDERS']['PrecompiledHeaderShared'] = bldsh
|
||||
|
||||
env['GCHCOM'] = '$CXX -o $TARGET -x c++-header -c $CXXFLAGS $_CCCOMCOM $SOURCE'
|
||||
env['GCHSHCOM'] = '$CXX -o $TARGET -x c++-header -c $SHCXXFLAGS $_CCCOMCOM $SOURCE'
|
||||
env['GCHSUFFIX'] = '.gch'
|
||||
|
||||
for suffix in SCons.Util.Split('.c .C .cc .cxx .cpp .c++'):
|
||||
env['BUILDERS']['StaticObject'].add_emitter( suffix, static_pch_emitter )
|
||||
env['BUILDERS']['SharedObject'].add_emitter( suffix, shared_pch_emitter )
|
||||
|
||||
|
||||
def exists(env):
|
||||
return env.Detect('g++')
|
||||
|
|
@ -22,7 +22,8 @@
|
|||
#####################################################################
|
||||
|
||||
|
||||
from SCons.SConf import SConf
|
||||
import SCons
|
||||
import SCons.SConf
|
||||
from SCons.Environment import Environment
|
||||
|
||||
from Buildhelper import *
|
||||
|
|
@ -77,8 +78,7 @@ class LumieraEnvironment(Environment):
|
|||
return libInfo
|
||||
|
||||
def Glob (self, pattern):
|
||||
""" temporary workaround; newer versions of SCons provide this as a global function
|
||||
"""
|
||||
""" temporary workaround; newer versions of SCons provide this as a global function """
|
||||
pattern = self.subst(pattern)
|
||||
return glob.glob(pattern)
|
||||
|
||||
|
|
@ -87,13 +87,25 @@ class LumieraEnvironment(Environment):
|
|||
self.__dict__[function.__name__] = function.__get__(self)
|
||||
|
||||
|
||||
#### temporary pre 1.0 SCons compatibility hack ####
|
||||
_ver = map(int, SCons.__version__.split('.'))
|
||||
_old = (_ver[0]<1 and _ver[1]<98)
|
||||
if _old:
|
||||
ConfigBase = SCons.SConf.SConf
|
||||
else:
|
||||
ConfigBase = SCons.SConf.SConfBase
|
||||
del LumieraEnvironment.Glob
|
||||
del LumieraEnvironment.AddMethod
|
||||
# use the official impl present since SCons 0.98
|
||||
# use the new name of the config context base class
|
||||
|
||||
|
||||
class LumieraConfigContext(SConf):
|
||||
|
||||
class LumieraConfigContext(ConfigBase):
|
||||
""" Extends the SCons Configure context with some convenience methods
|
||||
"""
|
||||
def __init__(self, *args,**kw):
|
||||
SConf.__init__(self,*args,**kw)
|
||||
ConfigBase.__init__(self,*args,**kw)
|
||||
|
||||
def CheckPkgConfig (self, libID, minVersion=0):
|
||||
print "Checking for library configuration: %s " % libID
|
||||
|
|
|
|||
3
doc/devel/.gitignore
vendored
Normal file
3
doc/devel/.gitignore
vendored
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
,doxylog
|
||||
warnings.txt
|
||||
html/*
|
||||
294
doc/devel/Doxyfile
Normal file
294
doc/devel/Doxyfile
Normal file
|
|
@ -0,0 +1,294 @@
|
|||
# Doxyfile 1.5.5
|
||||
|
||||
#---------------------------------------------------------------------------
|
||||
# Project related configuration options
|
||||
#---------------------------------------------------------------------------
|
||||
DOXYFILE_ENCODING = UTF-8
|
||||
PROJECT_NAME = Lumiera
|
||||
PROJECT_NUMBER = 0.1+pre
|
||||
OUTPUT_DIRECTORY =
|
||||
CREATE_SUBDIRS = YES
|
||||
OUTPUT_LANGUAGE = English
|
||||
BRIEF_MEMBER_DESC = YES
|
||||
REPEAT_BRIEF = NO
|
||||
ABBREVIATE_BRIEF = "The $name class" \
|
||||
"The $name widget" \
|
||||
"The $name file" \
|
||||
is \
|
||||
provides \
|
||||
specifies \
|
||||
contains \
|
||||
represents \
|
||||
a \
|
||||
an \
|
||||
the
|
||||
ALWAYS_DETAILED_SEC = NO
|
||||
INLINE_INHERITED_MEMB = NO
|
||||
FULL_PATH_NAMES = YES
|
||||
STRIP_FROM_PATH = ../../src/ \
|
||||
../../tests/
|
||||
STRIP_FROM_INC_PATH =
|
||||
SHORT_NAMES = NO
|
||||
JAVADOC_AUTOBRIEF = YES
|
||||
QT_AUTOBRIEF = NO
|
||||
MULTILINE_CPP_IS_BRIEF = NO
|
||||
DETAILS_AT_TOP = YES
|
||||
INHERIT_DOCS = YES
|
||||
SEPARATE_MEMBER_PAGES = NO
|
||||
TAB_SIZE = 4
|
||||
ALIASES =
|
||||
OPTIMIZE_OUTPUT_FOR_C = NO
|
||||
OPTIMIZE_OUTPUT_JAVA = NO
|
||||
OPTIMIZE_FOR_FORTRAN = NO
|
||||
OPTIMIZE_OUTPUT_VHDL = NO
|
||||
BUILTIN_STL_SUPPORT = YES
|
||||
CPP_CLI_SUPPORT = NO
|
||||
SIP_SUPPORT = NO
|
||||
DISTRIBUTE_GROUP_DOC = NO
|
||||
SUBGROUPING = YES
|
||||
TYPEDEF_HIDES_STRUCT = NO
|
||||
#---------------------------------------------------------------------------
|
||||
# Build related configuration options
|
||||
#---------------------------------------------------------------------------
|
||||
EXTRACT_ALL = NO
|
||||
EXTRACT_PRIVATE = YES
|
||||
EXTRACT_STATIC = YES
|
||||
EXTRACT_LOCAL_CLASSES = YES
|
||||
EXTRACT_LOCAL_METHODS = NO
|
||||
EXTRACT_ANON_NSPACES = NO
|
||||
HIDE_UNDOC_MEMBERS = NO
|
||||
HIDE_UNDOC_CLASSES = NO
|
||||
HIDE_FRIEND_COMPOUNDS = NO
|
||||
HIDE_IN_BODY_DOCS = NO
|
||||
INTERNAL_DOCS = YES
|
||||
CASE_SENSE_NAMES = YES
|
||||
HIDE_SCOPE_NAMES = NO
|
||||
SHOW_INCLUDE_FILES = YES
|
||||
INLINE_INFO = YES
|
||||
SORT_MEMBER_DOCS = NO
|
||||
SORT_BRIEF_DOCS = NO
|
||||
SORT_GROUP_NAMES = NO
|
||||
SORT_BY_SCOPE_NAME = NO
|
||||
GENERATE_TODOLIST = YES
|
||||
GENERATE_TESTLIST = YES
|
||||
GENERATE_BUGLIST = YES
|
||||
GENERATE_DEPRECATEDLIST= YES
|
||||
ENABLED_SECTIONS =
|
||||
MAX_INITIALIZER_LINES = 30
|
||||
SHOW_USED_FILES = YES
|
||||
SHOW_DIRECTORIES = NO
|
||||
FILE_VERSION_FILTER =
|
||||
#---------------------------------------------------------------------------
|
||||
# configuration options related to warning and progress messages
|
||||
#---------------------------------------------------------------------------
|
||||
QUIET = NO
|
||||
WARNINGS = YES
|
||||
WARN_IF_UNDOCUMENTED = NO
|
||||
WARN_IF_DOC_ERROR = YES
|
||||
WARN_NO_PARAMDOC = YES
|
||||
WARN_FORMAT = "$file:$line: $text"
|
||||
WARN_LOGFILE = warnings.txt
|
||||
#---------------------------------------------------------------------------
|
||||
# configuration options related to the input files
|
||||
#---------------------------------------------------------------------------
|
||||
INPUT = ../../src/ \
|
||||
../../tests/
|
||||
INPUT_ENCODING = UTF-8
|
||||
FILE_PATTERNS = *.c \
|
||||
*.cc \
|
||||
*.cxx \
|
||||
*.cpp \
|
||||
*.c++ \
|
||||
*.d \
|
||||
*.java \
|
||||
*.ii \
|
||||
*.ixx \
|
||||
*.ipp \
|
||||
*.i++ \
|
||||
*.inl \
|
||||
*.h \
|
||||
*.hh \
|
||||
*.hxx \
|
||||
*.hpp \
|
||||
*.h++ \
|
||||
*.idl \
|
||||
*.odl \
|
||||
*.cs \
|
||||
*.php \
|
||||
*.php3 \
|
||||
*.inc \
|
||||
*.m \
|
||||
*.mm \
|
||||
*.dox \
|
||||
*.py \
|
||||
*.C \
|
||||
*.CC \
|
||||
*.C++ \
|
||||
*.II \
|
||||
*.I++ \
|
||||
*.H \
|
||||
*.HH \
|
||||
*.H++ \
|
||||
*.CS \
|
||||
*.PHP \
|
||||
*.PHP3 \
|
||||
*.M \
|
||||
*.MM \
|
||||
*.PY
|
||||
RECURSIVE = YES
|
||||
EXCLUDE =
|
||||
EXCLUDE_SYMLINKS = YES
|
||||
EXCLUDE_PATTERNS =
|
||||
EXCLUDE_SYMBOLS =
|
||||
EXAMPLE_PATH =
|
||||
EXAMPLE_PATTERNS = *
|
||||
EXAMPLE_RECURSIVE = NO
|
||||
IMAGE_PATH =
|
||||
INPUT_FILTER =
|
||||
FILTER_PATTERNS =
|
||||
FILTER_SOURCE_FILES = NO
|
||||
#---------------------------------------------------------------------------
|
||||
# configuration options related to source browsing
|
||||
#---------------------------------------------------------------------------
|
||||
SOURCE_BROWSER = YES
|
||||
INLINE_SOURCES = YES
|
||||
STRIP_CODE_COMMENTS = YES
|
||||
REFERENCED_BY_RELATION = YES
|
||||
REFERENCES_RELATION = YES
|
||||
REFERENCES_LINK_SOURCE = YES
|
||||
USE_HTAGS = NO
|
||||
VERBATIM_HEADERS = YES
|
||||
#---------------------------------------------------------------------------
|
||||
# configuration options related to the alphabetical class index
|
||||
#---------------------------------------------------------------------------
|
||||
ALPHABETICAL_INDEX = YES
|
||||
COLS_IN_ALPHA_INDEX = 5
|
||||
IGNORE_PREFIX = lumiera:: \
|
||||
lumiera_ \
|
||||
lumi_ \
|
||||
LUMIERA_
|
||||
#---------------------------------------------------------------------------
|
||||
# configuration options related to the HTML output
|
||||
#---------------------------------------------------------------------------
|
||||
GENERATE_HTML = YES
|
||||
HTML_OUTPUT = html
|
||||
HTML_FILE_EXTENSION = .html
|
||||
HTML_HEADER =
|
||||
HTML_FOOTER =
|
||||
HTML_STYLESHEET =
|
||||
HTML_ALIGN_MEMBERS = YES
|
||||
GENERATE_HTMLHELP = NO
|
||||
GENERATE_DOCSET = NO
|
||||
DOCSET_FEEDNAME = "Lumiera Doxygen docs"
|
||||
DOCSET_BUNDLE_ID = org.doxygen.Project
|
||||
HTML_DYNAMIC_SECTIONS = NO
|
||||
CHM_FILE =
|
||||
HHC_LOCATION =
|
||||
GENERATE_CHI = NO
|
||||
BINARY_TOC = NO
|
||||
TOC_EXPAND = NO
|
||||
DISABLE_INDEX = NO
|
||||
ENUM_VALUES_PER_LINE = 4
|
||||
GENERATE_TREEVIEW = YES
|
||||
TREEVIEW_WIDTH = 250
|
||||
#---------------------------------------------------------------------------
|
||||
# configuration options related to the LaTeX output
|
||||
#---------------------------------------------------------------------------
|
||||
GENERATE_LATEX = NO
|
||||
LATEX_OUTPUT = latex
|
||||
LATEX_CMD_NAME = latex
|
||||
MAKEINDEX_CMD_NAME = makeindex
|
||||
COMPACT_LATEX = YES
|
||||
PAPER_TYPE = a4wide
|
||||
EXTRA_PACKAGES =
|
||||
LATEX_HEADER =
|
||||
PDF_HYPERLINKS = YES
|
||||
USE_PDFLATEX = YES
|
||||
LATEX_BATCHMODE = YES
|
||||
LATEX_HIDE_INDICES = NO
|
||||
#---------------------------------------------------------------------------
|
||||
# configuration options related to the RTF output
|
||||
#---------------------------------------------------------------------------
|
||||
GENERATE_RTF = NO
|
||||
RTF_OUTPUT = rtf
|
||||
COMPACT_RTF = NO
|
||||
RTF_HYPERLINKS = NO
|
||||
RTF_STYLESHEET_FILE =
|
||||
RTF_EXTENSIONS_FILE =
|
||||
#---------------------------------------------------------------------------
|
||||
# configuration options related to the man page output
|
||||
#---------------------------------------------------------------------------
|
||||
GENERATE_MAN = NO
|
||||
MAN_OUTPUT = man
|
||||
MAN_EXTENSION = .3
|
||||
MAN_LINKS = NO
|
||||
#---------------------------------------------------------------------------
|
||||
# configuration options related to the XML output
|
||||
#---------------------------------------------------------------------------
|
||||
GENERATE_XML = NO
|
||||
XML_OUTPUT = xml
|
||||
XML_SCHEMA =
|
||||
XML_DTD =
|
||||
XML_PROGRAMLISTING = YES
|
||||
#---------------------------------------------------------------------------
|
||||
# configuration options for the AutoGen Definitions output
|
||||
#---------------------------------------------------------------------------
|
||||
GENERATE_AUTOGEN_DEF = NO
|
||||
#---------------------------------------------------------------------------
|
||||
# configuration options related to the Perl module output
|
||||
#---------------------------------------------------------------------------
|
||||
GENERATE_PERLMOD = NO
|
||||
PERLMOD_LATEX = NO
|
||||
PERLMOD_PRETTY = YES
|
||||
PERLMOD_MAKEVAR_PREFIX =
|
||||
#---------------------------------------------------------------------------
|
||||
# Configuration options related to the preprocessor
|
||||
#---------------------------------------------------------------------------
|
||||
ENABLE_PREPROCESSING = YES
|
||||
MACRO_EXPANSION = NO
|
||||
EXPAND_ONLY_PREDEF = NO
|
||||
SEARCH_INCLUDES = YES
|
||||
INCLUDE_PATH =
|
||||
INCLUDE_FILE_PATTERNS =
|
||||
PREDEFINED =
|
||||
EXPAND_AS_DEFINED =
|
||||
SKIP_FUNCTION_MACROS = YES
|
||||
#---------------------------------------------------------------------------
|
||||
# Configuration::additions related to external references
|
||||
#---------------------------------------------------------------------------
|
||||
TAGFILES =
|
||||
GENERATE_TAGFILE =
|
||||
ALLEXTERNALS = NO
|
||||
EXTERNAL_GROUPS = YES
|
||||
PERL_PATH = /usr/bin/perl
|
||||
#---------------------------------------------------------------------------
|
||||
# Configuration options related to the dot tool
|
||||
#---------------------------------------------------------------------------
|
||||
CLASS_DIAGRAMS = YES
|
||||
MSCGEN_PATH =
|
||||
HIDE_UNDOC_RELATIONS = YES
|
||||
HAVE_DOT = YES
|
||||
CLASS_GRAPH = YES
|
||||
COLLABORATION_GRAPH = YES
|
||||
GROUP_GRAPHS = YES
|
||||
UML_LOOK = YES
|
||||
TEMPLATE_RELATIONS = YES
|
||||
INCLUDE_GRAPH = YES
|
||||
INCLUDED_BY_GRAPH = YES
|
||||
CALL_GRAPH = YES
|
||||
CALLER_GRAPH = YES
|
||||
GRAPHICAL_HIERARCHY = NO
|
||||
DIRECTORY_GRAPH = YES
|
||||
DOT_IMAGE_FORMAT = png
|
||||
DOT_PATH =
|
||||
DOTFILE_DIRS =
|
||||
DOT_GRAPH_MAX_NODES = 50
|
||||
MAX_DOT_GRAPH_DEPTH = 1000
|
||||
DOT_TRANSPARENT = NO
|
||||
DOT_MULTI_TARGETS = YES
|
||||
GENERATE_LEGEND = YES
|
||||
DOT_CLEANUP = YES
|
||||
#---------------------------------------------------------------------------
|
||||
# Configuration::additions related to the search engine
|
||||
#---------------------------------------------------------------------------
|
||||
SEARCHENGINE = NO
|
||||
Loading…
Reference in a new issue