summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile2
-rwxr-xr-xsrc/generate-gl-glue.sh19
2 files changed, 2 insertions, 19 deletions
diff --git a/Makefile b/Makefile
index f913f4c..84c016f 100644
--- a/Makefile
+++ b/Makefile
@@ -8,7 +8,7 @@ GL_GLUE=gl-glue.s
CC = gcc
CXX = g++
LD = g++
-AS = as
+AS = gcc -c -m32
LUAJIT = ../LuaJIT/src/libluajit.a
ifeq ($(SYSTEM),Darwin)
LIPO = lipo
diff --git a/src/generate-gl-glue.sh b/src/generate-gl-glue.sh
index d141e99..de6042a 100755
--- a/src/generate-gl-glue.sh
+++ b/src/generate-gl-glue.sh
@@ -51,31 +51,14 @@ cat $symlist | while read symbol ; do
echo ".globl _m$symbol"
echo "_m$symbol:"
case "$arch" in
- x86_64)
+ i386 | x86_64)
echo "jmp _$symbol"
;;
- i386)
- echo "jmp L_$symbol\$stub"
- ;;
*)
echo "b _$symbol"
esac
done
-if [ "x$arch" = "xi386" ] ; then
-
-echo ".section __IMPORT,__jump_table,symbol_stubs,self_modifying_code+pure_instructions,5"
-
-cat $symlist | while read symbol ; do
- echo "L_$symbol\$stub:"
- echo ".indirect_symbol _$symbol"
- echo "hlt; hlt; hlt; hlt; hlt;"
-done
-
-echo ".subsections_via_symbols"
-
-fi
-
elif [ "x$os" = "xLinux" ] ; then
cat $symlist | while read symbol ; do