   // name stat.
   public func doStat(path: String, buffer: UnsafeMutablePointer<stat>)
       -> Int32 {
-    return _stat(path, buffer)
+    return Glibc.stat(path, buffer)
   }
 
   public func lstat(path: String, buffer: UnsafeMutablePointer<stat>) -> Int32 {
-    return _lstat(path, buffer)
+    return Glibc.lstat(path, buffer)
   }
 
   public func statBuffer() -> stat {

  }

  public func readdir(dirp: COpaquePointer) -> DirentEntry {
    return dirp != nil ? _readdir(dirp) : nil
  }

  public func opendir(path: String) -> COpaquePointer {
    return _opendir(path)
  }

  public func opendir(pathBytes: [UInt8]) -> COpaquePointer {
    return _opendir(UnsafePointer<CChar>(pathBytes))
  }

  public func closedir(dirp: COpaquePointer) -> Int32 {
    return retry { _closedir(dirp) }
  }

  public func fgets(buffer: UnsafeMutablePointer<CChar>, length: Int32,
      fp: UnsafeMutablePointer<FILE>) -> UnsafeMutablePointer<CChar> {
    return _fgets(buffer, length, fp)
  }

  public func fread(buffer: UnsafeMutablePointer<Void>, size: Int,
      nmemb: Int, fp: UnsafeMutablePointer<FILE>) -> Int {
    return _fread(buffer, size, nmemb, fp)
  }

  public func popen(command: String, operation: PopenOperation = .R)

public enum SysError: ErrorType {
  case InvalidOpenFileOperation(operation: String)
}

public enum FileOperation: Int {
  case R
