de572d98af8238405c5d1292a788b1a85b0c68ebGarrett D'Amore# This file and its contents are supplied under the terms of the
de572d98af8238405c5d1292a788b1a85b0c68ebGarrett D'Amore# Common Development and Distribution License ("CDDL"), version 1.0.
de572d98af8238405c5d1292a788b1a85b0c68ebGarrett D'Amore# You may only use this file in accordance with the terms of version
de572d98af8238405c5d1292a788b1a85b0c68ebGarrett D'Amore# 1.0 of the CDDL.
de572d98af8238405c5d1292a788b1a85b0c68ebGarrett D'Amore# A full copy of the text of the CDDL should have accompanied this
de572d98af8238405c5d1292a788b1a85b0c68ebGarrett D'Amore# source. A copy of the CDDL is also available via the Internet at
de572d98af8238405c5d1292a788b1a85b0c68ebGarrett D'Amore# Copyright 2014 Garrett D'Amore <garrett@damore.org>
de572d98af8238405c5d1292a788b1a85b0c68ebGarrett D'Amore# First we set $dir to dirname $0, using efficient ksh builtins.
de572d98af8238405c5d1292a788b1a85b0c68ebGarrett D'Amoreif [[ ! -f ${cfg} && $cfg == symbols/setup.cfg ]]
de572d98af8238405c5d1292a788b1a85b0c68ebGarrett D'Amore # compiler check only
de572d98af8238405c5d1292a788b1a85b0c68ebGarrett D'Amore if [[ $a == "-d" ]]
de572d98af8238405c5d1292a788b1a85b0c68ebGarrett D'Amore# We look for architecture specific versions of the program,
de572d98af8238405c5d1292a788b1a85b0c68ebGarrett D'Amore# searching in several candidate directories. We run each one as
de572d98af8238405c5d1292a788b1a85b0c68ebGarrett D'Amore [[ -n $debug ]] && print "Checking for arch $f:"
de572d98af8238405c5d1292a788b1a85b0c68ebGarrett D'Amore [[ -n $found ]] && continue
de572d98af8238405c5d1292a788b1a85b0c68ebGarrett D'Amore if [[ -f $p ]]; then
de572d98af8238405c5d1292a788b1a85b0c68ebGarrett D'Amore [[ -n $debug ]] && print "Executing $p $* ${cfg}"
de572d98af8238405c5d1292a788b1a85b0c68ebGarrett D'Amore [[ -n $debug ]] && print
de572d98af8238405c5d1292a788b1a85b0c68ebGarrett D'Amore [[ -z $found ]] && [[ -n $debug ]] && print "NOT PRESENT"