|
15 | 15 | :${PGPORT=50432} |
16 | 16 | export PGPORT |
17 | 17 |
|
| 18 | +testhost=`uname -o` |
| 19 | + |
18 | 20 | temp_root=$PWD/tmp_check |
19 | 21 |
|
20 | 22 | if ["$1"='--install' ];then |
@@ -107,15 +109,28 @@ initdb |
107 | 109 | pg_upgrade -d"${PGDATA}.old" -D"${PGDATA}" -b"$oldbindir" -B"$bindir" |
108 | 110 |
|
109 | 111 | pg_ctl start -l"$logdir/postmaster2.log" -w |
110 | | -sh ./analyze_new_cluster.sh |
| 112 | + |
| 113 | +if [$testhost= Msys ];then |
| 114 | +cmd /c analyze_new_cluster.bat |
| 115 | +else |
| 116 | +sh ./analyze_new_cluster.sh |
| 117 | +fi |
111 | 118 | pg_dumpall>"$temp_root"/dump2.sql|| pg_dumpall2_status=$? |
112 | 119 | pg_ctl -m fast stop |
113 | 120 | if [-n"$pg_dumpall2_status" ];then |
114 | 121 | echo"pg_dumpall of post-upgrade database cluster failed" |
115 | 122 | exit 1 |
116 | 123 | fi |
117 | 124 |
|
118 | | -sh ./delete_old_cluster.sh |
| 125 | +if [$testhost= Msys ];then |
| 126 | +cmd /c delete_old_cluster.bat |
| 127 | +else |
| 128 | +sh ./delete_old_cluster.sh |
| 129 | +fi |
| 130 | + |
| 131 | +if [$testhost= Msys ];then |
| 132 | + dos2unix"$temp_root"/dump1.sql"$temp_root"/dump2.sql |
| 133 | +fi |
119 | 134 |
|
120 | 135 | if diff -q"$temp_root"/dump1.sql"$temp_root"/dump2.sql;then |
121 | 136 | echo PASSED |
|