
'Hack: prevent code stripping for reflection based apps.
'
MX2_WHOLE_ARCHIVE=0


'If you change anything below, you should rebuild all!


'***** WINDOWS DESKTOP TARGET *****

'Need this to override installed mingws.
'
GCC_EXEC_PREFIX=

'Add MinGW build tools to path...
'
'MinGW build tools can be found at https://monkey2.monkey-x.com/monkey2-files. Extract into your devtools folder.
'
'(Note: TDM GCC not recommended, as it uses SJLJ exceptions which are very slow)
'
PATH=${MX2_HOME}\devtools\i686-6.2.0-posix-dwarf-rt_v5-rev1\mingw32\bin;${PATH}

'Linker options
MX2_LD_OPTS_WINDOWS=-static -m32
MX2_LD_OPTS_WINDOWS_DEBUG=
MX2_LD_OPTS_WINDOWS_RELEASE=-s -O3 '-Wl,--gc-sections 

'C Compiler options
MX2_CC_OPTS_WINDOWS=-std=gnu99 -m32
MX2_CC_OPTS_WINDOWS_DEBUG=
MX2_CC_OPTS_WINDOWS_RELEASE=-O3 -DNDEBUG '-fdata-sections -ffunction-sections

'C++ Compiler options
MX2_CPP_OPTS_WINDOWS=-std=c++11 -m32
MX2_CPP_OPTS_WINDOWS_DEBUG=
MX2_CPP_OPTS_WINDOWS_RELEASE=-O3 -DNDEBUG '-fvtable-gc -fdata-sections -ffunction-sections


'***** EMSCRIPTEN/WASM *****

'Add emscripten build tools to path...
'
'Pre-built Emscripten build tools can be found at https://monkey2.monkey-x.com/monkey2-files. Extract into your devtools folder.
'
'Or you can build emscripten yourself: https://github.com/juj/emsdk/blob/master/README.md
'
PATH=${MX2_HOME}\devtools\emscripten-1.37.9\emscripten\tag-1.37.9;${PATH}

PATH=${MX2_HOME}\devtools\emscripten-1.37.9\python\2.7.5.3_64bit;${PATH}

'Add mserver_winnt emscripten mini-server/launcher.
'
MX2_MSERVER="${MX2_HOME}\devtools\mserver-v86c\mserver_winnt.exe"

'Linker options
MX2_LD_OPTS_EMSCRIPTEN=-s USE_SDL=2 -s TOTAL_MEMORY=67108864 -s DISABLE_EXCEPTION_CATCHING=1
MX2_LD_OPTS_EMSCRIPTEN_DEBUG=-O2
MX2_LD_OPTS_EMSCRIPTEN_RELEASE=-O3

'C Compiler options
MX2_CC_OPTS_EMSCRIPTEN=-std=gnu99 -s USE_SDL=2 -s TOTAL_MEMORY=67108864 -s DISABLE_EXCEPTION_CATCHING=1
MX2_CC_OPTS_EMSCRIPTEN_DEBUG=-O2
MX2_CC_OPTS_EMSCRIPTEN_RELEASE=-O3

'C++ Compiler options
MX2_CPP_OPTS_EMSCRIPTEN=-std=c++11 -s USE_SDL=2 -s TOTAL_MEMORY=67108864 -s DISABLE_EXCEPTION_CATCHING=1
MX2_CPP_OPTS_EMSCRIPTEN_DEBUG=-O2
MX2_CPP_OPTS_EMSCRIPTEN_RELEASE=-O3


'***** ANDROID *****

'This is where *my* ndk-bundle is located - yours is probably somewhere else!
'
'For android builds, you need to either set this correctly or make sure 'ndk-build' is in your system PATH.
'
'PATH=D:\devtools\Android\sdk\ndk-bundle;${PATH}

'Controls APP_ABI in Application.mk for NDK
'
MX2_ANDROID_APP_ABI=armeabi-v7a x86
'MX2_ANDROID_APP_ABI=all

'Controls APP_PLATFORM in Application.mk for NDK
'
MX2_ANDROID_APP_PLATFORM=10

'***** RASPBIAN *****

MX2_RASPBIAN_TOOLS=${MX2_HOME}\devtools\SysGCC\Raspberry\bin

'Linker options
MX2_LD_OPTS_RASPBIAN=-static
MX2_LD_OPTS_RASPBIAN_DEBUG=
MX2_LD_OPTS_RASPBIAN_RELEASE=-s ' -Wl,--gc-sections 

'C Compiler options
MX2_CC_OPTS_RASPBIAN=-std=gnu99
MX2_CC_OPTS_RASPBIAN_DEBUG=
MX2_CC_OPTS_RASPBIAN_RELEASE=-O3 -DNDEBUG ' -fdata-sections -ffunction-sections

'C++ Compiler options
MX2_CPP_OPTS_RASPBIAN=-std=c++11
MX2_CPP_OPTS_RASPBIAN_DEBUG=
MX2_CPP_OPTS_RASPBIAN_RELEASE=-O3 -DNDEBUG ' -fvtable-gc -fdata-sections -ffunction-sections
