Mac issue

33 views
Skip to first unread message

Igor Korot

unread,
Oct 5, 2012, 6:23:12 PM10/5/12
to wx-u...@googlegroups.com
Hi, ALL,
I have a problem, that hopefully some very experienced MAC developer
will help me
solve.

I developed a program for both Windows and Mac using Visual Studio and XCode.
On Windows there is no problem, however there is a problem on Mac.

At home I have Snow Leopard with XCode 3.2 which comes alone with the
Snow Leopard
installation disk. It is XCode 3.2.

I buuilt wxWidgets from Terminal and successfully built my program from XCode.

My client has Mac OS 10.6 (which I think is Snow Leopard as well) and XCode 4.2.
I remotely connected to that machine, successfully built wxWidgets
(same version) from
terminal, but I got a lot of errors trying to build my project. I got
about 200 compile errors.

Developer on the other side suggested to install XCode 4.2 on my home machine
and try to build the program and then send the project over. He showed
me that even
though Apple Store says "XCode 4.2 for Lion" he don't have Lion and
has XCode 4.2.

Now, my questions are:
1. Will it be possible to get XCode 4.2 for Snow Leopard? If yes, where?
2. If it is not possible (anymore?), what do I do? People on the other
side wants to
build the project locally.

Any suggestions?

Thank you.

Gadget/Steve

unread,
Oct 6, 2012, 3:04:27 AM10/6/12
to wx-u...@googlegroups.com
Not as a mac developer but as a developer on a lot of differing machines
I have a couple of things that you could consider:
1/ If you can get XCode 4.2 for your machine and it still gives the
errors then you can fix them and then deliver the source code,
2/ That many errors suggest a missing file in the source that you
installed or possibly a missing flag if you have conditionally
compilation in your files, (i.e. #ifdef ), these possibilities should be
investigated.
3/ Fix ALL the warnings in your code, preferably with the warnings
turned up to maximum - a warning on one compiler is sometimes an error
on another.
4/ Try building your code with gcc with the flags -Wall -Werror
-std=ANSI and FIX any errors/warnings - if your code is well behaved
ANSI code it should run just about anywhere.
N.B. Fix in both the above doesn't mean turning off the error, using any
#ifdef __ANSI__ / __VISUAL_C__ etc it means actually resolving the
issue(s) that cause the error/warning.
5/ Get a copy of Lint and run it on your code, other than the naming
convention messages just about everything that it will point out will be
either a potential bug/portability issue, etc., so ideally you resolve
all of them.

In general any ANSI compliant, clean code should run on just about anything.

Sorry that this is so general rather than Mac specific but it may help.

Gadget/Steve

Hector

unread,
Oct 6, 2012, 2:40:00 PM10/6/12
to wx-u...@googlegroups.com
XCode 4.2 is the last version of XCode that worked with Snow Leopard.

It's possible to find it by logging into your developper account and searching for "XCode 4.2".

Hector

unread,
Oct 6, 2012, 2:45:17 PM10/6/12
to wx-u...@googlegroups.com
You'll need to be inside the "Downloads for Apple Developers" section when you'll search for "XCode 4.2". You can easily reach that section by following the link to the latest version of XCode.

Dion Whittaker

unread,
Oct 6, 2012, 4:27:22 AM10/6/12
to wx-u...@googlegroups.com
XCode 4.2 is still available on the Apple developer site
https://developer.apple.com/ in the download section.

You will need a free apple developer ID in order to access the
downloads. Go to the member center, Mac Dev Center and view all
downloads. Various versions of XCode are available if you go back a
couple of pages. (You don't need the paid membership to access the
downloads).

If you have build issues one of the places to look might be which
version of the SDK is being used. Each version of Xcode defaults to
using the latest SDK.

Hope this helps.
Dion

Igor Korot

unread,
Oct 9, 2012, 4:10:53 PM10/9/12
to wx-u...@googlegroups.com
I grabbed the XCode 4.2 and successfully installed.

Now I'm having trouble building an executable.
Everything compiles fine with gcc-4.2 but for some unknown reason link
phase fails.
Looking at the link command I see it uses "-arch i386" instead of
"-arch x86_64".

Do you know how to properly add the build architecture to XCode?

I can probably build everything in the terminal but then I will need
to make a bundle...

Thank you.
> --
> Please read http://www.wxwidgets.org/support/mlhowto.htm before posting.
>
> To unsubscribe, send email to wx-users+u...@googlegroups.com
> or visit http://groups.google.com/group/wx-users
Reply all
Reply to author
Forward
0 new messages