Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deploy to device fails #2

Closed
raulriera opened this issue Jun 24, 2013 · 20 comments
Closed

Deploy to device fails #2

raulriera opened this issue Jun 24, 2013 · 20 comments

Comments

@raulriera
Copy link

If the module is added to a project and then deployed to the iPad (device, unsure if the problem also occurs on the iPhone)

[ERROR] :  ** BUILD FAILED **
[ERROR] :  The following build commands failed:
[ERROR] :   Ld build/Debug-iphoneos/[appname].app/[appname] normal armv7
[ERROR] :  (1 failure)

Module 1.0.1, Titanium 3.1.1

@viezel
Copy link
Owner

viezel commented Jun 25, 2013

can you show me some more build log. This error is not really possible to relate to the module.

@viezel
Copy link
Owner

viezel commented Jun 25, 2013

ios5, ios6 ?

@raulriera
Copy link
Author

iOS 6.1 (if I remove the module I can build just fine) Strangely there is no build.log on the build folder... so here is the complete output (although what I attached before was the complete error output) http://cl.ly/PqXr

@raulriera
Copy link
Author

Trying to use xcode directly to deploy gives out this error (maybe is more useful than the other one)

Image

@viezel
Copy link
Owner

viezel commented Jun 27, 2013

cheers @raulriera ill have a look at it, hopefully today :)

@viezel
Copy link
Owner

viezel commented Jun 27, 2013

hmmm... not that easy.
still working for a solution.

@raulriera
Copy link
Author

:)

@arnaudmorvan
Copy link

Hello,
I just tested the new repositorie but when I compile from the terminal I get this error:

thank you

** BUILD FAILED **
The following build commands failed:
CompileC build/nappui.build/Release-iphoneos/nappui.build/Objects-normal/armv7/JRSwizzle.o Classes/JRSwizzle.m normal armv7 objective-c com.apple.compilers.llvm.clang.1_0.compiler
CompileC build/nappui.build/Release-iphoneos/nappui.build/Objects-normal/armv7/TiUISearchBar+Extended.o Classes/TiUISearchBar+Extended.m normal armv7 objective-c com.apple.compilers.llvm.clang.1_0.compiler
CompileC build/nappui.build/Release-iphoneos/nappui.build/Objects-normal/armv7/TiUIView+TiUIWindow+Blurred.o Classes/TiUIView+TiUIWindow+Blurred.m normal armv7 objective-c com.apple.compilers.llvm.clang.1_0.compiler
CompileC build/nappui.build/Release-iphoneos/nappui.build/Objects-normal/armv7/TiUIView+Gestures.o Classes/TiUIView+Gestures.m normal armv7 objective-c com.apple.compilers.llvm.clang.1_0.compiler
CompileC build/nappui.build/Release-iphoneos/nappui.build/Objects-normal/armv7/TiUIView+Animation.o Classes/TiUIView+Animation.m normal armv7 objective-c com.apple.compilers.llvm.clang.1_0.compiler
CompileC build/nappui.build/Release-iphoneos/nappui.build/Objects-normal/armv7/TiUIView+WithShadow.o Classes/TiUIView+WithShadow.m normal armv7 objective-c com.apple.compilers.llvm.clang.1_0.compiler
(6 failures)
xcodebuild failed

@viezel
Copy link
Owner

viezel commented Jul 1, 2013

yes i know. Its not fixed. Im speaking with Appcelerator regarding this issue. I will update this ticket once it is resolved.

@arnaudmorvan
Copy link

Ok thank you, good luck :)

@viezel
Copy link
Owner

viezel commented Jul 12, 2013

Okay @raulriera.

After a long talk with Appcelerator Support, they came up with this hack:

The problem is:
Im extending some classes that are not exposed to the Module API. Like the SearchBar. So in order to get the SearchBar extended UI working, you would need to add proxies before requiring the module. This way the TiSDK have included the SearchBar to the build and the module API can now use them.
The below example shows how to expose all these proxies,

// If you remove code for any of the APIs except TiUIView (Available for module uses),
// then compile for iOS device will fail.
// Like, if i remove 
// var PickerV = Ti.UI.createPicker();
// from the below code, then build for iOS device will fail, as you have used that in your module, and xcode will report as undefined symbol for TiUIPicker.

var NappUI = require('dk.napp.ui');


var win1 = Ti.UI.createWindow({
    backgroundColor:"#FFF"
});

var win2 = Ti.UI.createWindow({
    backgroundColor:"#FFF"
});

var tb1 = Ti.UI.createTab({
    window:win1
});

var tb2 = Ti.UI.createTab({
    window:win2
});

var tabGr = Ti.UI.createTabGroup({
    tabs:[tb1,tb2]
});
var textf = Ti.UI.createTextField();

var webV = Ti.UI.createWebView();

var SBar = Ti.UI.createSearchBar();
var scroV = Ti.UI.createScrollableView();
var PickerV = Ti.UI.createPicker();

var toolBarV = Ti.UI.createToolbar();


var view = Ti.UI.createView({
    backgroundColor: '#999',
    height: 100,
    shadow: {
        shadowColor: '#000',
        shadowRadius: 10,
        shadowOffset: { x: 5, y: 5 },
        shadowOpacity: 1
    },
    top: 50,
    width: 100
});

window.add(view);



tabGr.open();

@raulriera
Copy link
Author

Wow hehe, so, I should do this for all the views or just the ones I am going to use? I have a searchBar but I don't have any custom properties on it.. I am just using the module for the gestures to be honest :)

@viezel
Copy link
Owner

viezel commented Jul 12, 2013

all..
Maybe we could create a commonJS module to reference all proxies, and null them again. Thereby, they have been created :)

@raulriera
Copy link
Author

That makes sense.

This is an alloy app, the problem is that I don't have a tab group... let's see how this behaves if I add a commonJS with the previous code in there :)

@viezel
Copy link
Owner

viezel commented Jul 12, 2013

Well if you dont add the tabgroup to anything, then nothing happens. Even though if create proxies, they are not visible. They have to be added to a window before anything will happen.
So it will work, but its a hack to get NappUI working :)

@raulriera
Copy link
Author

I embrace the hack then :) thanks!

@raulriera
Copy link
Author

This works, https://gist.github.com/raulriera/5984699 I guess I should clean up those objects afterwards.. but so far it;s back to the iPad :) thanks

@viezel
Copy link
Owner

viezel commented Jul 12, 2013

This should do it: https://gist.github.com/viezel/5984723

@viezel
Copy link
Owner

viezel commented Jul 12, 2013

I pushed it to this module: https://github.com/viezel/NappUI/blob/master/example/app.js#L3

@abangjenggot
Copy link

Hi guys,

i found this error when i try to package/distribute my ios app

[ERROR] : ** BUILD FAILED **
[ERROR] : The following build commands failed:
[ERROR] : Ld build/iVirtue.build/Release-iphoneos/iVirtue.build/Objects-normal/arm64/iVirtue normal arm64
[ERROR] : (1 failure)

do you guys have any idea what to do?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants