From 42fd04a7abb38bdcb2a46f9bfbad2d0168f0aad9 Mon Sep 17 00:00:00 2001 From: Norayr Chilingarian Date: Thu, 30 Jan 2014 00:03:19 +0400 Subject: [PATCH] remaining ooc C type files Former-commit-id: 3618fac1b10eed7fd3eb268dda5c10422f874fd7 --- src/lib/ooc/gnuc/armv6j/oocC.Mod | 72 +++++++++++++++++++++++++ src/lib/ooc/gnuc/armv6j_hardfp/oocC.Mod | 72 +++++++++++++++++++++++++ src/lib/ooc/gnuc/powerpc/oocC.Mod | 72 +++++++++++++++++++++++++ src/lib/ooc/gnuc/x86/oocC.Mod | 72 +++++++++++++++++++++++++ src/lib/ooc/gnuc/x86_64/oocC.Mod | 71 ++++++++++++++++++++++++ 5 files changed, 359 insertions(+) create mode 100644 src/lib/ooc/gnuc/armv6j/oocC.Mod create mode 100644 src/lib/ooc/gnuc/armv6j_hardfp/oocC.Mod create mode 100644 src/lib/ooc/gnuc/powerpc/oocC.Mod create mode 100644 src/lib/ooc/gnuc/x86/oocC.Mod create mode 100644 src/lib/ooc/gnuc/x86_64/oocC.Mod diff --git a/src/lib/ooc/gnuc/armv6j/oocC.Mod b/src/lib/ooc/gnuc/armv6j/oocC.Mod new file mode 100644 index 00000000..2e7751ff --- /dev/null +++ b/src/lib/ooc/gnuc/armv6j/oocC.Mod @@ -0,0 +1,72 @@ +(* $Id: C.Mod,v 1.9 1999/10/03 11:46:01 ooc-devel Exp $ *) +MODULE oocC; +(* Basic data types for interfacing to C code. + Copyright (C) 1997-1998 Michael van Acken + + This module is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public License + as published by the Free Software Foundation; either version 2 of + the License, or (at your option) any later version. + + This module is distributed in the hope that it will be useful, but + WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with OOC. If not, write to the Free Software Foundation, + 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +*) + +IMPORT + SYSTEM; + +(* +These types are intended to be equivalent to their C counterparts. +They may vary depending on your system, but as long as you stick to a 32 Bit +Unix they should be fairly safe. +*) + +TYPE + char* = CHAR; + signedchar* = SHORTINT; (* signed char *) + shortint* = INTEGER; (* short int *) + int* = LONGINT; + set* = SET; (* unsigned int, used as set *) + longint* = LONGINT; (* long int *) + (*longset* = SYSTEM.SET64; *) (* unsigned long, used as set *) + longset* = SET; + address* = LONGINT; + float* = REAL; + double* = LONGREAL; + + enum1* = int; + enum2* = int; + enum4* = int; + + (* if your C compiler uses short enumerations, you'll have to replace the + declarations above with + enum1* = SHORTINT; + enum2* = INTEGER; + enum4* = LONGINT; + *) + + FILE* = address; (* this is acually a replacement for `FILE*', i.e., for a pointer type *) + sizet* = longint; + uidt* = int; + gidt* = int; + + +TYPE (* some commonly used C array types *) + charPtr1d* = POINTER TO ARRAY OF char; + charPtr2d* = POINTER TO ARRAY OF charPtr1d; + intPtr1d* = POINTER TO ARRAY OF int; + +TYPE (* C string type, assignment compatible with character arrays and + string constants *) + string* = POINTER TO ARRAY OF char; + +TYPE + Proc* = PROCEDURE; + +END oocC. diff --git a/src/lib/ooc/gnuc/armv6j_hardfp/oocC.Mod b/src/lib/ooc/gnuc/armv6j_hardfp/oocC.Mod new file mode 100644 index 00000000..2e7751ff --- /dev/null +++ b/src/lib/ooc/gnuc/armv6j_hardfp/oocC.Mod @@ -0,0 +1,72 @@ +(* $Id: C.Mod,v 1.9 1999/10/03 11:46:01 ooc-devel Exp $ *) +MODULE oocC; +(* Basic data types for interfacing to C code. + Copyright (C) 1997-1998 Michael van Acken + + This module is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public License + as published by the Free Software Foundation; either version 2 of + the License, or (at your option) any later version. + + This module is distributed in the hope that it will be useful, but + WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with OOC. If not, write to the Free Software Foundation, + 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +*) + +IMPORT + SYSTEM; + +(* +These types are intended to be equivalent to their C counterparts. +They may vary depending on your system, but as long as you stick to a 32 Bit +Unix they should be fairly safe. +*) + +TYPE + char* = CHAR; + signedchar* = SHORTINT; (* signed char *) + shortint* = INTEGER; (* short int *) + int* = LONGINT; + set* = SET; (* unsigned int, used as set *) + longint* = LONGINT; (* long int *) + (*longset* = SYSTEM.SET64; *) (* unsigned long, used as set *) + longset* = SET; + address* = LONGINT; + float* = REAL; + double* = LONGREAL; + + enum1* = int; + enum2* = int; + enum4* = int; + + (* if your C compiler uses short enumerations, you'll have to replace the + declarations above with + enum1* = SHORTINT; + enum2* = INTEGER; + enum4* = LONGINT; + *) + + FILE* = address; (* this is acually a replacement for `FILE*', i.e., for a pointer type *) + sizet* = longint; + uidt* = int; + gidt* = int; + + +TYPE (* some commonly used C array types *) + charPtr1d* = POINTER TO ARRAY OF char; + charPtr2d* = POINTER TO ARRAY OF charPtr1d; + intPtr1d* = POINTER TO ARRAY OF int; + +TYPE (* C string type, assignment compatible with character arrays and + string constants *) + string* = POINTER TO ARRAY OF char; + +TYPE + Proc* = PROCEDURE; + +END oocC. diff --git a/src/lib/ooc/gnuc/powerpc/oocC.Mod b/src/lib/ooc/gnuc/powerpc/oocC.Mod new file mode 100644 index 00000000..2e7751ff --- /dev/null +++ b/src/lib/ooc/gnuc/powerpc/oocC.Mod @@ -0,0 +1,72 @@ +(* $Id: C.Mod,v 1.9 1999/10/03 11:46:01 ooc-devel Exp $ *) +MODULE oocC; +(* Basic data types for interfacing to C code. + Copyright (C) 1997-1998 Michael van Acken + + This module is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public License + as published by the Free Software Foundation; either version 2 of + the License, or (at your option) any later version. + + This module is distributed in the hope that it will be useful, but + WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with OOC. If not, write to the Free Software Foundation, + 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +*) + +IMPORT + SYSTEM; + +(* +These types are intended to be equivalent to their C counterparts. +They may vary depending on your system, but as long as you stick to a 32 Bit +Unix they should be fairly safe. +*) + +TYPE + char* = CHAR; + signedchar* = SHORTINT; (* signed char *) + shortint* = INTEGER; (* short int *) + int* = LONGINT; + set* = SET; (* unsigned int, used as set *) + longint* = LONGINT; (* long int *) + (*longset* = SYSTEM.SET64; *) (* unsigned long, used as set *) + longset* = SET; + address* = LONGINT; + float* = REAL; + double* = LONGREAL; + + enum1* = int; + enum2* = int; + enum4* = int; + + (* if your C compiler uses short enumerations, you'll have to replace the + declarations above with + enum1* = SHORTINT; + enum2* = INTEGER; + enum4* = LONGINT; + *) + + FILE* = address; (* this is acually a replacement for `FILE*', i.e., for a pointer type *) + sizet* = longint; + uidt* = int; + gidt* = int; + + +TYPE (* some commonly used C array types *) + charPtr1d* = POINTER TO ARRAY OF char; + charPtr2d* = POINTER TO ARRAY OF charPtr1d; + intPtr1d* = POINTER TO ARRAY OF int; + +TYPE (* C string type, assignment compatible with character arrays and + string constants *) + string* = POINTER TO ARRAY OF char; + +TYPE + Proc* = PROCEDURE; + +END oocC. diff --git a/src/lib/ooc/gnuc/x86/oocC.Mod b/src/lib/ooc/gnuc/x86/oocC.Mod new file mode 100644 index 00000000..2e7751ff --- /dev/null +++ b/src/lib/ooc/gnuc/x86/oocC.Mod @@ -0,0 +1,72 @@ +(* $Id: C.Mod,v 1.9 1999/10/03 11:46:01 ooc-devel Exp $ *) +MODULE oocC; +(* Basic data types for interfacing to C code. + Copyright (C) 1997-1998 Michael van Acken + + This module is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public License + as published by the Free Software Foundation; either version 2 of + the License, or (at your option) any later version. + + This module is distributed in the hope that it will be useful, but + WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with OOC. If not, write to the Free Software Foundation, + 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +*) + +IMPORT + SYSTEM; + +(* +These types are intended to be equivalent to their C counterparts. +They may vary depending on your system, but as long as you stick to a 32 Bit +Unix they should be fairly safe. +*) + +TYPE + char* = CHAR; + signedchar* = SHORTINT; (* signed char *) + shortint* = INTEGER; (* short int *) + int* = LONGINT; + set* = SET; (* unsigned int, used as set *) + longint* = LONGINT; (* long int *) + (*longset* = SYSTEM.SET64; *) (* unsigned long, used as set *) + longset* = SET; + address* = LONGINT; + float* = REAL; + double* = LONGREAL; + + enum1* = int; + enum2* = int; + enum4* = int; + + (* if your C compiler uses short enumerations, you'll have to replace the + declarations above with + enum1* = SHORTINT; + enum2* = INTEGER; + enum4* = LONGINT; + *) + + FILE* = address; (* this is acually a replacement for `FILE*', i.e., for a pointer type *) + sizet* = longint; + uidt* = int; + gidt* = int; + + +TYPE (* some commonly used C array types *) + charPtr1d* = POINTER TO ARRAY OF char; + charPtr2d* = POINTER TO ARRAY OF charPtr1d; + intPtr1d* = POINTER TO ARRAY OF int; + +TYPE (* C string type, assignment compatible with character arrays and + string constants *) + string* = POINTER TO ARRAY OF char; + +TYPE + Proc* = PROCEDURE; + +END oocC. diff --git a/src/lib/ooc/gnuc/x86_64/oocC.Mod b/src/lib/ooc/gnuc/x86_64/oocC.Mod new file mode 100644 index 00000000..14638e75 --- /dev/null +++ b/src/lib/ooc/gnuc/x86_64/oocC.Mod @@ -0,0 +1,71 @@ +(* $Id: C.Mod,v 1.9 1999/10/03 11:46:01 ooc-devel Exp $ *) +MODULE oocC; +(* Basic data types for interfacing to C code. + Copyright (C) 1997-1998 Michael van Acken + + This module is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public License + as published by the Free Software Foundation; either version 2 of + the License, or (at your option) any later version. + + This module is distributed in the hope that it will be useful, but + WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with OOC. If not, write to the Free Software Foundation, + 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +*) + +IMPORT + SYSTEM; + +(* +These types are intended to be equivalent to their C counterparts. +They may vary depending on your system, but as long as you stick to a 32 Bit +Unix they should be fairly safe. +*) + +TYPE + char* = CHAR; + signedchar* = SHORTINT; (* signed char *) + shortint* = RECORD a,b : SYSTEM.BYTE END; (* 2 bytes on x64_64 *) (* short int *) + int* = INTEGER; + set* = INTEGER;(*SET;*) (* unsigned int, used as set *) + longint* = LONGINT; (* long int *) + longset* = SET; (*SYSTEM.SET64; *) (* unsigned long, used as set *) + address* = LONGINT; (*SYSTEM.ADDRESS;*) + float* = REAL; + double* = LONGREAL; + + enum1* = int; + enum2* = int; + enum4* = int; + + (* if your C compiler uses short enumerations, you'll have to replace the + declarations above with + enum1* = SHORTINT; + enum2* = INTEGER; + enum4* = LONGINT; + *) + + FILE* = address; (* this is acually a replacement for `FILE*', i.e., for a pointer type *) + sizet* = longint; + uidt* = int; + gidt* = int; + + +TYPE (* some commonly used C array types *) + charPtr1d* = POINTER TO ARRAY OF char; + charPtr2d* = POINTER TO ARRAY OF charPtr1d; + intPtr1d* = POINTER TO ARRAY OF int; + +TYPE (* C string type, assignment compatible with character arrays and + string constants *) + string* = POINTER (*[CSTRING]*) TO ARRAY OF char; + +TYPE + Proc* = PROCEDURE; + +END oocC.