Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Generate files by the order of dependencies. This would later help wi…

…th the duplicate symbols
  • Loading branch information...
commit 9d947327a6e9a7068c832091ffcfcab542b3001d 1 parent 087fc7f
@malkia authored
View
BIN  bin/OSX/luajit
Binary file not shown
View
BIN  bin/OSX/luajit.dylib
Binary file not shown
View
54 luajit
@@ -0,0 +1,54 @@
+#!/bin/bash
+dirname=$(dirname $0)
+pushd $dirname 1>/dev/null 2>/dev/null && absname=$(pwd) && popd 1>/dev/null 2>/dev/null
+
+# uname <option>, where <option>:
+# -s, --kernel-name print the kernel name
+# -n, --nodename print the network node hostname
+# -r, --kernel-release print the kernel release
+# -v, --kernel-version print the kernel version
+# -m, --machine print the machine hardware name
+# -p, --processor print the processor type or "unknown"
+# -i, --hardware-platform print the hardware platform or "unknown" - does not work on OSX
+# -o, --operating-system print the operating system - does not work on OSX
+
+OS=Unknown
+ARCH=Unknown
+SO=.Unknown
+
+# Find ARCH by machine
+case `uname -m` in
+ x86_64) ARCH=x64;;
+ i686) ARCH=x86;;
+ i386) ARCH=x86;;
+ arm*) ARCH=arm;;
+esac
+
+# Find OS by kernel name
+case `uname -s` in
+ Linux)
+ OS=Linux
+ OSARCH=$OS/$ARCH
+ SO=.so
+ # this should go away at some point (-Wl,-rpath $ORIGN)
+ export LD_LIBRARY_PATH=$absname/:$absname/bin/$OSARCH/:$LD_LIBRARY_PATH
+ ;;
+ Darwin)
+ OS=OSX
+ OSARCH=$OS # universal
+ SO=.dylib
+ # this should go away at some point (install_name_tool with @rpath and @executable path)
+ export DYLD_LIBRARY_PATH=$absname/bin/$OSARCH:$DYLD_LIBRARY_PATH
+ ;;
+ *)
+ case `uname -o` in
+ Cygwin)
+ OS=Windows
+ SO=.dll
+ ;;
+ esac
+esac
+
+export LUA_PATH="$absname/?.lua;$LUA_PATH"
+"$dirname/bin/$OSARCH/luajit" "$@"
+
Please sign in to comment.
Something went wrong with that request. Please try again.