summaryrefslogtreecommitdiff
path: root/toolchain/ccache
diff options
context:
space:
mode:
Diffstat (limited to 'toolchain/ccache')
-rw-r--r--toolchain/ccache/ccache.mk23
1 files changed, 13 insertions, 10 deletions
diff --git a/toolchain/ccache/ccache.mk b/toolchain/ccache/ccache.mk
index 8a44a70fa..9cc177912 100644
--- a/toolchain/ccache/ccache.mk
+++ b/toolchain/ccache/ccache.mk
@@ -84,18 +84,21 @@ ccache-clean:
rm -rf $(STAGING_DIR)/bin/$(GNU_TARGET_NAME)-gcc
rm -rf $(STAGING_DIR)/bin/$(REAL_GNU_TARGET_NAME)-cc
rm -rf $(STAGING_DIR)/bin/$(REAL_GNU_TARGET_NAME)-gcc
- [ -f $(STAGING_DIR)/bin-ccache/$(REAL_GNU_TARGET_NAME)-gcc ] && \
- mv $(STAGING_DIR)/bin-ccache/$(REAL_GNU_TARGET_NAME)-gcc $(STAGING_DIR)/bin/
- (cd $(STAGING_DIR)/bin; \
- ln -fs $(REAL_GNU_TARGET_NAME)-gcc $(REAL_GNU_TARGET_NAME)-cc; \
- ln -fs $(REAL_GNU_TARGET_NAME)-gcc $(GNU_TARGET_NAME)-cc; \
- ln -fs $(REAL_GNU_TARGET_NAME)-gcc $(GNU_TARGET_NAME)-gcc;)
- [ -f $(STAGING_DIR)/bin-ccache/$(REAL_GNU_TARGET_NAME)-c++ ] && \
+ if [ -f $(STAGING_DIR)/bin-ccache/$(REAL_GNU_TARGET_NAME)-gcc ] ; then \
+ mv $(STAGING_DIR)/bin-ccache/$(REAL_GNU_TARGET_NAME)-gcc $(STAGING_DIR)/bin/; \
+ (cd $(STAGING_DIR)/bin; \
+ ln -fs $(REAL_GNU_TARGET_NAME)-gcc $(REAL_GNU_TARGET_NAME)-cc; \
+ ln -fs $(REAL_GNU_TARGET_NAME)-gcc $(GNU_TARGET_NAME)-cc; \
+ ln -fs $(REAL_GNU_TARGET_NAME)-gcc $(GNU_TARGET_NAME)-gcc); \
+ fi;
+ if [ -f $(STAGING_DIR)/bin-ccache/$(REAL_GNU_TARGET_NAME)-c++ ] ; then \
rm -f $(STAGING_DIR)/bin/$(REAL_GNU_TARGET_NAME)-c++; \
- mv $(STAGING_DIR)/bin-ccache/$(REAL_GNU_TARGET_NAME)-c++ $(STAGING_DIR)/bin/
- [ -f $(STAGING_DIR)/bin-ccache/$(REAL_GNU_TARGET_NAME)-g++ ] && \
+ mv $(STAGING_DIR)/bin-ccache/$(REAL_GNU_TARGET_NAME)-c++ $(STAGING_DIR)/bin/; \
+ fi;
+ if [ -f $(STAGING_DIR)/bin-ccache/$(REAL_GNU_TARGET_NAME)-g++ ] ; then \
rm -f $(STAGING_DIR)/bin/$(REAL_GNU_TARGET_NAME)-g++; \
- mv $(STAGING_DIR)/bin-ccache/$(REAL_GNU_TARGET_NAME)-g++ $(STAGING_DIR)/bin/
+ mv $(STAGING_DIR)/bin-ccache/$(REAL_GNU_TARGET_NAME)-g++ $(STAGING_DIR)/bin/; \
+ fi;
rm -rf $(STAGING_DIR)/bin-ccache/*
(cd $(STAGING_DIR)/bin; \
ln -fs $(REAL_GNU_TARGET_NAME)-g++ $(GNU_TARGET_NAME)-c++; \