Skip to content

Commit

Permalink
Snow Leopard: Force use of gcc 4.0
Browse files Browse the repository at this point in the history
To still support building a MacOS 10.4 (Tiger) target on a
Snow Leopard development host, we must make sure that we use
the gcc-4.0 compiler and not the default gcc 4.2 compiler.
(I have no way to test Wings on either Tiger or PPC Macs.)

It is probably still possible to build on 10.5 (Leopard) host,
but I have not tested that.

NOTE: This release for Mac OS X has been built with Snow
Leopard (10.6) as the host OS. It is still supposed to work on
Tiger (10.4) with either PPC or Intel CPUs, but I have no way to
actually test that. [bjorng]
  • Loading branch information
bjorng committed Sep 25, 2009
1 parent b2ad4d5 commit 1572c06
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 9 deletions.
5 changes: 3 additions & 2 deletions BUILD.unix
Original file line number Diff line number Diff line change
Expand Up @@ -192,8 +192,9 @@ Building an installation package for MacOS X

To build everything and pack it into a DMG file, you'll need:

- Xcode 3.0. Older versions may work, but I haven't tested them
with modern versions of Wings.
- Xcode 3.2 (running on Snow Leopard). Xcode 3.x running on Leopard will
probably also work, but I have not tested to build any Wings version after
1.1.12 with that configuration.

- The FBX library. http://www.autodesk.com/fbx

Expand Down
11 changes: 6 additions & 5 deletions macosx/Wings3d.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
archiveVersion = 1;
classes = {
};
objectVersion = 42;
objectVersion = 44;
objects = {

/* Begin PBXBuildFile section */
Expand Down Expand Up @@ -163,7 +163,7 @@
29B97313FDCFA39411CA2CEA /* Project object */ = {
isa = PBXProject;
buildConfigurationList = 4CA8398B085C2B4300C48A7F /* Build configuration list for PBXProject "Wings3d" */;
compatibilityVersion = "Xcode 2.4";
compatibilityVersion = "Xcode 3.0";
hasScannedForEncodings = 1;
mainGroup = 29B97314FDCFA39411CA2CEA /* Wings3d */;
projectDirPath = "";
Expand Down Expand Up @@ -356,7 +356,7 @@
isa = XCBuildConfiguration;
buildSettings = {
MACOSX_DEPLOYMENT_TARGET = 10.4;
SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk;
SDKROOT = "$(DEVELOPER_SDK_DIR)/MacOSX10.4u.sdk";
};
name = Debug;
};
Expand All @@ -368,7 +368,7 @@
i386,
);
MACOSX_DEPLOYMENT_TARGET = 10.4;
SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk;
SDKROOT = "$(DEVELOPER_SDK_DIR)/MacOSX10.4u.sdk";
};
name = Release;
};
Expand All @@ -379,8 +379,9 @@
ppc,
i386,
);
GCC_VERSION = 4.0;
MACOSX_DEPLOYMENT_TARGET = 10.4;
SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk;
SDKROOT = "$(DEVELOPER_SDK_DIR)/MacOSX10.4u.sdk";
};
name = Default;
};
Expand Down
5 changes: 3 additions & 2 deletions plugins_src/mac_file/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ WINGS_EBIN = ../../ebin
WINGS_INTL=../../intl_tools
UNIVERSAL_FLAGS = -isysroot /Developer/SDKs/MacOSX10.4u.sdk -arch i386 -arch ppc
CFLAGS = $(UNIVERSAL_FLAGS)
CC = gcc-4.0

ERL_DIR := $(shell echo 'io:format("~s~n",[code:root_dir()]),halt().' | erl | sed 's,^[0-9]*> *,,g' | tail +2)

Expand Down Expand Up @@ -42,12 +43,12 @@ $(LIBDIR)/%.beam: %.erl

$(LIBDIR)/mac_wings_file_drv.so: mac_wings_file_drv.c
install -d $(LIBDIR)
cc -ObjC -I $(ERL_DIR)/usr/include -bundle -flat_namespace -undefined suppress \
$(CC) -ObjC -I $(ERL_DIR)/usr/include -bundle -flat_namespace -undefined suppress \
-framework Cocoa -o $(LIBDIR)/mac_wings_file_drv.so $(UNIVERSAL_FLAGS) \
mac_wings_file_drv.c

$(LIBDIR)/mac_wings_image_drv.so: mac_wings_image_drv.m
install -d $(LIBDIR)
cc -I $(ERL_DIR)/usr/include -bundle -flat_namespace -undefined suppress \
$(CC) -I $(ERL_DIR)/usr/include -bundle -flat_namespace -undefined suppress \
-framework Cocoa -o $(LIBDIR)/mac_wings_image_drv.so $(UNIVERSAL_FLAGS) \
mac_wings_image_drv.m

0 comments on commit 1572c06

Please sign in to comment.