重复条目:自定义 Android 模块中的 org/appcelerator/titanium/gen/bindings.json [英] Duplicate entry: org/appcelerator/titanium/gen/bindings.json in custom Android module
问题描述
设置/问题
我为 Titanium 创建了一个自定义 Android 模块,用于在 Ti 中显示 Gif 动画.模块源代码可以在这里找到:
我的两个模块在/gen 文件夹中都有一个 bindings.json 文件,其中包含与 bindings/gifview.json 相同的信息.因此,如果我在一个模块中手动删除它,我可以同时使用两个模块(因为现在只有一个 bindings.json).
问题
我如何建议编译器不要创建此文件或更改名称?当我用 ant
编译模块时,我在输出中看到:
编译:[javac] 编译3个源文件到/home/miga/dev/ti.gif/android/build/classes[javac] 警告:[options] 引导类路径未与 -source 1.6 一起设置[javac] 注意:[KrollBindingGen] 运行 Kroll 绑定生成器.[javac] 注:[KrollBindingGen] 成功加载现有绑定数据:/home/miga/dev/ti.gif/android/build/classes/org/appcelerator/titanium/gen/bindings.json[javac] 注:[KrollBindingGen] 找到代理 GifView 的绑定[javac] 注意:[KrollBindingGen] 找到模块 Tigifview 的绑定[javac] 注:[KrollBindingGen] 生成 JSON:文件:/home/miga/dev/ti.gif/android/build/classes/org/appcelerator/titanium/gen/bindings.json[复制] 将 1 个文件复制到/home/miga/dev/ti.gif/android/build/classes
它正在创建 bindings.json
我的尝试
添加
org.eclipse.jdt.apt.processorOptions/kroll.jsonFile=migagifview.json
我的设置
- javac -version:javac 1.8.0_91
- CLI 版本 5.0.6
- Titanium SDK 版本 5.2.2.GA
- Android-23
这是一个已确认的错误,已在 6.1.0 中修复
问题详情:https://jira.appcelerator.org/browse/TIMOB-23502
Setup / Problem
I've create a custom Android module for Titanium to display Gif animations inside Ti. The module source code can be found here: https://github.com/m1ga/com.miga.gifview
The actual module is working fine but when I use it with a second module (with the same problem) I receive the following error:
java.util.zip.ZipException: duplicate entry: org/appcelerator/titanium/gen/bindings.json
The problem is inside the gifimageview.jar file:
My two modules each have a bindings.json file inside the /gen folder that contains the same information as the bindings/gifview.json. So if I remove it manually in one module I can use both modules (because there is only one bindings.json now).
Question
How can I advise the compiler not to create this file or change the name? When I compile the module with ant
I see this in the output:
compile:
[javac] Compiling 3 source files to /home/miga/dev/ti.gif/android/build/classes
[javac] warning: [options] bootstrap class path not set in conjunction with -source 1.6
[javac] Note: [KrollBindingGen] Running Kroll binding generator.
[javac] Note: [KrollBindingGen] Succesfully loaded existing binding data: /home/miga/dev/ti.gif/android/build/classes/org/appcelerator/titanium/gen/bindings.json
[javac] Note: [KrollBindingGen] Found binding for proxy GifView
[javac] Note: [KrollBindingGen] Found binding for module Tigifview
[javac] Note: [KrollBindingGen] Generating JSON: file:/home/miga/dev/ti.gif/android/build/classes/org/appcelerator/titanium/gen/bindings.json
[copy] Copying 1 file to /home/miga/dev/ti.gif/android/build/classes
There it is creating the bindings.json
What I've tried
Adding
org.eclipse.jdt.apt.processorOptions/kroll.jsonFile=migagifview.json
to the settings file: https://github.com/m1ga/com.miga.gifview/blob/master/android/.settings/org.eclipse.jdt.apt.core.prefs didn't work
My setup
- javac -version: javac 1.8.0_91
- CLI version 5.0.6
- Titanium SDK version 5.2.2.GA
- Android-23
This was a confirmed bug and is fixed in 6.1.0
Issue details: https://jira.appcelerator.org/browse/TIMOB-23502
这篇关于重复条目:自定义 Android 模块中的 org/appcelerator/titanium/gen/bindings.json的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!