• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1#!/bin/bash
2
3cd $(dirname $0)
4
5set -e
6
7PORT=12345
8
9./compile_extension.sh
10
11nohup php -d protobuf.keep_descriptor_pool_after_request=1 -dextension=../ext/google/protobuf/modules/protobuf.so -S localhost:$PORT multirequest.php 2>&1 &
12
13sleep 1
14
15wget http://localhost:$PORT/multirequest.result -O multirequest.result
16wget http://localhost:$PORT/multirequest.result -O multirequest.result
17
18pushd ../ext/google/protobuf
19phpize --clean
20popd
21
22PID=`ps | grep "php" | awk '{print $1}'`
23echo $PID
24
25if [[ -z "$PID" ]]
26then
27  echo "Failed"
28  exit 1
29else
30  kill $PID
31  echo "Succeeded"
32fi
33