From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 92909 invoked by alias); 29 Aug 2017 17:31:03 -0000 Mailing-List: contact kawa-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: kawa-owner@sourceware.org Received: (qmail 92899 invoked by uid 89); 29 Aug 2017 17:31:02 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-24.6 required=5.0 tests=AWL,BAYES_00,FREEMAIL_ENVFROM_END_DIGIT,FREEMAIL_FROM,GIT_PATCH_0,GIT_PATCH_1,GIT_PATCH_2,GIT_PATCH_3,RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=ham version=3.3.2 spammy=2017-08-30, 20170830 X-HELO: mail-ua0-f175.google.com Received: from mail-ua0-f175.google.com (HELO mail-ua0-f175.google.com) (209.85.217.175) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 29 Aug 2017 17:30:52 +0000 Received: by mail-ua0-f175.google.com with SMTP id 105so12267204uad.3 for ; Tue, 29 Aug 2017 10:30:52 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=memXl4tE+ZDW1fBwuP52L/woMTBRRres1W6gw+KxMz0=; b=qKSAuEKm/KTeDsdXkf/ixXA9t2UTjuoRzk97PF9qBOiIBRp6HCgK3fVxV92E3K5sBm 5Vc6loyIKkyoqnSY83uXFXST2FvVgIP+4DBXW41Mn8jJ5Tti5DomOW981u8oW5cAXPJ3 BWxEeJJwecW+BKdiBpmjgm11B02pBeV00g+CdHarEm6nPueGGsbPvGnmva3ejVvDNjeh bZsz1EUl2X0GGBBYgH7ZRtSs0q2xwW8eBc6S7Xb0O6jbj+zKZmlMkpNY4Vi2ZbPvbWk0 ehkQ5SQd+h3rDHVPTqU8Pbbe/X7O5pYUQo19qVNvQk9DjoxUbSrwUJXhho6/ynoi8kqd zWsA== X-Gm-Message-State: AHYfb5hgPd/pyYYalwk+E0A9G/HK/IrFDIP8JqAr94zEB5fo2QQxju4T /DWrrOAAOHgANUu2Fr89W6sUky5xgQ== X-Received: by 10.176.3.143 with SMTP id 15mr679451uau.85.1504027850481; Tue, 29 Aug 2017 10:30:50 -0700 (PDT) MIME-Version: 1.0 Received: by 10.159.51.65 with HTTP; Tue, 29 Aug 2017 10:30:49 -0700 (PDT) In-Reply-To: References: From: Kay Zheng Date: Tue, 29 Aug 2017 17:31:00 -0000 Message-ID: Subject: Re: "Uncaught translation error" when transforming Kawa-compiled classes with dex To: Sonny To Cc: Per Bothner , Kawa mailing list Content-Type: text/plain; charset="UTF-8" X-IsSubscribed: yes X-SW-Source: 2017-q3/txt/msg00010.txt.bz2 Hi Sonny, Thanks for the suggestion. I carelessly left out an important fact, that I've compiled the same app against the 2.4 branch this way and it worked well, so I'd suspect it's some changes in Kawa that caused this error. Not necessarily a bug, though. Regards, Kay Z. 2017-08-30 1:12 GMT+08:00 Sonny To : > try using jdk 1.7 > i had strange errors too when i compiled for jdk1.8 > > On Tue, Aug 29, 2017 at 8:10 PM, Kay Zheng wrote: >> Hi Per, >> >> I tried building a simple skeleton Android app against the master >> branch, targeting Android API level 21 (Android 5.0). The compilation >> went well, but there's this ambiguous error when classes are being >> transformed to dex files: >> >> Uncaught translation error: com.android.dx.cf.code.SimException: >> local variable type mismatch: attempt to set or access a value of type >> int using a local variable of type gnu.mapping.CallContext. This is >> symptomatic of .class transformation tools that ignore local variable >> information. >> >> I don't really understand this error message, but since >> gnu.mapping.CallContext is part of Kawa, I'd try and post it in this >> mailing list. >> >> The source code for the skeleton app is on >> https://github.com/l04m33/KawaAndroidTemplate >> >> And here's how I built Kawa (I didn't install JDK 6, and used OpenJDK >> 8 instead, thus the explicit JAVACFLAGS): >> >> $ cat rebuild-kawa-latest-android.sh >> #!/bin/sh >> >> cd ./Kawa-latest-android >> >> if [ -f 'Makefile' ]; then >> make clean >> make distclean >> fi >> >> git checkout -- . >> git apply ../kawa-javacflags.patch >> >> ./autogen.sh >> export JAVACFLAGS="-g -source 1.6 -target 1.6" >> ./configure >> --with-android=/home/user/android_sdk/platforms/android-21/android.jar >> \ >> --disable-xquery \ >> --disable-jemacs \ >> --with-java-source=6 >> make >> >> And the content of kawa-javacflags.patch: >> >> $ cat kawa-javacflags.patch >> diff --git a/Makefile.am b/Makefile.am >> index da9e490..a0df1a3 100644 >> --- a/Makefile.am >> +++ b/Makefile.am >> @@ -372,10 +372,10 @@ $(srcdir)/patch-source-list: $(top_srcdir)/configure >> | sed -e 's|./||' | sort > $@ >> >> kawa/Version.class: kawa/Version.java >> - $(JAVAC) -d . $^ >> + $(JAVAC) -d . $(JAVACFLAGS) $^ >> >> gnu/kawa/util/PreProcess.class: gnu/kawa/util/PreProcess.java >> - $(JAVAC) -d . $^ >> + $(JAVAC) -d . $(JAVACFLAGS) $^ >> >> JAVA_PREPROCESS_OPTIONS = @JAVA_SOURCE_SELECTOR@ >> $(PREPROCESS_HTTPSERVER) $(PREPROCESS_XML) $(PREPROCESS_JLINE3) >> $(PREPROCESS_AWT) >> >> P.S.: I think this is an separate issue with hairy details, so I made >> a new thread. >> >> Regards, >> Kay Z.