oNaiPs / droidVncServer

VNC server for Android devices.
GNU General Public License v3.0
909 stars 480 forks source link

error ndk build #53

Open oyahyaoui opened 11 years ago

oyahyaoui commented 11 years ago

Hi all, I faced an error when launching ndk-build. Below, the error log:

Compile arm : jpeg <= jidctfst.S jni/jpeg/jidctfst.S: Assembler messages: jni/jpeg/jidctfst.S:66: Error: missing ')' jni/jpeg/jidctfst.S:66: Error: garbage following instruction -- pld (r2,#0)' jni/jpeg/jidctfst.S:259: Error: missing ')' jni/jpeg/jidctfst.S:259: Error: garbage following instruction --pld (sp,#32)' jni/jpeg/jidctfst.S:271: Error: missing ')' jni/jpeg/jidctfst.S:271: Error: garbage following instruction -- pld (ip,#32)' /cygdrive/c/android-ndk/build/core/build-binary.mk:261: recipe for targetobj/local/armeabi/objs/jpeg/jidctfst.o' failed make: *\ [obj/local/armeabi/objs/jpeg/jidctfst.o] Error 1

Can you please help me on this? Thx.

rowntreerob commented 11 years ago

i had that same compiler error and changed case on the 'PLD' if its UPPER in source , chage it to lower. Note all other instructions are lower i think....

oyahyaoui commented 11 years ago

What do you mean by changing case to lower? Can you plz tell me how to do it? Many Thx/

rowntreerob commented 11 years ago

compile errors generated by command 'PLD'

i change "PLD" to 'pld' in the source, and the compile errors went away.

On Tue, Dec 4, 2012 at 10:15 AM, oyahyaoui notifications@github.com wrote:

What do you mean by changing case to lower? Can you plz tell me how to do it? Many Thx/

— Reply to this email directly or view it on GitHubhttps://github.com/oNaiPs/droid-VNC-server/issues/53#issuecomment-11008262.

oyahyaoui commented 11 years ago

try it and Did not do it: Compile arm : jpeg <= jidctfst.S jni/jpeg/jidctfst.S: Assembler messages: jni/jpeg/jidctfst.S:67: Error: garbage following instruction -- pld r2,#0' jni/jpeg/jidctfst.S:260: Error: missing ')' jni/jpeg/jidctfst.S:260: Error: garbage following instruction --pld (sp,#32)' jni/jpeg/jidctfst.S:272: Error: missing ')' jni/jpeg/jidctfst.S:272: Error: garbage following instruction -- pld (ip,#32)' /cygdrive/c/android-ndk/build/core/build-binary.mk:261: recipe for targetobj/local/armeabi/objs/jpeg/jidctfst.o' failed make: *\ [obj/local/armeabi/objs/jpeg/jidctfst.o] Error 1

rowntreerob commented 11 years ago

jni/jpeg/jidctfst.S:66: Error: missing ')' jni/jpeg/jidctfst.S:66: Error: garbage following instruction -- pld (r2,#0)' jni/jpeg/jidctfst.S:259: Error: missing ')' jni/jpeg/jidctfst.S:259: Error: garbage following instruction --pld (sp,#32)' jni/jpeg/jidctfst.S:271: Error: missing ')' jni/jpeg/jidctfst.S:271: Error: garbage following instruction -- `pld (ip,#32)' make: *\ [obj/local/ar

sed PLD to pld

i got the same error! as i told u already, the way i got rid of the compile error is to change an instruction 'PLD' to 'pld' the above is my log of my error and how i fixed it.

On Tue, Dec 4, 2012 at 10:56 AM, oyahyaoui notifications@github.com wrote:

try it and Did not do it: Compile arm : jpeg <= jidctfst.S jni/jpeg/jidctfst.S: Assembler messages: jni/jpeg/jidctfst.S:67: Error: garbage following instruction -- pld r2,#0' jni/jpeg/jidctfst.S:260: Error: missing ')' jni/jpeg/jidctfst.S:260: Error: garbage following instruction --pld (sp,

32 https://github.com/oNaiPs/droid-VNC-server/issues/32)'

jni/jpeg/jidctfst.S:272: Error: missing ')' jni/jpeg/jidctfst.S:272: Error: garbage following instruction -- pld (ip,#32)' /cygdrive/c/android-ndk/build/core/build-binary.mk:261: recipe for targetobj/local/armeabi/objs/jpeg/jidctfst.o' failed make: *\ [obj/local/armeabi/objs/jpeg/jidctfst.o] Error 1

— Reply to this email directly or view it on GitHubhttps://github.com/oNaiPs/droid-VNC-server/issues/53#issuecomment-11009964.

rowntreerob commented 11 years ago

look at the UPPERCASE PLD

https://github.com/oNaiPs/droid-VNC-server/blob/master/jni/jpeg/jidctfst.S

that is what i changed.

On Tue, Dec 4, 2012 at 12:19 PM, Robert Rowntree rowntreerob@gmail.comwrote:

jni/jpeg/jidctfst.S:66: Error: missing ')' jni/jpeg/jidctfst.S:66: Error: garbage following instruction -- pld (r2,#0)' jni/jpeg/jidctfst.S:259: Error: missing ')' jni/jpeg/jidctfst.S:259: Error: garbage following instruction --pld (sp,#32)' jni/jpeg/jidctfst.S:271: Error: missing ')' jni/jpeg/jidctfst.S:271: Error: garbage following instruction -- `pld (ip,#32)' make: *\ [obj/local/ar

sed PLD to pld

i got the same error! as i told u already, the way i got rid of the compile error is to change an instruction 'PLD' to 'pld' the above is my log of my error and how i fixed it.

On Tue, Dec 4, 2012 at 10:56 AM, oyahyaoui notifications@github.comwrote:

try it and Did not do it: Compile arm : jpeg <= jidctfst.S jni/jpeg/jidctfst.S: Assembler messages: jni/jpeg/jidctfst.S:67: Error: garbage following instruction -- pld r2,#0' jni/jpeg/jidctfst.S:260: Error: missing ')' jni/jpeg/jidctfst.S:260: Error: garbage following instruction --pld (sp,

32 https://github.com/oNaiPs/droid-VNC-server/issues/32)'

jni/jpeg/jidctfst.S:272: Error: missing ')' jni/jpeg/jidctfst.S:272: Error: garbage following instruction -- pld (ip,#32)' /cygdrive/c/android-ndk/build/core/build-binary.mk:261: recipe for targetobj/local/armeabi/objs/jpeg/jidctfst.o' failed make: *\ [obj/local/armeabi/objs/jpeg/jidctfst.o] Error 1

— Reply to this email directly or view it on GitHubhttps://github.com/oNaiPs/droid-VNC-server/issues/53#issuecomment-11009964.

rowntreerob commented 11 years ago

see build.log attached

i got rid of the refs to that asm file in the Android.mk in jni/jpeg folder

it builds fine on r8c NDK version

On Tue, Dec 4, 2012 at 12:33 PM, Robert Rowntree rowntreerob@gmail.comwrote:

look at the UPPERCASE PLD

https://github.com/oNaiPs/droid-VNC-server/blob/master/jni/jpeg/jidctfst.S

that is what i changed.

On Tue, Dec 4, 2012 at 12:19 PM, Robert Rowntree rowntreerob@gmail.comwrote:

jni/jpeg/jidctfst.S:66: Error: missing ')' jni/jpeg/jidctfst.S:66: Error: garbage following instruction -- pld (r2,#0)' jni/jpeg/jidctfst.S:259: Error: missing ')' jni/jpeg/jidctfst.S:259: Error: garbage following instruction --pld (sp,#32)' jni/jpeg/jidctfst.S:271: Error: missing ')' jni/jpeg/jidctfst.S:271: Error: garbage following instruction -- `pld (ip,#32)' make: *\ [obj/local/ar

sed PLD to pld

i got the same error! as i told u already, the way i got rid of the compile error is to change an instruction 'PLD' to 'pld' the above is my log of my error and how i fixed it.

On Tue, Dec 4, 2012 at 10:56 AM, oyahyaoui notifications@github.comwrote:

try it and Did not do it: Compile arm : jpeg <= jidctfst.S jni/jpeg/jidctfst.S: Assembler messages: jni/jpeg/jidctfst.S:67: Error: garbage following instruction -- pld r2,#0' jni/jpeg/jidctfst.S:260: Error: missing ')' jni/jpeg/jidctfst.S:260: Error: garbage following instruction --pld (sp,

32 https://github.com/oNaiPs/droid-VNC-server/issues/32)'

jni/jpeg/jidctfst.S:272: Error: missing ')' jni/jpeg/jidctfst.S:272: Error: garbage following instruction -- pld (ip,#32)' /cygdrive/c/android-ndk/build/core/build-binary.mk:261: recipe for targetobj/local/armeabi/objs/jpeg/jidctfst.o' failed make: *\ [obj/local/armeabi/objs/jpeg/jidctfst.o] Error 1

— Reply to this email directly or view it on GitHubhttps://github.com/oNaiPs/droid-VNC-server/issues/53#issuecomment-11009964.

giridhart commented 11 years ago

PLD to pld doesn't fix the issue.

rowntreerob commented 11 years ago

try following in ./jni/jpeg/Android.mk....

ifneq ($(TARGET_ARCH_ABI),armeabi-v7a)

LOCAL_PATH:= $(call my-dir) include $(CLEAR_VARS)

LOCAL_ARM_MODE := arm

LOCAL_SRC_FILES := \ jcapimin.c jcapistd.c jccoefct.c jccolor.c jcdctmgr.c jchuff.c \ jcinit.c jcmainct.c jcmarker.c jcmaster.c jcomapi.c jcparam.c \ jcphuff.c jcprepct.c jcsample.c jctrans.c jdapimin.c jdapistd.c \ jdatadst.c jdatasrc.c jdcoefct.c jdcolor.c jddctmgr.c jdhuff.c \ jdinput.c jdmainct.c jdmarker.c jdmaster.c jdmerge.c jdphuff.c \ jdpostct.c jdsample.c jdtrans.c jerror.c jfdctflt.c jfdctfst.c \ jfdctint.c jidctflt.c jidctred.c jquant1.c jidctint.c jidctfst.c \ jquant2.c jutils.c jmemmgr.c \ jmem-android.c

the assembler is only for the ARM version, don't break the Linux sim

temp fix until we understand why this broke cnn.com

ANDROID_JPEG_NO_ASSEMBLER := true

giridhart commented 11 years ago

It looks like syntax is wrong, I don't know why it worked in the first place.

it should be using [] instead of () so pld (sp, #0) becomes pld [sp, #0]

On Sat, Dec 8, 2012 at 1:04 AM, robert rowntree notifications@github.comwrote:

try following in ./jni/jpeg/Android.mk....

ifneq ($(TARGET_ARCH_ABI),armeabi-v7a)

LOCAL_PATH:= $(call my-dir) include $(CLEAR_VARS)

LOCAL_ARM_MODE := arm

LOCAL_SRC_FILES := \ jcapimin.c jcapistd.c jccoefct.c jccolor.c jcdctmgr.c jchuff.c \ jcinit.c jcmainct.c jcmarker.c jcmaster.c jcomapi.c jcparam.c \ jcphuff.c jcprepct.c jcsample.c jctrans.c jdapimin.c jdapistd.c \ jdatadst.c jdatasrc.c jdcoefct.c jdcolor.c jddctmgr.c jdhuff.c \ jdinput.c jdmainct.c jdmarker.c jdmaster.c jdmerge.c jdphuff.c \ jdpostct.c jdsample.c jdtrans.c jerror.c jfdctflt.c jfdctfst.c \ jfdctint.c jidctflt.c jidctred.c jquant1.c jidctint.c jidctfst.c \ jquant2.c jutils.c jmemmgr.c \ jmem-android.c the assembler is only for the ARM version, don't break the Linux sim temp fix until we understand why this broke cnn.com

ANDROID_JPEG_NO_ASSEMBLER := true

— Reply to this email directly or view it on GitHubhttps://github.com/oNaiPs/droid-VNC-server/issues/53#issuecomment-11152859.

robertoimai commented 11 years ago

Does anyone have a solution for this error? I'm getting the same thing

rowntreerob commented 11 years ago

goto jni/jpg folder and make following changes to Android.mk and it will build....

rob@ jpeg$ diff Android.mk~ Android.mk 15c15

< jfdctint.c jidctflt.c jidctred.c jquant1.c \

jfdctint.c jidctflt.c jidctred.c jquant1.c jidctint.c jidctfst.c \ 20,22d19 < ifneq ($(TARGET_ARCH),arm) < ANDROID_JPEG_NO_ASSEMBLER := true < endif 27,32d23 < ifeq ($(strip $(ANDROID_JPEG_NO_ASSEMBLER)),true) < LOCAL_SRC_FILES += jidctint.c jidctfst.c < else < LOCAL_SRC_FILES += jidctint.c jidctfst.S < endif < 34c25

< LOCAL_CFLAGS += -O3 -fstrict-aliasing -fprefetch-loop-arrays

LOCAL_CFLAGS += -O3 -fstrict-aliasing -fprefetch-loop-arrays -march=armv7-a -mfloat-abi=softfp -mfpu=vfpv3

rowntreerob commented 11 years ago

change the android.mk file in the problem folder (jni/jpg) as indicated by the DIFF in the paste

http://pastebin.com/K7LrDqxc

robertoimai commented 11 years ago

This is what I got:

cc1.exe: error: unrecognized command line option '-mfloat-abi=softfp' cc1.exe: error: unrecognized command line option '-mfpu=vfpv3' jni/jpeg/jcapimin.c:1:0: error: bad value (armv7-a) for -march= switch make: *\ [obj/local/x86/objs/jpeg/jcapimin.o] Error 1


From: robert rowntree [notifications@github.com] Sent: Friday, December 28, 2012 12:13 PM To: oNaiPs/droid-VNC-server Cc: Roberto Imai Subject: Re: [droid-VNC-server] error ndk build (#53)

change the android.mk file in the problem folder (jni/jpg) as indicated by the DIFF in the paste

http://pastebin.com/K7LrDqxc

— Reply to this email directly or view it on GitHubhttps://github.com/oNaiPs/droid-VNC-server/issues/53#issuecomment-11740444.

Djeezus commented 11 years ago

change "pld" argument enclosure to brackets in "jni/jpeg/jidctfst.S" it's just a simple syntax error

pld [s,#0] and so on ...

read all about it here :) http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.dui0068b/Chdjffbi.html

grtz, Gert

robertoimai commented 11 years ago

Yeah, I got it to compile and work, but was unsuccessful in changing the package name :( https://github.com/oNaiPs/droid-VNC-server/issues/58

radj commented 11 years ago

Changing from PLD() to PLD[] worked! Thanks for the solution @giridhart!

chorfa007 commented 11 years ago

Hi i confirme that change PLD() to PLD[] worked! thanks again @giridhart!

netty1916 commented 9 years ago

solution: Set ANDROID_JPEG_NO_ASSEMBLER := true in /jni/jpeg/Android.mk and change pld (...) to pld [...] confirmation ok!