Browse Source

Remove/replace/update deprecated calls

The deprecated calls have been updated and the "print" calls have been removed. These were for debug purposes but you can debug using `DLog(@"%@", object)` just as well. All tests succeed on OS X as well as iOS.
Pascal Pfiffner 10 years ago
parent
commit
5b082cfd8f

+ 0 - 1
Classes/RedlandModel.h

@@ -47,7 +47,6 @@
 
 - (librdf_model *)wrappedModel;
 
-- (void)print;
 - (int)size;
 - (void)sync;
 

+ 0 - 8
Classes/RedlandModel.m

@@ -94,14 +94,6 @@
 	return [[RedlandStorage alloc] initWithWrappedObject:storage owner:NO];
 }
 
-/**
- *  Dumps the contents of the receiver to standard error (for debugging purposes).
- */
-- (void)print
-{
-	librdf_model_print(wrappedObject, stderr);
-}
-
 /**
  *  Synchronises the model to the model implementation.
  */

+ 16 - 15
Classes/RedlandNode.m

@@ -263,24 +263,25 @@
 
 - (NSString *)description
 {
-	NSString *desc = nil;
-	char *outString;
-	size_t length;
-	raptor_world *world = raptor_new_world();
-	raptor_iostream *stream = raptor_new_iostream_to_string(world, (void **)&outString, &length, NULL);
-	if (0 == librdf_node_write(wrappedObject, stream) && length > 0) {
-		DLog(@"--->  %s", outString);
-		desc = [NSString stringWithCString:(const char *)outString encoding:NSUTF8StringEncoding];
-	}
-	else {
-		DLog(@"xxx>  FAILED to write to librdf_node");
-		desc = [super description];
-	}
+	librdf_node *node = wrappedObject;
+	unsigned char *outString;
 	
+	// write to a stream
+	raptor_iostream *stream = raptor_new_iostream_to_string(node->world, (void**)&outString, NULL, malloc);
+	int ret = librdf_node_write(node, stream);
 	raptor_free_iostream(stream);
-	raptor_free_world(world);
+	if (0 != ret) {
+		raptor_free_memory(outString);
+		outString = NULL;
+	}
+	
+	// return as NSString
+	if (outString) {
+		return [NSString stringWithCString:(const char *)outString encoding:NSUTF8StringEncoding];
+	}
 	
-	return desc;
+	DLog(@"xxx>  FAILED to write to librdf_node, node type: %d", node->type);
+	return [super description];
 }
 
 

+ 1 - 1
Classes/RedlandQueryResults.m

@@ -181,7 +181,7 @@ RedlandURI * RedlandSPARQLVariableBindingResultsXMLFormat = nil;
 	NSParameterAssert(formatURI != nil);
 	
 	size_t output_size;
-	unsigned char *output = librdf_query_results_to_counted_string(wrappedObject, [formatURI wrappedURI], [baseURI wrappedURI], &output_size);
+	unsigned char *output = librdf_query_results_to_counted_string2(wrappedObject, NULL, NULL, [formatURI wrappedURI], [baseURI wrappedURI], &output_size);
 	if (output != NULL) {
 		return [[NSString alloc] initWithBytesNoCopy:output length:output_size encoding:NSUTF8StringEncoding freeWhenDone:YES];
 	}

+ 0 - 2
Classes/RedlandStatement.h

@@ -53,7 +53,5 @@
 - (BOOL)matchesPartialStatement:(RedlandStatement *)aStatement;
 - (BOOL)isComplete;
 
-- (void)print;
-
 
 @end

+ 19 - 11
Classes/RedlandStatement.m

@@ -247,17 +247,25 @@
 #pragma mark - Descriptions
 - (NSString *)description
 {
-	unsigned char *statement_string = librdf_statement_to_string(wrappedObject);
-	return [[NSString alloc] initWithBytesNoCopy:statement_string length:strlen((char *)statement_string) encoding:NSUTF8StringEncoding freeWhenDone:YES];
-}
-
-/**
- *  Prints a description of the receiver to standard error.
- *  @warning For debugging purposes.
- */
-- (void)print
-{
-	librdf_statement_print(wrappedObject, stderr);
+	librdf_statement *stmt = wrappedObject;
+	unsigned char *outString;
+	
+	// write to a stream
+	raptor_iostream *stream = raptor_new_iostream_to_string(stmt->world, (void**)&outString, NULL, malloc);
+	int ret = librdf_statement_write(stmt, stream);
+	raptor_free_iostream(stream);
+	if (0 != ret) {
+		raptor_free_memory(outString);
+		outString = NULL;
+	}
+	
+	// return as NSString
+	if (outString) {
+		return [NSString stringWithCString:(const char *)outString encoding:NSUTF8StringEncoding];
+	}
+	
+	DLog(@"xxx>  FAILED to write to librdf_statement");
+	return [super description];
 }
 
 

+ 0 - 2
Classes/RedlandStream.h

@@ -48,8 +48,6 @@
 - (RedlandStatement *)object;
 - (RedlandNode *)context;
 
-- (void)print;
-
 - (RedlandStreamEnumerator *)statementEnumerator;
 
 

+ 0 - 9
Classes/RedlandStream.m

@@ -88,15 +88,6 @@
 
 
 #pragma mark - Utilities
-/**
- *  Prints out the stream to standard error.
-	For debugging purposes.
- */
-- (void)print
-{
-	librdf_stream_print(wrappedObject, stderr);
-}
-
 /**
  *  Returns a RedlandStreamEnumerator for the receiver.
 	It is recommended that you use this enumerator interface instead of accessing the stream directly.

+ 4 - 6
README.md

@@ -1,12 +1,10 @@
-    The project is heavily WIP!
-    
     STATUS:
     [x]  C libraries cross-compile successfully (armv6, armv7)
     [x]  Mac build succeeds
     [x]  Mac unit tests succeed
     [x]  iOS build succeeds
-    [~]  iOS unit tests succeed (1 exception remaining)
-    [ ]  Deprecated librdf calls have been replaced
+    [x]  iOS unit tests succeed
+    [x]  Deprecated librdf calls have been replaced
     [ ]  Mac framework has been used in a sample application
     [x]  iOS framework has been used in a sample app
 
@@ -20,10 +18,10 @@ This projects is a resurrection of Rene Puls' Objective-C wrapper for the [Redla
 Building the C libraries
 ------------------------
 
-There is a Python-script that downloads and (cross-)compiles [raptor2], [rasqal] and [librdf][redland], the components you need. The script needs you to have Xcode 4.4 or 4.5 and the iOS SDK 5.1 installed, and make sure you install the command line tools from within Xcode. Then just choose the **Build C Library** target and hit **Run**. Alternatively, open the Terminal and execute the script manually:
+There is a Python-script that downloads and (cross-)compiles [raptor2], [rasqal] and [librdf][redland], the components you need. The script needs you to have Xcode 4.4 or 4.5 and the iOS SDK 5.1 or later installed, and make sure you install the command line tools from within Xcode. Then just choose the **Redland C Library** target and hit **Run**. Alternatively, open the Terminal and execute the script manually:
 
     $ cd Redland-ObjC/Redland-source
-    $ ./redland.py
+    $ ./cross-compile.py
 
 Compiling requires `pkg-config` which you can most easily install via [Homebrew][]:
 

+ 39 - 37
Redland.xcodeproj/project.pbxproj

@@ -111,6 +111,17 @@
 		EDBA0E4907379BDD00610CB1 /* NOTICE.txt in Resources */ = {isa = PBXBuildFile; fileRef = EDBA0E4807379BDD00610CB1 /* NOTICE.txt */; };
 		EDBA0EB20737A89A00610CB1 /* LICENSE.txt in Resources */ = {isa = PBXBuildFile; fileRef = ED98645906FAF0D8009186B3 /* LICENSE.txt */; };
 		EE0CB64315BE4BF3004BB6C9 /* redland.h in Headers */ = {isa = PBXBuildFile; fileRef = EE0CB63A15BE4AF7004BB6C9 /* redland.h */; settings = {ATTRIBUTES = (Public, ); }; };
+		EE205F241602910A0020752E /* WorldTests.m in Sources */ = {isa = PBXBuildFile; fileRef = ED69A43B06F9E54B00A624F7 /* WorldTests.m */; };
+		EE205F251602910A0020752E /* URITests.m in Sources */ = {isa = PBXBuildFile; fileRef = ED69A3C106F9DCBA00A624F7 /* URITests.m */; };
+		EE205F261602910A0020752E /* NodeTests.m in Sources */ = {isa = PBXBuildFile; fileRef = ED69A49406F9EAF700A624F7 /* NodeTests.m */; };
+		EE205F271602910A0020752E /* StatementTests.m in Sources */ = {isa = PBXBuildFile; fileRef = ED69A5A306FA1ADA00A624F7 /* StatementTests.m */; };
+		EE205F281602910A0020752E /* StorageTests.m in Sources */ = {isa = PBXBuildFile; fileRef = ED69A67006FA28D400A624F7 /* StorageTests.m */; };
+		EE205F291602910A0020752E /* ModelTests.m in Sources */ = {isa = PBXBuildFile; fileRef = ED98630406FAE443009186B3 /* ModelTests.m */; };
+		EE205F2A1602910A0020752E /* ParserTests.m in Sources */ = {isa = PBXBuildFile; fileRef = ED9863F606FAEA05009186B3 /* ParserTests.m */; };
+		EE205F2B1602910A0020752E /* SerializerTests.m in Sources */ = {isa = PBXBuildFile; fileRef = ED98643906FAF064009186B3 /* SerializerTests.m */; };
+		EE205F2C1602910A0020752E /* QueryTests.m in Sources */ = {isa = PBXBuildFile; fileRef = ED98651B06FB12E6009186B3 /* QueryTests.m */; };
+		EE205F2D1602910A0020752E /* NamespaceTests.m in Sources */ = {isa = PBXBuildFile; fileRef = ED69A52B06F9F35E00A624F7 /* NamespaceTests.m */; };
+		EE205F2E1602917C0020752E /* libredland-ios.a in Frameworks */ = {isa = PBXBuildFile; fileRef = EEE7B44E15C84978004D5A68 /* libredland-ios.a */; };
 		EE5144EE15DAEF1400DA9BA2 /* RedlandModel.h in Headers */ = {isa = PBXBuildFile; fileRef = ED8D25D10688A7DF0039DA12 /* RedlandModel.h */; settings = {ATTRIBUTES = (Public, ); }; };
 		EE5144F015DAEFD400DA9BA2 /* RedlandWrappedObject.h in Headers */ = {isa = PBXBuildFile; fileRef = ED699ECF06F9D3D600A624F7 /* RedlandWrappedObject.h */; settings = {ATTRIBUTES = (Public, ); }; };
 		EE5144F115DAEFD400DA9BA2 /* RedlandWorld.h in Headers */ = {isa = PBXBuildFile; fileRef = ED8D24900688A22D0039DA12 /* RedlandWorld.h */; settings = {ATTRIBUTES = (Public, ); }; };
@@ -198,16 +209,6 @@
 		EEE7B48A15C849B3004D5A68 /* RedlandIteratorEnumerator.m in Sources */ = {isa = PBXBuildFile; fileRef = EDB09D2B0688D50F0071464A /* RedlandIteratorEnumerator.m */; };
 		EEE7B48B15C849B3004D5A68 /* RedlandQueryResultsEnumerator.m in Sources */ = {isa = PBXBuildFile; fileRef = ED486DF506DA80D500AA6058 /* RedlandQueryResultsEnumerator.m */; };
 		EEE7B48C15C849B3004D5A68 /* RedlandNamespace.m in Sources */ = {isa = PBXBuildFile; fileRef = EDAC63820694506E007A085A /* RedlandNamespace.m */; };
-		EEE7B48D15C849BA004D5A68 /* WorldTests.m in Sources */ = {isa = PBXBuildFile; fileRef = ED69A43B06F9E54B00A624F7 /* WorldTests.m */; };
-		EEE7B48E15C849BA004D5A68 /* URITests.m in Sources */ = {isa = PBXBuildFile; fileRef = ED69A3C106F9DCBA00A624F7 /* URITests.m */; };
-		EEE7B48F15C849BA004D5A68 /* NodeTests.m in Sources */ = {isa = PBXBuildFile; fileRef = ED69A49406F9EAF700A624F7 /* NodeTests.m */; };
-		EEE7B49015C849BA004D5A68 /* StatementTests.m in Sources */ = {isa = PBXBuildFile; fileRef = ED69A5A306FA1ADA00A624F7 /* StatementTests.m */; };
-		EEE7B49115C849BA004D5A68 /* StorageTests.m in Sources */ = {isa = PBXBuildFile; fileRef = ED69A67006FA28D400A624F7 /* StorageTests.m */; };
-		EEE7B49215C849BA004D5A68 /* ModelTests.m in Sources */ = {isa = PBXBuildFile; fileRef = ED98630406FAE443009186B3 /* ModelTests.m */; };
-		EEE7B49315C849BA004D5A68 /* ParserTests.m in Sources */ = {isa = PBXBuildFile; fileRef = ED9863F606FAEA05009186B3 /* ParserTests.m */; };
-		EEE7B49415C849BA004D5A68 /* SerializerTests.m in Sources */ = {isa = PBXBuildFile; fileRef = ED98643906FAF064009186B3 /* SerializerTests.m */; };
-		EEE7B49515C849BA004D5A68 /* QueryTests.m in Sources */ = {isa = PBXBuildFile; fileRef = ED98651B06FB12E6009186B3 /* QueryTests.m */; };
-		EEE7B49615C849BA004D5A68 /* NamespaceTests.m in Sources */ = {isa = PBXBuildFile; fileRef = ED69A52B06F9F35E00A624F7 /* NamespaceTests.m */; };
 		EEE7B49D15C84F61004D5A68 /* redland.h in Headers */ = {isa = PBXBuildFile; fileRef = EE0CB66315BE5CC1004BB6C9 /* redland.h */; settings = {ATTRIBUTES = (Public, ); }; };
 		EEE7B49E15C84F63004D5A68 /* librdf.h in Headers */ = {isa = PBXBuildFile; fileRef = EE0CB64A15BE5CC1004BB6C9 /* librdf.h */; settings = {ATTRIBUTES = (Public, ); }; };
 		EEE7B49F15C84F6A004D5A68 /* raptor.h in Headers */ = {isa = PBXBuildFile; fileRef = EE0CB64C15BE5CC1004BB6C9 /* raptor.h */; settings = {ATTRIBUTES = (Public, ); }; };
@@ -233,7 +234,6 @@
 		EEE7B4B315C84F86004D5A68 /* rdf_uri.h in Headers */ = {isa = PBXBuildFile; fileRef = EE0CB66115BE5CC1004BB6C9 /* rdf_uri.h */; settings = {ATTRIBUTES = (Public, ); }; };
 		EEE7B4B415C84F86004D5A68 /* rdf_utf8.h in Headers */ = {isa = PBXBuildFile; fileRef = EE0CB66215BE5CC1004BB6C9 /* rdf_utf8.h */; settings = {ATTRIBUTES = (Public, ); }; };
 		EEE7B4B615C85A2E004D5A68 /* SenTestingKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = ED48EB8108BB596300ACF14F /* SenTestingKit.framework */; };
-		EEE7B4B715C85C98004D5A68 /* libredland-ios.a in Frameworks */ = {isa = PBXBuildFile; fileRef = EEE7B44E15C84978004D5A68 /* libredland-ios.a */; };
 /* End PBXBuildFile section */
 
 /* Begin PBXContainerItemProxy section */
@@ -441,6 +441,7 @@
 		EE0CB66315BE5CC1004BB6C9 /* redland.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = redland.h; sourceTree = "<group>"; };
 		EE1DDDF215BEDCC700882BDA /* README.md */ = {isa = PBXFileReference; lastKnownFileType = text; path = README.md; sourceTree = "<group>"; };
 		EE1DDDF315BEDF0400882BDA /* pp-configure.sh */ = {isa = PBXFileReference; lastKnownFileType = text.script.sh; name = "pp-configure.sh"; path = "Mac/pp-configure.sh"; sourceTree = "<group>"; };
+		EE205F2F160291DD0020752E /* Tests-iOS-Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = "Tests-iOS-Info.plist"; sourceTree = "<group>"; };
 		EE555EE215C873B000F26A1A /* libz.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libz.dylib; path = Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS6.0.sdk/usr/lib/libz.dylib; sourceTree = DEVELOPER_DIR; };
 		EE7DF2C615ED5C9C00D328C1 /* cross-compile-config.py */ = {isa = PBXFileReference; lastKnownFileType = text.script.python; path = "cross-compile-config.py"; sourceTree = "<group>"; };
 		EEC146EC15DECDE6006B8798 /* AppledocSettings.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = AppledocSettings.plist; sourceTree = "<group>"; };
@@ -451,7 +452,7 @@
 		EEDE81B815BF375F00AC2B64 /* librasqal.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; path = librasqal.dylib; sourceTree = "<group>"; };
 		EEDE81B915BF375F00AC2B64 /* librdf.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; path = librdf.dylib; sourceTree = "<group>"; };
 		EEE7B44E15C84978004D5A68 /* libredland-ios.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libredland-ios.a"; sourceTree = BUILT_PRODUCTS_DIR; };
-		EEE7B45E15C84978004D5A68 /* Tests iOS.octest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; name = "Tests iOS.octest"; path = "Redland Tests iOS.octest"; sourceTree = BUILT_PRODUCTS_DIR; };
+		EEE7B45E15C84978004D5A68 /* Tests-iOS.octest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = "Tests-iOS.octest"; sourceTree = BUILT_PRODUCTS_DIR; };
 /* End PBXFileReference section */
 
 /* Begin PBXFrameworksBuildPhase section */
@@ -501,7 +502,7 @@
 			buildActionMask = 2147483647;
 			files = (
 				EE555EE315C873B000F26A1A /* libz.dylib in Frameworks */,
-				EEE7B4B715C85C98004D5A68 /* libredland-ios.a in Frameworks */,
+				EE205F2E1602917C0020752E /* libredland-ios.a in Frameworks */,
 				EEE7B4B615C85A2E004D5A68 /* SenTestingKit.framework in Frameworks */,
 				EEC9C56815CB051200B7C568 /* libraptor2.a in Frameworks */,
 				EEC9C56915CB051500B7C568 /* librasqal.a in Frameworks */,
@@ -521,7 +522,7 @@
 				ED8214C707397B78001CC6CB /* RedlandDocumentation */,
 				ED48EB5008BB557A00ACF14F /* Tests.octest */,
 				EEE7B44E15C84978004D5A68 /* libredland-ios.a */,
-				EEE7B45E15C84978004D5A68 /* Tests iOS.octest */,
+				EEE7B45E15C84978004D5A68 /* Tests-iOS.octest */,
 			);
 			name = Products;
 			sourceTree = "<group>";
@@ -533,7 +534,6 @@
 				EDF2FEA9071FE41900B18942 /* ChangeLog.txt */,
 				ED98645906FAF0D8009186B3 /* LICENSE.txt */,
 				EDBA0E4807379BDD00610CB1 /* NOTICE.txt */,
-				EEC146EC15DECDE6006B8798 /* AppledocSettings.plist */,
 				ED699E3406F9CBBF00A624F7 /* Basic Wrapper Classes */,
 				08FB77AEFE84172EC02AAC07 /* Additional Classes */,
 				ED69A3BB06F9DCA400A624F7 /* Tests */,
@@ -569,7 +569,9 @@
 				ED98662B06FB3D05009186B3 /* rdf-schema.rdf */,
 				8DC2EF5A0486A6940098B216 /* Info.plist */,
 				ED48EB4208BB554300ACF14F /* Tests-Info.plist */,
+				EE205F2F160291DD0020752E /* Tests-iOS-Info.plist */,
 				089C1666FE841158C02AAC07 /* InfoPlist.strings */,
+				EEC146EC15DECDE6006B8798 /* AppledocSettings.plist */,
 			);
 			name = Resources;
 			sourceTree = SOURCE_ROOT;
@@ -999,9 +1001,9 @@
 			productReference = EEE7B44E15C84978004D5A68 /* libredland-ios.a */;
 			productType = "com.apple.product-type.library.static";
 		};
-		EEE7B45D15C84978004D5A68 /* Redland Tests iOS */ = {
+		EEE7B45D15C84978004D5A68 /* Tests-iOS */ = {
 			isa = PBXNativeTarget;
-			buildConfigurationList = EEE7B47715C84979004D5A68 /* Build configuration list for PBXNativeTarget "Redland Tests iOS" */;
+			buildConfigurationList = EEE7B47715C84979004D5A68 /* Build configuration list for PBXNativeTarget "Tests-iOS" */;
 			buildPhases = (
 				EEE7B45B15C84978004D5A68 /* Resources */,
 				EEE7B45915C84978004D5A68 /* Sources */,
@@ -1013,9 +1015,9 @@
 			dependencies = (
 				EEE7B46515C84979004D5A68 /* PBXTargetDependency */,
 			);
-			name = "Redland Tests iOS";
+			name = "Tests-iOS";
 			productName = "redland-iosTests";
-			productReference = EEE7B45E15C84978004D5A68 /* Tests iOS.octest */;
+			productReference = EEE7B45E15C84978004D5A68 /* Tests-iOS.octest */;
 			productType = "com.apple.product-type.bundle";
 		};
 /* End PBXNativeTarget section */
@@ -1041,7 +1043,7 @@
 				8DC2EF4F0486A6940098B216 /* Redland */,
 				ED48EB4F08BB557A00ACF14F /* Tests */,
 				EEE7B44D15C84978004D5A68 /* redland-ios */,
-				EEE7B45D15C84978004D5A68 /* Redland Tests iOS */,
+				EEE7B45D15C84978004D5A68 /* Tests-iOS */,
 				EDEDCDFA07397483006DB0D1 /* Redland Documentation */,
 				ED8215FE07397F4A001CC6CB /* Release */,
 				EE1DDDEC15BED96100882BDA /* Redland C Library */,
@@ -1211,16 +1213,16 @@
 			isa = PBXSourcesBuildPhase;
 			buildActionMask = 2147483647;
 			files = (
-				EEE7B48D15C849BA004D5A68 /* WorldTests.m in Sources */,
-				EEE7B48E15C849BA004D5A68 /* URITests.m in Sources */,
-				EEE7B48F15C849BA004D5A68 /* NodeTests.m in Sources */,
-				EEE7B49015C849BA004D5A68 /* StatementTests.m in Sources */,
-				EEE7B49115C849BA004D5A68 /* StorageTests.m in Sources */,
-				EEE7B49215C849BA004D5A68 /* ModelTests.m in Sources */,
-				EEE7B49315C849BA004D5A68 /* ParserTests.m in Sources */,
-				EEE7B49415C849BA004D5A68 /* SerializerTests.m in Sources */,
-				EEE7B49515C849BA004D5A68 /* QueryTests.m in Sources */,
-				EEE7B49615C849BA004D5A68 /* NamespaceTests.m in Sources */,
+				EE205F241602910A0020752E /* WorldTests.m in Sources */,
+				EE205F251602910A0020752E /* URITests.m in Sources */,
+				EE205F261602910A0020752E /* NodeTests.m in Sources */,
+				EE205F271602910A0020752E /* StatementTests.m in Sources */,
+				EE205F281602910A0020752E /* StorageTests.m in Sources */,
+				EE205F291602910A0020752E /* ModelTests.m in Sources */,
+				EE205F2A1602910A0020752E /* ParserTests.m in Sources */,
+				EE205F2B1602910A0020752E /* SerializerTests.m in Sources */,
+				EE205F2C1602910A0020752E /* QueryTests.m in Sources */,
+				EE205F2D1602910A0020752E /* NamespaceTests.m in Sources */,
 			);
 			runOnlyForDeploymentPostprocessing = 0;
 		};
@@ -1762,7 +1764,7 @@
 				GCC_DYNAMIC_NO_PIC = NO;
 				GCC_OPTIMIZATION_LEVEL = 0;
 				GCC_PRECOMPILE_PREFIX_HEADER = YES;
-				GCC_PREFIX_HEADER = "redland-ios/redland-ios-Prefix.pch";
+				GCC_PREFIX_HEADER = Redland_Prefix.pch;
 				GCC_PREPROCESSOR_DEFINITIONS = (
 					"DEBUG=1",
 					"$(inherited)",
@@ -1771,7 +1773,7 @@
 				GCC_WARN_ABOUT_RETURN_TYPE = YES;
 				GCC_WARN_UNINITIALIZED_AUTOS = YES;
 				GCC_WARN_UNUSED_VARIABLE = YES;
-				INFOPLIST_FILE = "redland-iosTests/redland-iosTests-Info.plist";
+				INFOPLIST_FILE = "Tests-iOS-Info.plist";
 				IPHONEOS_DEPLOYMENT_TARGET = 6.0;
 				LIBRARY_SEARCH_PATHS = "$(SRCROOT)/Redland-source/Universal/";
 				OTHER_LDFLAGS = "-ObjC";
@@ -1798,7 +1800,7 @@
 				GCC_DYNAMIC_NO_PIC = NO;
 				GCC_OPTIMIZATION_LEVEL = 0;
 				GCC_PRECOMPILE_PREFIX_HEADER = YES;
-				GCC_PREFIX_HEADER = "redland-ios/redland-ios-Prefix.pch";
+				GCC_PREFIX_HEADER = Redland_Prefix.pch;
 				GCC_PREPROCESSOR_DEFINITIONS = (
 					"DEBUG=1",
 					"$(inherited)",
@@ -1807,7 +1809,7 @@
 				GCC_WARN_ABOUT_RETURN_TYPE = YES;
 				GCC_WARN_UNINITIALIZED_AUTOS = YES;
 				GCC_WARN_UNUSED_VARIABLE = YES;
-				INFOPLIST_FILE = "redland-iosTests/redland-iosTests-Info.plist";
+				INFOPLIST_FILE = "Tests-iOS-Info.plist";
 				IPHONEOS_DEPLOYMENT_TARGET = 6.0;
 				LIBRARY_SEARCH_PATHS = "$(SRCROOT)/Redland-source/Universal/";
 				OTHER_LDFLAGS = "-ObjC";
@@ -1832,11 +1834,11 @@
 				);
 				GCC_C_LANGUAGE_STANDARD = gnu99;
 				GCC_PRECOMPILE_PREFIX_HEADER = YES;
-				GCC_PREFIX_HEADER = "redland-ios/redland-ios-Prefix.pch";
+				GCC_PREFIX_HEADER = Redland_Prefix.pch;
 				GCC_WARN_ABOUT_RETURN_TYPE = YES;
 				GCC_WARN_UNINITIALIZED_AUTOS = YES;
 				GCC_WARN_UNUSED_VARIABLE = YES;
-				INFOPLIST_FILE = "redland-iosTests/redland-iosTests-Info.plist";
+				INFOPLIST_FILE = "Tests-iOS-Info.plist";
 				IPHONEOS_DEPLOYMENT_TARGET = 6.0;
 				LIBRARY_SEARCH_PATHS = "$(SRCROOT)/Redland-source/Universal/";
 				OTHER_LDFLAGS = "-ObjC";
@@ -1920,7 +1922,7 @@
 			defaultConfigurationIsVisible = 0;
 			defaultConfigurationName = Development;
 		};
-		EEE7B47715C84979004D5A68 /* Build configuration list for PBXNativeTarget "Redland Tests iOS" */ = {
+		EEE7B47715C84979004D5A68 /* Build configuration list for PBXNativeTarget "Tests-iOS" */ = {
 			isa = XCConfigurationList;
 			buildConfigurations = (
 				EEE7B47315C84979004D5A68 /* Development */,

+ 0 - 0
Redland.xcodeproj/xcshareddata/xcschemes/C Library.xcscheme → Redland.xcodeproj/xcshareddata/xcschemes/Redland C Library.xcscheme


+ 59 - 0
Redland.xcodeproj/xcshareddata/xcschemes/Redland Documentation.xcscheme

@@ -0,0 +1,59 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<Scheme
+   LastUpgradeVersion = "0440"
+   version = "1.3">
+   <BuildAction
+      parallelizeBuildables = "YES"
+      buildImplicitDependencies = "YES">
+      <BuildActionEntries>
+         <BuildActionEntry
+            buildForTesting = "YES"
+            buildForRunning = "YES"
+            buildForProfiling = "YES"
+            buildForArchiving = "YES"
+            buildForAnalyzing = "YES">
+            <BuildableReference
+               BuildableIdentifier = "primary"
+               BlueprintIdentifier = "EDEDCDFA07397483006DB0D1"
+               BuildableName = "Redland Documentation"
+               BlueprintName = "Redland Documentation"
+               ReferencedContainer = "container:Redland.xcodeproj">
+            </BuildableReference>
+         </BuildActionEntry>
+      </BuildActionEntries>
+   </BuildAction>
+   <TestAction
+      selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
+      selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
+      shouldUseLaunchSchemeArgsEnv = "YES"
+      buildConfiguration = "Debug">
+      <Testables>
+      </Testables>
+   </TestAction>
+   <LaunchAction
+      selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
+      selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
+      launchStyle = "0"
+      useCustomWorkingDirectory = "NO"
+      buildConfiguration = "Debug"
+      ignoresPersistentStateOnLaunch = "NO"
+      debugDocumentVersioning = "YES"
+      allowLocationSimulation = "YES">
+      <AdditionalOptions>
+      </AdditionalOptions>
+   </LaunchAction>
+   <ProfileAction
+      shouldUseLaunchSchemeArgsEnv = "YES"
+      savedToolIdentifier = ""
+      useCustomWorkingDirectory = "NO"
+      buildConfiguration = "Deployment"
+      debugDocumentVersioning = "YES">
+   </ProfileAction>
+   <AnalyzeAction
+      buildConfiguration = "Debug">
+   </AnalyzeAction>
+   <ArchiveAction
+      buildConfiguration = "Deployment"
+      revealArchiveInOrganizer = "YES">
+   </ArchiveAction>
+</Scheme>

+ 69 - 0
Redland.xcodeproj/xcshareddata/xcschemes/Redland.xcscheme

@@ -0,0 +1,69 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<Scheme
+   LastUpgradeVersion = "0440"
+   version = "1.3">
+   <BuildAction
+      parallelizeBuildables = "YES"
+      buildImplicitDependencies = "YES">
+      <BuildActionEntries>
+         <BuildActionEntry
+            buildForTesting = "YES"
+            buildForRunning = "YES"
+            buildForProfiling = "YES"
+            buildForArchiving = "YES"
+            buildForAnalyzing = "YES">
+            <BuildableReference
+               BuildableIdentifier = "primary"
+               BlueprintIdentifier = "8DC2EF4F0486A6940098B216"
+               BuildableName = "Redland.framework"
+               BlueprintName = "Redland"
+               ReferencedContainer = "container:Redland.xcodeproj">
+            </BuildableReference>
+         </BuildActionEntry>
+      </BuildActionEntries>
+   </BuildAction>
+   <TestAction
+      selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
+      selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
+      shouldUseLaunchSchemeArgsEnv = "YES"
+      buildConfiguration = "Debug">
+      <Testables>
+         <TestableReference
+            skipped = "NO">
+            <BuildableReference
+               BuildableIdentifier = "primary"
+               BlueprintIdentifier = "ED48EB4F08BB557A00ACF14F"
+               BuildableName = "Tests.octest"
+               BlueprintName = "Tests"
+               ReferencedContainer = "container:Redland.xcodeproj">
+            </BuildableReference>
+         </TestableReference>
+      </Testables>
+   </TestAction>
+   <LaunchAction
+      selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
+      selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
+      launchStyle = "0"
+      useCustomWorkingDirectory = "NO"
+      buildConfiguration = "Debug"
+      ignoresPersistentStateOnLaunch = "NO"
+      debugDocumentVersioning = "YES"
+      allowLocationSimulation = "YES">
+      <AdditionalOptions>
+      </AdditionalOptions>
+   </LaunchAction>
+   <ProfileAction
+      shouldUseLaunchSchemeArgsEnv = "YES"
+      savedToolIdentifier = ""
+      useCustomWorkingDirectory = "NO"
+      buildConfiguration = "Deployment"
+      debugDocumentVersioning = "YES">
+   </ProfileAction>
+   <AnalyzeAction
+      buildConfiguration = "Debug">
+   </AnalyzeAction>
+   <ArchiveAction
+      buildConfiguration = "Deployment"
+      revealArchiveInOrganizer = "YES">
+   </ArchiveAction>
+</Scheme>

+ 7 - 3
Redland.xcodeproj/xcshareddata/xcschemes/redland-ios.xcscheme

@@ -1,7 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <Scheme
    LastUpgradeVersion = "0440"
-   version = "1.3">
+   version = "1.7">
    <BuildAction
       parallelizeBuildables = "YES"
       buildImplicitDependencies = "YES">
@@ -33,10 +33,14 @@
             <BuildableReference
                BuildableIdentifier = "primary"
                BlueprintIdentifier = "EEE7B45D15C84978004D5A68"
-               BuildableName = "Redland Tests iOS.octest"
-               BlueprintName = "Redland Tests iOS"
+               BuildableName = "Tests-iOS.octest"
+               BlueprintName = "Tests-iOS"
                ReferencedContainer = "container:Redland.xcodeproj">
             </BuildableReference>
+            <LocationScenarioReference
+               identifier = "com.apple.dt.IDEFoundation.CurrentLocationScenarioIdentifier"
+               referenceType = "1">
+            </LocationScenarioReference>
          </TestableReference>
       </Testables>
    </TestAction>

+ 2 - 2
Tests-Info.plist

@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
 <plist version="1.0">
 <dict>
 	<key>CFBundleDevelopmentRegion</key>
@@ -7,7 +7,7 @@
 	<key>CFBundleExecutable</key>
 	<string>Tests</string>
 	<key>CFBundleIdentifier</key>
-	<string>com.yourcompany.Tests</string>
+	<string>com.github.p2.redland-tests</string>
 	<key>CFBundleInfoDictionaryVersion</key>
 	<string>6.0</string>
 	<key>CFBundlePackageType</key>

+ 20 - 0
Tests-iOS-Info.plist

@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+<dict>
+	<key>CFBundleDevelopmentRegion</key>
+	<string>English</string>
+	<key>CFBundleExecutable</key>
+	<string>Tests-iOS</string>
+	<key>CFBundleIdentifier</key>
+	<string>com.github.p2.redland-ios-tests</string>
+	<key>CFBundleInfoDictionaryVersion</key>
+	<string>6.0</string>
+	<key>CFBundlePackageType</key>
+	<string>APPL</string>
+	<key>CFBundleSignature</key>
+	<string>????</string>
+	<key>CFBundleVersion</key>
+	<string>1.0</string>
+</dict>
+</plist>

+ 0 - 5
Tests/ParserTests.m

@@ -95,15 +95,10 @@ static NSString * const RDFXMLTestDataLocation = @"http://www.w3.org/1999/02/22-
 
 - (void)testParseError
 {
-	// librdf_parser_parse_string_as_stream crashes on iPhone Simulator??
-#if TARGET_IPHONE_SIMULATOR
-#warning Check why this crashes on iPhone Simulator
-#else
 	NSString *string = @"This is NOT RDF/XML.";
 	RedlandParser *parser = [RedlandParser parserWithName:RedlandRDFXMLParserName];
 	
 	STAssertThrowsSpecific([parser parseString:string asStreamWithBaseURI:[RedlandURI URIWithString:@"http://foo/"]], RedlandException, nil);
-#endif
 }
 
 - (void)testSetFeature