[cmucl/cmucl][rtoy-unix-core] 2 commits: Export unix-uname. Used on linux and solaris.

Raymond Toy rtoy at common-lisp.net
Sun May 17 05:10:13 UTC 2015


Raymond Toy pushed to branch rtoy-unix-core at cmucl / cmucl


Commits:
42675559 by Raymond Toy at 2015-05-16T21:59:29Z
Export unix-uname.  Used on linux and solaris.

- - - - -
c076d550 by Raymond Toy at 2015-05-16T22:09:57Z
Support for netbsd.  From Robert Swindells.

- - - - -


2 changed files:

- src/code/exports.lisp
- src/code/unix.lisp


Changes:

=====================================
src/code/exports.lisp
=====================================
--- a/src/code/exports.lisp
+++ b/src/code/exports.lisp
@@ -248,6 +248,10 @@
 	   "CLOSE-DIR"
 	   "OPEN-DIR"
 	   "READ-DIR"
+
+	   ;; linux-os, sunos-os.
+	   "UNIX-UNAME"
+
 	   ;; filesys.lisp
 	   "UNIX-GETPWUID"
 


=====================================
src/code/unix.lisp
=====================================
--- a/src/code/unix.lisp
+++ b/src/code/unix.lisp
@@ -1226,6 +1226,27 @@
     (st-fstype (array char 16))
     (st-pad4 (array long 8))))
 
+#+netbsd
+(def-alien-type nil
+  (struct stat
+    (st-dev dev-t)
+    (st-mode mode-t)
+    (st-ino ino-t)
+    (st-nlink nlink-t)
+    (st-uid uid-t)
+    (st-gid gid-t)
+    (st-rdev dev-t)
+    (st-atime (struct timespec-t))
+    (st-mtime (struct timespec-t))
+    (st-ctime (struct timespec-t))
+    (st-birthtime (struct timespec-t))
+    (st-size off-t)
+    (st-blocks off-t)
+    (st-blksize long)
+    (st-flags   unsigned-long)
+    (st-gen     unsigned-long)
+    (st-spare (array unsigned-long 2))))
+
 (defmacro extract-stat-results (buf)
   `(values T
 	   (slot ,buf 'st-dev)



View it on GitLab: https://gitlab.common-lisp.net/cmucl/cmucl/compare/72afb878f276cef6b754ae2d5a0eff931bf457bc...c076d5501e7c12e8c9dcebbc30b117d0e9cc649d
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.common-lisp.net/pipermail/cmucl-cvs/attachments/20150517/a6f10a09/attachment.html>


More information about the cmucl-cvs mailing list