Has anyone had any luck implementing the tibar for iphone and mwaysolutions.barcode for android into one single app.js?
As of right now in my app.js I am checking if the device is an android phone then I require('com.mwaysolutions.barcode') otherwise if it's an iPhone I require('tibar'). So far this seems to work on the android emulator but not on the iPhone emulator. I receive this error when building for iPhone:
Third-party module: com.mwaysolutions.barcode/0.2 missing library at /Library/Application Support/Titanium/modules/android/com.mwaysolutions.barcode/0.2/libcom.mwaysolutions.barcode.a [ERROR] Error: Traceback (most recent call last): File "/Library/Application Support/Titanium/mobilesdk/osx/1.7.1/iphone/builder.py", line 638, in main sys.exit(1) SystemExit: 1'Thanks for any help.
While I have not made an application using the two specific modules you name, I can tell you what I believe will solve your problem. In your tiapp.xml file, for each <module ...> tag add the platform attribute, something like:
<module platform="iphone" version="0.4.2">tibar</module> <module platform="android" version="0.2">com.mwaysolutions.barcode</module>This should limit which platforms look for the presence of the module at compile time. You still should have your app.js code perform the checks it does now as well.
Awesome. Thanks. I was just facing the same issue.
Think you can help? Login to answer this question!