Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update testing environment setup script for Apple Silicon Macs. #694

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 14 additions & 10 deletions TestSupport/setup_env.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,23 +8,27 @@

VIRTUALENV_PATH=$1

if [ -d "$VIRTUALENV_PATH" ]; then
if [ -d "$VIRTUALENV_PATH" ]; then
echo "Virtual Env already installed"
elif [ -z "$VIRTUALENV_PATH" ]; then
echo "Usage: ./setup_env.sh <folder path>"
else
mkdir $VIRTUALENV_PATH
# Please ensure that `python` command refers to Python 2.7.18 to avoid compatibility issues.
# If you are using asdf, make sure to install and set Python 2.7.18 with the following commands:
#
# asdf install python 2.7.18
# asdf local python 2.7.18
# pip install virtualenv
python -m virtualenv $VIRTUALENV_PATH
source $VIRTUALENV_PATH/bin/activate

pushd $VIRTUALENV_PATH

curl -L -o virtualenv.pyz https://bootstrap.pypa.io/virtualenv.pyz

popd
# Make sure [email protected] is installed
brew install [email protected]

python $VIRTUALENV_PATH/virtualenv.pyz $VIRTUALENV_PATH
pip install Twisted==15.5
LDFLAGS="-L$(brew --prefix [email protected])/lib" CFLAGS="-I$(brew --prefix [email protected])/include" pip install cryptography
pip install autobahntestsuite

source $VIRTUALENV_PATH/bin/activate
pip install autobahntestsuite

echo "Environment succesfully set up in $VIRTUALENV_PATH."
fi