mirror of
https://github.com/radareorg/radare2.git
synced 2024-11-23 13:19:54 +00:00
Avoid overwriting r_version.h if it didn't change.
This commit is contained in:
parent
42acaa7596
commit
b6a0a939fd
16
Makefile
16
Makefile
@ -37,13 +37,15 @@ GIT_TIP=$(shell git rev-parse HEAD 2>/dev/null || echo HEAD)
|
||||
GIT_NOW=$(shell date +%Y-%m-%d)
|
||||
|
||||
libr/include/r_version.h:
|
||||
echo "#ifndef R_VERSION_H" > $@
|
||||
echo "#define R_VERSION_H 1" >> $@
|
||||
echo "#define R2_VERSION_COMMIT $(R2VC)" >> $@
|
||||
echo '#define R2_GITTAP "$(GIT_TAP)"' >> $@
|
||||
echo '#define R2_GITTIP "$(GIT_TIP)"' >> $@
|
||||
echo '#define R2_BIRTH "$(GIT_NOW)"' >> $@
|
||||
echo '#endif' >> $@
|
||||
echo "#ifndef R_VERSION_H" > $@.tmp
|
||||
echo "#define R_VERSION_H 1" >> $@.tmp
|
||||
echo "#define R2_VERSION_COMMIT $(R2VC)" >> $@.tmp
|
||||
echo '#define R2_GITTAP "$(GIT_TAP)"' >> $@.tmp
|
||||
echo '#define R2_GITTIP "$(GIT_TIP)"' >> $@.tmp
|
||||
echo '#define R2_BIRTH "$(GIT_NOW)"' >> $@.tmp
|
||||
echo '#endif' >> $@.tmp
|
||||
diff -q $@.tmp $@ || mv -f $@.tmp $@
|
||||
rm -f $@.tmp
|
||||
|
||||
plugins.cfg:
|
||||
@if [ ! -e config-user.mk ]; then echo ; \
|
||||
|
Loading…
Reference in New Issue
Block a user