@@ -8,7 +8,17 @@ ls -al isework/container.xst
8
8
chmod a-w isework/container.xst
9
9
ls -al isework/container.xst
10
10
11
- ( cd src ; make generated_vhdl firmware ../iomap.txt tools utilities )
11
+ # ensure these directory exists, if not, make them
12
+ if test ! -e " ./sdcard-files" ; then
13
+ echo " Creating ./sdcard-files"
14
+ mkdir ./sdcard-files
15
+ fi
16
+ if test ! -e " ./sdcard-files/old-bitfiles" ; then
17
+ echo " Creating ./sdcard-files/old-bitfiles"
18
+ mkdir ./sdcard-files/old-bitfiles
19
+ fi
20
+
21
+ ( cd src ; make generated_vhdl firmware ../iomap.txt tools utilities roms)
12
22
retcode=$?
13
23
14
24
if [ $retcode -ne 0 ] ; then
@@ -168,7 +178,17 @@ echo "From $outfile6: =================================================" >> $out
168
178
echo " Nil" >> $outfile0
169
179
170
180
echo " "
171
- # now copy the bit-file to the top-level-directory, and timestamp it with time and git-status
172
- echo " cp ./isework/container.bit ./bit${datetime2} _${branch2} _${gitstring} .bit"
173
- cp ./isework/container.bit ./bit${datetime2} _${branch2} _${gitstring} .bit
174
- ls ./bit${datetime2} _${branch2} _${gitstring} .bit
181
+ # now prepare the sdcard-output directory by moving any existing bit-file
182
+ for filename in ./sdcard-files/* .bit; do
183
+ echo " mv ${filename} ./sdcard-files/old-bitfiles"
184
+ mv ${filename} ./sdcard-files/old-bitfiles
185
+ done
186
+ # now copy the bit-file to the sdcard-output directory, and timestamp it with time and git-status
187
+ echo " cp ./isework/container.bit ./sdcard-files/bit${datetime2} _${branch2} _${gitstring} .bit"
188
+ cp ./isework/container.bit ./sdcard-files/bit${datetime2} _${branch2} _${gitstring} .bit
189
+ # and the KICKUP file
190
+ echo " cp ./src/KICKUP.M65 ./sdcard-files"
191
+ cp ./src/KICKUP.M65 ./sdcard-files
192
+
193
+ echo " "
194
+ ls -al ./sdcard-files
0 commit comments