ObjFW  Check-in [e5d2a616de]

Overview
Comment:Merge branch 'master' into runtime
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | runtime
Files: files | file ages | folders
SHA3-256: e5d2a616dec62cbec91dc4a5e24b90c0bdf822beba6958ebdec594e0f1233997
User & Date: js on 2012-04-21 10:35:43
Other Links: branch diff | manifest | tags
Context
2012-04-21
10:56
Remove useless thread-checking. check-in: 555445ce0a user: js tags: runtime
10:35
Merge branch 'master' into runtime check-in: e5d2a616de user: js tags: runtime
10:30
Use __objc_yes and __objc_no if available. check-in: e571ecccc0 user: js tags: trunk
2012-04-20
19:02
Don't use the lower 8 bits for runtime flags. check-in: 1b3d035041 user: js tags: runtime
Changes

Modified Makefile from [2c18cb613e] to [c8b4784a7f].

1
2
3
4
5
6
7
8
9
10
11
12


13
14
15
16
17
18
19
20
21
22
23
24
25
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27












+
+













include extra.mk

SUBDIRS = src utils ${TESTS}
DISTCLEAN = aclocal.m4		\
	    autom4te.cache	\
	    buildsys.mk		\
	    config.h		\
	    config.log		\
	    config.status	\
	    extra.mk

include buildsys.mk

utils ${TESTS}: src

tarball:
	echo "Generating tarball for version ${PACKAGE_VERSION}..."
	rm -fr tmp.tar objfw-${PACKAGE_VERSION} objfw-${PACKAGE_VERSION}.tar \
		objfw-${PACKAGE_VERSION}.tar.gz
	git archive HEAD --prefix objfw-${PACKAGE_VERSION}/ -o tmp.tar
	tar xf tmp.tar
	rm -f tmp.tar objfw-${PACKAGE_VERSION}/.gitignore
	cp configure config.h.in objfw-${PACKAGE_VERSION}/
	tar cf objfw-${PACKAGE_VERSION}.tar objfw-${PACKAGE_VERSION}
	rm -fr objfw-${PACKAGE_VERSION}
	gzip -9 objfw-${PACKAGE_VERSION}.tar
	rm -f objfw-${PACKAGE_VERSION}.tar

Modified ObjFW.xcodeproj/project.pbxproj from [3d876805a7] to [0481245247].

67
68
69
70
71
72
73
74

75
76
77
78
79
80
81
67
68
69
70
71
72
73

74
75
76
77
78
79
80
81







-
+







		4B17FFB2133A3664003E6DCD /* OFUnsupportedProtocolException.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B17FFB0133A365C003E6DCD /* OFUnsupportedProtocolException.m */; };
		4B17FFB5133A375B003E6DCD /* OFUnboundNamespaceException.h in Headers */ = {isa = PBXBuildFile; fileRef = 4B17FFB3133A374C003E6DCD /* OFUnboundNamespaceException.h */; settings = {ATTRIBUTES = (Public, ); }; };
		4B17FFB6133A375B003E6DCD /* OFUnboundNamespaceException.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B17FFB4133A3750003E6DCD /* OFUnboundNamespaceException.m */; };
		4B17FFB9133A381D003E6DCD /* OFInvalidServerReplyException.h in Headers */ = {isa = PBXBuildFile; fileRef = 4B17FFB7133A380F003E6DCD /* OFInvalidServerReplyException.h */; settings = {ATTRIBUTES = (Public, ); }; };
		4B17FFBA133A381D003E6DCD /* OFInvalidServerReplyException.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B17FFB8133A3813003E6DCD /* OFInvalidServerReplyException.m */; };
		4B23CA92133811DC0047A1D9 /* TestPlugin.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B6EF684123535B60076B512 /* TestPlugin.m */; };
		4B23CA93133811E20047A1D9 /* ObjFW.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 4B3D23761337FBC800DD29B8 /* ObjFW.framework */; };
		4B23CA941338121C0047A1D9 /* TestPlugin.impl in CopyFiles */ = {isa = PBXBuildFile; fileRef = 4B23CA8A133811610047A1D9 /* TestPlugin.impl */; };
		4B23CA941338121C0047A1D9 /* TestPlugin.bundle in CopyFiles */ = {isa = PBXBuildFile; fileRef = 4B23CA8A133811610047A1D9 /* TestPlugin.bundle */; };
		4B29BC3B133AC4E80004B236 /* OFChangeDirectoryFailedException.h in Headers */ = {isa = PBXBuildFile; fileRef = 4B29BC33133AC4E80004B236 /* OFChangeDirectoryFailedException.h */; settings = {ATTRIBUTES = (Public, ); }; };
		4B29BC3C133AC4E80004B236 /* OFChangeDirectoryFailedException.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B29BC34133AC4E80004B236 /* OFChangeDirectoryFailedException.m */; };
		4B29BC3D133AC4E80004B236 /* OFChangeFileModeFailedException.h in Headers */ = {isa = PBXBuildFile; fileRef = 4B29BC35133AC4E80004B236 /* OFChangeFileModeFailedException.h */; settings = {ATTRIBUTES = (Public, ); }; };
		4B29BC3E133AC4E80004B236 /* OFChangeFileModeFailedException.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B29BC36133AC4E80004B236 /* OFChangeFileModeFailedException.m */; };
		4B29BC3F133AC4E80004B236 /* OFCreateDirectoryFailedException.h in Headers */ = {isa = PBXBuildFile; fileRef = 4B29BC37133AC4E80004B236 /* OFCreateDirectoryFailedException.h */; settings = {ATTRIBUTES = (Public, ); }; };
		4B29BC40133AC4E80004B236 /* OFCreateDirectoryFailedException.m in Sources */ = {isa = PBXBuildFile; fileRef = 4B29BC38133AC4E80004B236 /* OFCreateDirectoryFailedException.m */; };
		4B29BC41133AC4E80004B236 /* OFSeekFailedException.h in Headers */ = {isa = PBXBuildFile; fileRef = 4B29BC39133AC4E80004B236 /* OFSeekFailedException.h */; settings = {ATTRIBUTES = (Public, ); }; };
371
372
373
374
375
376
377
378

379
380
381
382
383
384
385
371
372
373
374
375
376
377

378
379
380
381
382
383
384
385







-
+







/* Begin PBXCopyFilesBuildPhase section */
		4BF33AEE133807310059CEF7 /* CopyFiles */ = {
			isa = PBXCopyFilesBuildPhase;
			buildActionMask = 12;
			dstPath = plugin;
			dstSubfolderSpec = 16;
			files = (
				4B23CA941338121C0047A1D9 /* TestPlugin.impl in CopyFiles */,
				4B23CA941338121C0047A1D9 /* TestPlugin.bundle in CopyFiles */,
			);
			runOnlyForDeploymentPostprocessing = 0;
		};
		4BF33B4013380CA40059CEF7 /* CopyFiles */ = {
			isa = PBXCopyFilesBuildPhase;
			buildActionMask = 2147483647;
			dstPath = "";
435
436
437
438
439
440
441
442

443
444
445
446
447
448
449
435
436
437
438
439
440
441

442
443
444
445
446
447
448
449







-
+







		4B17FFB0133A365C003E6DCD /* OFUnsupportedProtocolException.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFUnsupportedProtocolException.m; path = src/exceptions/OFUnsupportedProtocolException.m; sourceTree = "<group>"; };
		4B17FFB3133A374C003E6DCD /* OFUnboundNamespaceException.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = OFUnboundNamespaceException.h; path = src/exceptions/OFUnboundNamespaceException.h; sourceTree = "<group>"; };
		4B17FFB4133A3750003E6DCD /* OFUnboundNamespaceException.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFUnboundNamespaceException.m; path = src/exceptions/OFUnboundNamespaceException.m; sourceTree = "<group>"; };
		4B17FFB7133A380F003E6DCD /* OFInvalidServerReplyException.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = OFInvalidServerReplyException.h; path = src/exceptions/OFInvalidServerReplyException.h; sourceTree = "<group>"; };
		4B17FFB8133A3813003E6DCD /* OFInvalidServerReplyException.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFInvalidServerReplyException.m; path = src/exceptions/OFInvalidServerReplyException.m; sourceTree = "<group>"; };
		4B19023A1338D6A2000374C9 /* Makefile */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.make; name = Makefile; path = src/Makefile; sourceTree = SOURCE_ROOT; };
		4B19023D1338D6D5000374C9 /* Makefile */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.make; name = Makefile; path = tests/Makefile; sourceTree = "<group>"; };
		4B23CA8A133811610047A1D9 /* TestPlugin.impl */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.dylib"; includeInIndex = 0; path = TestPlugin.impl; sourceTree = BUILT_PRODUCTS_DIR; };
		4B23CA8A133811610047A1D9 /* TestPlugin.bundle */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.dylib"; includeInIndex = 0; path = TestPlugin.bundle; sourceTree = BUILT_PRODUCTS_DIR; };
		4B29BC33133AC4E80004B236 /* OFChangeDirectoryFailedException.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = OFChangeDirectoryFailedException.h; path = src/exceptions/OFChangeDirectoryFailedException.h; sourceTree = "<group>"; };
		4B29BC34133AC4E80004B236 /* OFChangeDirectoryFailedException.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFChangeDirectoryFailedException.m; path = src/exceptions/OFChangeDirectoryFailedException.m; sourceTree = "<group>"; };
		4B29BC35133AC4E80004B236 /* OFChangeFileModeFailedException.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = OFChangeFileModeFailedException.h; path = src/exceptions/OFChangeFileModeFailedException.h; sourceTree = "<group>"; };
		4B29BC36133AC4E80004B236 /* OFChangeFileModeFailedException.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFChangeFileModeFailedException.m; path = src/exceptions/OFChangeFileModeFailedException.m; sourceTree = "<group>"; };
		4B29BC37133AC4E80004B236 /* OFCreateDirectoryFailedException.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = OFCreateDirectoryFailedException.h; path = src/exceptions/OFCreateDirectoryFailedException.h; sourceTree = "<group>"; };
		4B29BC38133AC4E80004B236 /* OFCreateDirectoryFailedException.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OFCreateDirectoryFailedException.m; path = src/exceptions/OFCreateDirectoryFailedException.m; sourceTree = "<group>"; };
		4B29BC39133AC4E80004B236 /* OFSeekFailedException.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = OFSeekFailedException.h; path = src/exceptions/OFSeekFailedException.h; sourceTree = "<group>"; };
859
860
861
862
863
864
865
866

867
868
869
870
871
872
873
859
860
861
862
863
864
865

866
867
868
869
870
871
872
873







-
+







			name = "Supporting Files";
			sourceTree = "<group>";
		};
		4B3D23771337FBC800DD29B8 /* Products */ = {
			isa = PBXGroup;
			children = (
				4BF33AF0133807310059CEF7 /* Tests */,
				4B23CA8A133811610047A1D9 /* TestPlugin.impl */,
				4B23CA8A133811610047A1D9 /* TestPlugin.bundle */,
			);
			name = Products;
			sourceTree = "<group>";
		};
		4B3D23801337FBC800DD29B8 /* Supporting Files */ = {
			isa = PBXGroup;
			children = (
1290
1291
1292
1293
1294
1295
1296
1297

1298
1299
1300
1301
1302
1303
1304
1290
1291
1292
1293
1294
1295
1296

1297
1298
1299
1300
1301
1302
1303
1304







-
+







			buildRules = (
			);
			dependencies = (
				4B23CA91133811BA0047A1D9 /* PBXTargetDependency */,
			);
			name = TestPlugin;
			productName = TestPlugin;
			productReference = 4B23CA8A133811610047A1D9 /* TestPlugin.impl */;
			productReference = 4B23CA8A133811610047A1D9 /* TestPlugin.bundle */;
			productType = "com.apple.product-type.library.dynamic";
		};
		4B3D23751337FBC800DD29B8 /* ObjFW */ = {
			isa = PBXNativeTarget;
			buildConfigurationList = 4B3D23861337FBC800DD29B8 /* Build configuration list for PBXNativeTarget "ObjFW" */;
			buildPhases = (
				4B3D23711337FBC800DD29B8 /* Sources */,
1338
1339
1340
1341
1342
1343
1344
1345

1346
1347
1348
1349
1350
1351
1352
1338
1339
1340
1341
1342
1343
1344

1345
1346
1347
1348
1349
1350
1351
1352







-
+







		};
/* End PBXNativeTarget section */

/* Begin PBXProject section */
		08FB7793FE84155DC02AAC07 /* Project object */ = {
			isa = PBXProject;
			attributes = {
				LastUpgradeCheck = 0420;
				LastUpgradeCheck = 0430;
			};
			buildConfigurationList = 1DEB919308733D9F0010E9CD /* Build configuration list for PBXProject "ObjFW" */;
			compatibilityVersion = "Xcode 3.2";
			developmentRegion = English;
			hasScannedForEncodings = 1;
			knownRegions = (
				English,
1669
1670
1671
1672
1673
1674
1675
1676

1677
1678
1679
1680
1681
1682
1683
1684
1685
1686
1687
1688

1689
1690
1691
1692
1693
1694
1695
1669
1670
1671
1672
1673
1674
1675

1676
1677
1678
1679
1680
1681
1682
1683
1684
1685
1686
1687

1688
1689
1690
1691
1692
1693
1694
1695







-
+











-
+







			name = Release;
		};
		4B23CA8C133811610047A1D9 /* Debug */ = {
			isa = XCBuildConfiguration;
			buildSettings = {
				DYLIB_COMPATIBILITY_VERSION = "";
				DYLIB_CURRENT_VERSION = "";
				EXECUTABLE_EXTENSION = impl;
				EXECUTABLE_EXTENSION = bundle;
				INSTALL_PATH = "";
				MACH_O_TYPE = mh_bundle;
				PRODUCT_NAME = "$(TARGET_NAME)";
			};
			name = Debug;
		};
		4B23CA8D133811610047A1D9 /* Release */ = {
			isa = XCBuildConfiguration;
			buildSettings = {
				DYLIB_COMPATIBILITY_VERSION = "";
				DYLIB_CURRENT_VERSION = "";
				EXECUTABLE_EXTENSION = impl;
				EXECUTABLE_EXTENSION = bundle;
				INSTALL_PATH = "";
				MACH_O_TYPE = mh_bundle;
				PRODUCT_NAME = "$(TARGET_NAME)";
			};
			name = Release;
		};
		4B3D23871337FBC800DD29B8 /* Debug */ = {

Modified buildsys.mk.in from [0f6756deb9] to [8ce39250fe].

100
101
102
103
104
105
106
107

108
109
110
111
112
113
114
115




116
117
118
119
120
121
122
100
101
102
103
104
105
106

107
108
109
110
111
112
113


114
115
116
117
118
119
120
121
122
123
124







-
+






-
-
+
+
+
+







PLUGIN_OBJS = ${OBJS:.o=.plugin.o}

MO_FILES = ${LOCALES:.po=.mo}

.SILENT:
.SUFFIXES:
.SUFFIXES: .beam .c .c.dep .cc .cc.dep .class .cxx .cxx.dep .d .erl .lib.o .java .mo .m .m.dep .mm .mm.dep .o .plugin.o .po .py .pyc .rc .S .S.dep .xpm
.PHONY: all subdirs pre-depend depend install install-extra uninstall uninstall-extra clean distclean locales
.PHONY: all subdirs pre-depend depend install install-extra uninstall uninstall-extra clean distclean locales ${SUBDIRS}

all:
	${MAKE} ${MFLAGS} subdirs
	${MAKE} ${MFLAGS} depend
	${MAKE} ${STATIC_LIB} ${STATIC_LIB_NOINST} ${STATIC_PIC_LIB} ${STATIC_PIC_LIB_NOINST} ${SHARED_LIB} ${SHARED_LIB_NOINST} ${PLUGIN} ${PLUGIN_NOINST} ${PROG} ${PROG_NOINST} ${JARFILE} locales

subdirs:
	for i in ${SUBDIRS}; do \
subdirs: ${SUBDIRS}

${SUBDIRS}:
	for i in $@; do \
		${DIR_ENTER}; \
		${MAKE} ${MFLAGS} || exit $$?; \
		${DIR_LEAVE}; \
	done

depend: pre-depend ${SRCS}
	regen=0; \

Modified configure.ac from [7573e14a8c] to [11d50fbc2c].

633
634
635
636
637
638
639
640
641
642
643
633
634
635
636
637
638
639

640
641
642







-



BUILDSYS_TOUCH_DEPS

dnl We don't call AC_PROG_CPP, but only AC_PROG_OBJCPP and set CPP to OBJCPP
dnl and add OBJCPPFLAGS to CPPFLAGS, thus we need to AC_SUBST these ourself.
AC_SUBST(CPP)
AC_SUBST(CPPFLAGS)

AC_SUBST(PACKAGE, ObjFW)
AC_CONFIG_FILES([buildsys.mk extra.mk utils/objfw-config Info.plist])
AC_CONFIG_HEADERS([config.h src/objfw-defs.h])
AC_OUTPUT

Modified src/OFFile.m from [83d1b0c935] to [69833cd0ab].

157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
157
158
159
160
161
162
163







164
165
166
167
168
169
170







-
-
-
-
-
-
-







	[pool release];
}

@interface OFFileSingleton: OFFile
@end

@implementation OFFile
+ (void)load
{
	of_stdin = [[OFFileSingleton alloc] initWithFileDescriptor: 0];
	of_stdout = [[OFFileSingleton alloc] initWithFileDescriptor: 1];
	of_stderr = [[OFFileSingleton alloc] initWithFileDescriptor: 2];
}

#if defined(OF_THREADS) && !defined(_WIN32)
+ (void)initialize
{
	if (self != [OFFile class])
		return;

	if (!of_mutex_new(&mutex))
784
785
786
787
788
789
790







791
792
793
794
795
796
797
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797







+
+
+
+
+
+
+







		close(fileDescriptor);

	[super dealloc];
}
@end

@implementation OFFileSingleton
+ (void)load
{
	of_stdin = [[OFFileSingleton alloc] initWithFileDescriptor: 0];
	of_stdout = [[OFFileSingleton alloc] initWithFileDescriptor: 1];
	of_stderr = [[OFFileSingleton alloc] initWithFileDescriptor: 2];
}

- initWithPath: (OFString*)path
	  mode: (OFString*)mode
{
	Class c = isa;
	[self release];
	@throw [OFNotImplementedException exceptionWithClass: c
						    selector: _cmd];

Modified src/OFNumber.h from [6fa2f56574] to [5d5851287a].

816
817
818
819
820
821
822





816
817
818
819
820
821
822
823
824
825
826
827







+
+
+
+
+
 *	  specified number.
 *
 * \param num The number to divide by
 * \return The remainder of a division by the specified number
 */
- (OFNumber*)remainderOfDivisionWithNumber: (OFNumber*)num;
@end

#ifndef NSINTEGER_DEFINED
/* Required for number literals to work */
@compatibility_alias NSNumber OFNumber;
#endif

Modified src/OFObject.h from [c823dc085d] to [491222589f].

28
29
30
31
32
33
34







35
36
37
38
39
40
41
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48







+
+
+
+
+
+
+







#include <limits.h>

#ifdef OF_OBJFW_RUNTIME
# import "runtime.h"
#else
# import <objc/objc.h>
#endif

#if defined(__has_feature) && __has_feature(objc_bool)
# undef YES
# define YES __objc_yes
# undef NO
# define NO __objc_no
#endif

#define OF_RETAIN_COUNT_MAX UINT_MAX
#define OF_INVALID_INDEX SIZE_MAX

/**
 * \brief A result of a comparison.
 */

Modified src/OFString.h from [1b7d10d7f5] to [2bed144e84].

854
855
856
857
858
859
860





854
855
856
857
858
859
860
861
862
863
864
865







+
+
+
+
+
#import "OFMutableString.h"
#import "OFString+Hashing.h"
#import "OFString+JSONValue.h"
#import "OFString+Serialization.h"
#import "OFString+URLEncoding.h"
#import "OFString+XMLEscaping.h"
#import "OFString+XMLUnescaping.h"

#ifndef NSINTEGER_DEFINED
/* Required for string boxing literals to work */
@compatibility_alias NSString OFString;
#endif