Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitaly.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPatrick Steinhardt <psteinhardt@gitlab.com>2021-03-05 12:26:40 +0300
committerPatrick Steinhardt <psteinhardt@gitlab.com>2021-03-09 10:56:09 +0300
commitf9ec40319b076f5e50f6ca0e381d1e9e83e0af5e (patch)
tree4c11aa77e32bf437ee33496c06991dd435f7d55b
parent56c901febc2dbfc498d7998cc9229c438ffc7370 (diff)
Makefile: Fix protoc compiler always being considered out-of-date
The rule which provides our protoc compiler simply unzips the static protoc archive into the correct place. But unzip will set the modification time of unzipped files to their original creation date, which currently is July 28th 2020. As a result, the protoc executable will always be older than its "protoc.zip" dependency and thus cause make(1) to consider it out-of-date. Fix the issue by passing `-DD`, which suppresses restoration of file and directory mtimes.
-rw-r--r--Makefile3
1 files changed, 1 insertions, 2 deletions
diff --git a/Makefile b/Makefile
index 900528912..d44ead7cd 100644
--- a/Makefile
+++ b/Makefile
@@ -464,8 +464,7 @@ ${TOOLS_DIR}/protoc.zip: ${TOOLS_DIR}/protoc.version
${PROTOC}: ${TOOLS_DIR}/protoc.zip
${Q}rm -rf ${TOOLS_DIR}/protoc
- ${Q}mkdir -p ${TOOLS_DIR}/protoc
- cd ${TOOLS_DIR}/protoc && unzip ${TOOLS_DIR}/protoc.zip
+ ${Q}unzip -DD -q -d ${TOOLS_DIR}/protoc ${TOOLS_DIR}/protoc.zip
# We're using per-tool go.mod files in order to avoid conflicts in the graph in
# case we used a single go.mod file for all tools.