Przeglądaj źródła

* implemented GetProcessId, defined TimeVal and TimeZone in addition to TTimeVal, TTimeZone, Makefile defaults to binutilsprefix i386-netware

armin 20 lat temu
rodzic
commit
8eb794231c

+ 5 - 4
rtl/netwlibc/Makefile

@@ -1,11 +1,11 @@
 #
-# Don't edit, this file is generated by FPCMake Version 1.1 [2004/12/05]
+# Don't edit, this file is generated by FPCMake Version 1.1 [2004/11/26]
 #
 default: all
-MAKEFILETARGETS=linux go32v2 win32 os2 freebsd beos netbsd amiga atari sunos qnx netware openbsd wdosx palmos macos darwin emx watcom morphos netwlibc
+MAKEFILETARGETS=netwlibc
 BSDs = freebsd netbsd openbsd darwin
 UNIXs = linux $(BSDs) sunos qnx
-LIMIT83fs = go32v2 os2 emx watcom
+LIMIT83fs = go32v2 os2
 FORCE:
 .PHONY: FORCE
 override PATH:=$(patsubst %/,%,$(subst \,/,$(PATH)))
@@ -236,6 +236,7 @@ endif
 override FPCOPT+=-Ur
 override FPCOPT+=-dMT -dDEBUG_MT
 CREATESMART=0
+BINUTILSPREFIX=i386-netware-
 OBJPASDIR=$(RTL)/objpas
 override TARGET_UNITS+=$(SYSTEMUNIT) objpas macpas strings lineinfo winsock heaptrc matrix nwsnut libc dos crt objects sysconst dynlibs initc sysutils types typinfo systhrds classes cpu mmx getopts dateutils strutils convutils charset ucomplex variants rtlconst math varutils freebidi utf8bidi mouse video keyboard cmem sockets
 override TARGET_LOADERS+=nwplibc nwl_main nwl_dlle
@@ -577,7 +578,7 @@ HASSHAREDLIB=1
 ZIPSUFFIX=darwin
 endif
 ifneq ($(findstring $(OS_SOURCE),$(LIMIT83fs)),)
-FPCMADE=fpcmade.$(FPCMADEEXT)
+FPCMADE=fpcmade$(FPCMADEEXT)
 else
 FPCMADE=fpcmade.$(FULL_TARGET)
 endif

+ 3 - 0
rtl/netwlibc/Makefile.fpc

@@ -69,6 +69,9 @@ override FPCOPT+=-dMT -dDEBUG_MT
 #CREATESMART=1
 CREATESMART=0
 
+# always use i386-netware- as the prefix for binutils (they are the same for netware and netwlibc)
+BINUTILSPREFIX=i386-netware-
+
 # Paths
 OBJPASDIR=$(RTL)/objpas
 

+ 11 - 2
rtl/netwlibc/libc.pp

@@ -1273,11 +1273,12 @@ type
      end;
 
    Ptimezone = ^Ttimezone;
-   Ttimezone = record                   { returned by gettimeofday() }
+   TTimezone = record                   { returned by gettimeofday() }
         tz_secondswest : time_t;        { seconds west of UTC }
         tz_minuteswest : longint;       { minutes west of UTC (GMT) }
         tz_dsttime     : longint;       { nonzero if DST is ever in effect }
      end;
+   Timezone = TTimezone;
 
 {
 ** Normally this functions fills struct tms with several time values. Most of
@@ -1296,6 +1297,7 @@ type
         tv_sec  : longint;
         tv_usec : longint;
      end;
+   Timeval = TTimeval;
 
 (** unsupported pragma#pragma pack()*)
 { operations on struct timeval; note timercmp() does not work for >= or <=  }
@@ -7196,7 +7198,7 @@ function getnlmhandlefromthread(thread:pointer):pointer;cdecl;external libc_nlm
 function getnlmname(handle:pointer; name:Pchar):Pchar;cdecl;external libc_nlm name 'getnlmname';
 function getnlmloadpath(loadpath:Pchar):Pchar;cdecl;external libc_nlm name 'getnlmloadpath';
 function getthreadname(threadid:pointer; name:Pchar; maxlen:size_t):longint;cdecl;external libc_nlm name 'getthreadname';
-function getthreadid:pointer;cdecl;external libc_nlm name 'getthreadid';
+function _getthreadid:pointer;cdecl;external libc_nlm name 'getthreadid';
 function library_calloc(handle:pointer; size:size_t; count:size_t):pointer;cdecl;external libc_nlm name 'library_calloc';
 procedure library_free(addr:pointer);cdecl;external libc_nlm name 'library_free';
 function library_malloc(handle:pointer; size:size_t):pointer;cdecl;external libc_nlm name 'library_malloc';
@@ -9068,3 +9070,10 @@ end;
 
 end.
 {$endif}
+
+{
+  $Log$
+  Revision 1.5  2004-12-07 11:40:43  armin
+  * implemented GetProcessId, defined TimeVal and TimeZone in addition to TTimeVal, TTimeZone, Makefile defaults to binutilsprefix i386-netware
+
+}

+ 5 - 3
rtl/netwlibc/system.pp

@@ -1011,8 +1011,7 @@ end;
 
 function GetProcessID: SizeUInt;
 begin
-{$WARNING GetProcessID implementation missing}
- GetProcessID := 1;
+ GetProcessID := SizeUInt (getnlmhandle);
 end;
 
 
@@ -1191,7 +1190,10 @@ Begin
 End.
 {
   $Log$
-  Revision 1.9  2004-12-05 14:36:38  hajny
+  Revision 1.10  2004-12-07 11:40:43  armin
+  * implemented GetProcessId, defined TimeVal and TimeZone in addition to TTimeVal, TTimeZone, Makefile defaults to binutilsprefix i386-netware
+
+  Revision 1.9  2004/12/05 14:36:38  hajny
     + GetProcessID added
 
   Revision 1.8  2004/11/25 12:38:17  armin