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

Updating MOAI Xcode sample project settings so they compile again #124

Open
wants to merge 10 commits into
base: mindsnacks-dev
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
16 changes: 8 additions & 8 deletions xcode/ios/Classes/MoaiAppDelegate.mm
Expand Up @@ -37,7 +37,7 @@ -( void ) dealloc {
//----------------------------------------------------------------//
-( void ) application:( UIApplication* )application didFailToRegisterForRemoteNotificationsWithError:( NSError* )error {

AKUNotifyRemoteNotificationRegistrationComplete ( nil );
// AKUNotifyRemoteNotificationRegistrationComplete ( nil );
}

//----------------------------------------------------------------//
Expand Down Expand Up @@ -73,11 +73,11 @@ -( BOOL ) application:( UIApplication* )application didFinishLaunchingWithOption
[ mMoaiView run:@"main.lua" ];

// check to see if the app was lanuched from a remote notification
NSDictionary* pushBundle = [ launchOptions objectForKey:UIApplicationLaunchOptionsRemoteNotificationKey ];
if ( pushBundle != NULL ) {
AKUNotifyRemoteNotificationReceived ( pushBundle );
}
// NSDictionary* pushBundle = [ launchOptions objectForKey:UIApplicationLaunchOptionsRemoteNotificationKey ];
// if ( pushBundle != NULL ) {
//
// AKUNotifyRemoteNotificationReceived ( pushBundle );
// }

// return
return true;
Expand All @@ -87,13 +87,13 @@ -( BOOL ) application:( UIApplication* )application didFinishLaunchingWithOption
//----------------------------------------------------------------//
-( void ) application:( UIApplication* )application didReceiveRemoteNotification:( NSDictionary* )pushBundle {

AKUNotifyRemoteNotificationReceived ( pushBundle );
// AKUNotifyRemoteNotificationReceived ( pushBundle );
}

//----------------------------------------------------------------//
-( void ) application:( UIApplication* )application didRegisterForRemoteNotificationsWithDeviceToken:( NSData* )deviceToken {

AKUNotifyRemoteNotificationRegistrationComplete ( deviceToken );
// AKUNotifyRemoteNotificationRegistrationComplete ( deviceToken );
}

//----------------------------------------------------------------//
Expand Down
7 changes: 5 additions & 2 deletions xcode/ios/Classes/MoaiView.mm
Expand Up @@ -123,11 +123,14 @@ -( void ) handleTouches :( NSSet* )touches :( BOOL )down {
for ( UITouch* touch in touches ) {

CGPoint p = [ touch locationInView:self ];

UInt64 touchAddress = (UInt64)touch;
int touchID = (int)(touchAddress & UINT32_MAX);

AKUEnqueueTouchEvent (
MoaiInputDeviceID::DEVICE,
MoaiInputDeviceSensorID::TOUCH,
( int )touch, // use the address of the touch as a unique id
touchID, // use the address of the touch as a unique id
down,
p.x * [[ UIScreen mainScreen ] scale ],
p.y * [[ UIScreen mainScreen ] scale ]
Expand Down Expand Up @@ -350,4 +353,4 @@ -( void )touchesMoved:( NSSet* )touches withEvent:( UIEvent* )event {
[ self handleTouches :touches :YES ];
}

@end
@end
6 changes: 3 additions & 3 deletions xcode/ios/Info.plist
Expand Up @@ -18,19 +18,19 @@
<string>Icon-Small@2x.png</string>
</array>
<key>CFBundleIdentifier</key>
<string>com.getmoai.samples</string>
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>${PRODUCT_NAME}</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>1.0</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
<string>1</string>
<key>CFBundleShortVersionString</key>
<string>1.0</string>
<key>LSRequiresIPhoneOS</key>
<true/>
<key>UIPrerenderedIcon</key>
Expand Down
97 changes: 79 additions & 18 deletions xcode/ios/MoaiSample.xcodeproj/project.pbxproj
Expand Up @@ -24,7 +24,6 @@
03CC910C13B3C48400B2724C /* AudioToolbox.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 03CC910B13B3C48400B2724C /* AudioToolbox.framework */; };
03CC911C13B3C49400B2724C /* SystemConfiguration.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 03CC911B13B3C49400B2724C /* SystemConfiguration.framework */; };
03CC912213B3C4A400B2724C /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 03CC912113B3C4A400B2724C /* QuartzCore.framework */; };
03CC912C13B3C4C000B2724C /* StoreKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 03CC912B13B3C4C000B2724C /* StoreKit.framework */; };
0711070513C637F000EE7C53 /* CoreTelephony.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 0711070413C637F000EE7C53 /* CoreTelephony.framework */; };
078D630113BA9EA30072F273 /* MoaiVC.mm in Sources */ = {isa = PBXBuildFile; fileRef = 078D630013BA9EA30072F273 /* MoaiVC.mm */; };
079530CE1447A0FF00143A72 /* MediaPlayer.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 079530CD1447A0FF00143A72 /* MediaPlayer.framework */; };
Expand All @@ -36,7 +35,6 @@
1D60589F0D05DD5A006BFB54 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1D30AB110D05D00D00671497 /* Foundation.framework */; };
1DF5F4E00D08C38300B7A737 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1DF5F4DF0D08C38300B7A737 /* UIKit.framework */; };
288765A50DF7441C002DB57D /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 288765A40DF7441C002DB57D /* CoreGraphics.framework */; };
665383F3160A798F003D5529 /* FacebookSDKResources.bundle in Resources */ = {isa = PBXBuildFile; fileRef = 665383F2160A798F003D5529 /* FacebookSDKResources.bundle */; };
665383F7160A8466003D5529 /* MessageUI.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 665383F6160A8466003D5529 /* MessageUI.framework */; };
B4D552A51863700E00CB70BD /* lua in Resources */ = {isa = PBXBuildFile; fileRef = 074C469A14240A180066B1EB /* lua */; };
CD464CE0147259EA00501E4E /* libmoai-ios-zlcore.a in Frameworks */ = {isa = PBXBuildFile; fileRef = CD04AF1214725736009C20E5 /* libmoai-ios-zlcore.a */; };
Expand Down Expand Up @@ -106,6 +104,34 @@
remoteGlobalIDString = CDD06A061398822500AB0420;
remoteInfo = "libmoai-iphone-luaext";
};
4D2019E4258C23140066DD72 /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = 03CC90AE13B3C39D00B2724C /* libmoai.xcodeproj */;
proxyType = 2;
remoteGlobalIDString = EB9EE00B1BE9421B00E8938F;
remoteInfo = "libmoai-tvos";
};
4D2019E6258C23140066DD72 /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = 03CC90AE13B3C39D00B2724C /* libmoai.xcodeproj */;
proxyType = 2;
remoteGlobalIDString = EB9EE1851BE9422800E8938F;
remoteInfo = "libmoai-tvos-3rdparty";
};
4D2019E8258C23140066DD72 /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = 03CC90AE13B3C39D00B2724C /* libmoai.xcodeproj */;
proxyType = 2;
remoteGlobalIDString = EB9EE1B81BE9423500E8938F;
remoteInfo = "libmoai-tvos-luaext";
};
4D2019EA258C23140066DD72 /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = 03CC90AE13B3C39D00B2724C /* libmoai.xcodeproj */;
proxyType = 2;
remoteGlobalIDString = EB9EE1F51BE9424500E8938F;
remoteInfo = "libmoai-tvos-zlcore";
};
CD04AF1114725736009C20E5 /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = 03CC90AE13B3C39D00B2724C /* libmoai.xcodeproj */;
Expand Down Expand Up @@ -155,7 +181,6 @@
03CC910B13B3C48400B2724C /* AudioToolbox.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AudioToolbox.framework; path = System/Library/Frameworks/AudioToolbox.framework; sourceTree = SDKROOT; };
03CC911B13B3C49400B2724C /* SystemConfiguration.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = SystemConfiguration.framework; path = System/Library/Frameworks/SystemConfiguration.framework; sourceTree = SDKROOT; };
03CC912113B3C4A400B2724C /* QuartzCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QuartzCore.framework; path = System/Library/Frameworks/QuartzCore.framework; sourceTree = SDKROOT; };
03CC912B13B3C4C000B2724C /* StoreKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = StoreKit.framework; path = System/Library/Frameworks/StoreKit.framework; sourceTree = SDKROOT; };
0711070413C637F000EE7C53 /* CoreTelephony.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreTelephony.framework; path = System/Library/Frameworks/CoreTelephony.framework; sourceTree = SDKROOT; };
074C469A14240A180066B1EB /* lua */ = {isa = PBXFileReference; lastKnownFileType = folder; path = lua; sourceTree = "<group>"; };
078D62FF13BA9EA30072F273 /* MoaiVC.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MoaiVC.h; sourceTree = "<group>"; };
Expand Down Expand Up @@ -192,7 +217,6 @@
665383F7160A8466003D5529 /* MessageUI.framework in Frameworks */,
03CC90F813B3C45A00B2724C /* OpenGLES.framework in Frameworks */,
03CC912213B3C4A400B2724C /* QuartzCore.framework in Frameworks */,
03CC912C13B3C4C000B2724C /* StoreKit.framework in Frameworks */,
03CC911C13B3C49400B2724C /* SystemConfiguration.framework in Frameworks */,
07EF3E44147BAAA5006CFDCE /* Twitter.framework in Frameworks */,
1DF5F4E00D08C38300B7A737 /* UIKit.framework in Frameworks */,
Expand All @@ -213,6 +237,10 @@
03CC90C713B3C39D00B2724C /* libmoai-osx-3rdparty.a */,
03CC90C913B3C39D00B2724C /* libmoai-osx-luaext.a */,
CD04AF1414725736009C20E5 /* libmoai-osx-zlcore.a */,
4D2019E5258C23140066DD72 /* libmoai-tvos.a */,
4D2019E7258C23140066DD72 /* libmoai-tvos-3rdparty.a */,
4D2019E9258C23140066DD72 /* libmoai-tvos-luaext.a */,
4D2019EB258C23140066DD72 /* libmoai-tvos-zlcore.a */,
);
name = Products;
sourceTree = "<group>";
Expand Down Expand Up @@ -302,7 +330,6 @@
1D30AB110D05D00D00671497 /* Foundation.framework */,
03CC90F713B3C45A00B2724C /* OpenGLES.framework */,
03CC912113B3C4A400B2724C /* QuartzCore.framework */,
03CC912B13B3C4C000B2724C /* StoreKit.framework */,
03CC911B13B3C49400B2724C /* SystemConfiguration.framework */,
1DF5F4DF0D08C38300B7A737 /* UIKit.framework */,
07EF3E43147BAAA5006CFDCE /* Twitter.framework */,
Expand Down Expand Up @@ -359,6 +386,11 @@
isa = PBXProject;
attributes = {
LastUpgradeCheck = 0420;
TargetAttributes = {
1D6058900D05DD3D006BFB54 = {
DevelopmentTeam = JG69W4K637;
};
};
};
buildConfigurationList = C01FCF4E08A954540054247B /* Build configuration list for PBXProject "MoaiSample" */;
compatibilityVersion = "Xcode 3.2";
Expand Down Expand Up @@ -428,6 +460,34 @@
remoteRef = 03CC90C813B3C39D00B2724C /* PBXContainerItemProxy */;
sourceTree = BUILT_PRODUCTS_DIR;
};
4D2019E5258C23140066DD72 /* libmoai-tvos.a */ = {
isa = PBXReferenceProxy;
fileType = archive.ar;
path = "libmoai-tvos.a";
remoteRef = 4D2019E4258C23140066DD72 /* PBXContainerItemProxy */;
sourceTree = BUILT_PRODUCTS_DIR;
};
4D2019E7258C23140066DD72 /* libmoai-tvos-3rdparty.a */ = {
isa = PBXReferenceProxy;
fileType = archive.ar;
path = "libmoai-tvos-3rdparty.a";
remoteRef = 4D2019E6258C23140066DD72 /* PBXContainerItemProxy */;
sourceTree = BUILT_PRODUCTS_DIR;
};
4D2019E9258C23140066DD72 /* libmoai-tvos-luaext.a */ = {
isa = PBXReferenceProxy;
fileType = archive.ar;
path = "libmoai-tvos-luaext.a";
remoteRef = 4D2019E8258C23140066DD72 /* PBXContainerItemProxy */;
sourceTree = BUILT_PRODUCTS_DIR;
};
4D2019EB258C23140066DD72 /* libmoai-tvos-zlcore.a */ = {
isa = PBXReferenceProxy;
fileType = archive.ar;
path = "libmoai-tvos-zlcore.a";
remoteRef = 4D2019EA258C23140066DD72 /* PBXContainerItemProxy */;
sourceTree = BUILT_PRODUCTS_DIR;
};
CD04AF1214725736009C20E5 /* libmoai-ios-zlcore.a */ = {
isa = PBXReferenceProxy;
fileType = archive.ar;
Expand Down Expand Up @@ -455,7 +515,6 @@
03CC905B13B3C1B700B2724C /* Icon-Small@2x.png in Resources */,
03CC905C13B3C1B700B2724C /* Icon.png in Resources */,
03CC905D13B3C1B700B2724C /* Icon@2x.png in Resources */,
665383F3160A798F003D5529 /* FacebookSDKResources.bundle in Resources */,
B4D552A51863700E00CB70BD /* lua in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
Expand Down Expand Up @@ -505,33 +564,41 @@
1D6058940D05DD3E006BFB54 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
DEVELOPMENT_TEAM = JG69W4K637;
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this development team id for a personal account? If so we might want to unset that.

GCC_PREPROCESSOR_DEFINITIONS = "";
LIBRARY_SEARCH_PATHS = "";
OTHER_LDFLAGS = "";
PRODUCT_BUNDLE_IDENTIFIER = com.elevate.moaisample;
PRODUCT_NAME = moai;
VALID_ARCHS = "i386 x86_64 armv7 armv7s arm64";
};
name = Debug;
};
1D6058950D05DD3E006BFB54 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
DEVELOPMENT_TEAM = JG69W4K637;
GCC_PREPROCESSOR_DEFINITIONS = "";
LIBRARY_SEARCH_PATHS = "";
OTHER_LDFLAGS = "";
PRODUCT_BUNDLE_IDENTIFIER = com.elevate.moaisample;
PRODUCT_NAME = moai;
VALID_ARCHS = "i386 x86_64 armv7 armv7s arm64";
};
name = Release;
};
C01FCF4F08A954540054247B /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ARCHS = "$(ARCHS_STANDARD_32_BIT)";
ARCHS = "$(ARCHS_STANDARD)";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
COMPRESS_PNG_FILES = NO;
GCC_C_LANGUAGE_STANDARD = c99;
HEADER_SEARCH_PATHS = "\"$(SRCROOT)/../../src\"/**";
INFOPLIST_FILE = Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 4.3;
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
LIBRARY_SEARCH_PATHS = (
"\"$(SRCROOT)/../../3rdparty/crittercismiOS-3.3.3/CrittercismSDK-crashonly\"",
"\"$(SRCROOT)/../../3rdparty/facebookiOS-3.0.6.b\"",
Expand All @@ -541,10 +608,7 @@
"-include",
"\"zlcore/zl_replace.h\"",
);
OTHER_LDFLAGS = (
"-force_load",
"\"$(BUILT_PRODUCTS_DIR)/libmoai-ios-tapjoy.a\"",
);
OTHER_LDFLAGS = "";
SDKROOT = iphoneos;
TARGETED_DEVICE_FAMILY = "1,2";
VALID_ARCHS = "i386 armv7 armv7s";
Expand All @@ -554,14 +618,14 @@
C01FCF5008A954540054247B /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ARCHS = "$(ARCHS_STANDARD_32_BIT)";
ARCHS = "$(ARCHS_STANDARD)";
CODE_SIGN_ENTITLEMENTS = Entitlements.plist;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
COMPRESS_PNG_FILES = NO;
GCC_C_LANGUAGE_STANDARD = c99;
HEADER_SEARCH_PATHS = "\"$(SRCROOT)/../../src\"/**";
INFOPLIST_FILE = Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 4.3;
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
LIBRARY_SEARCH_PATHS = (
"\"$(SRCROOT)/../../3rdparty/crittercismiOS-3.3.3/CrittercismSDK-crashonly\"",
"\"$(SRCROOT)/../../3rdparty/facebookiOS-3.0.6.b\"",
Expand All @@ -571,10 +635,7 @@
"-include",
"\"zlcore/zl_replace.h\"",
);
OTHER_LDFLAGS = (
"-force_load",
"\"$(BUILT_PRODUCTS_DIR)/libmoai-ios-tapjoy.a\"",
);
OTHER_LDFLAGS = "";
"PROVISIONING_PROFILE[sdk=iphoneos*]" = "";
SDKROOT = iphoneos;
TARGETED_DEVICE_FAMILY = "1,2";
Expand Down
6 changes: 4 additions & 2 deletions xcode/libmoai/libmoai.xcodeproj/project.pbxproj
Expand Up @@ -10381,7 +10381,8 @@
"\"../../3rdparty/facebookiOS-3.0.6.b/src\"",
"../../3rdparty/sfmt-1.4/",
);
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
MACOSX_DEPLOYMENT_TARGET = 10.9;
OTHER_CFLAGS = (
"-include",
"\"zlcore/zl_replace.h\"",
Expand Down Expand Up @@ -10604,7 +10605,8 @@
"\"../../3rdparty/facebookiOS-3.0.6.b/src\"",
"../../3rdparty/sfmt-1.4/",
);
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
MACOSX_DEPLOYMENT_TARGET = 10.9;
ONLY_ACTIVE_ARCH = YES;
OTHER_CFLAGS = (
"-include",
Expand Down