Sfoglia il codice sorgente

Merged revisions 7581-7585 via svnmerge from
http://svn.freepascal.org/svn/fpc/trunk

........
r7581 | pierre | 2007-06-05 11:04:43 +0200 (Tue, 05 Jun 2007) | 1 line

remove syncobjs from netwlibc target list
........
r7582 | pierre | 2007-06-05 11:22:40 +0200 (Tue, 05 Jun 2007) | 1 line

* use libc unit GetLastError to implement GetLastOSError
........
r7583 | pierre | 2007-06-05 11:29:27 +0200 (Tue, 05 Jun 2007) | 1 line

netwlibc now has GetLastOSError
........
r7584 | pierre | 2007-06-05 11:36:05 +0200 (Tue, 05 Jun 2007) | 1 line

* use __get_errno_ptr to implement GetLastOSError
........
r7585 | pierre | 2007-06-05 11:37:17 +0200 (Tue, 05 Jun 2007) | 1 line

netware now has GetLastOSError
........

git-svn-id: branches/fixes_2_2@7589 -

pierre 18 anni fa
parent
commit
efae1d5820

+ 1 - 1
packages/fcl-base/Makefile

@@ -260,7 +260,7 @@ ifeq ($(FULL_TARGET),i386-qnx)
 override TARGET_UNITS+=contnrs inifiles ezcgi pipes rtfpars idea base64 gettext iostream zstream cachecls avl_tree eventlog custapp cgiapp wformat whtml wtex rttiutils bufstream streamex blowfish zipper streamio inicol pooledmm libtar streamcoll
 endif
 ifeq ($(FULL_TARGET),i386-netware)
-override TARGET_UNITS+=contnrs inifiles ezcgi pipes rtfpars idea base64 gettext iostream zstream cachecls avl_tree eventlog custapp cgiapp wformat whtml wtex rttiutils bufstream streamex blowfish zipper streamio inicol pooledmm libtar streamcoll  resolve ssockets
+override TARGET_UNITS+=contnrs inifiles ezcgi pipes rtfpars idea base64 gettext iostream zstream cachecls avl_tree eventlog custapp cgiapp wformat whtml wtex rttiutils bufstream streamex blowfish zipper streamio inicol pooledmm libtar streamcoll  resolve ssockets syncobjs
 endif
 ifeq ($(FULL_TARGET),i386-openbsd)
 override TARGET_UNITS+=contnrs inifiles ezcgi pipes rtfpars idea base64 gettext iostream zstream cachecls avl_tree eventlog custapp cgiapp wformat whtml wtex rttiutils bufstream streamex blowfish zipper streamio inicol pooledmm libtar streamcoll  process ssockets resolve fpasync simpleipc dbugmsg dbugintf daemonapp

+ 2 - 1
packages/fcl-base/Makefile.fpc

@@ -45,7 +45,8 @@ units_win64=process fileinfo resolve ssockets syncobjs simpleipc dbugmsg dbugint
 units_wince=process fileinfo resolve ssockets syncobjs simpleipc dbugmsg dbugintf
 units_os2=resolve ssockets
 units_emx=resolve ssockets
-units_netware=resolve ssockets
+# syncobjs requires GetLastOSError function
+units_netware=resolve ssockets syncobjs
 units_netwlibc=resolve ssockets syncobjs
 rsts=ssockets cachecls resolve custapp cgiapp eventlog registry simpleipc streamcoll inicol
 

+ 8 - 0
rtl/netware/sysutils.pp

@@ -26,6 +26,7 @@ uses DOS;
 {$I nwsys.inc}
 {$I errno.inc}
 {$DEFINE HAS_SLEEP}
+{$DEFINE HAS_OSERROR}
 
 TYPE
   TNetwareFindData =
@@ -573,6 +574,13 @@ begin
   _delay (milliseconds);
 end;
 
+Function GetLastOSError : Integer;
+
+begin
+  Result:=Integer(__get_errno_ptr^);
+end;
+
+
 
 {****************************************************************************
                               Initialization code

+ 7 - 0
rtl/netwlibc/sysutils.pp

@@ -36,6 +36,7 @@ TYPE
   END;
 
 {$DEFINE HAS_SLEEP}
+{$DEFINE HAS_OSERROR}
 { Include platform independent interface part }
 {$i sysutilh.inc}
 
@@ -628,6 +629,12 @@ begin
   result := ExecuteProcess (Path, params);
 end;
 
+Function GetLastOSError : Integer;
+
+begin
+  Result:=Integer(GetLastError);
+end;
+
 
 {******************************************************************************
                                --- Exec ---