浏览代码

ENH: Cleaned up remote invocation.

Brad King 23 年之前
父节点
当前提交
adf6ac61e8
共有 1 个文件被更改,包括 6 次插入3 次删除
  1. 6 3
      Utilities/Release/cmake_release.sh

+ 6 - 3
Utilities/Release/cmake_release.sh

@@ -20,7 +20,7 @@
 # CMake UNIX Release Script.
 #
 
-SELF="$0"
+[ -z "$REMOTE" ] && SELF="$0"
 CVSROOT=":pserver:[email protected]:/cvsroot/CMake"
 CVSROOT_GREP=":pserver:[email protected]:[0-9]*/cvsroot/CMake"
 TAG="Release-1-6"
@@ -58,7 +58,9 @@ remote()
     shift
     REMOTE_TASK="$@"
     echo "------- Running remote task on $HOST. -------"
-    (echo "TASK=\"${REMOTE_TASK}\"" && cat $SELF) | ssh "$HOST" /bin/sh 2>/dev/null
+    (echo "REMOTE=\"1\"" &&
+     echo "TASK=\"${REMOTE_TASK}\"" &&
+     cat $SELF) | ssh "$HOST" /bin/sh 2>/dev/null
     echo "-------- Remote task on $HOST done.  --------"
 }
 
@@ -207,6 +209,7 @@ configure()
     echo "Running configure ..." &&
     (
         cd "cmake-${VERSION}-${PLATFORM}" &&
+        export CC CXX CFLAGS CXXFLAGS &&
         ../cmake-${VERSION}/configure --prefix=${PREFIX}
     ) >Logs/configure.log 2>&1 || error_log Logs/configure.log
 }
@@ -314,7 +317,7 @@ package()
 }
 
 if [ -z "$TASK" ]; then
-    TASK="$@"
+    [ -z "$REMOTE" ] && TASK="$@"
 fi
 
 if [ -z "$TASK" ]; then