]> code.delx.au - pulseaudio/commitdiff
make bootstrap.sh aware of Darwin environment
authorDaniel Mack <daniel@caiaq.de>
Fri, 17 Jul 2009 11:45:37 +0000 (13:45 +0200)
committerDiego Elio 'Flameeyes' Pettenò <flameeyes@gmail.com>
Fri, 17 Jul 2009 18:45:05 +0000 (20:45 +0200)
Signed-off-by: Daniel Mack <daniel@caiaq.de>
bootstrap.sh

index aa9755faacf8d462249830a5563d935f136e39e5..a5bd9a7814520006a16eea2681f930f26a199b3f 100755 (executable)
@@ -40,10 +40,22 @@ run_versioned() {
 
 set -ex
 
+case $(uname) in
+       *Darwin*)
+               CP_OPTS="-R"
+               CHMOD_OPTS=""
+               LIBTOOLIZE="glibtoolize"
+               ;;
+       *)
+               CP_OPTS="-av"
+               CHMOD_OPTS="-c"
+               ;;
+esac
+
 if [ -f .git/hooks/pre-commit.sample -a ! -f .git/hooks/pre-commit ] ; then
     echo "Activating pre-commit hook."
-    cp -av .git/hooks/pre-commit.sample .git/hooks/pre-commit
-    chmod -c +x  .git/hooks/pre-commit
+    cp ${CP_OPTS}  .git/hooks/pre-commit.sample .git/hooks/pre-commit
+    chmod ${CHMOD_OPTS} +x  .git/hooks/pre-commit
 fi
 
 if [ -f .tarball-version ]; then