D issues are now tracked on GitHub. This Bugzilla instance remains as a read-only archive.
Issue 3185 - osx is not a directory (complains cannot read std/c/osx/socket.d)
Summary: osx is not a directory (complains cannot read std/c/osx/socket.d)
Status: RESOLVED FIXED
Alias: None
Product: D
Classification: Unclassified
Component: dmd (show other issues)
Version: D2
Hardware: Other Mac OS X
: P2 normal
Assignee: No Owner
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-07-16 22:40 UTC by Mike Kinney
Modified: 2015-06-09 01:28 UTC (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description Mike Kinney 2009-07-16 22:40:44 UTC
Looks the the dmd.2.031.zip has the osx directory as a single file.

When you try to compile the samples/d/listener.d, you get this:
$ dmd listener.d 
/Users/mikekinney/dmd2/osx/bin/../../src/phobos/std/socket.d(79): Error: module socket cannot read file 'std/c/osx/socket.d'

Checked the zip file and it does not show dmd2/src/phobos/std/c/osx/socket.d :
$ unzip -l dmd.2.031.zip | grep socket.d
    15145  05-03-09 15:07   dmd2/src/druntime/import/core/sys/posix/sys/socket.d
     2694  07-05-09 01:19   dmd2/src/phobos/std/c/linux/socket.d
    38820  07-05-09 01:19   dmd2/src/phobos/std/socket.d

Because osx is a file not a directory:
$ ls -al dmd2/src/phobos/std/c | grep osx
-rw-r--r--   1 mikekinney  staff  2633 Jul  5 01:19 osx
$ head dmd2/src/phobos/std/c/osx
/*
    Written by Christopher E. Miller
    Placed into public domain.
*/


module std.c.osx.socket;

private import core.stdc.stdint;
public import core.sys.posix.arpa.inet;
Comment 1 Walter Bright 2009-09-03 13:41:37 UTC
Fixed dmd 2.032