msi was acting up on a new application I was developing. When I ran make in my support module Db source directory I got:
wenorum@xildev4 488> make
perl -CSD /eda/epics/R3.15.5/base/bin/linux-x86_64/makeMakefile.pl O.linux-x86_64 ../../..
make -C O.linux-x86_64 -f ../Makefile TOP=../../.. \
make[1]: Entering directory `/home/lxusers/w/wenorum/src/siocPowerSupplyPWM/powerSupplyPWMSup/Db/O.linux-x86_64'
/eda/epics/R3.15.5/base/bin/linux-x86_64/msi -D -I. -I.. -I../O.Common -I../../../db -I/eda/epics/R3.15.5/modules/instrument/QF2preMonitor/head/db -I/eda/epics/R3.15.5/modules/soft/asyn/asyn4-31/db -I/eda/epics/R3.15.5/modules/soft/autosave/autosave-5-8/db -I/eda/epics/R3.15.5/modules/soft/iocExit/iocExit-2-0/db -I/eda/epics/R3.15.5/base/db -o ../O.Common/powerSupplyPWMSup.db -S../powerSupplyPWMSup.substitutions > powerSupplyPWMSup.db.d
Usage: msi [options] [template]
stdin is used if neither template nor substitution file is given
-h Print this help message
-D Output file dependencies, not substitutions
-V Undefined macros generate an error
-g All macros have global scope
-o<FILE> Send output to <FILE>
-I<DIR> Add <DIR> to include file search path
-M<SUBST> Add <SUBST> to (global) macro definitions
(<SUBST> takes the form VAR=VALUE,...)
-S<FILE> Expand the substitutions in FILE
Inflating database from ../powerSupplyPWMSup.substitutions
/eda/epics/R3.15.5/base/bin/linux-x86_64/msi -I. -I.. -I../O.Common -I../../../db -I/eda/epics/R3.15.5/modules/instrument/QF2preMonitor/head/db -I/eda/epics/R3.15.5/modules/soft/asyn/asyn4-31/db -I/eda/epics/R3.15.5/modules/soft/autosave/autosave-5-8/db -I/eda/epics/R3.15.5/modules/soft/iocExit/iocExit-2-0/db -I/eda/epics/R3.15.5/base/db -o powerSupplyPWMSup.db -S../powerSupplyPWMSup.substitutions
Usage: msi [options] [template]
stdin is used if neither template nor substitution file is given
-h Print this help message
-D Output file dependencies, not substitutions
-V Undefined macros generate an error
-g All macros have global scope
-o<FILE> Send output to <FILE>
-I<DIR> Add <DIR> to include file search path
-M<SUBST> Add <SUBST> to (global) macro definitions
(<SUBST> takes the form VAR=VALUE,...)
-S<FILE> Expand the substitutions in FILE
make[1]: *** [../O.Common/powerSupplyPWMSup.db] Error 1
make[1]: Leaving directory `/home/lxusers/w/wenorum/src/siocPowerSupplyPWM/powerSupplyPWMSup/Db/O.linux-x86_64'
make: *** [install.linux-x86_64] Error 2
Running msi again produced a .db file in the support module <TOP>/db/ directory.
wenorum@xildev4 491> cat powerSupplyPWMSup.substitutions
file "perFPGA.template"
{ pattern
{ P, R, PORT }
{"\$(P)","\$(R)","\$(PORT)" }
}
file "perBridge.template"
{ pattern
{ P, R, PORT, C }
{"\$(P)","\$(R)","\$(PORT)", 0 }}
}
So the error was in my code, but the error message produced by msi was pretty unhelpful. Something like “powerSupplyPWMSup.substitutions:10 — syntax error" would have been a lot more useful. Also it would probably be better if msi and/or the make system could remove any output file when the source contains syntax errors.