...
prj = env.ImportProject ()
since no name is provided, the local project is targetedcore = env.ImportProject (name = ‘CORE’)
access the project named core. Since this one is pre-initialized, this is an access, not a creationcsc = env.ImportProject (name = ‘CSC’)
If the project was previously created, it is just accessed.
If not, the project is created, using the current project as a template, i.e. it assumes the same include and library directory layout, as it does the library prefix and suffix. If these need customizing the full call isCode Block env.ImportProject (name = <name>, root = <root_directory>, incdir = <include_directory>, (can be absolute or relative to root, eg ‘inc’), libdir = <library_directory>, (can be absolute or relative to root, ‘iib’), pkgdir = <package_directory>, (this is not too useful), libprefix = <library_prefix> , (eg ‘lib’), libsuffix = <library_suffix>, (eg ‘.so’)
Here’s the call I use to initialize the ‘CORE’ project
nameCode Block env.ImportProject (
name = 'CORE',
incdir = paths.inc_core,
libdir = paths.lib)
If one had a need or desire to tailor each individual package, then the ‘pkgdir’ would be useful.
Effectively one could create a ‘Project’ for each package.
...