#
# Try haxelib install hxcpp when you get haxelib setup message
# (haxelib path search..)
#
#ln -s  /Users/admin/Downloads/Stencyl-full/plaf/haxe/lib/openfl-native/1,1,4/templates/neko/bin/neko-mac /Users/admin/Downloads/Stencyl-full/plaf/haxe/lib/openfl-native/1,1,4/templates/neko/bin/neko
# ln -s 
rm -rf obj
rm -rf ../ndll
mkdir ../ndll
mkdir ../ndll/iPhone
#export NEKOLPATH=/Users/admin/Downloads/Stencyl-full/plaf/haxe/lib/openfl-native/1,1,4/templates/neko/ndll/mac
#export NEKOLPATH=/Users/admin/Downloads/Stencyl-full/plaf/haxe/lib/lime/lime/templates/neko/ndll/mac64
export NEKOLPATH=/Users/admin/Downloads/plaf/neko-mac
#export NEKOPATH=/Users/admin/Downloads/Stencyl-full/plaf/haxe/lib/openfl-native/1,1,4/templates/neko/bin
#export NEKOPATH=/Users/admin/Downloads/Stencyl-full/plaf/haxe/lib/lime/lime/templates/neko/bin
#export NEKOPATH=/Users/admin/Downloads/Stencyl-full/plaf/neko-macx
export NEKOPATH=/Users/admin/Downloads/plaf/haxe-bin/mac
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$NEKOLPATH
export DYLD_LIBRARY_PATH=$NEKOLPATH
export PATH=$PATH:$NEKOPATH:/Users/admin/Downloads//Stencyl-full/plaf/haxe:$NEKOLPATH
echo $PATH
#haxelib run hxcpp Build.xml -Dandroid
haxelib run hxcpp Build.xml -Diphoneos
haxelib run hxcpp Build.xml -Diphoneos -DHXCPP_ARMV7
haxelib run hxcpp Build.xml -Diphoneos -DHXCPP_ARM64
haxelib run hxcpp Build.xml -Diphonesim
#haxelib run hxcpp Build.xml -DHXCPP_M64

rm -rf /Users/admin/stencylworks/games-generated/aa/Export/ios/aa/haxe/build/Release-iphoneos-64/include/MicroPhone.h
rm -rf /Users/admin/stencylworks/games-generated/aa/Export/ios/aa/haxe/build/Release-iphoneos-64/obj/iphoneos-c11-64/*MicroPhone*

rm -rf /Users/admin/stencylworks/games-generated/aa/Export/ios/aa/haxe/build/Release-iphoneos-v7/include/MicroPhone.h
rm -rf /Users/admin/stencylworks/games-generated/aa/Export/ios/aa/haxe/build/Release-iphoneos-v7/obj/iphoneos-c11-v7/*MicroPhone*

rm -rf  /Users/admin/stencylworks/games-generated/aa/Export/ios/aa/lib/arm64/libSayMi*.a
rm -rf  /Users/admin/stencylworks/games-generated/aa/Export/ios/aa/lib/armv7/libSayMi*.a
rm -rf  /Users/admin/stencylworks/games-generated/aa/Export/ios/aa/lib/i386/libSayMi*.a


