From dd9c9b18505d8659fc65139abc78ae8ba5966e88 Mon Sep 17 00:00:00 2001 From: simonmar Date: Fri, 6 Sep 2002 14:38:15 +0000 Subject: [PATCH] [project @ 2002-09-06 14:38:15 by simonmar] Make it build on mingw32, with a cut-down set of types --- System/Posix/Types.hs | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) diff --git a/System/Posix/Types.hs b/System/Posix/Types.hs index 79b3446..7edc927 100644 --- a/System/Posix/Types.hs +++ b/System/Posix/Types.hs @@ -13,6 +13,8 @@ -- ----------------------------------------------------------------------------- +#include "config.h" + module System.Posix.Types ( CDev(..), CIno(..), CMode(..), COff(..), CPid(..), CSsize(..), @@ -23,15 +25,18 @@ module System.Posix.Types ( Fd(..), +#ifndef mingw32_TARGET_OS + LinkCount, + UserID, + GroupID, +#endif + ByteCount, ClockTick, EpochTime, FileOffset, - GroupID, - LinkCount, ProcessID, ProcessGroupID, - UserID, DeviceID, FileID, FileMode @@ -54,7 +59,6 @@ import GHC.Show #include "Dynamic.h" #include "CTypes.h" -#include "config.h" NUMERIC_TYPE(CDev,tyConCDev,"CDev",HTYPE_DEV_T) INTEGRAL_TYPE(CIno,tyConCIno,"CIno",HTYPE_INO_T) @@ -82,15 +86,18 @@ INTEGRAL_TYPE(CBlkCnt,tyConBlkCnd,"CBlkCnt",HTYPE_BLKCNT_T) INTEGRAL_TYPE(Fd,tyConFd,"Fd",CInt) -- nicer names, and backwards compatibility with POSIX library: +#ifndef mingw32_TARGET_OS +type LinkCount = CNlink +type UserID = CUid +type GroupID = CGid +#endif + type ByteCount = CSize type ClockTick = CClock type EpochTime = CTime -type LinkCount = CNlink type DeviceID = CDev type FileID = CIno type FileMode = CMode type ProcessID = CPid -type UserID = CUid -type GroupID = CGid type FileOffset = COff type ProcessGroupID = CPid -- 1.7.10.4