File tree 6 files changed +107
-0
lines changed
6 files changed +107
-0
lines changed Original file line number Diff line number Diff line change @@ -85,6 +85,30 @@ else version (MIPS32)
85
85
void _dl_mcount_wrapper_check (void * __selfpc);
86
86
}
87
87
}
88
+ else version (PPC64 )
89
+ {
90
+ // http://sourceware.org/git/?p=glibc.git;a=blob;f=ports/sysdeps/mips/bits/dlfcn.h
91
+ // enum RTLD_LAZY = 0x0001; // POSIX
92
+ // enum RTLD_NOW = 0x0002; // POSIX
93
+ enum RTLD_BINDING_MASK = 0x3 ;
94
+ enum RTLD_NOLOAD = 0x00004 ;
95
+ enum RTLD_DEEPBIND = 0x00008 ;
96
+
97
+ // enum RTLD_GLOBAL = 0x00100; // POSIX
98
+ // enum RTLD_LOCAL = 0; // POSIX
99
+ enum RTLD_NODELETE = 0x01000 ;
100
+
101
+ static if (__USE_GNU)
102
+ {
103
+ RT DL_CALL_FCT (RT , Args... )(RT function (Args) fctp, auto ref Args args)
104
+ {
105
+ _dl_mcount_wrapper_check(cast (void * )fctp);
106
+ return fctp (args);
107
+ }
108
+
109
+ void _dl_mcount_wrapper_check (void * __selfpc);
110
+ }
111
+ }
88
112
else
89
113
static assert (0 , " unimplemented" );
90
114
Original file line number Diff line number Diff line change @@ -33,6 +33,12 @@ else version (MIPS32)
33
33
alias __WORDSIZE __ELF_NATIVE_CLASS;
34
34
alias uint32_t Elf_Symndx;
35
35
}
36
+ else version (PPC64 )
37
+ {
38
+ // http://sourceware.org/git/?p=glibc.git;a=blob;f=bits/elfclass.h
39
+ alias __WORDSIZE __ELF_NATIVE_CLASS;
40
+ alias uint32_t Elf_Symndx;
41
+ }
36
42
else
37
43
static assert (0 , " unimplemented" );
38
44
// <bits/elfclass.h>
Original file line number Diff line number Diff line change @@ -57,6 +57,13 @@ version( linux )
57
57
enum RTLD_GLOBAL = 0x0004 ;
58
58
enum RTLD_LOCAL = 0 ;
59
59
}
60
+ else version (PPC64 )
61
+ {
62
+ enum RTLD_LAZY = 0x00001 ;
63
+ enum RTLD_NOW = 0x00002 ;
64
+ enum RTLD_GLOBAL = 0x00100 ;
65
+ enum RTLD_LOCAL = 0 ;
66
+ }
60
67
else
61
68
static assert (0 , " unimplemented" );
62
69
Original file line number Diff line number Diff line change @@ -185,6 +185,30 @@ version( linux )
185
185
enum SIGUSR2 = 17 ;
186
186
enum SIGURG = 21 ;
187
187
}
188
+ else version (PPC64 )
189
+ {
190
+ // SIGABRT (defined in core.stdc.signal)
191
+ enum SIGALRM = 14 ;
192
+ enum SIGBUS = 7 ;
193
+ enum SIGCHLD = 17 ;
194
+ enum SIGCONT = 18 ;
195
+ // SIGFPE (defined in core.stdc.signal)
196
+ enum SIGHUP = 1 ;
197
+ // SIGILL (defined in core.stdc.signal)
198
+ // SIGINT (defined in core.stdc.signal)
199
+ enum SIGKILL = 9 ;
200
+ enum SIGPIPE = 13 ;
201
+ enum SIGQUIT = 3 ;
202
+ // SIGSEGV (defined in core.stdc.signal)
203
+ enum SIGSTOP = 19 ;
204
+ // SIGTERM (defined in core.stdc.signal)
205
+ enum SIGTSTP = 20 ;
206
+ enum SIGTTIN = 21 ;
207
+ enum SIGTTOU = 22 ;
208
+ enum SIGUSR1 = 10 ;
209
+ enum SIGUSR2 = 12 ;
210
+ enum SIGURG = 23 ;
211
+ }
188
212
else
189
213
static assert (0 , " unimplemented" );
190
214
}
@@ -860,6 +884,16 @@ version( linux )
860
884
enum SIGXCPU = 30 ;
861
885
enum SIGXFSZ = 31 ;
862
886
}
887
+ else version (PPC64 )
888
+ {
889
+ enum SIGPOLL = 29 ;
890
+ enum SIGPROF = 27 ;
891
+ enum SIGSYS = 31 ;
892
+ enum SIGTRAP = 5 ;
893
+ enum SIGVTALRM = 26 ;
894
+ enum SIGXCPU = 24 ;
895
+ enum SIGXFSZ = 25 ;
896
+ }
863
897
else
864
898
static assert (0 , " unimplemented" );
865
899
Original file line number Diff line number Diff line change @@ -190,6 +190,8 @@ version( linux )
190
190
enum MAP_ANON = 0x20 ; // non-standard
191
191
else version (MIPS32 )
192
192
enum MAP_ANON = 0x0800 ; // non-standard
193
+ else version (PPC64 )
194
+ enum MAP_ANON = 0x20 ; // non-standard
193
195
else
194
196
static assert (0 , " unimplemented" );
195
197
Original file line number Diff line number Diff line change @@ -310,6 +310,40 @@ version( linux )
310
310
SO_TYPE = 0x1008 ,
311
311
}
312
312
}
313
+ else version (PPC64 )
314
+ {
315
+ enum
316
+ {
317
+ SOCK_DGRAM = 2 ,
318
+ SOCK_SEQPACKET = 5 ,
319
+ SOCK_STREAM = 1
320
+ }
321
+
322
+ enum
323
+ {
324
+ SOL_SOCKET = 1
325
+ }
326
+
327
+ enum
328
+ {
329
+ SO_ACCEPTCONN = 30 ,
330
+ SO_BROADCAST = 6 ,
331
+ SO_DEBUG = 1 ,
332
+ SO_DONTROUTE = 5 ,
333
+ SO_ERROR = 4 ,
334
+ SO_KEEPALIVE = 9 ,
335
+ SO_LINGER = 13 ,
336
+ SO_OOBINLINE = 10 ,
337
+ SO_RCVBUF = 8 ,
338
+ SO_RCVLOWAT = 16 ,
339
+ SO_RCVTIMEO = 18 ,
340
+ SO_REUSEADDR = 2 ,
341
+ SO_SNDBUF = 7 ,
342
+ SO_SNDLOWAT = 17 ,
343
+ SO_SNDTIMEO = 19 ,
344
+ SO_TYPE = 3
345
+ }
346
+ }
313
347
else
314
348
static assert (0 , " unimplemented" );
315
349
You can’t perform that action at this time.
0 commit comments