Return-Path: X-Original-To: apmail-cordova-dev-archive@www.apache.org Delivered-To: apmail-cordova-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 59C54EC44 for ; Mon, 25 Feb 2013 18:02:20 +0000 (UTC) Received: (qmail 66464 invoked by uid 500); 25 Feb 2013 18:02:20 -0000 Delivered-To: apmail-cordova-dev-archive@cordova.apache.org Received: (qmail 66434 invoked by uid 500); 25 Feb 2013 18:02:20 -0000 Mailing-List: contact dev-help@cordova.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cordova.apache.org Delivered-To: mailing list dev@cordova.apache.org Received: (qmail 66425 invoked by uid 99); 25 Feb 2013 18:02:20 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 25 Feb 2013 18:02:20 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of mmocny@google.com designates 209.85.214.42 as permitted sender) Received: from [209.85.214.42] (HELO mail-bk0-f42.google.com) (209.85.214.42) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 25 Feb 2013 18:02:15 +0000 Received: by mail-bk0-f42.google.com with SMTP id jk7so1421083bkc.15 for ; Mon, 25 Feb 2013 10:01:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:x-received:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:content-type; bh=2XtzFpvDpKZQXj7E4pbyr5d0uMH+DYJYieos+GsKXlo=; b=Dh0n6Jn6DxwPen4ckYH0A4J1jAhZgLy7OJPkGNTVMP5ygcTpqUEVWG9R/ArTD48Rj8 h3K7xrR9Jh/py+ZtXg6VYLga9mhWjzLQfVfdhyKopdHhnRQ1W5Z7lUAcrfsxv9T9mkhR 64MuN8okkpv2E4sNTTxb6Qno1pAV/Apq9Vmec7uPOWdlDKf/iQIS4lsqRxeH4LDZgt35 QMLfV4z4c7ldSeqovasXn7FT61rZ9WFBp8n/+bG2ysRIev9G4/RvztGAZDDv1ayRZckz ZPia7m1La79A+Ej7P0GdWz18lagbkqj5i+WjcM49a3iPyYXk6ifZiqEhl78cLp9qhPDF b1Ww== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=mime-version:x-received:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:content-type; bh=2XtzFpvDpKZQXj7E4pbyr5d0uMH+DYJYieos+GsKXlo=; b=VTl+eObfq83PGCCGTjYj+YO1KSmOh/ilXJ/lE+rZ+0tyMm+SVJCVrPgJHr/8RV/FTX FQWtPeSo3hCFlc9dTd/Xh+odfAO6RJ4ntu/Y9Sqb4hqk4wu0IhACGcTAadO6ijOtRKU5 ZpaTxyhG7Guk89lqrzWUEcqHfUSU9UjPzsghU= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:x-received:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:content-type :x-gm-message-state; bh=2XtzFpvDpKZQXj7E4pbyr5d0uMH+DYJYieos+GsKXlo=; b=V/aemoO/PZPJ/gc0disHObr2F7JlulpgjOZbLhXNfgXbCLMWIJeUBNAhRBSpTzjloB gFxlKrXVY9912His4cb75QdlobF9/38v+s2rzD6D9dZE7p36EiwIW/c9QjL/NXmH8vJd +ZT3X0JeCo9b60P9ExztYDs9uRwH9Jb0EcS1YyEBBGUdugZDdt7UPof9gEKVrZLH65tT tYbjPA+mmiOf/rpKz+c2wWn0o5u2BBfCszGHCUz9fSI3xIOCXDwWg2Y3Lu8E9qrBFn0J 4MRdATBSOznhiiyl8bAtxWVlTfLlzqyck0LC05SCwtm7nK64l4xsLkiHVfVslSC/byLM IY2w== MIME-Version: 1.0 X-Received: by 10.204.129.70 with SMTP id n6mr5437013bks.60.1361815313657; Mon, 25 Feb 2013 10:01:53 -0800 (PST) Sender: mmocny@google.com Received: by 10.205.9.5 with HTTP; Mon, 25 Feb 2013 10:01:53 -0800 (PST) In-Reply-To: References: <232E544B-C1DA-4E67-BA3C-632DED530398@gmail.com> Date: Mon, 25 Feb 2013 13:01:53 -0500 X-Google-Sender-Auth: Gqx1a1W48QOYTsbt1yXNSR3EUjg Message-ID: Subject: Re: [plugins] Static or Dynamic Libraries From: Michal Mocny To: dev Content-Type: multipart/alternative; boundary=0015174488a205808304d69056d5 X-Gm-Message-State: ALoCoQn6szXrp+8T/Rl6iSymTrmq06cMnFOOn2QNQ3aqZCSA7MvlsYBaLnZjIZe6KjpM2eeh4KQSNpItoSguYSGpjcfWDdtNGBiK2/w/Nd69mxWtDCFvVUguUten8SLXWzb4v8+MDS304qtlHpiFp/jg0mFr0bcVZpSGTzkdDz5Tq1rZbR4beAEjhHm70851Kt4j+wq2/Bqj X-Virus-Checked: Checked by ClamAV on apache.org --0015174488a205808304d69056d5 Content-Type: text/plain; charset=ISO-8859-1 The original proposal said that pre-compiled "Can be an alternative (not replacement) to distributing plugins as source-code." so I don't think the original intent was for selling plugins. Thats not to say that that isn't useful, but my understanding is that end goal of this particular thread is attaining app developer simplicity. On Mon, Feb 25, 2013 at 12:49 PM, Andrew Grieve wrote: > On Mon, Feb 25, 2013 at 9:11 AM, Braden Shepherdson >wrote: > > > I'm working on our prototype for automatic installation of Javascript > from > > plugins in cordova-cli. We already have installation for native code and > > non-JS www assets. I don't see anything to be gained from precompiled > > libraries, since a user of Cordova already has the device SDK in place > and > > is using either our scripts (cordova build, bin/emulate, etc.) or > > Eclipse/Xcode/etc. to build the deployable application. > > > > Switching to libraries loses us transparency for bugfixes ("make this > > change in some/plugin/File.java and see if that fixes your bug") and > error > > messages, and it's not like we've got closed-source products we want to > > make sure people can't read. > > > > Yep, this is certainly a trade-off with this approach. I don't think we're > suggesting moving any of the core plugins to be pre-compiled, but just that > this will enable people to sell plugins without giving away their source > code. > > > > > > Braden > > > > > > On Sat, Feb 23, 2013 at 10:07 PM, Simon MacDonald < > > simon.macdonald@gmail.com > > > wrote: > > > > > The other issue with jars on Android is they will be unable to refer to > > > anything in the res folder. That's basically why Android library > projects > > > exist as conventional jars just don't cut it. Luckily since most > Cordova > > > plugins will do their UI in HTML the likelihood of the plugin needing > to > > > access the res folder is very low. > > > > > > > > > Simon Mac Donald > > > http://hi.im/simonmacdonald > > > > > > > > > On Fri, Feb 22, 2013 at 7:33 PM, Michael Brooks < > > michael@michaelbrooks.ca > > > >wrote: > > > > > > > Sweet, thanks for the Android input Joe! > > > > > > > > It's awesome to see such detailed responses for Android, BlackBerry, > > iOS, > > > > and Windows! > > > > > > > > I suppose we can proceed as Marcel suggestion? Create JIRA issue, > link > > to > > > > this thread, but keep our vision forward by finishing source-code > > > > distributed plugins. > > > > > > > > Michael > > > > > > > > On Fri, Feb 22, 2013 at 4:23 PM, Joe Bowser > wrote: > > > > > > > > > Hey > > > > > > > > > > I'm definitely a fan of pre-compiled libraries for plugins. The > main > > > > > reason I like JARs instead of Java files is because of the > following: > > > > > > > > > > * Cleaner projects > > > > > * Installation is extremely easy for non-Activity plugins (drop in > > the > > > > > libs directory) > > > > > > > > > > The downsides on Android: > > > > > > > > > > * You can't verify a JAR - Have to trust that the JAR isn't > sketchy, > > > > > signatures can mitigate this, but not eliminate it > > > > > * JARs can't transport assets, assets would have to be transported > > > > > separately > > > > > > > > > > Overall, if you sign the JARs and allow for a mechanism for our > users > > > > > to check the signature of the JAR, I'm cool with this approach. We > > > > > should remember that our users aren't the type of people who will > > > > > check a Java file to make sure the plugin does what it says it > does, > > > > > and it would be nice to be able to have a tool to give them some > > > > > assurance that the plugin does only what they think it does. > > > > > > > > > > Joe > > > > > > > > > > > > > > > On Fri, Feb 22, 2013 at 1:30 PM, Michael Brooks > > > > > wrote: > > > > > > Great responses everyone. We've now got a decent overall of the > iOS > > > and > > > > > WP > > > > > > landscape, not to mention use-cases of other projects such Google > > > Maps. > > > > > > > > > > > > tl;dr: IMHO, those three things listed above is where we should > put > > > our > > > > > >> effort to make plugins easier, then see where that gets us. I > > think > > > it > > > > > will > > > > > >> drive us the furthest forward. Then go back an reevaluate > whether > > or > > > > > not to > > > > > >> provide precompiled libs to see if it truly makes life easier > for > > > the > > > > > user, > > > > > >> or if it complicates life for the user. > > > > > > > > > > > > > > > > > > Marcel, this is the feedback that I was hoping to see! Thanks a > > bunch > > > > for > > > > > > the analysis. > > > > > > > > > > > > The project is always driven by what gives ours users the most > > value. > > > > So, > > > > > > it makes sense to not lose sight of our goal - offering plugins > to > > > > users. > > > > > > If the first phase is source-code only, then so be it. > > > > > > > > > > > > The intention of packaging plugins as libraries is entirely > around > > > > making > > > > > > the users' life less painful. I was reminded of this problem last > > > > night, > > > > > > when I had to compile a 2 year old OS X library because the > > developer > > > > did > > > > > > not publish the .framework. Unsurprisingly, it failed to build > > > because > > > > > > Xcode no longer bundles the necessary libraries. Similarly, if I > > > needed > > > > > to > > > > > > a use a JPG or MP3 library, I would not want to include the > source > > > code > > > > > in > > > > > > my project simply because it takes too long to compile (assume it > > > does > > > > > > compile). > > > > > > > > > > > > Michael > > > > > > > > > > > > On Fri, Feb 22, 2013 at 12:38 PM, Marcel Kinard < > > cmarcelk@gmail.com> > > > > > wrote: > > > > > > > > > > > >> So if I back up for a moment and look at the bigger picture, it > > > looks > > > > > like > > > > > >> what you are going for is to make it easier for Cordova users to > > > pick > > > > up > > > > > >> plugins, either base ones or third-party ones. There are many > ways > > > to > > > > do > > > > > >> that, providing precompiled code is one way. > > > > > >> > > > > > >> If I were to step into the shoes of a relatively new Cordova > user > > > who > > > > > >> wanted to pick up a plugin for my app, I don't think the > > compilation > > > > is > > > > > >> difficult enough to warrant some workaround such as providing > > > > > libraries. My > > > > > >> [admitedly, limited] understanding is that as a Cordova user I > > > always > > > > > need > > > > > >> to use the device SDK to build my app. Therefore the compiler is > > > right > > > > > >> there and it's not difficult to invoke (i.e., iOS always needs > > > > > compilation). > > > > > >> > > > > > >> While still in the shoes of that Cordova user, what appears to > be > > > more > > > > > >> challenging in that role is figuring out what files are needed, > > > where > > > > to > > > > > >> put them, and what to edit (i.e., config.xml). Basically, > getting > > > the > > > > > >> environment and content setup for the SDK to run against. After > > > that, > > > > > >> running the SDK/compiler is easy. So for this difficulty, the > > kinds > > > of > > > > > >> helps could include: > > > > > >> - docs: overall on how to install/remove plugins, and > > > plugin-specific > > > > > docs > > > > > >> on their specific requirements/quirks > > > > > >> - tooling: a CLI (i.e., plugman) that could make it as easy as > npm > > > > > >> - verification: help me as a user understand if the plugin is in > > > there > > > > > >> correctly, (i.e., smoke test or something like 'rpm -V') > > > > > >> > > > > > >> tl;dr: IMHO, those three things listed above is where we should > > put > > > > our > > > > > >> effort to make plugins easier, then see where that gets us. I > > think > > > it > > > > > will > > > > > >> drive us the furthest forward. Then go back an reevaluate > whether > > or > > > > > not to > > > > > >> provide precompiled libs to see if it truly makes life easier > for > > > the > > > > > user, > > > > > >> or if it complicates life for the user. > > > > > >> > > > > > >> The library idea is neat, it ought be captured in Jira while > these > > > > other > > > > > >> things are worked on first. > > > > > >> > > > > > >> -- Marcel Kinard > > > > > > > > > > > > > > > --0015174488a205808304d69056d5--