diff --git a/cmake/BBBCrossCompileConfig.cmake b/cmake/BBBCrossCompileConfig.cmake index ace7264..bcf98ae 100644 --- a/cmake/BBBCrossCompileConfig.cmake +++ b/cmake/BBBCrossCompileConfig.cmake @@ -1,19 +1,19 @@ -# BBB_ROOTFS should point to the local directory which contains all the +# LINUX_ROOTFS should point to the local directory which contains all the # libraries and includes from the target raspi. # The following command can be used to do this, replace and the # local accordingly: # rsync -vR --progress -rl --delete-after --safe-links pi@:/{lib,usr,opt/vc/lib} -# RASPBIAN_ROOTFS needs to be passed to the CMake command or defined in the +# LINUX_ROOTFS needs to be passed to the CMake command or defined in the # application CMakeLists.txt before loading the toolchain file. # CROSS_COMPILE also needs to be set accordingly or passed to the CMake command -if(NOT DEFINED ENV{BBB_ROOTFS}) +if(NOT DEFINED ENV{LINUX_ROOTFS}) message(FATAL_ERROR - "Define the BBB_ROOTFS variable to point to the Beagle Bone Black rootfs." + "Define the LINUX_ROOTFS variable to point to the Beagle Bone Black rootfs." ) else() - set(SYSROOT_PATH "$ENV{BBB_ROOTFS}" CACHE PATH "BBB root filesystem path") + set(SYSROOT_PATH "$ENV{LINUX_ROOTFS}" CACHE PATH "Local Linux root filesystem path") message(STATUS "Beagle Bone Black sysroot: ${SYSROOT_PATH}") endif() diff --git a/cmake/PreProjectConfig.cmake b/cmake/PreProjectConfig.cmake index 619d6dd..b93bfdc 100644 --- a/cmake/PreProjectConfig.cmake +++ b/cmake/PreProjectConfig.cmake @@ -6,31 +6,22 @@ if(DEFINED TGT_BSP) message(STATUS "FSFW OSAL invalid for specified target BSP ${TGT_BSP}!") message(STATUS "Setting valid OS_FSFW: linux") set(OS_FSFW "linux") - if(${TGT_BSP} MATCHES "arm/stm32h743zi-nucleo") - if(NOT ${OS_FSFW} MATCHES freertos) - message(STATUS - "FSFW OSAL invalid for specified target BSP ${TGT_BSP}!" - ) - message(STATUS "Setting valid OS_FSFW: freertos") - set(OS_FSFW "freertos") - endif() - endif() endif() endif() if(${OS_FSFW} STREQUAL linux AND TGT_BSP) if(${TGT_BSP} MATCHES "host/none") elseif(${TGT_BSP} MATCHES "arm/raspberrypi") - if(NOT DEFINED ENV{RASPBIAN_ROOTFS}) + if(NOT DEFINED ENV{LINUX_ROOTFS}) if(NOT RASPBIAN_ROOTFS) - set(ENV{RASPBIAN_ROOTFS} "$ENV{HOME}/raspberrypi/rootfs") + message(FATAL_ERROR "LINUX_ROOTFS must be set to Raspberry Pi rootfs location") else() - set(ENV{RASPBIAN_ROOTFS} "${RASPBIAN_ROOTFS}") + set(ENV{LINUX_ROOTFS} "${LINUX_ROOTFS}") endif() else() message(STATUS - "RASPBIAN_ROOTFS from environmental variables used: " - "$ENV{RASPBIAN_ROOTFS}" + "LINUX_ROOTFS from environmental variables used: " + "$ENV{LINUX_ROOTFS}" ) endif() diff --git a/cmake/RPiCrossCompileConfig.cmake b/cmake/RPiCrossCompileConfig.cmake index c885558..76d2931 100644 --- a/cmake/RPiCrossCompileConfig.cmake +++ b/cmake/RPiCrossCompileConfig.cmake @@ -9,22 +9,22 @@ else() endif() -# RASPBIAN_ROOTFS should point to the local directory which contains all the +# LINUX_ROOTFS should point to the local directory which contains all the # libraries and includes from the target raspi. # The following command can be used to do this, replace and the # local accordingly: # rsync -vR --progress -rl --delete-after --safe-links pi@:/{lib,usr,opt/vc/lib} -# RASPBIAN_ROOTFS needs to be passed to the CMake command or defined in the +# LINUX_ROOTFS needs to be passed to the CMake command or defined in the # application CMakeLists.txt before loading the toolchain file. # CROSS_COMPILE also needs to be set accordingly or passed to the CMake command -if(NOT DEFINED ENV{RASPBIAN_ROOTFS}) +if(NOT DEFINED ENV{LINUX_ROOTFS}) message(FATAL_ERROR - "Define the RASPBIAN_ROOTFS variable to point to the Raspberry Pi rootfs." + "Define the LINUX_ROOTFS variable to point to the Raspberry Pi rootfs." ) else() - set(SYSROOT_PATH "$ENV{RASPBIAN_ROOTFS}" CACHE PATH "Raspbian root filesystem path") + set(SYSROOT_PATH "$ENV{LINUX_ROOTFS}" CACHE PATH "Local linux root filesystem path") message(STATUS "Raspberry Pi sysroot: ${SYSROOT_PATH}") endif() diff --git a/doc/README-bbb.md b/doc/README-bbb.md index f0606ac..a5c9640 100644 --- a/doc/README-bbb.md +++ b/doc/README-bbb.md @@ -232,7 +232,7 @@ These prerequisites are valid for Linux as well as Windows hosts. It is recommended to set the following environmental variables for the CMake build: - `CROSS_COMPILE`: Explicitely specify the name of the cross compiler - - `BBB_ROOTFS`: Explicitely set the path to the local BBB rootfs + - `LINUX_ROOTFS`: Explicitely set the path to the local BBB rootfs For example with the following commands @@ -244,7 +244,7 @@ It is recommended to test whether the environmental variables were set correctly for example by running ```sh -echo $BBB_ROOTFS +echo $LINUX_ROOTFS ``` These variables can either be set every time before a debugging session to diff --git a/doc/README-rpi.md b/doc/README-rpi.md index c8dc46f..6316bdb 100644 --- a/doc/README-rpi.md +++ b/doc/README-rpi.md @@ -258,14 +258,14 @@ cross-compile a toolchain yourself by following the steps in the It is recommended to set the following environmental variables for the CMake build: - `CROSS_COMPILE`: Explicitely specify the name of the cross compiler - `RASPBERRY_VERSION`: Explicitely specify the version of the Raspberry Pi - - `RASPBIAN_ROOTFS`: Explicitely set the path to the local RPi rootfs + - `LINUX_ROOTFS`: Explicitely set the path to the local RPi rootfs For example with the following commands ```sh export CROSS_COMPILE="arm-linux-gnueabihf" export RASPBERRY_VERSION="4" -export RASPBIAN_ROOTFS="" +export LINUX_ROOTFS="" ``` It is recommended to test whether the environmental variables were set correctly,