2016-11-07 19:31:29 -08:00
|
|
|
#!/bin/sh
|
|
|
|
if clang --version >/dev/null 2>&1; then true; else
|
|
|
|
echo "ERROR: Can't execute clang. You need to install Xcode and command line tools."
|
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
|
|
|
|
if mcs --version >/dev/null 2>&1; then true; else
|
|
|
|
echo "ERROR: Can't execute mcs. You need to install Mono from http://www.mono-project.com/download/ and re-login to apply PATH environment."
|
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
|
2016-11-11 09:04:31 -08:00
|
|
|
if mono --version >/dev/null 2>&1; then true; else
|
2016-11-07 19:31:29 -08:00
|
|
|
echo "ERROR: Can't execute mono64. You need to install Mono from http://www.mono-project.com/download/ and re-login to apply PATH environment."
|
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
|
2016-11-11 09:04:31 -08:00
|
|
|
cd "$( dirname "$0" )"
|
|
|
|
|
2016-11-07 19:31:29 -08:00
|
|
|
NUNIT=NUnit-2.6.4/bin
|
|
|
|
if [ -d $NUNIT \
|
|
|
|
-a -f $NUNIT/nunit-console.exe \
|
|
|
|
-a -f $NUNIT/lib/nunit-console-runner.dll \
|
|
|
|
-a -f $NUNIT/lib/nunit.core.dll \
|
|
|
|
-a -f $NUNIT/lib/nunit.core.interfaces.dll \
|
|
|
|
-a -f $NUNIT/lib/nunit.util.dll ]; then true; else
|
|
|
|
curl -L -O https://github.com/nunit/nunitv2/releases/download/2.6.4/NUnit-2.6.4.zip
|
2016-11-11 09:04:31 -08:00
|
|
|
unzip -qq NUnit-2.6.4.zip
|
2016-11-07 19:31:29 -08:00
|
|
|
rm NUnit-2.6.4.zip
|
|
|
|
fi
|
|
|
|
|
2016-12-07 05:12:11 -08:00
|
|
|
clang -g -Wall -Wextra -dynamiclib -o libyoga.dylib -I../../.. ../../../yoga/*.c ../../Yoga/YGInterop.cpp
|
2016-12-02 11:18:16 -08:00
|
|
|
mcs -debug -t:library -r:$NUNIT/nunit.framework.dll -out:YogaTest.dll *.cs ../../../csharp/Facebook.Yoga/*cs
|
|
|
|
MONO_PATH=$NUNIT mono --arch=64 --debug $NUNIT/nunit-console.exe YogaTest.dll
|