diff --git a/4-Deploy-motorVMC.md b/4-Deploy-motorVMC.md index c3cbe2c25d198e4e3cd2bd82280d3f5c6c4342fb..40850e7fd0bce21aadda398568b5c435e2b36db1 100644 --- a/4-Deploy-motorVMC.md +++ b/4-Deploy-motorVMC.md @@ -83,7 +83,7 @@ The error was much more helpful in step 2.4 because [xxx's CONFIG file prints th <details> <summary>hint</summary> -The README.md file indicates: *"The definitions of `MOTOR` and `EPICS_BASE` need to be corrected in `motorVMC/configure/RELEASE` before motorVMC can be built."* +The **motorVMC/README.md** file indicates: *"The definitions of `MOTOR` and `EPICS_BASE` need to be corrected in `motorVMC/configure/RELEASE` before motorVMC can be built."* The **motorVMC/configure/RELEASE** file doesn't contain any definitions, but it does include other files **if they exist**. @@ -99,9 +99,9 @@ The **motorVMC/configure/RELEASE** file doesn't contain any definitions, but it $ cp -p configure/EXAMPLE_RELEASE.local configure/RELEASE.local ``` -The RELEASE.local file contains two variables that need be defined: `MOTOR` and `MOTOR_VMC` +The **RELEASE.local** file contains two variables that need be defined: `MOTOR` and `MOTOR_VMC` -`MOTOR` should be set to the same path that is in the envPaths file: +`MOTOR` should be set to the same path that is in the **envPaths** file: ``` $ grep MOTOR ${IOC_DIR}/xxx/iocBoot/iocxxx/envPaths @@ -131,7 +131,8 @@ MOTOR_VMC=/home/beams/USERNAME/PET-S2/epics/synApps/support/motorVMC <summary>where is EPICS_BASE defined?</summary> The `EPICS_BASE` variable is not explicitly defined: it is defined in the motor - configuration file that is included with on line 2 of the configure/RELEASE.local file `-include $(MOTOR)/modules/RELEASE.$(EPICS_HOST_ARCH).local`: +configuration file that is included with on line 2 of the **configure/RELEASE.local** +file `-include $(MOTOR)/modules/RELEASE.$(EPICS_HOST_ARCH).local`: ``` $ cat ${MOTOR}/modules/RELEASE.${EPICS_HOST_ARCH}.local @@ -149,22 +150,32 @@ SUPPORT = /APSshare/epics/synApps_6_2_1/support <details> <summary>what is the difference between RELEASE and RELEASE.local?</summary> -In the motorVMC module's configure folder, the presence of two RELEASE files, RELEASE and RELEASE.local, suggests that there are two levels of configuration that can be applied when building the IOC. Here's the difference between the two: +In the motorVMC module's configure folder, the presence of two **RELEASE** files, +**RELEASE** and **RELEASE.local**, allows for two levels of configuration that can +be applied when building the IOC. Here's the difference between the two: -- RELEASE file: -The RELEASE file contains the default configuration for the motorVMC module. It specifies the paths to external support modules or libraries required by the motorVMC module. This file provides a standard configuration that is used by default when building the IOC. +- **RELEASE** file: +The **RELEASE** file contains the default configuration for the motorVMC module. +It specifies the paths to external support modules or libraries required by the +motorVMC module. This file provides a standard configuration that is used by default +when building the IOC. -- RELEASE.local file: -The RELEASE.local file is intended for local customization of the configuration. It allows you to override or modify the default configuration specified in the RELEASE file. By including the RELEASE.local file in the configure/RELEASE file, you can provide additional or alternative configuration settings specific to your local environment or requirements. +- **RELEASE.local** file: +The **RELEASE.local** file is intended for local customization of the configuration. +It allows you to override or modify the default configuration specified in the +**RELEASE** file. By including the RELEASE.local file in the **configure/RELEASE** +file, you can provide additional or alternative configuration settings specific to +your local environment or requirements. </details> <details> -<summary>what is the difference between "building inside motor" and "building outside motor"?</summary> +<summary>what is the difference between "building inside motor" and +"building outside motor"?</summary> -The RELEASE file contains the following: +The **RELEASE** file contains the following: ``` $ cat configure/RELEASE @@ -176,15 +187,28 @@ $ cat configure/RELEASE -include $(TOP)/configure/RELEASE.local ``` -"building inside motor" and "building outside motor" refer to different scenarios or environments for compiling or building the IOC. +"building inside motor" and "building outside motor" refer to different scenarios +for compiling or building the IOC. - Building inside motor: -When building inside motor, it implies that you are within the motor module's directory structure. The `$(TOP)` variable represents the top-level directory of the motor module. In this case, the IOC is being built as part of the motor module itself. -The line `-include $(TOP)/../RELEASE.$(EPICS_HOST_ARCH).local` is included in the configure/RELEASE file. This line instructs the build system to include the generated release file from the motor module. The release file contains configuration information specific to the motor module, such as paths to external support modules or libraries. +When building inside motor, it implies that you are within the motor module's +directory structure. The `$(TOP)` variable represents the top-level directory of +the motor module. In this case, the IOC is being built as part of the motor module +itself. The line `-include $(TOP)/../RELEASE.$(EPICS_HOST_ARCH).local` is included +in the configure/RELEASE file. This line instructs the build system to include +the generated release file from the motor module. The release file contains +configuration information specific to the motor module, such as paths to external +support modules or libraries. - Building outside motor: -When building outside motor, it means you are not within the motor module's directory structure. It implies that you are building the IOC separately from the motor module: the 'make' command is issued in the ${SUPPORT_DIR}/motorVMC directory. -In this case, the line -include `$(TOP)/configure/RELEASE.local` is included in the configure/RELEASE file. This line instructs the build system to include the RELEASE.local file from the motorVMC module. The RELEASE.local file typically contains configuration information specific to the IOC being built outside the motor module. +When building outside motor, it means you are not within the motor module's directory +structure. It implies that you are building the IOC separately from the motor module: +the `make` command is issued in the ${SUPPORT_DIR}/motorVMC directory. +In this case, the line `-include $(TOP)/configure/RELEASE.local` is included in the +**configure/RELEASE** file. This line instructs the build system to include the +**RELEASE.local** file from the motorVMC module. The **RELEASE.local** file typically +contains configuration information specific to the IOC being built outside the motor +module. </details> @@ -222,11 +246,15 @@ make: *** [/APSshare/epics/base-7.0.4.1/configure/RULES_DIRS:85: configure.insta ``` </details> -Note: this build error occurs when there is a mismatch (hard mount vs soft link) between the /APSshare mount on the computer that built the support on /APSshare and the computer building the IOC. The two `MOTOR` paths actually point to the same directory. +Note: this build error occurs when there is a mismatch (hard mount vs soft link) +between the **/APSshare** mount on the computer that built the support on **/APSshare** +and the computer building the IOC. The two `MOTOR` paths actually point to the same +directory. ### 4.6 Resolve build error #2 -The **configure/CONFIG_SITE** is where the checkRelease behavior is defined. The `CHECK_RELEASE` variable can be overridden to ignore this error. +The **configure/CONFIG_SITE** is where the checkRelease behavior is defined. +The `CHECK_RELEASE` variable can be overridden to ignore this error. <details> <summary>hint</summary> @@ -259,6 +287,35 @@ $ echo "CHECK_RELEASE = NO" > configure/CONFIG_SITE.local ``` </details> +<details> +<summary>what does this mean</summary> + +The error message indicates a conflict between the `MOTOR` definition in the +**RELEASE.local** file and the `SUPPORT` support directory because of the +mounting configuration or symbolic links between different machines. + +To resolve this error, you can modify the `CHECK_RELEASE` setting to either `NO` +or `WARN` in the **configure/CONFIG_SITE** file. This will disable or allow the build +to continue despite the inconsistency detected. However, please note that it's +important to ensure the paths in the **RELEASE*** files accurately reflect the correct +locations of the support applications to avoid potential issues during runtime. + +Just like the **RELEASE.local** file, the **CONFIG_SITE.local** file allows for local +customization of the build configuration. The lines +`-include $(TOP)/../CONFIG_SITE.local` and `-include $(TOP)/configure/CONFIG_SITE.local` + in the **configure/CONFIG_SITE** file instruct the build system to include the + **CONFIG_SITE.local** files if they exist in the specified locations. The `$(TOP)` + variable represents the top-level directory of the IOC. + + + Note: the linux command `$ echo "CHECK_RELEASE = NO" > configure/CONFIG_SITE.local` + writes the text "CHECK_RELEASE = NO" to the **configure/CONFIG_SITE.local** file. + If the file does not exist, the `>` sign creates the file and writes the output to it. + If the file already exists, the `>` sign overwrites its contents with the new output + +</details> + + ### 4.7 Build motorVMC ```