Ian Lynagh [Wed, 11 Aug 2010 18:27:30 +0000 (18:27 +0000)]
Add emptyPermissions
Ian Lynagh [Mon, 2 Aug 2010 17:27:59 +0000 (17:27 +0000)]
Make the permissions type abstract
simonpj@microsoft.com [Tue, 27 Jul 2010 15:17:46 +0000 (15:17 +0000)]
Avoid need for ambiguity resolution; be explicit
Simon Marlow [Wed, 23 Jun 2010 10:43:44 +0000 (10:43 +0000)]
require base-4.2; the Windows code needs withFilePath (#4147)
Ian Lynagh [Sun, 13 Jun 2010 13:42:35 +0000 (13:42 +0000)]
Check for a NULL result from realpath; fixes #4113 on non-Windows
Simon Marlow [Wed, 2 Jun 2010 08:24:44 +0000 (08:24 +0000)]
Allow base-4.3
Simon Marlow [Wed, 5 May 2010 10:13:26 +0000 (10:13 +0000)]
Allow filepath-1.2.*
Ian Lynagh [Sat, 27 Feb 2010 21:01:28 +0000 (21:01 +0000)]
Bump version number
Simon Marlow [Fri, 26 Feb 2010 09:31:44 +0000 (09:31 +0000)]
Fix #3878: various directory tests were wrong on Unix systems
benl@cse.unsw.edu.au [Wed, 3 Feb 2010 07:09:57 +0000 (07:09 +0000)]
On Solaris, _FILE_OFFSET_BITS must be defined before including sys/stat.h
Malcolm.Wallace@cs.york.ac.uk [Tue, 24 Nov 2009 03:32:46 +0000 (03:32 +0000)]
Make it build with nhc98 again.
Recent changes use System.Posix or System.Win32, neither of which is
available to nhc98.
Malcolm.Wallace@cs.york.ac.uk [Mon, 23 Nov 2009 09:54:12 +0000 (09:54 +0000)]
Make indentation H'98 compliant.
Malcolm.Wallace@cs.york.ac.uk [Mon, 23 Nov 2009 09:05:57 +0000 (09:05 +0000)]
Use H'98-compliant indentation in do-block.
Ian Lynagh [Thu, 19 Nov 2009 12:29:51 +0000 (12:29 +0000)]
Include sys/types.h in HsDirectory.h; fixes trac #3653
Ian Lynagh [Tue, 22 Sep 2009 00:13:56 +0000 (00:13 +0000)]
Update output: filenames in exceptions on Windows
Ian Lynagh [Sun, 20 Sep 2009 14:18:52 +0000 (14:18 +0000)]
Bump version to 1.0.1.0
Ian Lynagh [Fri, 11 Sep 2009 16:07:28 +0000 (16:07 +0000)]
Allow building with base 4.2
Ian Lynagh [Sun, 9 Aug 2009 12:06:37 +0000 (12:06 +0000)]
Export copyPermissions; fixes proposal #3392
Simon Marlow [Mon, 29 Jun 2009 11:26:04 +0000 (11:26 +0000)]
move Win32 SearchPath and SHGetFolderPath into the Win32 package
That completes the transition to Unicode FilePath support in the
directory package on Win32 (#3300).
The main cleanup remaining to do here is to use native Win32
implementations of getPermissions/setPermissions/copyPermissions
instead of calls to stat().
We are very close to being able to remove the last bits of C and
autoconf here...
Simon Marlow [Mon, 29 Jun 2009 11:08:36 +0000 (11:08 +0000)]
add a test for getHomeDirectory et. al.
Simon Marlow [Tue, 23 Jun 2009 08:11:29 +0000 (08:11 +0000)]
add Windows output
Simon Marlow [Thu, 18 Jun 2009 13:48:58 +0000 (13:48 +0000)]
Windows: Unicode getDirectoryContents and setPermissions
Simon Marlow [Thu, 18 Jun 2009 10:29:00 +0000 (10:29 +0000)]
add a test for getDirectoryContents on a non-existent directory
Simon Marlow [Wed, 17 Jun 2009 15:38:52 +0000 (15:38 +0000)]
Decouple from System.Posix.Internals on Unix
This will let me clean up System.Posix.Internals, and move in the
direction of having System.Directory depend only on either
System.Posix or System.Win32.
Simon Marlow [Fri, 29 May 2009 13:22:05 +0000 (13:22 +0000)]
changes for the new IO library
Simon Marlow [Fri, 29 May 2009 12:34:49 +0000 (12:34 +0000)]
Fix #3189: add docs to findExecutable
Simon Marlow [Thu, 28 May 2009 13:57:06 +0000 (13:57 +0000)]
Fix #3189: use System.Win32.getFullPathName
Ian Lynagh [Sun, 24 May 2009 15:59:51 +0000 (15:59 +0000)]
Give bounds for the dependencies; fixes #3141
Malcolm.Wallace@cs.york.ac.uk [Wed, 1 Apr 2009 10:59:53 +0000 (10:59 +0000)]
use Nhc98BaseConfig.h rather than HsDirectoryConfig.h
Malcolm.Wallace@cs.york.ac.uk [Mon, 16 Mar 2009 11:38:15 +0000 (11:38 +0000)]
Since __hscore_R_OK and friends are inline C, use correct .h location.
This patch just adds HsDirectory.h into the foreign imports of these
values. Without it, nhc98 cannot generate correct interfacing code.
Ian Lynagh [Fri, 13 Mar 2009 21:13:57 +0000 (21:13 +0000)]
Stop the copyFile00{1,2} tests tripping over each other
Simon Marlow [Thu, 12 Mar 2009 16:14:08 +0000 (16:14 +0000)]
FIX #3086: use System.Win32.getTemporaryDirectory
Simon Marlow [Wed, 11 Mar 2009 11:37:37 +0000 (11:37 +0000)]
FIX #2963: Use System.Win32.getCurrentDirectory
Ian Lynagh [Sat, 7 Mar 2009 15:38:47 +0000 (15:38 +0000)]
Add config.guess, config.sub and install-sh
Malcolm.Wallace@cs.york.ac.uk [Wed, 18 Feb 2009 12:03:00 +0000 (12:03 +0000)]
Fix Hugs build (#ifdef code inclusion was slightly wrong)
Malcolm.Wallace@cs.york.ac.uk [Fri, 6 Feb 2009 17:34:47 +0000 (17:34 +0000)]
nhc98 now uses more of the code (shared with ghc) here.
Simon Marlow [Wed, 4 Feb 2009 16:33:19 +0000 (16:33 +0000)]
fix this test for the new version of createDirectoryIfMissing (#2808)
- add another race test, for two threads both doing create;cleanup
- ignore isDoesNotExistErrors in create
Duncan Coutts [Mon, 22 Dec 2008 16:41:05 +0000 (16:41 +0000)]
Fix createDirectoryIfMissing to not throw if the dir got deleted
When we call createDirectory and some file system object already exists
we have a problem. We need to distinguish if it is a file that already
exists or if it is a directory because in the latter case it is not an
error. Previously we called doesDirectoryExist however that does not
distinguish the dir not existing (due to another thread deleting it)
and an ordinary file existing. We now use withFileStatus to throw the
original AlreadyExistsError only if a non-directory object exists.
So now the only time we should get a spurious exception is if another
thread deletes the directory and puts a file in its place between our
call to createDirectory and withFileStatus. It should now be safe to
race createDirectoryIfMissing with itself or deleteDirectoryRecursive.
Duncan Coutts [Thu, 18 Dec 2008 14:47:04 +0000 (14:47 +0000)]
Alternative implementation of createDirectoryIfMissing
Ian Lynagh [Thu, 22 Jan 2009 01:12:58 +0000 (01:12 +0000)]
Require Cabal version >= 1.6
Ian Lynagh [Wed, 21 Jan 2009 18:21:23 +0000 (18:21 +0000)]
Add "bug-reports" and "source-repository" info to the Cabal file
Ian Lynagh [Fri, 9 Jan 2009 18:25:54 +0000 (18:25 +0000)]
Fix getPermissions001 on Windows
Ian Lynagh [Sun, 4 Jan 2009 17:31:59 +0000 (17:31 +0000)]
Avoid using IOError internals
Simon Marlow [Mon, 1 Dec 2008 09:18:39 +0000 (09:18 +0000)]
add Windows output
Simon Marlow [Mon, 1 Dec 2008 09:22:54 +0000 (09:22 +0000)]
rename test directory to avoid clash
Simon Marlow [Wed, 26 Nov 2008 12:36:59 +0000 (12:36 +0000)]
avoid race conditions in createDirectoryIfMissing (#2808)
Simon Marlow [Wed, 26 Nov 2008 11:56:06 +0000 (11:56 +0000)]
add test for createDirectoryIfMissing (#2808)
Simon Marlow [Fri, 14 Nov 2008 10:41:13 +0000 (10:41 +0000)]
add some extra_cleans
Simon Marlow [Wed, 12 Nov 2008 12:21:18 +0000 (12:21 +0000)]
make this test more robust to changes in the testsuite driver
Simon Marlow [Sat, 27 Sep 2008 13:31:11 +0000 (13:31 +0000)]
Fix these tests
Ian Lynagh [Sat, 20 Sep 2008 16:00:29 +0000 (16:00 +0000)]
Bump version number to 1.0.0.2
Ross Paterson [Sun, 31 Aug 2008 14:39:21 +0000 (14:39 +0000)]
fix typo in extra-source-files
Malcolm.Wallace@cs.york.ac.uk [Thu, 28 Aug 2008 10:47:33 +0000 (10:47 +0000)]
fix cabal build-depends for nhc98
Simon Marlow [Tue, 26 Aug 2008 09:17:19 +0000 (09:17 +0000)]
add createDirectory (already exists) test
Ross Paterson [Sun, 24 Aug 2008 22:44:13 +0000 (22:44 +0000)]
add extra-source-files
Ross Paterson [Sun, 24 Aug 2008 00:30:13 +0000 (00:30 +0000)]
add category field
Simon Marlow [Thu, 21 Aug 2008 14:35:50 +0000 (14:35 +0000)]
make more use of System.Win32 or System.Posix
Simon Marlow [Wed, 20 Aug 2008 14:01:24 +0000 (14:01 +0000)]
fix #2298: use MoveFileEx() on Windows
Simon Marlow [Mon, 18 Aug 2008 15:50:59 +0000 (15:50 +0000)]
test for renameFile
Ross Paterson [Tue, 12 Aug 2008 23:45:53 +0000 (23:45 +0000)]
import the Haskell 98 module Control.Exception.Base instead
Malcolm.Wallace@cs.york.ac.uk [Tue, 5 Aug 2008 15:52:53 +0000 (15:52 +0000)]
fixup for change of exception types in nhc98
Ian Lynagh [Sun, 3 Aug 2008 11:41:20 +0000 (11:41 +0000)]
Remove uses of catchAny and ignoreExceptions
Ian Lynagh [Mon, 23 Jun 2008 19:31:05 +0000 (19:31 +0000)]
Follow extensible exceptions changes
Ian Lynagh [Thu, 3 Jul 2008 15:47:32 +0000 (15:47 +0000)]
Silence warnings
Ian Lynagh [Fri, 20 Jun 2008 01:13:18 +0000 (01:13 +0000)]
Fix warnings in directory
Ian Lynagh [Wed, 11 Jun 2008 18:08:44 +0000 (18:08 +0000)]
Make currentDirectory001 not conflict with other tests running in parallel
Malcolm.Wallace@cs.york.ac.uk [Wed, 20 Feb 2008 10:24:53 +0000 (10:24 +0000)]
unbreak previous patch for nhc98
Simon Marlow [Mon, 18 Feb 2008 12:29:08 +0000 (12:29 +0000)]
getTemporaryDirectory: be more precise when catching exns from getEnv
Simon Marlow [Tue, 5 Feb 2008 14:54:50 +0000 (14:54 +0000)]
make this test work on Windows
I have no idea why it worked before
Simon Marlow [Tue, 22 Jan 2008 16:59:14 +0000 (16:59 +0000)]
canonicalizePath should also do System.FilePath.normalise
The example I've found where this is necessary is on Windows:
canonicalizePath on its own doesn't upper-case the drive letter, but
normalise does.
Ian Lynagh [Mon, 26 Nov 2007 21:42:52 +0000 (21:42 +0000)]
Fix a URL
Ross Paterson [Sat, 17 Nov 2007 14:40:59 +0000 (14:40 +0000)]
fix imports for non-GHC
Duncan Coutts [Thu, 18 Oct 2007 12:49:40 +0000 (12:49 +0000)]
Specify build-type: Configure
Simon Marlow [Thu, 18 Oct 2007 13:32:20 +0000 (13:32 +0000)]
this sneaked in somehow
Simon Marlow [Thu, 18 Oct 2007 13:06:23 +0000 (13:06 +0000)]
add test for #1652
Simon Marlow [Thu, 18 Oct 2007 12:17:55 +0000 (12:17 +0000)]
import System.Directory, not Directory
Simon Marlow [Thu, 18 Oct 2007 12:14:05 +0000 (12:14 +0000)]
move copyFile001 from testsuite
Simon Marlow [Thu, 18 Oct 2007 12:01:15 +0000 (12:01 +0000)]
Move tests from testsuite/tests/ghc-regress/lib/Directory
Ian Lynagh [Thu, 13 Sep 2007 21:05:26 +0000 (21:05 +0000)]
Add more entries to boring file
Ian Lynagh [Thu, 13 Sep 2007 20:46:48 +0000 (20:46 +0000)]
Add a boring file
sven.panne@aedion.de [Sun, 2 Sep 2007 12:55:21 +0000 (12:55 +0000)]
Fixed permission setting in copyFile
Copy the permissions to the *temporary* file before moving it, no to the
probably non-existing real destination file. Before this fix, "try" silently
wiped this bug under the carpet, leading to silently broken permissions.
Simon Marlow [Fri, 24 Aug 2007 10:41:06 +0000 (10:41 +0000)]
delete configure droppings in setup clean
Simon Marlow [Thu, 23 Aug 2007 11:16:05 +0000 (11:16 +0000)]
FIX #1280: getPermissions wasn't working on Vista
It turns out that _access() in the Windows C runtime used to ignore
the X_OK flag, in Vista it now returns an error. After browsing the C
runtime sources, I discovered that _stat() has an almost but not quite
completely bogus implementation of the st_mode field, which lets us
implement a slightly less incorrect approximation to getPermissions than does
_access().
Malcolm.Wallace@cs.york.ac.uk [Sat, 4 Aug 2007 09:28:15 +0000 (09:28 +0000)]
Restore working version of copyFile for nhc98.
The recent patch changing its implementation was insufficiently portable.
Ian Lynagh [Sun, 22 Jul 2007 11:26:49 +0000 (11:26 +0000)]
Use Control.Exception exception handlers, and make copyFile meet its spec
copyFile wasn't atomic before
Ian Lynagh [Sun, 22 Jul 2007 10:34:05 +0000 (10:34 +0000)]
Fix whitespace
Ian Lynagh [Sat, 21 Jul 2007 20:01:54 +0000 (20:01 +0000)]
Fix doesDirectoryExist; fixes trac #1490
We used to always strip trailing path separators from the path we were
given, but mingw's stat succeeds for C:\ and C:\foo but fails for C:
and C:\foo\. Thus we now use a trailing slash if and only if the path
we are given is a drive.
Ian Lynagh [Sun, 1 Jul 2007 22:25:33 +0000 (22:25 +0000)]
Ooops, we don't have dropDrive
Without it we sometimes do a redundant directory creation attempt, but
no harm should be done.
Ian Lynagh [Sat, 30 Jun 2007 12:52:44 +0000 (12:52 +0000)]
Use filepath rather than our own System.Directory.Internals
Ian Lynagh [Sat, 30 Jun 2007 10:58:34 +0000 (10:58 +0000)]
Add makeRelativeToCurrentDirectory
Moved from the filepath package, which we now depend on.
Malcolm.Wallace@cs.york.ac.uk [Wed, 27 Jun 2007 10:39:23 +0000 (10:39 +0000)]
Avoid using C comments in Haskell code :-)
Bertram Felgenhauer [Wed, 13 Jun 2007 04:03:40 +0000 (04:03 +0000)]
install HsDirectoryConfig.h
Simon Marlow [Wed, 6 Jun 2007 14:21:53 +0000 (14:21 +0000)]
#undef PACKAGE_NAME and friends to avoid clashes
Ross Paterson [Mon, 4 Jun 2007 11:59:35 +0000 (11:59 +0000)]
--configure-option and --ghc-option are now provided by Cabal
Malcolm.Wallace@cs.york.ac.uk [Fri, 25 May 2007 10:25:40 +0000 (10:25 +0000)]
Cpp exclusion macro -> defined(__GLASGOW_HASKELL__) || defined(__HUGS__)
Nhc98 does not define the symbol __NHC__ when compiling C code.
Ross Paterson [Fri, 25 May 2007 00:51:19 +0000 (00:51 +0000)]
all but NHC
Ross Paterson [Fri, 25 May 2007 00:16:25 +0000 (00:16 +0000)]
update CFILES pragma (used by Hugs only)
Malcolm.Wallace@cs.york.ac.uk [Thu, 24 May 2007 14:45:08 +0000 (14:45 +0000)]
glasgow only
Ian Lynagh [Thu, 24 May 2007 14:17:45 +0000 (14:17 +0000)]
Put configure.ac back in the repo; not sure how it got removed
Ian Lynagh [Wed, 23 May 2007 20:09:04 +0000 (20:09 +0000)]
Need shlobj.h on Windows