Return-Path: Delivered-To: apmail-felix-dev-archive@www.apache.org Received: (qmail 28439 invoked from network); 4 May 2010 14:22:08 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 4 May 2010 14:22:08 -0000 Received: (qmail 50543 invoked by uid 500); 4 May 2010 14:22:08 -0000 Delivered-To: apmail-felix-dev-archive@felix.apache.org Received: (qmail 50469 invoked by uid 500); 4 May 2010 14:22:08 -0000 Mailing-List: contact dev-help@felix.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@felix.apache.org Delivered-To: mailing list dev@felix.apache.org Received: (qmail 50461 invoked by uid 99); 4 May 2010 14:22:08 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 04 May 2010 14:22:08 +0000 X-ASF-Spam-Status: No, hits=-2.3 required=10.0 tests=RCVD_IN_DNSWL_MED,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of brucej@qualcomm.com designates 199.106.114.251 as permitted sender) Received: from [199.106.114.251] (HELO wolverine02.qualcomm.com) (199.106.114.251) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 04 May 2010 14:22:01 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=qualcomm.com; i=brucej@qualcomm.com; q=dns/txt; s=qcdkim; t=1272982920; x=1304518920; h=from:to:date:subject:thread-topic:thread-index: message-id:in-reply-to:accept-language:content-language: x-ms-has-attach:x-ms-tnef-correlator:user-agent: acceptlanguage:content-type:content-transfer-encoding: mime-version; z=From:=20"Jackson,=20Bruce"=20|To: =20"dev@felix.apache.org"=20|Date: =20Tue,=204=20May=202010=2007:21:30=20-0700|Subject:=20Re :=20Felix=20compiler=20version=20&=20Android=20dx |Thread-Topic:=20Felix=20compiler=20version=20&=20Android =20dx|Thread-Index:=20AcrrhHZMPSMKg64sSdiYervVKtCG2QAEKCU D|Message-ID:=20 |In-Reply-To:=20|Accept-Language:=20en-US |Content-Language:=20en-US|X-MS-Has-Attach: |X-MS-TNEF-Correlator:|user-agent:=20Microsoft-Entourage/ 13.4.0.100208|acceptlanguage:=20en-US|Content-Type:=20tex t/plain=3B=20charset=3D"iso-8859-1" |Content-Transfer-Encoding:=20quoted-printable |MIME-Version:=201.0; bh=nCCRNAnghlA39ZZ1pmVrhAbrnIOb88YSVZJQw72QrTE=; b=GDU6VZFzqjnDa2yrRv4ASABcJg1bHt1cNhiQOY1gZaOQsOQXshwbQ599 w6ymkwlVxlFR7i2B5+aI9gXlsD84K6jTwrqBuesVgSsotdKAHY95nS/0S 8H1XduSBrkCSYIZeaoJKTFgr/Z3RoRObVaKNAf2iDkSSU51hGyCYyGRsj U=; X-IronPort-AV: E=McAfee;i="5400,1158,5971"; a="40280482" Received: from ironmsg02-r.qualcomm.com ([172.30.46.16]) by wolverine02.qualcomm.com with ESMTP; 04 May 2010 07:21:38 -0700 X-IronPort-AV: E=Sophos;i="4.52,327,1270450800"; d="scan'208";a="63198333" Received: from nasanexhub05.na.qualcomm.com ([129.46.134.219]) by ironmsg02-R.qualcomm.com with ESMTP/TLS/RC4-MD5; 04 May 2010 07:21:37 -0700 Received: from NASANEXMB03.na.qualcomm.com ([10.45.76.130]) by nasanexhub05.na.qualcomm.com ([129.46.134.219]) with mapi; Tue, 4 May 2010 07:21:20 -0700 From: "Jackson, Bruce" To: "dev@felix.apache.org" Date: Tue, 4 May 2010 07:21:30 -0700 Subject: Re: Felix compiler version & Android dx Thread-Topic: Felix compiler version & Android dx Thread-Index: AcrrhHZMPSMKg64sSdiYervVKtCG2QAEKCUD Message-ID: In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: user-agent: Microsoft-Entourage/13.4.0.100208 acceptlanguage: en-US Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Virus-Checked: Checked by ClamAV on apache.org Toni I don't think its an Apple issue. The dx tool works fine for me with no warnings as long as the source is compiled with either 1.5 or 1.6. Thanks Bruce On 04/05/2010 13:22, "Toni Menzel" wrote: > I have the same issues with all Apple SDKs (tried 5 and 6) here. > Lets hope that Google's not dissing Apple Java this way. >=20 > So far it let to not more than those warn messages produced by dx. >=20 > Toni >=20 > On Tue, May 4, 2010 at 1:54 PM, Karl Pauls wrote: >=20 >> And like before, make sure you don't have other messages like "class >> resolved by unexpected dex" in the log ... >>=20 >> regards, >>=20 >> Karl >>=20 >> On Tue, May 4, 2010 at 1:33 PM, Karl Pauls wrote: >>> Well, this should be easy enough to test, right? Just re-compile the >>> eventadmin and see whether that fixes the issue or not - if it does, >>> that would be really useful to know :-) >>>=20 >>> regards, >>>=20 >>> Karl >>>=20 >>> On Tue, May 4, 2010 at 1:23 PM, Jackson, Bruce >> wrote: >>>> Hi All >>>>=20 >>>> Some time back, we had a discussion about the default compiler version >> used to build Felix, and whether this was compatible with the requiremen= ts >> of Android. >>>>=20 >>>> I noted that when you dx the bundle jars produced by the regular Felix >> build, you get a whole collection of warning of the the form: >>>>=20 >>>> $ dx --dex --output=3Dclasses.dex org.apache.felix.eventadmin-1.2.2.ja= r >>>> warning: Ignoring InnerClasses attribute for an anonymous inner class >> that doesn't come with an associated EnclosingMethod attribute. (This cl= ass >> was probably produced by a broken compiler.) >>>>=20 >>>> ...for example. We debated this, and decided that these were just >> warning and not a real problem. However, now that I have a working Felix >> framework on Android, I find that when I load and start the EventAdmin >> bundle, I find that it fails to start with the following message in the = log: >>>>=20 >>>> 05-04 12:01:26.853: WARN/System.err(4682): >> org.osgi.framework.BundleException: Activator start error in bundle >> org.apache.felix.eventadmin [5]. >>>> 05-04 12:01:26.853: WARN/System.err(4682): at >> org.apache.felix.framework.Felix.activateBundle(Felix.java:1807) >>>> 05-04 12:01:26.853: WARN/System.err(4682): at >> org.apache.felix.framework.Felix.startBundle(Felix.java:1682) >>>> 05-04 12:01:26.853: WARN/System.err(4682): at >> org.apache.felix.framework.BundleImpl.start(BundleImpl.java:905) >>>> 05-04 12:01:26.853: WARN/System.err(4682): at >> org.apache.felix.framework.BundleImpl.start(BundleImpl.java:892) >>>> 05-04 12:01:26.853: WARN/System.err(4682): at >> com.skifta.android.client.SkiftaService.startOSGi(SkiftaService.java:437= ) >>>> 05-04 12:01:26.853: WARN/System.err(4682): at >> com.skifta.android.client.SkiftaService.init(SkiftaService.java:174) >>>> 05-04 12:01:26.853: WARN/System.err(4682): at >> com.skifta.android.client.SkiftaService.onCreate(SkiftaService.java:166) >>>> 05-04 12:01:26.853: WARN/System.err(4682): at >> android.app.ActivityThread.handleCreateService(ActivityThread.java:2894) >>>> 05-04 12:01:26.853: WARN/System.err(4682): at >> android.app.ActivityThread.access$3200(ActivityThread.java:126) >>>> 05-04 12:01:26.853: WARN/System.err(4682): at >> android.app.ActivityThread$H.handleMessage(ActivityThread.java:1986) >>>> 05-04 12:01:26.853: WARN/System.err(4682): at >> android.os.Handler.dispatchMessage(Handler.java:99) >>>> 05-04 12:01:26.853: WARN/System.err(4682): at >> android.os.Looper.loop(Looper.java:123) >>>> 05-04 12:01:26.853: WARN/System.err(4682): at >> android.app.ActivityThread.main(ActivityThread.java:4595) >>>> 05-04 12:01:26.853: WARN/System.err(4682): at >> java.lang.reflect.Method.invokeNative(Native Method) >>>> 05-04 12:01:26.853: WARN/System.err(4682): at >> java.lang.reflect.Method.invoke(Method.java:521) >>>> 05-04 12:01:26.853: WARN/System.err(4682): at >> com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.ja= va:86 >> 0) >>>> 05-04 12:01:26.853: WARN/System.err(4682): at >> com.android.internal.os.ZygoteInit.main(ZygoteInit.java:618) >>>> 05-04 12:01:26.853: WARN/System.err(4682): at >> dalvik.system.NativeStart.main(Native Method) >>>> 05-04 12:01:26.853: WARN/System.err(4682): Caused by: >> java.lang.NoClassDefFoundError: >> org.apache.felix.eventadmin.impl.handler.BlacklistingHandlerTasks$1 >>>> 05-04 12:01:26.853: WARN/System.err(4682): at >> org.apache.felix.eventadmin.impl.handler.BlacklistingHandlerTasks.= (Blac >> klistingHandlerTasks.java:223) >>>> 05-04 12:01:26.853: WARN/System.err(4682): at >> org.apache.felix.eventadmin.impl.Configuration.start(Configuration.java:= 293) >>>> 05-04 12:01:26.853: WARN/System.err(4682): at >> org.apache.felix.eventadmin.impl.Configuration.(Configuration.java= :152) >>>> 05-04 12:01:26.853: WARN/System.err(4682): at >> org.apache.felix.eventadmin.impl.Activator.start(Activator.java:65) >>>> 05-04 12:01:26.853: WARN/System.err(4682): at >> org.apache.felix.framework.util.SecureAction.startActivator(SecureAction= .java >> :661) >>>> 05-04 12:01:26.853: WARN/System.err(4682): at >> org.apache.felix.framework.Felix.activateBundle(Felix.java:1760) >>>> 05-04 12:01:26.853: WARN/System.err(4682): ... 17 more >>>>=20 >>>> Looking at the class in question (BlacklistingHandlerTasks:223) I see >> that this is a use of an anonymous inner class: >>>>=20 >>>> private final EventHandler m_nullEventHandler =3D new EventHandler() >>>> { >>>> /** >>>> * This is a null object that is supposed to do nothing at this >> point. >>>> * >>>> * @param event an event that is not used >>>> */ >>>> public void handleEvent(final Event event) >>>> { >>>> // This is a null object that is supposed to do nothing at >> this >>>> // point. This is used once a EventHandler is requested for = a >>>> // servicereference that is either stale (i.e., unregistered= ) >> or >>>> // blacklisted. >>>> } >>>> }; >>>>=20 >>>> Is this an example of the problem we were discussing a couple of weeks >> ago, where dx can=B9t produce correct copde because the compiler version= that >> was used to create the bundle was pre-1.5 do you think? >>>>=20 >>>> Thanks >>>>=20 >>>> Bruce >>>>=20 >>>=20 >>>=20 >>>=20 >>> -- >>> Karl Pauls >>> karlpauls@gmail.com >>>=20 >>=20 >>=20 >>=20 >> -- >> Karl Pauls >> karlpauls@gmail.com >>=20 >=20 >=20