Permalink
Browse files

initial commit - fix of example template

  • Loading branch information...
0 parents commit 62baebdccee360369c356e8695215e1d77b7596e @meeech committed Mar 18, 2012
4 .gitignore
@@ -0,0 +1,4 @@
+tmp
+bin
+build
+*.zip
23 .project
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>plist-module</name>
+ <comment></comment>
+ <projects>
+ </projects>
+ <buildSpec>
+ <buildCommand>
+ <name>com.aptana.ide.core.unifiedBuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>com.appcelerator.titanium.core.builder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ </buildSpec>
+ <natures>
+ <nature>com.appcelerator.titanium.mobile.module.nature</nature>
+ <nature>com.aptana.projects.webnature</nature>
+ </natures>
+</projectDescription>
2 Classes/.gitignore
@@ -0,0 +1,2 @@
+ComMeeechPlist.h
+ComMeeechPlist.m
16 Classes/ComMeeechPlistModule.h
@@ -0,0 +1,16 @@
+/**
+ * Your Copyright Here
+ *
+ * Appcelerator Titanium is Copyright (c) 2009-2010 by Appcelerator, Inc.
+ * and licensed under the Apache Public License (version 2)
+ */
+#import "TiModule.h"
+
+@interface ComMeeechPlistModule : TiModule
+{
+
+}
+
+@property NSString *exampleProp;
+
+@end
97 Classes/ComMeeechPlistModule.m
@@ -0,0 +1,97 @@
+/**
+ * Your Copyright Here
+ *
+ * Appcelerator Titanium is Copyright (c) 2009-2010 by Appcelerator, Inc.
+ * and licensed under the Apache Public License (version 2)
+ */
+#import "ComMeeechPlistModule.h"
+#import "TiBase.h"
+#import "TiHost.h"
+#import "TiUtils.h"
+
+@implementation ComMeeechPlistModule
+
+@synthesize exampleProp;
+
+#pragma mark Internal
+
+// this is generated for your module, please do not change it
+-(id)moduleGUID
+{
+ return @"9f589e5f-9866-4242-a057-d610f3bc8699";
+}
+
+// this is generated for your module, please do not change it
+-(NSString*)moduleId
+{
+ return @"com.meeech.plist";
+}
+
+#pragma mark Lifecycle
+
+-(void)startup
+{
+ // this method is called when the module is first loaded
+ // you *must* call the superclass
+ [super startup];
+
+ NSLog(@"[INFO] %@ loaded",self);
+}
+
+-(void)shutdown:(id)sender
+{
+ // this method is called when the module is being unloaded
+ // typically this is during shutdown. make sure you don't do too
+ // much processing here or the app will be quit forceably
+
+ // you *must* call the superclass
+ [super shutdown:sender];
+}
+
+#pragma mark Cleanup
+
+-(void)dealloc
+{
+ // release any resources that have been retained by the module
+ [super dealloc];
+}
+
+#pragma mark Internal Memory Management
+
+-(void)didReceiveMemoryWarning:(NSNotification*)notification
+{
+ // optionally release any resources that can be dynamically
+ // reloaded once memory is available - such as caches
+ [super didReceiveMemoryWarning:notification];
+}
+
+#pragma mark Listener Notifications
+
+-(void)_listenerAdded:(NSString *)type count:(int)count
+{
+ if (count == 1 && [type isEqualToString:@"my_event"])
+ {
+ // the first (of potentially many) listener is being added
+ // for event named 'my_event'
+ }
+}
+
+-(void)_listenerRemoved:(NSString *)type count:(int)count
+{
+ if (count == 0 && [type isEqualToString:@"my_event"])
+ {
+ // the last listener called for event named 'my_event' has
+ // been removed, we can optionally clean up any resources
+ // since no body is listening at this point for that event
+ }
+}
+
+#pragma Public APIs
+
+-(id)example:(id)args
+{
+ // example method
+ return @"hello world";
+}
+
+@end
9 Classes/ComMeeechPlistModuleAssets.h
@@ -0,0 +1,9 @@
+/**
+ * This is a generated file. Do not edit or your changes will be lost
+ */
+
+@interface ComMeeechPlistModuleAssets : NSObject
+{
+}
+- (NSData*) moduleAsset;
+@end
15 Classes/ComMeeechPlistModuleAssets.m
@@ -0,0 +1,15 @@
+/**
+ * This is a generated file. Do not edit or your changes will be lost
+ */
+#import "ComMeeechPlistModuleAssets.h"
+
+extern NSData * dataWithHexString (NSString * hexString);
+
+@implementation ComMeeechPlistModuleAssets
+
+- (NSData*) moduleAsset
+{
+ return nil;
+}
+
+@end
4 ComMeeechPlist_Prefix.pch
@@ -0,0 +1,4 @@
+
+#ifdef __OBJC__
+ #import <Foundation/Foundation.h>
+#endif
1 LICENSE
@@ -0,0 +1 @@
+Use at will.
151 README
@@ -0,0 +1,151 @@
+Appcelerator Titanium iPhone Module Project
+===========================================
+
+This is a skeleton Titanium Mobile iPhone module project. Modules can be
+used to extend the functionality of Titanium by providing additional native
+code that is compiled into your application at build time and can expose certain
+APIs into JavaScript.
+
+MODULE NAMING
+--------------
+
+Choose a unique module id for your module. This ID usually follows a namespace
+convention using DNS notation. For example, com.appcelerator.module.test. This
+ID can only be used once by all public modules in Titanium.
+
+
+COMPONENTS
+-----------
+
+Components that are exposed by your module must follow a special naming convention.
+A component (widget, proxy, etc) must be named with the pattern:
+
+ Ti<ModuleName><ComponentName>Proxy
+
+For example, if you component was called Foo, your proxy would be named:
+
+ TiMyfirstFooProxy
+
+For view proxies or widgets, you must create both a view proxy and a view implementation.
+If you widget was named proxy, you would create the following files:
+
+ TiMyfirstFooProxy.h
+ TiMyfirstFooProxy.m
+ TiMyfirstFoo.h
+ TiMyfirstFoo.m
+
+The view implementation is named the same except it does contain the suffix `Proxy`.
+
+View implementations extend the Titanium base class `TiUIView`. View Proxies extend the
+Titanium base class `TiUIViewProxy` or `TiUIWidgetProxy`.
+
+For proxies that are simply native objects that can be returned to JavaScript, you can
+simply extend `TiProxy` and no view implementation is required.
+
+
+GET STARTED
+------------
+
+1. Edit manifest with the appropriate details about your module.
+2. Edit LICENSE to add your license details.
+3. Place any assets (such as PNG files) that are required in the assets folder.
+4. Edit the titanium.xcconfig and make sure you're building for the right Titanium version.
+5. Code and build.
+
+BUILD TIME COMPILER CONFIG
+--------------------------
+
+You can edit the file `module.xcconfig` to include any build time settings that should be
+set during application compilation that your module requires. This file will automatically get `#include` in the main application project.
+
+For more information about this file, please see the Apple documentation at:
+
+<http://developer.apple.com/mac/library/documentation/DeveloperTools/Conceptual/XcodeBuildSystem/400-Build_Configurations/build_configs.html>
+
+
+DOCUMENTATION FOR YOUR MODULE
+-----------------------------
+
+You should provide at least minimal documentation for your module in `documentation` folder using the Markdown syntax.
+
+For more information on the Markdown syntax, refer to this documentation at:
+
+<http://daringfireball.net/projects/markdown/>
+
+
+TEST HARNESS EXAMPLE FOR YOUR MODULE
+------------------------------------
+
+The `example` directory contains a skeleton application test harness that can be
+used for testing and providing an example of usage to the users of your module.
+
+
+INSTALL YOUR MODULE
+--------------------
+
+1. Run `build.py` which creates your distribution
+2. cd to `/Library/Application Support/Titanium`
+3. copy this zip file into the folder of your Titanium SDK
+
+REGISTER YOUR MODULE
+---------------------
+
+Register your module with your application by editing `tiapp.xml` and adding your module.
+Example:
+
+<modules>
+ <module version="0.1">com.meeech.plist</module>
+</modules>
+
+When you run your project, the compiler will know automatically compile in your module
+dependencies and copy appropriate image assets into the application.
+
+USING YOUR MODULE IN CODE
+-------------------------
+
+To use your module in code, you will need to require it.
+
+For example,
+
+ var my_module = require('com.meeech.plist');
+ my_module.foo();
+
+WRITING PURE JS NATIVE MODULES
+------------------------------
+
+You can write a pure JavaScript "natively compiled" module. This is nice if you
+want to distribute a JS module pre-compiled.
+
+To create a module, create a file named com.meeech.plist.js under the assets folder.
+This file must be in the Common JS format. For example:
+
+ exports.echo = function(s)
+ {
+ return s;
+ };
+
+Any functions and properties that are exported will be made available as part of your
+module. All other code inside your JS will be private to your module.
+
+For pure JS module, you don't need to modify any of the Objective-C module code. You
+can leave it as-is and build.
+
+TESTING YOUR MODULE
+-------------------
+
+Run the `titanium.py` script to test your module or test from within XCode.
+To test with the script, execute:
+
+ titanium run --dir=YOURMODULEDIR
+
+
+This will execute the app.js in the example folder as a Titanium application.
+
+
+DISTRIBUTING YOUR MODULE
+-------------------------
+
+Currently, you will need to manually distribution your module distribution zip file directly. However, in the near future, we will make module distribution and sharing built-in to Titanium Developer and in the Titanium Marketplace!
+
+
+Cheers!
6 assets/README
@@ -0,0 +1,6 @@
+Place your assets like PNG files in this directory and they will be packaged with your module.
+
+If you create a file named com.meeech.plist.js in this directory, it will be
+compiled and used as your module. This allows you to run pure Javascript
+modules that are pre-compiled.
+
218 build.py
@@ -0,0 +1,218 @@
+#!/usr/bin/env python
+#
+# Appcelerator Titanium Module Packager
+#
+#
+import os, sys, glob, string
+import zipfile
+from datetime import date
+
+try:
+ import json
+except:
+ import simplejson as json
+
+cwd = os.path.abspath(os.path.dirname(sys._getframe(0).f_code.co_filename))
+os.chdir(cwd)
+required_module_keys = ['name','version','moduleid','description','copyright','license','copyright','platform','minsdk']
+module_defaults = {
+ 'description':'My module',
+ 'author': 'Your Name',
+ 'license' : 'Specify your license',
+ 'copyright' : 'Copyright (c) %s by Your Company' % str(date.today().year),
+}
+module_license_default = "TODO: place your license here and we'll include it in the module distribution"
+
+def find_sdk(config):
+ sdk = config['TITANIUM_SDK']
+ return os.path.expandvars(os.path.expanduser(sdk))
+
+def replace_vars(config,token):
+ idx = token.find('$(')
+ while idx != -1:
+ idx2 = token.find(')',idx+2)
+ if idx2 == -1: break
+ key = token[idx+2:idx2]
+ if not config.has_key(key): break
+ token = token.replace('$(%s)' % key, config[key])
+ idx = token.find('$(')
+ return token
+
+
+def read_ti_xcconfig():
+ contents = open(os.path.join(cwd,'titanium.xcconfig')).read()
+ config = {}
+ for line in contents.splitlines(False):
+ line = line.strip()
+ if line[0:2]=='//': continue
+ idx = line.find('=')
+ if idx > 0:
+ key = line[0:idx].strip()
+ value = line[idx+1:].strip()
+ config[key] = replace_vars(config,value)
+ return config
+
+def generate_doc(config):
+ docdir = os.path.join(cwd,'documentation')
+ if not os.path.exists(docdir):
+ print "Couldn't find documentation file at: %s" % docdir
+ return None
+ sdk = find_sdk(config)
+ support_dir = os.path.join(sdk,'module','support')
+ sys.path.append(support_dir)
+ try:
+ import markdown2 as markdown
+ except ImportError:
+ import markdown
+ documentation = []
+ for file in os.listdir(docdir):
+ if file in ignoreFiles or os.path.isdir(os.path.join(docdir, file)):
+ continue
+ md = open(os.path.join(docdir,file)).read()
+ html = markdown.markdown(md)
+ documentation.append({file:html});
+ return documentation
+
+def compile_js(manifest,config):
+ js_file = os.path.join(cwd,'assets','com.meeech.plist.js')
+ if not os.path.exists(js_file): return
+
+ sdk = find_sdk(config)
+ iphone_dir = os.path.join(sdk,'iphone')
+ sys.path.insert(0,iphone_dir)
+ from compiler import Compiler
+
+ path = os.path.basename(js_file)
+ compiler = Compiler(cwd, manifest['moduleid'], manifest['name'], 'commonjs')
+ metadata = compiler.make_function_from_file(path,js_file)
+
+ exports = open('metadata.json','w')
+ json.dump({'exports':compiler.exports }, exports)
+ exports.close()
+
+ method = metadata['method']
+ eq = path.replace('.','_')
+ method = ' return %s;' % method
+
+ f = os.path.join(cwd,'Classes','ComMeeechPlistModuleAssets.m')
+ c = open(f).read()
+ idx = c.find('return ')
+ before = c[0:idx]
+ after = """
+}
+
+@end
+ """
+ newc = before + method + after
+
+ if newc!=c:
+ x = open(f,'w')
+ x.write(newc)
+ x.close()
+
+def die(msg):
+ print msg
+ sys.exit(1)
+
+def warn(msg):
+ print "[WARN] %s" % msg
+
+def validate_license():
+ c = open(os.path.join(cwd,'LICENSE')).read()
+ if c.find(module_license_default)!=-1:
+ warn('please update the LICENSE file with your license text before distributing')
+
+def validate_manifest():
+ path = os.path.join(cwd,'manifest')
+ f = open(path)
+ if not os.path.exists(path): die("missing %s" % path)
+ manifest = {}
+ for line in f.readlines():
+ line = line.strip()
+ if line[0:1]=='#': continue
+ if line.find(':') < 0: continue
+ key,value = line.split(':')
+ manifest[key.strip()]=value.strip()
+ for key in required_module_keys:
+ if not manifest.has_key(key): die("missing required manifest key '%s'" % key)
+ if module_defaults.has_key(key):
+ defvalue = module_defaults[key]
+ curvalue = manifest[key]
+ if curvalue==defvalue: warn("please update the manifest key: '%s' to a non-default value" % key)
+ return manifest,path
+
+ignoreFiles = ['.DS_Store','.gitignore','libTitanium.a','titanium.jar','README','com.meeech.plist.js']
+ignoreDirs = ['.DS_Store','.svn','.git','CVSROOT']
+
+def zip_dir(zf,dir,basepath,ignore=[]):
+ for root, dirs, files in os.walk(dir):
+ for name in ignoreDirs:
+ if name in dirs:
+ dirs.remove(name) # don't visit ignored directories
+ for file in files:
+ if file in ignoreFiles: continue
+ e = os.path.splitext(file)
+ if len(e)==2 and e[1]=='.pyc':continue
+ from_ = os.path.join(root, file)
+ to_ = from_.replace(dir, basepath, 1)
+ zf.write(from_, to_)
+
+def glob_libfiles():
+ files = []
+ for libfile in glob.glob('build/**/*.a'):
+ if libfile.find('Release-')!=-1:
+ files.append(libfile)
+ return files
+
+def build_module(manifest,config):
+ rc = os.system("xcodebuild -sdk iphoneos -configuration Release")
+ if rc != 0:
+ die("xcodebuild failed")
+ rc = os.system("xcodebuild -sdk iphonesimulator -configuration Release")
+ if rc != 0:
+ die("xcodebuild failed")
+ # build the merged library using lipo
+ moduleid = manifest['moduleid']
+ libpaths = ''
+ for libfile in glob_libfiles():
+ libpaths+='%s ' % libfile
+
+ os.system("lipo %s -create -output build/lib%s.a" %(libpaths,moduleid))
+
+def package_module(manifest,mf,config):
+ name = manifest['name'].lower()
+ moduleid = manifest['moduleid'].lower()
+ version = manifest['version']
+ modulezip = '%s-iphone-%s.zip' % (moduleid,version)
+ if os.path.exists(modulezip): os.remove(modulezip)
+ zf = zipfile.ZipFile(modulezip, 'w', zipfile.ZIP_DEFLATED)
+ modulepath = 'modules/iphone/%s/%s' % (moduleid,version)
+ zf.write(mf,'%s/manifest' % modulepath)
+ libname = 'lib%s.a' % moduleid
+ zf.write('build/%s' % libname, '%s/%s' % (modulepath,libname))
+ docs = generate_doc(config)
+ if docs!=None:
+ for doc in docs:
+ for file, html in doc.iteritems():
+ filename = string.replace(file,'.md','.html')
+ zf.writestr('%s/documentation/%s'%(modulepath,filename),html)
+ for dn in ('assets','example','platform'):
+ if os.path.exists(dn):
+ zip_dir(zf,dn,'%s/%s' % (modulepath,dn),['README'])
+ zf.write('LICENSE','%s/LICENSE' % modulepath)
+ zf.write('module.xcconfig','%s/module.xcconfig' % modulepath)
+ exports_file = 'metadata.json'
+ if os.path.exists(exports_file):
+ zf.write(exports_file, '%s/%s' % (modulepath, exports_file))
+ zf.close()
+
+
+if __name__ == '__main__':
+ manifest,mf = validate_manifest()
+ validate_license()
+ config = read_ti_xcconfig()
+ compile_js(manifest,config)
+ build_module(manifest,config)
+ package_module(manifest,mf,config)
+ sys.exit(0)
+
39 documentation/index.md
@@ -0,0 +1,39 @@
+# plist-module Module
+
+## Description
+
+TODO: Enter your module description here
+
+## Accessing the plist-module Module
+
+To access this module from JavaScript, you would do the following:
+
+ var plist-module = require("com.meeech.plist");
+
+The plist-module variable is a reference to the Module object.
+
+## Reference
+
+TODO: If your module has an API, you should document
+the reference here.
+
+### ___PROJECTNAMEASIDENTIFIER__.function
+
+TODO: This is an example of a module function.
+
+### ___PROJECTNAMEASIDENTIFIER__.property
+
+TODO: This is an example of a module property.
+
+## Usage
+
+TODO: Enter your usage example here
+
+## Author
+
+TODO: Enter your author name, email and other contact
+details you want to share here.
+
+## License
+
+TODO: Enter your license/legal information here.
24 example/app.js
@@ -0,0 +1,24 @@
+// This is a test harness for your module
+// You should do something interesting in this harness
+// to test out the module and to provide instructions
+// to users on how to use it by example.
+
+
+// open a single window
+var window = Ti.UI.createWindow({
+ backgroundColor:'white'
+});
+var label = Ti.UI.createLabel();
+window.add(label);
+window.open();
+
+// TODO: write your module tests here
+var plistmodule = require('com.meeech.plist');
+Ti.API.info("module is => " + plistmodule);
+
+label.text = plistmodule.example();
+
+plistmodule.exampleProp = "This is a test value";
+
+Ti.API.info("module exampleProp is => " + plistmodule.exampleProp);
+
1 hooks/README
@@ -0,0 +1 @@
+These files are not yet supported as of 1.4.0 but will be in a near future release.
35 hooks/add.py
@@ -0,0 +1,35 @@
+#!/usr/bin/env python
+#
+# This is the module project add hook that will be
+# called when your module is added to a project
+#
+import os, sys
+
+def dequote(s):
+ if s[0:1] == '"':
+ return s[1:-1]
+ return s
+
+def main(args,argc):
+ # You will get the following command line arguments
+ # in the following order:
+ #
+ # project_dir = the full path to the project root directory
+ # project_type = the type of project (desktop, mobile, ipad)
+ # project_name = the name of the project
+ #
+ project_dir = dequote(os.path.expanduser(args[1]))
+ project_type = dequote(args[2])
+ project_name = dequote(args[3])
+
+ # TODO: write your add hook here (optional)
+
+
+ # exit
+ sys.exit(0)
+
+
+
+if __name__ == '__main__':
+ main(sys.argv,len(sys.argv))
+
19 hooks/install.py
@@ -0,0 +1,19 @@
+#!/usr/bin/env python
+#
+# This is the module install hook that will be
+# called when your module is first installed
+#
+import os, sys
+
+def main(args,argc):
+
+ # TODO: write your install hook here (optional)
+
+ # exit
+ sys.exit(0)
+
+
+
+if __name__ == '__main__':
+ main(sys.argv,len(sys.argv))
+
34 hooks/remove.py
@@ -0,0 +1,34 @@
+#!/usr/bin/env python
+#
+# This is the module project remove hook that will be
+# called when your module is remove from a project
+#
+import os, sys
+
+def dequote(s):
+ if s[0:1] == '"':
+ return s[1:-1]
+ return s
+
+def main(args,argc):
+ # You will get the following command line arguments
+ # in the following order:
+ #
+ # project_dir = the full path to the project root directory
+ # project_type = the type of project (desktop, mobile, ipad)
+ # project_name = the name of the project
+ #
+ project_dir = dequote(os.path.expanduser(args[1]))
+ project_type = dequote(args[2])
+ project_name = dequote(args[3])
+
+ # TODO: write your remove hook here (optional)
+
+ # exit
+ sys.exit(0)
+
+
+
+if __name__ == '__main__':
+ main(sys.argv,len(sys.argv))
+
18 hooks/uninstall.py
@@ -0,0 +1,18 @@
+#!/usr/bin/env python
+#
+# This is the module uninstall hook that will be
+# called when your module is uninstalled
+#
+import os, sys
+
+def main(args,argc):
+
+ # TODO: write your uninstall hook here (optional)
+
+ # exit
+ sys.exit(0)
+
+
+if __name__ == '__main__':
+ main(sys.argv,len(sys.argv))
+
18 manifest
@@ -0,0 +1,18 @@
+#
+# this is your module manifest and used by Titanium
+# during compilation, packaging, distribution, etc.
+#
+version: 1.0
+apiversion: 2
+description: A module to fetch plist data at runtime.
+author: Mitchell Amihod
+license: Use at will.
+copyright: 2012
+
+
+# these should not be edited
+name: plist-module
+moduleid: com.meeech.plist
+guid: 9f589e5f-9866-4242-a057-d610f3bc8699
+platform: iphone
+minsdk: 1.8.2
27 module.xcconfig
@@ -0,0 +1,27 @@
+//
+// PLACE ANY BUILD DEFINITIONS IN THIS FILE AND THEY WILL BE
+// PICKED UP DURING THE APP BUILD FOR YOUR MODULE
+//
+// see the following webpage for instructions on the settings
+// for this file:
+// http://developer.apple.com/mac/library/documentation/DeveloperTools/Conceptual/XcodeBuildSystem/400-Build_Configurations/build_configs.html
+//
+
+//
+// How to add a Framework (example)
+//
+// OTHER_LDFLAGS=$(inherited) -framework Foo
+//
+// Adding a framework for a specific version(s) of iPhone:
+//
+// OTHER_LDFLAGS[sdk=iphoneos4*]=$(inherited) -framework Foo
+// OTHER_LDFLAGS[sdk=iphonesimulator4*]=$(inherited) -framework Foo
+//
+//
+// How to add a compiler define:
+//
+// OTHER_CFLAGS=$(inherited) -DFOO=1
+//
+//
+// IMPORTANT NOTE: always use $(inherited) in your overrides
+//
3 platform/README
@@ -0,0 +1,3 @@
+You can place platform-specific files here in sub-folders named "android" and/or "iphone", just as you can with normal Titanium Mobile SDK projects. Any folders and files you place here will be merged with the platform-specific files in a Titanium Mobile project that uses this module.
+
+When a Titanium Mobile project that uses this module is built, the files from this platform/ folder will be treated the same as files (if any) from the Titanium Mobile project's platform/ folder.
443 plist-module.xcodeproj/project.pbxproj
@@ -0,0 +1,443 @@
+// !$*UTF8*$!
+{
+ archiveVersion = 1;
+ classes = {
+ };
+ objectVersion = 45;
+ objects = {
+
+/* Begin PBXAggregateTarget section */
+ 24416B8111C4CA220047AFDD /* Build & Test */ = {
+ isa = PBXAggregateTarget;
+ buildConfigurationList = 24416B8A11C4CA520047AFDD /* Build configuration list for PBXAggregateTarget "Build & Test" */;
+ buildPhases = (
+ 24416B8011C4CA220047AFDD /* ShellScript */,
+ );
+ dependencies = (
+ 24416B8511C4CA280047AFDD /* PBXTargetDependency */,
+ );
+ name = "Build & Test";
+ productName = "Build & test";
+ };
+/* End PBXAggregateTarget section */
+
+/* Begin PBXBuildFile section */
+ 24DD6CF91134B3F500162E58 /* ComMeeechPlistModule.h in Headers */ = {isa = PBXBuildFile; fileRef = 24DD6CF71134B3F500162E58 /* ComMeeechPlistModule.h */; };
+ 24DD6CFA1134B3F500162E58 /* ComMeeechPlistModule.m in Sources */ = {isa = PBXBuildFile; fileRef = 24DD6CF81134B3F500162E58 /* ComMeeechPlistModule.m */; };
+ 24DE9E1111C5FE74003F90F6 /* ComMeeechPlistModuleAssets.h in Headers */ = {isa = PBXBuildFile; fileRef = 24DE9E0F11C5FE74003F90F6 /* ComMeeechPlistModuleAssets.h */; };
+ 24DE9E1211C5FE74003F90F6 /* ComMeeechPlistModuleAssets.m in Sources */ = {isa = PBXBuildFile; fileRef = 24DE9E1011C5FE74003F90F6 /* ComMeeechPlistModuleAssets.m */; };
+ AA747D9F0F9514B9006C5449 /* ComMeeechPlist_Prefix.pch in Headers */ = {isa = PBXBuildFile; fileRef = AA747D9E0F9514B9006C5449 /* ComMeeechPlist_Prefix.pch */; };
+ AACBBE4A0F95108600F1A2B1 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = AACBBE490F95108600F1A2B1 /* Foundation.framework */; };
+/* End PBXBuildFile section */
+
+/* Begin PBXContainerItemProxy section */
+ 24416B8411C4CA280047AFDD /* PBXContainerItemProxy */ = {
+ isa = PBXContainerItemProxy;
+ containerPortal = 0867D690FE84028FC02AAC07 /* Project object */;
+ proxyType = 1;
+ remoteGlobalIDString = D2AAC07D0554694100DB518D;
+ remoteInfo = "plist-module";
+ };
+/* End PBXContainerItemProxy section */
+
+/* Begin PBXFileReference section */
+ 24DD6CF71134B3F500162E58 /* ComMeeechPlistModule.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = "ComMeeechPlistModule.h"; path = "Classes/ComMeeechPlistModule.h"; sourceTree = "<group>"; };
+ 24DD6CF81134B3F500162E58 /* ComMeeechPlistModule.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = "ComMeeechPlistModule.m"; path = "Classes/ComMeeechPlistModule.m"; sourceTree = "<group>"; };
+ 24DD6D1B1134B66800162E58 /* titanium.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; path = titanium.xcconfig; sourceTree = "<group>"; };
+ 24DE9E0F11C5FE74003F90F6 /* ComMeeechPlistModuleAssets.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = "ComMeeechPlistModuleAssets.h"; path = "Classes/ComMeeechPlistModuleAssets.h"; sourceTree = "<group>"; };
+ 24DE9E1011C5FE74003F90F6 /* ComMeeechPlistModuleAssets.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = "ComMeeechPlistModuleAssets.m"; path = "Classes/ComMeeechPlistModuleAssets.m"; sourceTree = "<group>"; };
+ AA747D9E0F9514B9006C5449 /* ComMeeechPlist_Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "ComMeeechPlist_Prefix.pch"; sourceTree = SOURCE_ROOT; };
+ AACBBE490F95108600F1A2B1 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
+ D2AAC07E0554694100DB518D /* libComMeeechPlist.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libComMeeechPlist.a"; sourceTree = BUILT_PRODUCTS_DIR; };
+/* End PBXFileReference section */
+
+/* Begin PBXFrameworksBuildPhase section */
+ D2AAC07C0554694100DB518D /* Frameworks */ = {
+ isa = PBXFrameworksBuildPhase;
+ buildActionMask = 2147483647;
+ files = (
+ AACBBE4A0F95108600F1A2B1 /* Foundation.framework in Frameworks */,
+ );
+ runOnlyForDeploymentPostprocessing = 0;
+ };
+/* End PBXFrameworksBuildPhase section */
+
+/* Begin PBXGroup section */
+ 034768DFFF38A50411DB9C8B /* Products */ = {
+ isa = PBXGroup;
+ children = (
+ D2AAC07E0554694100DB518D /* libComMeeechPlist.a */,
+ );
+ name = Products;
+ sourceTree = "<group>";
+ };
+ 0867D691FE84028FC02AAC07 /* plist-module */ = {
+ isa = PBXGroup;
+ children = (
+ 08FB77AEFE84172EC02AAC07 /* Classes */,
+ 32C88DFF0371C24200C91783 /* Other Sources */,
+ 0867D69AFE84028FC02AAC07 /* Frameworks */,
+ 034768DFFF38A50411DB9C8B /* Products */,
+ );
+ name = "plist-module";
+ sourceTree = "<group>";
+ };
+ 0867D69AFE84028FC02AAC07 /* Frameworks */ = {
+ isa = PBXGroup;
+ children = (
+ AACBBE490F95108600F1A2B1 /* Foundation.framework */,
+ );
+ name = Frameworks;
+ sourceTree = "<group>";
+ };
+ 08FB77AEFE84172EC02AAC07 /* Classes */ = {
+ isa = PBXGroup;
+ children = (
+ 24DE9E0F11C5FE74003F90F6 /* ComMeeechPlistModuleAssets.h */,
+ 24DE9E1011C5FE74003F90F6 /* ComMeeechPlistModuleAssets.m */,
+ 24DD6CF71134B3F500162E58 /* ComMeeechPlistModule.h */,
+ 24DD6CF81134B3F500162E58 /* ComMeeechPlistModule.m */,
+ );
+ name = Classes;
+ sourceTree = "<group>";
+ };
+ 32C88DFF0371C24200C91783 /* Other Sources */ = {
+ isa = PBXGroup;
+ children = (
+ AA747D9E0F9514B9006C5449 /* ComMeeechPlist_Prefix.pch */,
+ 24DD6D1B1134B66800162E58 /* titanium.xcconfig */,
+ );
+ name = "Other Sources";
+ sourceTree = "<group>";
+ };
+/* End PBXGroup section */
+
+/* Begin PBXHeadersBuildPhase section */
+ D2AAC07A0554694100DB518D /* Headers */ = {
+ isa = PBXHeadersBuildPhase;
+ buildActionMask = 2147483647;
+ files = (
+ AA747D9F0F9514B9006C5449 /* ComMeeechPlist_Prefix.pch in Headers */,
+ 24DD6CF91134B3F500162E58 /* ComMeeechPlistModule.h in Headers */,
+ 24DE9E1111C5FE74003F90F6 /* ComMeeechPlistModuleAssets.h in Headers */,
+ );
+ runOnlyForDeploymentPostprocessing = 0;
+ };
+/* End PBXHeadersBuildPhase section */
+
+/* Begin PBXNativeTarget section */
+ D2AAC07D0554694100DB518D /* plist-module */ = {
+ isa = PBXNativeTarget;
+ buildConfigurationList = 1DEB921E08733DC00010E9CD /* Build configuration list for PBXNativeTarget "plist-module" */;
+ buildPhases = (
+ D2AAC07A0554694100DB518D /* Headers */,
+ D2AAC07B0554694100DB518D /* Sources */,
+ D2AAC07C0554694100DB518D /* Frameworks */,
+ );
+ buildRules = (
+ );
+ dependencies = (
+ );
+ name = "plist-module";
+ productName = "plist-module";
+ productReference = D2AAC07E0554694100DB518D /* libComMeeechPlist.a */;
+ productType = "com.apple.product-type.library.static";
+ };
+/* End PBXNativeTarget section */
+
+/* Begin PBXProject section */
+ 0867D690FE84028FC02AAC07 /* Project object */ = {
+ isa = PBXProject;
+ buildConfigurationList = 1DEB922208733DC00010E9CD /* Build configuration list for PBXProject "plist-module" */;
+ compatibilityVersion = "Xcode 3.1";
+ developmentRegion = English;
+ hasScannedForEncodings = 1;
+ knownRegions = (
+ English,
+ Japanese,
+ French,
+ German,
+ );
+ mainGroup = 0867D691FE84028FC02AAC07 /* plist-module */;
+ productRefGroup = 034768DFFF38A50411DB9C8B /* Products */;
+ projectDirPath = "";
+ projectRoot = "";
+ targets = (
+ D2AAC07D0554694100DB518D /* plist-module */,
+ 24416B8111C4CA220047AFDD /* Build & Test */,
+ );
+ };
+/* End PBXProject section */
+
+/* Begin PBXShellScriptBuildPhase section */
+ 24416B8011C4CA220047AFDD /* ShellScript */ = {
+ isa = PBXShellScriptBuildPhase;
+ buildActionMask = 2147483647;
+ files = (
+ );
+ inputPaths = (
+ );
+ outputPaths = (
+ );
+ runOnlyForDeploymentPostprocessing = 0;
+ shellPath = /bin/sh;
+ shellScript = "# shell script goes here\n\npython \"${TITANIUM_SDK}/titanium.py\" run --dir=\"${PROJECT_DIR}\"\nexit $?\n";
+ };
+/* End PBXShellScriptBuildPhase section */
+
+/* Begin PBXSourcesBuildPhase section */
+ D2AAC07B0554694100DB518D /* Sources */ = {
+ isa = PBXSourcesBuildPhase;
+ buildActionMask = 2147483647;
+ files = (
+ 24DD6CFA1134B3F500162E58 /* ComMeeechPlistModule.m in Sources */,
+ 24DE9E1211C5FE74003F90F6 /* ComMeeechPlistModuleAssets.m in Sources */,
+ );
+ runOnlyForDeploymentPostprocessing = 0;
+ };
+/* End PBXSourcesBuildPhase section */
+
+/* Begin PBXTargetDependency section */
+ 24416B8511C4CA280047AFDD /* PBXTargetDependency */ = {
+ isa = PBXTargetDependency;
+ target = D2AAC07D0554694100DB518D /* plist-module */;
+ targetProxy = 24416B8411C4CA280047AFDD /* PBXContainerItemProxy */;
+ };
+/* End PBXTargetDependency section */
+
+/* Begin XCBuildConfiguration section */
+ 1DEB921F08733DC00010E9CD /* Debug */ = {
+ isa = XCBuildConfiguration;
+ baseConfigurationReference = 24DD6D1B1134B66800162E58 /* titanium.xcconfig */;
+ buildSettings = {
+ ARCHS = (
+ armv6,
+ armv7,
+ );
+ "ARCHS[sdk=iphoneos*]" = (
+ armv6,
+ armv7,
+ );
+ "ARCHS[sdk=iphonesimulator*]" = i386;
+ CODE_SIGN_IDENTITY = "iPhone Developer";
+ "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
+ GCC_C_LANGUAGE_STANDARD = c99;
+ GCC_PREPROCESSOR_DEFINITIONS = "TI_VERSION=$(TI_VERSION)";
+ GCC_TREAT_WARNINGS_AS_ERRORS = NO;
+ GCC_VERSION = "";
+ GCC_WARN_ABOUT_RETURN_TYPE = NO;
+ GCC_WARN_MISSING_PARENTHESES = NO;
+ GCC_WARN_SHADOW = NO;
+ GCC_WARN_STRICT_SELECTOR_MATCH = NO;
+ GCC_WARN_UNUSED_FUNCTION = YES;
+ GCC_WARN_UNUSED_PARAMETER = NO;
+ GCC_WARN_UNUSED_VALUE = NO;
+ GCC_WARN_UNUSED_VARIABLE = NO;
+ GCC_OPTIMIZATION_LEVEL = 0;
+ GCC_PRECOMPILE_PREFIX_HEADER = YES;
+ GCC_PREFIX_HEADER = "ComMeeechPlist_Prefix.pch";
+ OTHER_CFLAGS = (
+ "-DDEBUG",
+ "-DTI_POST_1_2",
+ );
+ OTHER_LDFLAGS = "-ObjC";
+ PROVISIONING_PROFILE = "";
+ "PROVISIONING_PROFILE[sdk=iphoneos*]" = "";
+ RUN_CLANG_STATIC_ANALYZER = NO;
+ SDKROOT = iphoneos;
+ USER_HEADER_SEARCH_PATHS = "";
+ DSTROOT = "/tmp/ComMeeechPlist.dst";
+ INSTALL_PATH = /usr/local/lib;
+ PRODUCT_NAME = "ComMeeechPlist";
+ };
+ name = Debug;
+ };
+ 1DEB922008733DC00010E9CD /* Release */ = {
+ isa = XCBuildConfiguration;
+ baseConfigurationReference = 24DD6D1B1134B66800162E58 /* titanium.xcconfig */;
+ buildSettings = {
+ ARCHS = (
+ armv6,
+ armv7,
+ );
+ "ARCHS[sdk=iphoneos*]" = (
+ armv6,
+ armv7,
+ );
+ "ARCHS[sdk=iphonesimulator*]" = i386;
+ GCC_C_LANGUAGE_STANDARD = c99;
+ GCC_PREPROCESSOR_DEFINITIONS = "TI_VERSION=$(TI_VERSION)";
+ GCC_TREAT_WARNINGS_AS_ERRORS = NO;
+ GCC_VERSION = "";
+ GCC_WARN_ABOUT_RETURN_TYPE = NO;
+ GCC_WARN_MISSING_PARENTHESES = NO;
+ GCC_WARN_SHADOW = NO;
+ GCC_WARN_STRICT_SELECTOR_MATCH = NO;
+ GCC_WARN_UNUSED_FUNCTION = YES;
+ GCC_WARN_UNUSED_PARAMETER = NO;
+ GCC_WARN_UNUSED_VALUE = NO;
+ GCC_WARN_UNUSED_VARIABLE = NO;
+ GCC_MODEL_TUNING = G5;
+ GCC_PRECOMPILE_PREFIX_HEADER = YES;
+ GCC_PREFIX_HEADER = "ComMeeechPlist_Prefix.pch";
+ IPHONEOS_DEPLOYMENT_TARGET = 4.0;
+ OTHER_CFLAGS = "-DTI_POST_1_2";
+ OTHER_LDFLAGS = "-ObjC";
+ PROVISIONING_PROFILE = "";
+ "PROVISIONING_PROFILE[sdk=iphoneos*]" = "";
+ RUN_CLANG_STATIC_ANALYZER = NO;
+ SDKROOT = iphoneos;
+ USER_HEADER_SEARCH_PATHS = "";
+ ALWAYS_SEARCH_USER_PATHS = NO;
+ DSTROOT = "/tmp/ComMeeechPlist.dst";
+ INSTALL_PATH = /usr/local/lib;
+ PRODUCT_NAME = "ComMeeechPlist";
+ };
+ name = Release;
+ };
+ 1DEB922308733DC00010E9CD /* Debug */ = {
+ isa = XCBuildConfiguration;
+ baseConfigurationReference = 24DD6D1B1134B66800162E58 /* titanium.xcconfig */;
+ buildSettings = {
+ ARCHS = (
+ armv6,
+ armv7,
+ );
+ "ARCHS[sdk=iphoneos*]" = (
+ armv6,
+ armv7,
+ );
+ "ARCHS[sdk=iphonesimulator*]" = i386;
+ CODE_SIGN_IDENTITY = "iPhone Developer";
+ "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
+ GCC_C_LANGUAGE_STANDARD = c99;
+ GCC_PREPROCESSOR_DEFINITIONS = "TI_VERSION=$(TI_VERSION)";
+ GCC_TREAT_WARNINGS_AS_ERRORS = NO;
+ GCC_VERSION = "";
+ GCC_WARN_ABOUT_RETURN_TYPE = NO;
+ GCC_WARN_MISSING_PARENTHESES = NO;
+ GCC_WARN_SHADOW = NO;
+ GCC_WARN_STRICT_SELECTOR_MATCH = NO;
+ GCC_WARN_UNUSED_FUNCTION = YES;
+ GCC_WARN_UNUSED_PARAMETER = NO;
+ GCC_WARN_UNUSED_VALUE = NO;
+ GCC_WARN_UNUSED_VARIABLE = NO;
+ GCC_OPTIMIZATION_LEVEL = 0;
+ GCC_PRECOMPILE_PREFIX_HEADER = YES;
+ GCC_PREFIX_HEADER = "ComMeeechPlist_Prefix.pch";
+ OTHER_CFLAGS = (
+ "-DDEBUG",
+ "-DTI_POST_1_2",
+ );
+ OTHER_LDFLAGS = "-ObjC";
+ PROVISIONING_PROFILE = "";
+ "PROVISIONING_PROFILE[sdk=iphoneos*]" = "";
+ RUN_CLANG_STATIC_ANALYZER = NO;
+ SDKROOT = iphoneos;
+ USER_HEADER_SEARCH_PATHS = "";
+ DSTROOT = "/tmp/ComMeeechPlist.dst";
+ INSTALL_PATH = /usr/local/lib;
+ PRODUCT_NAME = "ComMeeechPlist";
+ };
+ name = Debug;
+ };
+ 1DEB922408733DC00010E9CD /* Release */ = {
+ isa = XCBuildConfiguration;
+ baseConfigurationReference = 24DD6D1B1134B66800162E58 /* titanium.xcconfig */;
+ buildSettings = {
+ ARCHS = (
+ armv6,
+ armv7,
+ );
+ "ARCHS[sdk=iphoneos*]" = (
+ armv6,
+ armv7,
+ );
+ "ARCHS[sdk=iphonesimulator*]" = i386;
+ GCC_C_LANGUAGE_STANDARD = c99;
+ GCC_PREPROCESSOR_DEFINITIONS = "TI_VERSION=$(TI_VERSION)";
+ GCC_TREAT_WARNINGS_AS_ERRORS = NO;
+ GCC_VERSION = "";
+ GCC_WARN_ABOUT_RETURN_TYPE = NO;
+ GCC_WARN_MISSING_PARENTHESES = NO;
+ GCC_WARN_SHADOW = NO;
+ GCC_WARN_STRICT_SELECTOR_MATCH = NO;
+ GCC_WARN_UNUSED_FUNCTION = YES;
+ GCC_WARN_UNUSED_PARAMETER = NO;
+ GCC_WARN_UNUSED_VALUE = NO;
+ GCC_WARN_UNUSED_VARIABLE = NO;
+ GCC_MODEL_TUNING = G5;
+ GCC_PRECOMPILE_PREFIX_HEADER = YES;
+ GCC_PREFIX_HEADER = "ComMeeechPlist_Prefix.pch";
+ IPHONEOS_DEPLOYMENT_TARGET = 4.0;
+ OTHER_CFLAGS = "-DTI_POST_1_2";
+ OTHER_LDFLAGS = "-ObjC";
+ PROVISIONING_PROFILE = "";
+ "PROVISIONING_PROFILE[sdk=iphoneos*]" = "";
+ RUN_CLANG_STATIC_ANALYZER = NO;
+ SDKROOT = iphoneos;
+ USER_HEADER_SEARCH_PATHS = "";
+ ALWAYS_SEARCH_USER_PATHS = NO;
+ DSTROOT = "/tmp/ComMeeechPlist.dst";
+ INSTALL_PATH = /usr/local/lib;
+ PRODUCT_NAME = "ComMeeechPlist";
+ };
+ name = Release;
+ };
+ 24416B8211C4CA220047AFDD /* Debug */ = {
+ isa = XCBuildConfiguration;
+ baseConfigurationReference = 24DD6D1B1134B66800162E58 /* titanium.xcconfig */;
+ buildSettings = {
+ COPY_PHASE_STRIP = NO;
+ GCC_DYNAMIC_NO_PIC = NO;
+ GCC_OPTIMIZATION_LEVEL = 0;
+ PRODUCT_NAME = "Build & test";
+ };
+ name = Debug;
+ };
+ 24416B8311C4CA220047AFDD /* Release */ = {
+ isa = XCBuildConfiguration;
+ baseConfigurationReference = 24DD6D1B1134B66800162E58 /* titanium.xcconfig */;
+ buildSettings = {
+ COPY_PHASE_STRIP = YES;
+ DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
+ GCC_ENABLE_FIX_AND_CONTINUE = NO;
+ PRODUCT_NAME = "Build & test";
+ ZERO_LINK = NO;
+ };
+ name = Release;
+ };
+/* End XCBuildConfiguration section */
+
+/* Begin XCConfigurationList section */
+ 1DEB921E08733DC00010E9CD /* Build configuration list for PBXNativeTarget "plist-module" */ = {
+ isa = XCConfigurationList;
+ buildConfigurations = (
+ 1DEB921F08733DC00010E9CD /* Debug */,
+ 1DEB922008733DC00010E9CD /* Release */,
+ );
+ defaultConfigurationIsVisible = 0;
+ defaultConfigurationName = Release;
+ };
+ 1DEB922208733DC00010E9CD /* Build configuration list for PBXProject "plist-module" */ = {
+ isa = XCConfigurationList;
+ buildConfigurations = (
+ 1DEB922308733DC00010E9CD /* Debug */,
+ 1DEB922408733DC00010E9CD /* Release */,
+ );
+ defaultConfigurationIsVisible = 0;
+ defaultConfigurationName = Release;
+ };
+ 24416B8A11C4CA520047AFDD /* Build configuration list for PBXAggregateTarget "Build & Test" */ = {
+ isa = XCConfigurationList;
+ buildConfigurations = (
+ 24416B8211C4CA220047AFDD /* Debug */,
+ 24416B8311C4CA220047AFDD /* Release */,
+ );
+ defaultConfigurationIsVisible = 0;
+ defaultConfigurationName = Release;
+ };
+/* End XCConfigurationList section */
+ };
+ rootObject = 0867D690FE84028FC02AAC07 /* Project object */;
+}
11 timodule.xml
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<ti:module xmlns:ti="http://ti.appcelerator.org" xmlns:android="http://schemas.android.com/apk/res/android">
+ <!--
+ Similar to tiapp.xml, but contains module/platform specific
+ configuration in <iphone> and <android> sections
+ -->
+ <iphone>
+ </iphone>
+ <android xmlns:android="http://schemas.android.com/apk/res/android">
+ </android>
+</ti:module>
19 titanium.xcconfig
@@ -0,0 +1,19 @@
+//
+//
+// CHANGE THESE VALUES TO REFLECT THE VERSION (AND LOCATION IF DIFFERENT)
+// OF YOUR TITANIUM SDK YOU'RE BUILDING FOR
+//
+//
+TITANIUM_SDK_VERSION = 1.8.2
+
+
+//
+// THESE SHOULD BE OK GENERALLY AS-IS
+//
+TITANIUM_SDK = /Library/Application Support/Titanium/mobilesdk/osx/$(TITANIUM_SDK_VERSION)
+TITANIUM_BASE_SDK = "$(TITANIUM_SDK)/iphone/include"
+TITANIUM_BASE_SDK2 = "$(TITANIUM_SDK)/iphone/include/TiCore"
+HEADER_SEARCH_PATHS= $(TITANIUM_BASE_SDK) $(TITANIUM_BASE_SDK2)
+
+
+

0 comments on commit 62baebd

Please sign in to comment.