# a tuple = (parameter name, default value, prompt, validation method)
parameters = [
(file_subst, "%(NAME)s"),
- ("get_method", "archive", "get method for prepare", lambda l: l in ['cvs', 'git', 'archive'])
+ ("get_method", "dir", "archive", "get method for prepare", lambda l: l in ['cvs', 'git', 'archive', 'dir'])
]
# configuration to use this component with sat
{
name : "%(NAME)sCPP"
component_name : "%(NAME)s"
- get_sources : '%(get_method)s'
+ get_source : '%(get_method)s'
build_source : 'autotools'
git_info:
{
{
archive_name : '%(target)s'
}
+ dir_info:
+ {
+ dir : '%(target)s'
+ }
source_dir : $APPLICATION.workdir + $VARS.sep + 'SOURCES' + $VARS.sep + $name
build_dir : $APPLICATION.workdir + $VARS.sep + 'BUILD' + $VARS.sep + $name
depend : [
opt_depend : []
properties :
{
- is_cpp : "yes"
- environment : "salome"
+ cpp : "yes"
+ generate : "yes"
has_salome_gui : "yes"
logo : $source_dir + "/resources/%(NAME)s.png"
}
l_binpath_libpath = []
# create additional ROOT_DIR for CPP components
- if src.product.product_is_cpp(pi):
- assert 'component_name' in pi, 'Error : CPP component should have a component_name field'
+ if 'component_name' in pi:
compo_name = pi.component_name
- compo_root_dir = compo_name + "_ROOT_DIR"
- envcompo_root_dir = os.path.join(
- self.cfg.TOOLS.common.install_root, compo_name )
- self.set(compo_root_dir , envcompo_root_dir)
- bin_path = os.path.join(envcompo_root_dir, 'bin', 'salome')
- lib_path = os.path.join(envcompo_root_dir, 'lib', 'salome')
- l_binpath_libpath.append( (bin_path, lib_path) )
+ if compo_name + "CPP" == pi.name:
+ compo_root_dir = compo_name + "_ROOT_DIR"
+ envcompo_root_dir = os.path.join(
+ self.cfg.TOOLS.common.install_root, compo_name )
+ self.set(compo_root_dir , envcompo_root_dir)
+ bin_path = os.path.join(envcompo_root_dir, 'bin', 'salome')
+ lib_path = os.path.join(envcompo_root_dir, 'lib', 'salome')
+ l_binpath_libpath.append( (bin_path, lib_path) )
bin_path = os.path.join(env_root_dir, 'bin', 'salome')
if src.get_property_in_product_cfg(pi, "fhs"):