allow IOC to mount through different path than build system

This commit is contained in:
Jeff Hill
2000-09-26 16:41:34 +00:00
parent cab274cc36
commit b9fb83d506
3 changed files with 19 additions and 2 deletions

View File

@@ -3,3 +3,11 @@ include $(TOP)/configure/CONFIG_APP
# Add any changes to make definitions here
#CROSS_COMPILER_TARGET_ARCHS = vxWorks-68040
# Use this when your IOC and the host use different paths
# to access the application. Typically this will be
# used with the Microsoft FTP server or with NFS mounts. Use
# is indicated by failure of the cdCommands script on
# vxWorks. You must rebuild in the iocBoot directory
# before this takes effect.
#IOCS_APPL_TOP = <the top of the application as seen by the IOC>

View File

@@ -2,8 +2,8 @@
include $(EPICS_BASE)/configure/RULES_DIRS
buildInstall: cdCommands
cdCommands: Makefile
$(PERL) $(TOP)/configure/makeIocCdCommands.pl $(ARCH)
cdCommands: Makefile $(TOP)/configure/makeIocCdCommands.pl $(TOP)/configure/CONFIG
$(PERL) $(TOP)/configure/makeIocCdCommands.pl $(ARCH) $(IOCS_APPL_TOP)
clean:
@$(RM) cdCommands

View File

@@ -6,7 +6,16 @@ use Cwd;
$cwd = cwd();
#hack for sun4
$cwd =~ s|/tmp_mnt||;
#hack for win32
$cwd =~ s|\\|\/|g;
$arch = $ARGV[0];
$iocsApplTop = $ARGV[1];
#remove top parts of current working directory
#and add ioc's appl top alias (if supplied)
if ( $iocsApplTop ne "" ) {
$cwd =~ s|.*(/iocBoot.*)|$1|;
$cwd = $iocsApplTop . $cwd;
}
unlink("cdCommands");
open(OUT,">cdCommands") or die "$! opening cdCommands";