Both TOOL and TARGET variables are automatically set internally as/where needed.  They are not part of the documented interface.
TOOL variables control what tools are run (among those that OpenCPI builds, like ocpigen), and are currently set /determined by the sourced opencpi-setup.sh.
TARGET variables are set internally in some places when you are building or running (via ocpidev) and default to the TOOL variables if no target RCC platform is specified.

A recent change in "develop" fixed a set of issues involving optimized vs. unoptimized targets - i.e. where you install opencpi unoptimized, and then also install it optimized.
AFAICT it was tested in various combinations of installation sequences, but is still busted in develop for this case, and doing "export OCPI_TARGET_DIR=$OCPI_TOOL_DIR" after sourcing opencpi-setup.sh is a workaround.

Jim


On 4/26/23 7:34 AM, dwp@md1tech.co.uk wrote:

Hi,

The TOOL variables were indeed set. I unset them and ran the source command and they returned to the same values:

OCPI_TOOL_OS=linux
OCPI_TOOL_PLATFORM=ubuntu22_04
OCPI_TOOL_ARCH=x86_64
OCPI_TOOL_DIR=ubuntu22_04
OCPI_TOOL_OS_VERSION=u22_04
OCPI_TOOL_PLATFORM_DIR=/home/dwp/git/opencpi/project-registry/ocpi.core/exports/rcc/platforms/ubuntu22_04

Running the source command also removed the TARGET variables and the problem returned when attempting ocpidev run
application example_rxToFile
giving the following output:

/bin/bash: line 1: target-/example_rxToFile: No such file or directory
make: *** [/home/dwp/git/opencpi/cdk/include/application.mk:70: run] Error 127

It is only when OCPI_TARGET_DIR is set to ubuntu_22_04 that the application runs. I can see that this variable is used in the file
<opencpi-root-dir>/cdk/include/application.mk on line 63.

Thanks,
Dan


_______________________________________________
discuss mailing list -- discuss@lists.opencpi.org
To unsubscribe send an email to discuss-leave@lists.opencpi.org