Skip to content

Commit f9c418c

Browse files
committed
Fixed the BUILD scripts to work outside of a git repository
1 parent 5b275b4 commit f9c418c

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

BUILD/FINISH.sh

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -48,11 +48,15 @@ commands="$commands
4848
path=`dirname $0`
4949
. \"$path/autorun.sh\""
5050

51-
if [ -z "$just_clean" ]
51+
if [ -z "$just_clean"]
5252
then
53-
commands="$commands
54-
git submodule update
55-
CC=\"$CC\" CFLAGS=\"$cflags\" CXX=\"$CXX\" CXXFLAGS=\"$cxxflags\" CXXLDFLAGS=\"$CXXLDFLAGS\" $configure"
53+
if test -d .git
54+
then
55+
commands="$commands
56+
git submodule update"
57+
fi
58+
commands="$commands
59+
CC=\"$CC\" CFLAGS=\"$cflags\" CXX=\"$CXX\" CXXFLAGS=\"$cxxflags\" CXXLDFLAGS=\"$CXXLDFLAGS\" $configure"
5660
fi
5761

5862
if [ -z "$just_configure" -a -z "$just_clean" ]

0 commit comments

Comments
 (0)