Skip to content

Commit

Permalink
Add hashlink as a submodule.
Browse files Browse the repository at this point in the history
  • Loading branch information
Apprentice-Alchemist committed Feb 28, 2022
1 parent c827c9e commit f9e2508
Show file tree
Hide file tree
Showing 10 changed files with 294 additions and 954 deletions.
6 changes: 6 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,12 @@
Export/
ndll/*/lime*
ndll/*/liblime*
ndll/*/*.hdll
ndll/*/*.hash
ndll/*/*.so
ndll/*/*.dylib
ndll/*/*.lib
ndll/*/hl*
project/all_objs
project/obj
project/vc*.pdb
Expand Down
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -58,3 +58,6 @@
[submodule "project/lib/mojoal"]
path = project/lib/mojoal
url = https://github.com/native-toolkit/mojoal
[submodule "project/lib/hashlink"]
path = project/lib/hashlink
url = https://github.com/HaxeFoundation/hashlink
52 changes: 27 additions & 25 deletions project/Build.xml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
<set name="ios" value="1" if="iphone" />
<set name="tvos" value="1" if="appletv" />

<set name="LIME_CAIRO" value="1"/>
<set name="LIME_CAIRO" value="1" />
<set name="LIME_CURL" value="1" unless="emscripten || winrt" />
<set name="LIME_EFSW" value="1" if="windows || mac || linux" unless="winrt" />
<set name="LIME_JPEG" value="1" />
Expand Down Expand Up @@ -65,10 +65,10 @@
<section if="LIME_CAIRO">

<compilerflag value="-I${NATIVE_TOOLKIT_PATH}/cairo/include" />
<compilerflag value="-I${NATIVE_TOOLKIT_PATH}/cairo/include/configs/default/" unless="windows || mac || linux"/>
<compilerflag value="-I${NATIVE_TOOLKIT_PATH}/cairo/include/configs/linux/" if="linux"/>
<compilerflag value="-I${NATIVE_TOOLKIT_PATH}/cairo/include/configs/windows/" if="windows"/>
<compilerflag value="-I${NATIVE_TOOLKIT_PATH}/cairo/include/configs/mac/" if="mac"/>
<compilerflag value="-I${NATIVE_TOOLKIT_PATH}/cairo/include/configs/default/" unless="windows || mac || linux" />
<compilerflag value="-I${NATIVE_TOOLKIT_PATH}/cairo/include/configs/linux/" if="linux" />
<compilerflag value="-I${NATIVE_TOOLKIT_PATH}/cairo/include/configs/windows/" if="windows" />
<compilerflag value="-I${NATIVE_TOOLKIT_PATH}/cairo/include/configs/mac/" if="mac" />
<compilerflag value="-DLIME_CAIRO" />
<compilerflag value="-DHAVE_CONFIG_H" />
<compilerflag value="-DCAIRO_WIN32_STATIC_BUILD" if="windows" />
Expand Down Expand Up @@ -124,6 +124,8 @@

</section>

<compilerflag value="-I${NATIVE_TOOLKIT_PATH}/hashlink/src" />

<section if="LIME_HASHLINK">

<compilerflag value="-DLIME_HASHLINK" />
Expand Down Expand Up @@ -218,22 +220,22 @@
<section unless="emscripten">

<compilerflag value="-I${NATIVE_TOOLKIT_PATH}/sdl/include/" />
<compilerflag value="-I${NATIVE_TOOLKIT_PATH}/sdl/include/configs/default/" unless="windows || mac || linux || rpi"/>
<compilerflag value="-I${NATIVE_TOOLKIT_PATH}/sdl/include/configs/linux/" if="linux" unless="rpi"/>
<compilerflag value="-I${NATIVE_TOOLKIT_PATH}/sdl/include/configs/windows/" if="windows" unless="winrt"/>
<compilerflag value="-I${NATIVE_TOOLKIT_PATH}/sdl/include/configs/mac/" if="mac"/>
<compilerflag value="-I${NATIVE_TOOLKIT_PATH}/sdl/include/configs/rpi/" if="rpi"/>
<compilerflag value="-I${NATIVE_TOOLKIT_PATH}/sdl/include/configs/winrt/" if="winrt"/>
<compilerflag value="-I${NATIVE_TOOLKIT_PATH}/sdl/include/configs/default/" unless="windows || mac || linux || rpi" />
<compilerflag value="-I${NATIVE_TOOLKIT_PATH}/sdl/include/configs/linux/" if="linux" unless="rpi" />
<compilerflag value="-I${NATIVE_TOOLKIT_PATH}/sdl/include/configs/windows/" if="windows" unless="winrt" />
<compilerflag value="-I${NATIVE_TOOLKIT_PATH}/sdl/include/configs/mac/" if="mac" />
<compilerflag value="-I${NATIVE_TOOLKIT_PATH}/sdl/include/configs/rpi/" if="rpi" />
<compilerflag value="-I${NATIVE_TOOLKIT_PATH}/sdl/include/configs/winrt/" if="winrt" />

<compilerflag value="-DHAVE_LIBC" />

</section>

<section if="rpi">

<compilerflag value="-I/opt/vc/include"/>
<compilerflag value="-I/opt/vc/include/interface/vcos/pthreads"/>
<compilerflag value="-I/opt/vc/include/interface/vmcs_host/linux"/>
<compilerflag value="-I/opt/vc/include" />
<compilerflag value="-I/opt/vc/include/interface/vcos/pthreads" />
<compilerflag value="-I/opt/vc/include/interface/vmcs_host/linux" />
<compilerflag value="-lbrcmGLESv2" />
<compilerflag value="-lbrcmEGL" />
<compilerflag value="-Wl,--no-undefined -lm -L/opt/vc/lib -lbcm_host -ldl -lpthread -lrt" />
Expand Down Expand Up @@ -325,7 +327,7 @@

<files id="android-cpufeatures">

<compilerflag value="-I${ANDROID_NDK_ROOT}/sources/android/cpufeatures" if="android"/>
<compilerflag value="-I${ANDROID_NDK_ROOT}/sources/android/cpufeatures" if="android" />
<file name="${ANDROID_NDK_ROOT}/sources/android/cpufeatures/cpu-features.c" />

</files>
Expand Down Expand Up @@ -422,7 +424,7 @@
<lib name="Xinput.lib" if="winrt" />
<lib name="DXGI.lib" if="winrt" />

<lib name="-libpath:../templates/bin/hl/windows" if="LIME_HASHLINK" />
<lib name="-libpath:${OUTPUT_DIR}/${BINDIR}" if="LIME_HASHLINK" />
<lib name="libhl.lib" if="LIME_HASHLINK" />
<!-- <lib name="-delayload:libhl.dll" /> -->

Expand All @@ -436,14 +438,14 @@
<lib name="-lgc" if="LIME_NEKO" />
<lib name="-lm" if="LIME_NEKO" />

<lib name="-L../templates/bin/hl/linux" if="LIME_HASHLINK" />
<lib name="-L${OUTPUT_DIR}/${BINDIR}" if="LIME_HASHLINK" />
<lib name="-lhl" if="LIME_HASHLINK" />

</section>

<section if="mac">

<vflag name="-l" value="iconv"/>
<vflag name="-l" value="iconv" />
<vflag name="-framework" value="IOKit" />
<vflag name="-framework" value="Foundation" />
<vflag name="-framework" value="CoreAudio" />
Expand All @@ -455,12 +457,12 @@
<vflag name="-framework" value="ForceFeedback" />
<vflag name="-framework" value="Carbon" />
<vflag name="-framework" value="AppKit" />
<vflag name="-framework" value="OpenAL"/>
<vflag name="-framework" value="OpenAL" />

<lib name="/opt/local/lib/libgc.a" if="LIME_NEKO" />
<lib name="-lm" if="LIME_NEKO" />

<lib name="-L../templates/bin/hl/mac" if="LIME_HASHLINK" />
<lib name="-L${OUTPUT_DIR}/${BINDIR}" if="LIME_HASHLINK" />
<lib name="-lhl" if="LIME_HASHLINK" />

</section>
Expand Down Expand Up @@ -500,8 +502,8 @@
<vflag name="-framework" value="OpenGLES" />
<vflag name="-framework" value="AudioToolbox" />
<vflag name="-framework" value="AudioUnit" />
<vflag name="-framework" value="OpenAL"/>
<vflag name="-framework" value="GameController"/>
<vflag name="-framework" value="OpenAL" />
<vflag name="-framework" value="GameController" />
<!-- <vflag name="-framework" value="CoreBluetooth" /> -->

<lib name="-ldl" />
Expand All @@ -519,9 +521,9 @@
<vflag name="-framework" value="OpenGLES" />
<vflag name="-framework" value="AudioToolbox" />
<vflag name="-framework" value="AudioUnit" />
<vflag name="-framework" value="OpenAL"/>
<vflag name="-framework" value="CoreMotion"/>
<vflag name="-framework" value="CoreText"/>
<vflag name="-framework" value="OpenAL" />
<vflag name="-framework" value="CoreMotion" />
<vflag name="-framework" value="CoreText" />
<!-- <vflag name="-framework" value="CoreBluetooth" /> -->

<lib name="-ldl" />
Expand Down
Loading

0 comments on commit f9e2508

Please sign in to comment.