Linux wireless drivers development
 help / color / mirror / Atom feed
* [PATCH] Don't get iw version from git if there is no .git/
@ 2013-09-06 15:41 Florian Schmaus
  2013-10-01 11:03 ` Johannes Berg
  0 siblings, 1 reply; 2+ messages in thread
From: Florian Schmaus @ 2013-09-06 15:41 UTC (permalink / raw)
  To: johannes; +Cc: linux-wireless, Florian Schmaus

The version.sh script should only try to get the version from git if the
source actually resides in a git repository, i.e. .git/ exists. Doing
otherwise in a non-git source repo results in git ascending until it
finds a .git directory, which will cause problems in some source-based
distributions ( https://bugs.gentoo.org/show_bug.cgi?id=482334 ).
---
 version.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/version.sh b/version.sh
index 80e55ab..0f1aa1d 100755
--- a/version.sh
+++ b/version.sh
@@ -3,7 +3,7 @@
 VERSION="3.11"
 OUT="$1"
 
-if head=`git rev-parse --verify HEAD 2>/dev/null`; then
+if [ -d .git ] && head=`git rev-parse --verify HEAD 2>/dev/null`; then
 	git update-index --refresh --unmerged > /dev/null
 	descr=$(git describe)
 
-- 
1.8.1.5


^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2013-10-01 11:03 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-09-06 15:41 [PATCH] Don't get iw version from git if there is no .git/ Florian Schmaus
2013-10-01 11:03 ` Johannes Berg

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox