From aaf3aced55a3dba302ab4a25559607be8703c563 Mon Sep 17 00:00:00 2001 From: midipix Date: Sep 22 2016 02:32:56 +0000 Subject: build system: when building from a git repo, explicitly depend on .git/index. --- diff --git a/Makefile.in b/Makefile.in index 1a30a9f..1bbc47f 100644 --- a/Makefile.in +++ b/Makefile.in @@ -2,7 +2,7 @@ PACKAGE = @package@ NICKNAME = @nickname@ PROJECT_DIR = @project_dir@ SOURCE_DIR = @source_dir@ -GIT_REFERENCE_DIR = @git_reference_dir@ +GIT_REFERENCE_INDEX = @git_reference_index@ CUSTOM_INSTALL_HEADERS = @custom_install_headers@ AVOID_VERSION = @avoid_version@ @@ -219,7 +219,7 @@ host.tag: Makefile $(PROJECT_DIR)/sysinfo/host/host.sh --compiler="$(CC)" --cflags="$(CFLAGS)" touch host.tag -version.tag: $(GIT_REFERENCE_DIR) +version.tag: $(GIT_REFERENCE_INDEX) $(PROJECT_DIR)/sysinfo/version.sh \ -s $(SOURCE_DIR) \ -o build/$(PACKAGE)_version.h \ diff --git a/configure b/configure index 83de4b6..98efb4f 100755 --- a/configure +++ b/configure @@ -138,10 +138,10 @@ common_defaults() # git if [ -n "$mb_source_dir" ]; then if [ -d "$mb_source_dir/.git" ]; then - mb_git_reference_dir="\$(SOURCE_DIR)/.git" + mb_git_reference_index="\$(SOURCE_DIR)/.git/index" fi elif [ -d "$mb_project_dir/.git" ]; then - mb_git_reference_dir="\$(PROJECT_DIR)/.git" + mb_git_reference_index="\$(PROJECT_DIR)/.git/index" fi # project @@ -390,7 +390,7 @@ config_copy() -e 's^@nickname@^'"$mb_nickname"'^g' \ -e 's^@project_dir@^'"$mb_project_dir"'^g' \ -e 's^@source_dir@^'"$mb_source_dir"'^g' \ - -e 's^@git_reference_dir@^'"$mb_git_reference_dir"'^g' \ + -e 's^@git_reference_index@^'"$mb_git_reference_index"'^g' \ -e 's^@custom_install_headers@^'"$mb_custom_install_headers"'^g' \ -e 's^@avoid_version@^'"$mb_avoid_version"'^g' \ \