ObjFW  Check-in [7f83956d3e]

Overview
Comment:Fix compilation on MorphOS
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: 7f83956d3e8279e43aa502c324734d1f9642735f46e69e906179b82d9bdb512e
User & Date: js on 2020-01-16 01:23:36
Other Links: manifest | tags
Context
2020-01-19
13:36
OFHostAddressResolver: More consistent exceptions check-in: 77e3fa54bc user: js tags: trunk
2020-01-16
01:23
Fix compilation on MorphOS check-in: 7f83956d3e user: js tags: trunk
2020-01-14
22:53
OF{Poll,Select}KernelEventObserver: Throw EBADF check-in: 94479b861b user: js tags: trunk
Changes

Modified src/runtime/morphos-clib.h from [407871c4d0] to [779ee8fb5d].

48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
Class glue_class_getSuperclass(Class);
unsigned long glue_class_getInstanceSize(Class);
bool glue_class_respondsToSelector(Class, SEL);
bool glue_class_conformsToProtocol(Class, Protocol *);
IMP glue_class_getMethodImplementation(Class, SEL);
IMP glue_class_getMethodImplementation_stret(Class, SEL);
Method glue_class_getInstanceMethod(Class, SEL);
bool glue_class_addMethod(Class class_, SEL selector, IMP, const char *);
IMP glue_class_replaceMethod(Class, SEL, IMP, const char *);
Class glue_object_getClass(id);
Class glue_object_setClass(id, Class);
const char *glue_object_getClassName(id);
const char *glue_protocol_getName(Protocol *);
bool glue_protocol_isEqual(Protocol *, Protocol *);
bool glue_protocol_conformsToProtocol(Protocol *, Protocol *);
objc_uncaught_exception_handler_t glue_objc_setUncaughtExceptionHandler(objc_uncaught_exception_handler_t);
void glue_objc_setForwardHandler(IMP, IMP);
void glue_objc_setEnumerationMutationHandler(objc_enumeration_mutation_handler_t);
id _Nullable glue_objc_constructInstance(Class class_, void *bytes);
void glue_objc_exit(void);
Ivar *glue_class_copyIvarList(Class class_, unsigned int *outCount);
const char *glue_ivar_getName(Ivar ivar);
const char *glue_ivar_getTypeEncoding(Ivar ivar);
ptrdiff_t glue_ivar_getOffset(Ivar ivar);
Method *glue_class_copyMethodList(Class class_, unsigned int *outCount);
SEL glue_method_getName(Method method);
const char *glue_method_getTypeEncoding(Method method);
objc_property_t *glue_class_copyPropertyList(Class class_, unsigned int *outCount);
const char *glue_property_getName(objc_property_t property);
char *glue_property_copyAttributeValue(objc_property_t property, const char *name);
void *glue_objc_destructInstance(id object);
void *glue_objc_autoreleasePoolPush(void);
void glue_objc_autoreleasePoolPop(void *pool);
id glue__objc_rootAutorelease(id object);







|










|

|
|
|
|
|
|
|
|
|
|
|

|
|
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
Class glue_class_getSuperclass(Class);
unsigned long glue_class_getInstanceSize(Class);
bool glue_class_respondsToSelector(Class, SEL);
bool glue_class_conformsToProtocol(Class, Protocol *);
IMP glue_class_getMethodImplementation(Class, SEL);
IMP glue_class_getMethodImplementation_stret(Class, SEL);
Method glue_class_getInstanceMethod(Class, SEL);
bool glue_class_addMethod(Class, SEL, IMP, const char *);
IMP glue_class_replaceMethod(Class, SEL, IMP, const char *);
Class glue_object_getClass(id);
Class glue_object_setClass(id, Class);
const char *glue_object_getClassName(id);
const char *glue_protocol_getName(Protocol *);
bool glue_protocol_isEqual(Protocol *, Protocol *);
bool glue_protocol_conformsToProtocol(Protocol *, Protocol *);
objc_uncaught_exception_handler_t glue_objc_setUncaughtExceptionHandler(objc_uncaught_exception_handler_t);
void glue_objc_setForwardHandler(IMP, IMP);
void glue_objc_setEnumerationMutationHandler(objc_enumeration_mutation_handler_t);
id glue_objc_constructInstance(Class, void *);
void glue_objc_exit(void);
Ivar *glue_class_copyIvarList(Class, unsigned int *);
const char *glue_ivar_getName(Ivar);
const char *glue_ivar_getTypeEncoding(Ivar);
ptrdiff_t glue_ivar_getOffset(Ivar);
Method *glue_class_copyMethodList(Class, unsigned int *);
SEL glue_method_getName(Method);
const char *glue_method_getTypeEncoding(Method);
objc_property_t *glue_class_copyPropertyList(Class, unsigned int *);
const char *glue_property_getName(objc_property_t);
char *glue_property_copyAttributeValue(objc_property_t, const char *);
void *glue_objc_destructInstance(id);
void *glue_objc_autoreleasePoolPush(void);
void glue_objc_autoreleasePoolPop(void *);
id glue__objc_rootAutorelease(id);

Modified src/runtime/morphos.fd from [01e9313771] to [5afb6ca118].

74
75
76
77
78
79
80
81
82
83
84
glue_class_copyMethodList(class_,outCount)(sysv,r12base)
glue_method_getName(method)(sysv,r12base)
glue_method_getTypeEncoding(method)(sysv,r12base)
glue_class_copyPropertyList(class_,outCount)(sysv,r12base)
glue_property_getName(property)(sysv,r12base)
glue_property_copyAttributeValue(property,name)(sysv,r12base)
glue_objc_destructInstance(object)(sysv,r12base)
objc_autoreleasePoolPush()(sysv,r12base)
objc_autoreleasePoolPop(pool)(sysv,r12base)
_objc_rootAutorelease(object)(sysv,r12base)
##end







|
|
|

74
75
76
77
78
79
80
81
82
83
84
glue_class_copyMethodList(class_,outCount)(sysv,r12base)
glue_method_getName(method)(sysv,r12base)
glue_method_getTypeEncoding(method)(sysv,r12base)
glue_class_copyPropertyList(class_,outCount)(sysv,r12base)
glue_property_getName(property)(sysv,r12base)
glue_property_copyAttributeValue(property,name)(sysv,r12base)
glue_objc_destructInstance(object)(sysv,r12base)
glue_objc_autoreleasePoolPush()(sysv,r12base)
glue_objc_autoreleasePoolPop(pool)(sysv,r12base)
glue__objc_rootAutorelease(object)(sysv,r12base)
##end

Modified src/socket.m from [a70c769a92] to [353f4118f9].

54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
# include <3ds/types.h>
# include <3ds/services/soc.h>
#endif

#if defined(OF_HAVE_THREADS) && !defined(OF_AMIGAOS)
static of_mutex_t mutex;
#endif
#ifndef OF_AMIGAOS
static bool initSuccessful = false;
#else
# ifdef OF_HAVE_THREADS
of_tlskey_t of_socket_base_key;
#  ifdef OF_AMIGAOS4
of_tlskey_t of_socket_interface_key;
#  endif







|







54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
# include <3ds/types.h>
# include <3ds/services/soc.h>
#endif

#if defined(OF_HAVE_THREADS) && !defined(OF_AMIGAOS)
static of_mutex_t mutex;
#endif
#if !defined(OF_AMIGAOS) || !defined(OF_HAVE_THREADS)
static bool initSuccessful = false;
#else
# ifdef OF_HAVE_THREADS
of_tlskey_t of_socket_base_key;
#  ifdef OF_AMIGAOS4
of_tlskey_t of_socket_interface_key;
#  endif

Modified src/socket_helpers.h from [609fc24588] to [76048c8293].

45
46
47
48
49
50
51



52

53
54
55
56
57
58
59
#endif

#ifndef SOCK_CLOEXEC
# define SOCK_CLOEXEC 0
#endif

#if defined(OF_AMIGAOS)



# include <proto/bsdsocket.h>

# include <sys/filio.h>
# define closesocket(sock) CloseSocket(sock)
# define ioctlsocket(fd, req, arg) IoctlSocket(fd, req, arg)
# define hstrerror(err) "unknown (no hstrerror)"
# define SOCKET_ERROR -1
# ifdef OF_HAVE_THREADS
#  define SocketBase ((struct Library *)of_tlskey_get(of_socket_base_key))







>
>
>
|
>







45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
#endif

#ifndef SOCK_CLOEXEC
# define SOCK_CLOEXEC 0
#endif

#if defined(OF_AMIGAOS)
# ifdef OF_MORPHOS
#  include <proto/socket.h>
# else
#  include <proto/bsdsocket.h>
# endif
# include <sys/filio.h>
# define closesocket(sock) CloseSocket(sock)
# define ioctlsocket(fd, req, arg) IoctlSocket(fd, req, arg)
# define hstrerror(err) "unknown (no hstrerror)"
# define SOCKET_ERROR -1
# ifdef OF_HAVE_THREADS
#  define SocketBase ((struct Library *)of_tlskey_get(of_socket_base_key))