mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-06-13 05:17:13 +02:00
Added pattern generator - must still implement client-server commands
This commit is contained in:
20
slsDetectorSoftware/patternGenerator/generate.sh
Executable file
20
slsDetectorSoftware/patternGenerator/generate.sh
Executable file
@ -0,0 +1,20 @@
|
||||
if [ "$#" -eq 0 ]; then
|
||||
echo "Wrong number of arguments: usage should be $0 patname"
|
||||
exit 1
|
||||
fi
|
||||
infile=$1
|
||||
outfile=$infile"at"
|
||||
if [ "$#" -ge 2 ]; then
|
||||
outfile=$2
|
||||
fi
|
||||
exe=$infile"exe"
|
||||
if [ "$#" -ge 3 ]; then
|
||||
exe=$3
|
||||
fi
|
||||
|
||||
if [ -f "$infile" ]
|
||||
then
|
||||
gcc -DINFILE="\"$infile\"" -DOUTFILE="\"$outfile\"" -o $exe generator.c ; ./$exe ; rm $exe
|
||||
else
|
||||
echo "$infile not found."
|
||||
fi
|
Reference in New Issue
Block a user