Very frustrating OSX Lion issues

New developer to HaXE(3-4 years AS experience) and am trying to get nme to compile for iOS. Running standard Lion with latest version of XCode 4.2. I followed the install directions for NME to the letter, and when i go to test-compile (nme test "Actuat…

Viewing 1 to 20 (23 Total)
Very frustrating OSX Lion issues

rolith

rolith
Total Posts: 2
Joined: February 29, 2012

New developer to HaXE(3-4 years AS experience) and am trying to get nme to compile for iOS. Running standard Lion with latest version of XCode 4.2. I followed the install directions for NME to the letter, and when i go to test-compile (nme test "Actuate Example.nmml" ios -simulator) it APPEARS to be working, then dies, giving the error:

error: can't exec '/usr/bin/make' (No such file or directory)

I'm pretty unfamiliar with OSX in general and again am just trying to get a simple demo haXe demo to compile to make sure I'm going to be able to compile on iOS with my haXe code.

Would appreciate any and all help. Again, not a developer newbie, but new to working on non-windows systems and brand new to haXe / NME.

Tags:
Posted on February 29, 2012 at 2:36 PM

wtsnz

wtsnz
Total Posts: 74
Joined: September 11, 2011

Re: Very frustrating OSX Lion issues

Hi Rolith,

It sounds like you are having the same problems I had when setting the HaXe NME environment up..

The latest version of Xcode (from the app store) has changed all the directories around, and NME has not been update to fix these issues yet!

To fix the make error, you need to add the new directory to your PATH variable, just execute this command in terminal:

'export PATH=$PATH:/Applications/Xcode.app/Contents/Developer/usr/bin'

Once that's done, you should be able to type 'make' into terminal and it should work. However, you still might not be able to build NME apps, one more directory change is the developer directory from '/Developer/' to the /Applications/Xcode.app/

So we need to create a symbolic link like so

'sudo ln -s /Applications/Xcode.app/Contents/Developer /Developer'

And voila! Everything *should* work!

Posted on February 29, 2012 at 3:41 PM

singmajesty

singmajesty
Total Posts: 2146
Joined: August 25, 2011

Re: Very frustrating OSX Lion issues

Would you mind checking something for me?

Apple recently moved where XCode installs its files. It is possible that it has installed to your Applications directory, and is not at /Developer like before.

We need to update NME to handle this issue automatically. In the meantime, it may be possible to create a "symlink" on your root directory at /Developer, over to the Applications folder where XCode is really installed.

Posted on February 29, 2012 at 3:42 PM

singmajesty

singmajesty
Total Posts: 2146
Joined: August 25, 2011

Re: Very frustrating OSX Lion issues

Hah! vfxguynz, you beat me to it!

Posted on February 29, 2012 at 3:43 PM

rolith

rolith
Total Posts: 2
Joined: February 29, 2012

Re: Very frustrating OSX Lion issues

that did it, thanks!

Now I'm having issues compiling to my actual iOS device... but I'm pretty sure that's apple's fault, not your guys... not sure what I'm missing or is required. The company's had an iOS developers license for a year or two but this is my first attempt to get neck deep in it, and it's a bit confusing.

Posted on February 29, 2012 at 4:30 PM

singmajesty

singmajesty
Total Posts: 2146
Joined: August 25, 2011

Re: Very frustrating OSX Lion issues

Provisioning is definitely confusing/frustrating. The last time I installed XCode, I had to nuke my certificates on the server and start all over sad

Posted on March 01, 2012 at 10:47 PM

djuniah

djuniah
Total Posts: 5
Joined: March 07, 2012

Re: Very frustrating OSX Lion issues

I'm having the same issues as rolith. I ran 'export PATH=$PATH:/Applications/Xcode.app/Contents/Developer/usr/bin' and my path var currently shows this:

$ echo $PATH
/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/X11/bin:/Applications/Xcode.app/Contents/Developer/usr/bin

So it did make it in. However, XCode is still throwing that same error. I tried restarting both XCode and the computer itself. Any idea why this is happening?

should i symlink the make command to /usr/bin?

Also, i'm running the update command from windows if that makes a difference...

tried editing project.pbxproj to point to the new address as well (the buildtoolpath= line) and that seemed to work. (I say seemed to because i ran into another issue, but it did seem to solve this specific one)

This is the error that showed up next:
"Shell Script Invocation Error" Unknown Identifier

the code was from ApplicationMain.hx and was at the line that said this:
nme.Lib.create(function()
{
Main.main()
}

I thought maybe it had something to do with how my project had been set up, so i tried the demo example from this page:http://www.joshuagranick.com/blog/2011/07/14/android-ios-webos-and-...
but that also failed. Any idea why that might be?

EDIT: ok i think i got that solved as well. I was running the "nme update" line from that demo. Instead, i tried nme test ".nmml" ios -simulator and that seems to compile now (albeit with a few warnings). I'm updating the simulator now to give it a test.

Posted on March 08, 2012 at 12:56 PM

Huge

Huge
Total Posts: 548
Joined: October 07, 2011

Re: Very frustrating OSX Lion issues

Hi,
I think the correct fix for this is to install the "optional command-line utilities" from the setting panel.

Hugh

Posted on March 08, 2012 at 7:03 PM

tonypee

tonypee
Total Posts: 33
Joined: March 11, 2012

Re: Very frustrating OSX Lion issues

Im having serious issues with xcode 4.3 too - ive got around the initial issue of it not finding g++ via editing the build-tool/iphoneos-toolchain.xml - to point not at /Developer/

llvm-g++-4.2: error trying to exec '/Applications/Xcode.app/Contents/Developer/usr/bin/../llvm-gcc-4.2/bin/arm-apple-darwin11-llvm-g++-4.2': execvp: No such file or directory

it seems like arm-... doesnt exist - it must be depreciated ? should i have to install something else, or change my compiler settings - im trying to get the pirate pig example to build

cheers

Posted on March 11, 2012 at 1:41 AM

Huge

Huge
Total Posts: 548
Joined: October 07, 2011

Re: Very frustrating OSX Lion issues

Hi,
The svn version of HXCPP should have this developer/xcode fix for macos - I'm currently looking into ios.
Did you install the additional command-line tools?
XCode > Preferences > Downloads > Components > command line tools.

Hugh

Posted on March 11, 2012 at 10:33 AM

tonypee

tonypee
Total Posts: 33
Joined: March 11, 2012

Re: Very frustrating OSX Lion issues

yeah - ive already done that, but unfortunately it didnt fix things.

ive done
$ sudo xcode-select -switch /Applications/Xcode.app/Contents/Developer

and edited the
<compiler id="iPhoneSim" exe="/Applications/Xcode.app/Contents/Developer/usr/bin/g++" if="iphonesim">

(and for ios)

running nme test ... ios :

Creating hxcpp.h.gch...
/Applications/Xcode.app/Contents/Developer/usr/bin/g++ -Iinclude -c -O2 -arch armv7 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS4.2.sdk -fvisibility=hidden -fno-stack-protector -DIPHONE -DIPHONEOS -DSTATIC_LINK -I/usr/lib/haxe/lib/hxcpp/2,08,1//include -fvisibility-inlines-hidden -frtti -o hxcpp.h.gch /usr/lib/haxe/lib/hxcpp/2,08,1//include/hxcpp.h
llvm-g++-4.2: error trying to exec '/Applications/Xcode.app/Contents/Developer/usr/bin/../llvm-gcc-4.2/bin/arm-apple-darwin11-llvm-g++-4.2': execvp: No such file or directory
Called from ? line 1
Called from BuildTool.hx line 1152
Called from BuildTool.hx line 501
Called from a C function
Called from BuildTool.hx line 538
Called from BuildTool.hx line 657
Called from BuildTool.hx line 685
Called from BuildTool.hx line 153
Uncaught exception - Error creating pch: 65280 - build cancelled
if ( !(cmp -s build/Release-iphoneos/ApplicationMain.iphoneos.a ../lib/ApplicationMain.a) ); then echo "Copy library..."; cp build/Release-iphoneos/ApplicationMain.iphoneos.a ../lib/ApplicationMain.a; fi
Copy library...
cp: build/Release-iphoneos/ApplicationMain.iphoneos.a: No such file or directory
make: *** [build-haxe] Error 1
.

** BUILD FAILED **


I had things compiling fine yesterday with ios-sim, etc. but i xcode couldnt connect to my phone, as it had a newer OS - so i have updated to the latest lion + xcode 4.3.1 and now get this. are you on the latest version?

thanks Hugh

Posted on March 11, 2012 at 7:19 PM

tonypee

tonypee
Total Posts: 33
Joined: March 11, 2012

Re: Very frustrating OSX Lion issues

basically 'arm-apple-darwin11-llvm-g++-4.2' doesnt exist.

when searching for this people say that it isnt supported? only i686 currently. hmm

Posted on March 11, 2012 at 7:21 PM

Huge

Huge
Total Posts: 548
Joined: October 07, 2011

Re: Very frustrating OSX Lion issues

Hi,
I notice your sysroot still has 4.2 in it - maybe you need 5.x?

Hugh

Posted on March 11, 2012 at 9:34 PM

tonypee

tonypee
Total Posts: 33
Joined: March 11, 2012

Re: Very frustrating OSX Lion issues

Okay i've updated that in the Build-common.xml - to 5.1, and it doesnt do anything.


Creating hxcpp.h.gch...
/Applications/Xcode.app/Contents/Developer/usr/bin/g++ -Iinclude -c -O2 -arch armv7 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS5.1.sdk -fvisibility=hidden -fno-stack-protector -DIPHONE -DIPHONEOS -DSTATIC_LINK -I/usr/lib/haxe/lib/hxcpp/2,08,1//include -fvisibility-inlines-hidden -frtti -o hxcpp.h.gch /usr/lib/haxe/lib/hxcpp/2,08,1//include/hxcpp.h
llvm-g++-4.2: error trying to exec '/Applications/Xcode.app/Contents/Developer/usr/bin/../llvm-gcc-4.2/bin/arm-apple-darwin11-llvm-g++-4.2': execvp: No such file or directory


Can anyone confirm that things work with xcode 4.3.1 ? - because i might have to reinstall. It seems weird, since i had it compiling (earlier xcode). maybe there are old settings from the other version kicking around.

Posted on March 11, 2012 at 11:54 PM

Huge

Huge
Total Posts: 548
Joined: October 07, 2011

Re: Very frustrating OSX Lion issues

Hi,
Also, maybe you only need the xcode part:

sudo xcode-select -switch /Applications/Xcode.app

Hugh

Posted on March 12, 2012 at 12:05 AM

tonypee

tonypee
Total Posts: 33
Joined: March 11, 2012

Re: Very frustrating OSX Lion issues

Nope- didn't help. Hmm

Posted on March 12, 2012 at 3:04 AM

Huge

Huge
Total Posts: 548
Joined: October 07, 2011

Re: Very frustrating OSX Lion issues

Hi,
Are you building iphone builds from the command-line? I have been doing the iphone builds from xode, and the desktop builds from the command line.

Hugh

Posted on March 12, 2012 at 7:55 AM

tonypee

tonypee
Total Posts: 33
Joined: March 11, 2012

Re: Very frustrating OSX Lion issues

I have been doing both i think.

i ran 'nme build xxxx ios' from the commandline, which created the initial 'Export', this worked fine before i updated xcode. Then having the xcode project open i was compiling. Then i updated xcode, and it wouldnt compile from the IDE. I deleted the export folder, then recompiled from the commandline. I get all of the project generated, but the issues are as listed. In xcode the issues are the same. should i try deleting EVERTHING.. and starting again - are you on 4.3.1?

Posted on March 12, 2012 at 8:21 AM

djuniah

djuniah
Total Posts: 5
Joined: March 07, 2012

Re: Very frustrating OSX Lion issues

I had a similar "file not found" error with a ".a" file and i was able to get around it.

First, i'll describe my setup:
Box 1) Windows 7 developement box. All code is written here, and i run the HaXe command that generates the cpp code on this box. The output folder for the iOS code is shared over the network.
Box 2) OSX Lion box. This box mounts the previously mentioned network share and tries to build from there.

That setup caused issues. I tried to copy the output folder locally before compiling and that seemed to help. It looks like some part of the build process didnt like the fact that it was operating over a network share. I'm still not 100% sure on this info, but i believe that was the cause of my issue with the missing .a file.

Posted on March 13, 2012 at 2:52 PM

Huge

Huge
Total Posts: 548
Joined: October 07, 2011

Re: Very frustrating OSX Lion issues

Hi,
I have just updated HXCPP and NME on SVN with new project stuff for ios.
This should allow fat binaries/deplyment versions and a few other minor tweaks - I had it all working on latest OSX with latest xcode.
See if you have any problems with the new setup.

Hugh

Posted on March 13, 2012 at 8:19 PM
« Previous12Next »