cordova-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Pat Deegan (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (CB-11338) Plugin javascript resources not copied over to platform for ubuntu
Date Wed, 01 Jun 2016 18:19:59 GMT

     [ https://issues.apache.org/jira/browse/CB-11338?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Pat Deegan updated CB-11338:
----------------------------
    Component/s: Ubuntu

> Plugin javascript resources not copied over to platform for ubuntu
> ------------------------------------------------------------------
>
>                 Key: CB-11338
>                 URL: https://issues.apache.org/jira/browse/CB-11338
>             Project: Apache Cordova
>          Issue Type: Bug
>          Components: CLI, Ubuntu
>         Environment: Ubuntu 15.10
> Current env (though only recently updated in hopes of resolving issue, which was present
with prior versions of cordova/nodejs):
> $ cordova -v
> 6.1.1
> $ nodejs -v
> v6.2.0
>            Reporter: Pat Deegan
>              Labels: copy, javascript, plugins, ubuntu
>
> Plugin javascript files, including cordova_plugins.js and contents of plugins/ directory,
fail to be included in builds for ubuntu.  The issue has been found using a host of different
plugins (with notional ubuntu support), and will be demonstrated here using the cordova-plugin-device.
> Note: the same plugins do work without issue in Android builds, and the problem may be
solved with a simple manual copy, as demonstrated below.
> To replicate failure:
> =================================================
> cordova create plugintest com.example.plugintest plugintest
> cd plugintest/
> cordova plugins add cordova-plugin-device   --save
> cordova platform add ubuntu
> cordova prepare ubuntu
> cordova run ubuntu --verbose --debug 
> =================================================
> Using chromium to inspect console output and variables (entries preceded by ">" are
my input to the console):
> =================================================
> Failed to load resource: net::ERR_FILE_NOT_FOUND  
> file:///tmp/plugintest/platforms/ubuntu/native/prefix/www/cordova_plugins.js 
> Received Event: deviceready
> > device
> VM67:1 Uncaught ReferenceError: device is not defined(...)
> =================================================
> To fix:
> =================================================
> cp ./platforms/ubuntu/platform_www/cordova_plugins.js ./platforms/ubuntu/native/prefix/www/
> cp -R ./platforms/ubuntu/platform_www/plugins/ ./platforms/ubuntu/native/prefix/www/
> cordova run ubuntu --verbose --debug --nobuild
> =================================================
> (The --nobuild option is important, otherwise the copied files are destroyed).  At this
stage, connecting to the console shows no net::ERR_FILE_NOT_FOUND and the "device" from the
plugin is present
> =================================================
> adding proxy for Device
> Received Event: deviceready
> > device
> Device {available: true, platform: "Linux", version: "15.10", uuid: "{95eabc1234-d601-7563-d35b-abc1234}",
...}
> > device.cordova
> "4.3.2"
> =================================================
> I'm not certain whether the fix would allow building of deb packages, but is sufficient
for "cordova run" commands to work correctly.
> I'd appreciate any info concerning anything I may be missing/doing wrong and/or more
permanent/automated fixes.
> Thanks,
> PatD



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org


Mime
View raw message