1# Folder structure:
2
3The default folder structure, which you will have if you just follow the default
4instructions is as follows:
5.
6├── components
7│   ├── common           Set of common scripts, documentation, etc
8│   ├── component_x      A BabbleSim component
9│   │   ├── Depends
10│   │   ├── doc
11│   │   ├── Makefile
12│   │   └── src
13│   └── ext_component_y  An external BabbleSim component (hosted in its own repo)
14│       ├── Depends
15│       ├── doc
16│       ├── Makefile
17│       └── src
18├── Makefile -> components/common/Makefile
19├── bin                  Where executables are installed ready to use
20├── lib                  Where libraries are stored ready to be loaded/linked to
21└── results              Where simulations output is stored
22
23But, other structures are supported.
24
25To easily support placing components and/or the output in different folders
26a set of environment variables are defined. These wil be set to the
27automatically assuming the default folder structure when using the provided
28Makefiles. But they can be set to something else before calling make.
29
30BSIM_COMPONENTS_PATH : Path to the components folder
31                       By default the top level makefile assumes it is in the
32                       same directory as the folder components/
33                       The individual component makefiles, assume they are
34                       placed inside components/<component>/
35
36BSIM_BASE_PATH       : Path to the folder where the base repo was cloned.
37                       By default the same as BSIM_COMPONENTS_PATH
38
39BSIM_OUT_PATH:       : Where the compilation results are installed. That is,
40                       where lib/ bin/ and results/ will be created.
41
42COMPONENT_OUTPUT_DIR : Where the intermediate results of compiling a particular
43                       component will be placed
44                       By default the folder of the component being compiled
45
46For the 2G4 external components:
47
482G4_libPhyComv1_COMP_PATH : Path where ext_2G4_libPhyComv1 was cloned.
49                           By default assumed to be
50                           ${BSIM_COMPONENTS_PATH}/ext_2G4_libPhyComv1
51
522G4_phy_v1_COMP_PATH     : Path where ext_2G4_phy_v1 was cloned.
53                           By default assumed to be
54                           ${BSIM_COMPONENTS_PATH}/ext_2G4_phy_v1