Re: Errors compiling LuaJit for Android on Mac

  • From: Nika Kolomentseva <nika@xxxxxxxxxxxxxxx>
  • To: luajit@xxxxxxxxxxxxx
  • Date: Thu, 13 Sep 2012 16:35:25 -0700

Nevermind: I had issues compiling beta 9 but beta 10 compiles just fine.

Thanks

On Thu, Sep 13, 2012 at 4:03 PM, Nika Kolomentseva <nika@xxxxxxxxxxxxxxx>wrote:

> Please advise about building android LuaJit on mac or  tips on resolving
> pseudo-op: `.private_extern' assembler errors in general.
>
>
>
>
>
> I am on Mac and following instruction to complie LuaJit2 in doc/install
> or http://luajit.org/install.html#android :
>
>
>
> The only change I made is to change linux-x86 to darwin-x86 to get NDK
> cross compiler. I also added TARGET_SYS=Linux (I tried with and without)
> per installation notes: “Whenever the host OS and the target OS differ, you
> need to specify TARGET_SYS or you'll get assembler or linker errors…”
>
>
>
> So my build script looks like this:
>
>
>
>
>
>     NDK=$ANDROID_NDK
>
>     NDKABI=8
>
>     NDKVER=$NDK/toolchains/arm-linux-androideabi-4.4.3
>
>     NDKP=$NDKVER/prebuilt/darwin-x86/bin/arm-linux-androideabi-
>
>     NDKF="--sysroot $NDK/platforms/android-$NDKABI/arch-arm"
>
>
>
>     make HOST_CC="gcc -m32" CROSS=$NDKP TARGET_SYS=Linux
> TARGET_FLAGS="$NDKF""
>
>
>
>
>
>
>
> My $ANDROID_NDK points to r8b Android NDK. But I also tried r8 and r7, and
> I tried gcc 4.6 with r8b. In all cases I get similar errors:
>
>
>
> ==== Building LuaJIT 2.0.0-beta9 ====
>
> make -C src
>
> ASM       lj_vm.o
>
> lj_vm.s: Assembler messages:
>
> lj_vm.s:5: Error: unknown pseudo-op: `.private_extern'
>
> lj_vm.s:8: Error: unknown pseudo-op: `.private_extern'
>
> lj_vm.s:25: Error: unknown pseudo-op: `.private_extern'
>
>
>
> …
>
>

Other related posts: