Added st.cmd@Cross files for cross builds.

This commit is contained in:
Janet B. Anderson
2005-02-23 22:10:28 +00:00
parent 1aca5dc42a
commit 64e299dfdb
4 changed files with 50 additions and 1 deletions

View File

@@ -47,6 +47,7 @@ TEMPLATES += top/exampleBoot/nfsCommands@vxWorks
TEMPLATES += top/exampleBoot/ioc/Makefile@Common
TEMPLATES += top/exampleBoot/ioc/Makefile@vxWorks
TEMPLATES += top/exampleBoot/ioc/st.cmd@Common
TEMPLATES += top/exampleBoot/ioc/st.cmd@Cross
TEMPLATES += top/exampleBoot/ioc/st.cmd@vxWorks
TEMPLATES += top/exampleBoot/ioc/st.cmd@RTEMS
TEMPLATES += top/exampleBoot/ioc/README@Common
@@ -74,6 +75,7 @@ TEMPLATES += top/iocBoot/nfsCommands@vxWorks
TEMPLATES += top/iocBoot/ioc/Makefile@Common
TEMPLATES += top/iocBoot/ioc/Makefile@vxWorks
TEMPLATES += top/iocBoot/ioc/st.cmd@Common
TEMPLATES += top/iocBoot/ioc/st.cmd@Cross
TEMPLATES += top/iocBoot/ioc/st.cmd@vxWorks
TEMPLATES += top/iocBoot/ioc/st.cmd@RTEMS

View File

@@ -51,11 +51,14 @@ sub ReplaceFilename { # (filename)
# NB: Won't work with directories, don't use '@' in a directory name!
my($base,$filearch) = split /@/, $file;
if ($base ne $file) { # This file is arch-specific
my($os,$cpu_toolset) = split /-/, $arch, 2;
my($os,$cpu,$toolset) = split /-/, $arch, 3;
if (-r "$base\@$arch") { # A version exists for this arch
$base = '' unless ($filearch eq $arch && -s $file);
} elsif (-r "$base\@$os") { # A version exists for this os
$base = '' unless ($filearch eq $os && -s $file);
} elsif ( $ENV{EPICS_HOST_ARCH} !~ "$os-$cpu" &&
-r "$base\@Cross" ) { # Cross version exists
$base = '' unless ($filearch eq "Cross" && -s $file);
} elsif (-r "$base\@Common") { # Default version exists
$base = '' unless ($filearch eq "Common" && -s $file);
} else { # No default version

View File

@@ -0,0 +1,26 @@
#!../../bin/_ARCH_/_APPNAME_
## You may have to change _APPNAME_ to something else
## everywhere it appears in this file
#< envPaths
## Register all support components
dbLoadDatabase("../../dbd/_APPNAME_.dbd",0,0)
_APPNAME__registerRecordDeviceDriver(pdbbase)
## Load record instances
dbLoadRecords("../../db/dbExample1.db","user=_USER_Host")
dbLoadRecords("../../db/dbExample2.db","user=_USER_Host,no=1,scan=1 second")
dbLoadRecords("../../db/dbExample2.db","user=_USER_Host,no=2,scan=2 second")
dbLoadRecords("../../db/dbExample2.db","user=_USER_Host,no=3,scan=5 second")
dbLoadRecords("../../db/dbSubExample.db","user=_USER_Host")
## Set this to see messages from mySub
#var mySubDebug 1
iocInit()
## Start any sequence programs
#seq sncExample,"user=_USER_"

View File

@@ -0,0 +1,18 @@
#!../../bin/_ARCH_/_APPNAME_
## You may have to change _APPNAME_ to something else
## everywhere it appears in this file
#< envPaths
## Register all support components
dbLoadDatabase("../../dbd/_APPNAME_.dbd",0,0)
_APPNAME__registerRecordDeviceDriver(pdbbase)
## Load record instances
dbLoadRecords("../../db/_APPNAME_.db","user=_USER_")
iocInit()
## Start any sequence programs
#seq snc_APPNAME_,"user=_USER_"