Skip to content

Commit 39f76b3

Browse files
author
Xiangfu Liu
committedSep 2, 2011
add git rev to boot.crc.bin
1 parent 41bafe1 commit 39f76b3

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed
 

‎src/Makefile

+1-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ load: boot.bin
3232
.PHONY: clean depend load boot.crc.bin
3333

3434
boot.crc.bin: boot.bin
35-
IMAGES_DIR=$(IMGDIR) ./append_crc_len.sh
35+
IMAGES_DIR=$(IMAGES_DIR) ./append_crc_len.sh
3636

3737
depend:
3838
makedepend -Y -- $(CFLAGS) -- *.c

‎src/append_crc_len.sh

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
#!/bin/bash
22

3-
BOOT_CRC_BIN="boot.crc.bin"
3+
REV=$(git log | head -n 1 | cut -b8-14)
4+
BOOT_CRC_BIN="boot.crc.${REV}.bin"
45

56
CRC_LEN_TMP=`mktemp`
67
BOOT_BIN_TMP=`mktemp`
@@ -70,5 +71,5 @@ do
7071
fi
7172
done
7273

73-
echo "boot.crc.bin created"
74+
echo "${BOOT_CRC_BIN} created"
7475
exit 0

0 commit comments

Comments
 (0)
Please sign in to comment.