do not remove links found in .git directory
authorCristian Stoica <cristian.stoica@nxp.com>
Mon, 16 May 2016 13:10:24 +0000 (16:10 +0300)
committerRichard Levitte <levitte@openssl.org>
Mon, 16 May 2016 15:58:52 +0000 (17:58 +0200)
Some setups use links inside .git directory and make clean should not
remove them to avoid breaking git meta-information.

Signed-off-by: Cristian Stoica <cristian.stoica@nxp.com>
CLA: none; trivial
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Richard Levitte <levitte@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/1078)

Configurations/unix-Makefile.tmpl

index ea3b7083e6b8a62da4b8ac5d751df0b2ece79929..a31867ed3203947d9ba70cdee5d9eeed88a46a0a 100644 (file)
@@ -259,7 +259,7 @@ clean: libclean
        rm -f core
        rm -f tags TAGS
        rm -f openssl.pc libcrypto.pc libssl.pc
-       -rm -f `find . -type l`
+       -rm -f `find . -type l -a \! -path "./.git/*"`
        rm -f $(TARFILE)
 
 # This exists solely for those who still type 'make depend'