1.0.41.55: Solaris fixes
authorJuho Snellman <jsnell@iki.fi>
Mon, 23 Aug 2010 23:21:27 +0000 (23:21 +0000)
committerJuho Snellman <jsnell@iki.fi>
Mon, 23 Aug 2010 23:21:27 +0000 (23:21 +0000)
     * Remove bashisms.
     * Conditionalize out some constants and functions that
       don't exist on Solaris.
     * Patch from Jim Wise.

contrib/asdf-module.mk
contrib/sb-bsd-sockets/constants.lisp
contrib/sb-posix/constants.lisp
contrib/sb-posix/interface.lisp
contrib/sb-posix/posix-tests.lisp
tests/subr.sh
version.lisp-expr

index a9e55d7..b6edb51 100644 (file)
@@ -11,6 +11,7 @@ UNAME:=$(shell uname -s)
 
 ifeq (SunOS,$(UNAME))
   EXTRA_CFLAGS=-D_XOPEN_SOURCE=500 -D__EXTENSIONS__
+  PATH:=/usr/xpg4/bin:${PATH}
 endif
 ifeq (CYGWIN,$(findstring CYGWIN,$(UNAME)))
   EXTRA_CFLAGS=-mno-cygwin
index 2b131f2..3cc35a4 100644 (file)
@@ -47,7 +47,7 @@
            "Send periodic keepalives: if peer does not respond, we get SIGPIPE")
  (:integer so-oobinline "SO_OOBINLINE"
            "Put out-of-band data into the normal input queue when received")
- #-freebsd
+ #+linux
  (:integer so-no-check "SO_NO_CHECK")
  #+linux (:integer so-priority "SO_PRIORITY")
  (:integer so-linger "SO_LINGER"
@@ -85,7 +85,7 @@
  (:integer NO-RECOVERY "NO_RECOVERY" "Non recoverable errors, FORMERR, REFUSED, NOTIMP.")
  (:integer NO-DATA "NO_DATA" "Valid name, no data record of requested type.")
  (:integer NO-ADDRESS "NO_ADDRESS" "No address, look for MX record.")
- #-hpux (:function h-strerror ("hstrerror" c-string (errno int)))
+ #-(or hpux sunos) (:function h-strerror ("hstrerror" c-string (errno int)))
 
  (:integer O-NONBLOCK "O_NONBLOCK")
  (:integer f-getfl "F_GETFL")
@@ -98,7 +98,7 @@
  (:integer msg-eor "MSG_EOR")
  (:integer msg-dontroute "MSG_DONTROUTE")
  (:integer msg-dontwait "MSG_DONTWAIT")
- (:integer msg-nosignal "MSG_NOSIGNAL")
+ #+linux (:integer msg-nosignal "MSG_NOSIGNAL")
  #+linux (:integer msg-confirm "MSG_CONFIRM")
  #+linux (:integer msg-more "MSG_MORE")
 
index 2d3c90a..c00a7bf 100644 (file)
  (:errno ecomm "ECOMM" nil t)
  (:errno eproto "EPROTO" nil t)
  (:errno emultihop "EMULTIHOP" nil t)
- (:errno edotdot "EDOTDOT" nil t)
+#-sunos (:errno edotdot "EDOTDOT" nil t)
  (:errno ebadmsg "EBADMSG" nil t)
  (:errno eoverflow "EOVERFLOW" nil t)
  (:errno enotuniq "ENOTUNIQ" nil t)
  (:errno ealready "EALREADY" nil t)
  (:errno einprogress "EINPROGRESS" nil t)
  (:errno estale "ESTALE" nil t)
- (:errno euclean "EUCLEAN" nil t)
- (:errno enotnam "ENOTNAM" nil t)
- (:errno enavail "ENAVAIL" nil t)
- (:errno eremoteio "EREMOTEIO" nil t)
- (:errno edquot "EDQUOT" nil t)
- (:errno enomedium "ENOMEDIUM" nil t)
- (:errno emediumtype "EMEDIUMTYPE" nil t)
+#-sunos (:errno euclean "EUCLEAN" nil t)
+#-sunos (:errno enotnam "ENOTNAM" nil t)
+#-sunos (:errno enavail "ENAVAIL" nil t)
+#-sunos (:errno eremoteio "EREMOTEIO" nil t)
+#-sunos (:errno edquot "EDQUOT" nil t)
+#-sunos (:errno enomedium "ENOMEDIUM" nil t)
+#-sunos (:errno emediumtype "EMEDIUMTYPE" nil t)
 
  ;; wait
  (:integer wnohang "WNOHANG")
  (:integer s-ifreg "S_IFREG" nil t)
  (:integer s-iflnk "S_IFLNK" nil t)
  (:integer s-ifsock "S_IFSOCK" nil t)
- (:integer s-ifwht "S_IFWHT" nil t)
+#-sunos (:integer s-ifwht "S_IFWHT" nil t)
  (:integer s-isuid "S_ISUID" nil t)
  (:integer s-isgid "S_ISGID" nil t)
  (:integer s-isvtx "S_ISVTX" nil t)
  (:integer o-ndelay "O_NDELAY" nil t)
  (:integer o-sync "O_SYNC" nil t)
  (:integer o-nofollow "O_NOFOLLOW" nil t)
- (:integer o-directory "O_DIRECTORY" nil t)
- (:integer o-direct "O_DIRECT" nil t)
- (:integer o-async "O_ASYNC" nil t)
+#-sunos (:integer o-directory "O_DIRECTORY" nil t)
+#-sunos (:integer o-direct "O_DIRECT" nil t)
+#-sunos (:integer o-async "O_ASYNC" nil t)
  (:integer o-largefile "O_LARGEFILE" nil t)     ; hmm...
  (:integer o-dsync "O_DSYNC" nil t)
  (:integer o-rsync "O_RSYNC" nil t)
  ;; Additional, non-standard openlog() facilities (most of which
  ;; probably won't be needed by Lisp programs, but here for
  ;; completeness).
- #-win32
+ #-(or win32 sunos)
  (:integer
   log-authpriv "LOG_AUTHPRIV" "openlog() facility for authorization messages" t)
  #-win32
  #-win32
  (:integer
   log-daemon "LOG_DAEMON" "openlog() facility for arbitrary daemons" t)
- #-win32
+ #-(or win32 sunos)
  (:integer
   log-ftp "LOG_FTP" "openlog() facility for FTP daemons" t)
  #-win32
   "If supplied to openlog(), do not wait for child processes created by calls to syslog()."
   t)
  ;; Not in SUSv3, but at least Glibc and BSD libc have this
- #-win32
+ #-(or win32 sunos)
  (:integer
   log-perror "LOG_PERROR"
   "If supplied to openlog(), write log messages to the process's standard error descriptor in addition to the logging facility."
index 0995a1d..9d248dd 100644 (file)
 
   ;; uid, gid
   (define-call "geteuid" uid-t never-fails) ; "always successful", it says
-  (define-call "getresuid" uid-t never-fails)
+#-sunos  (define-call "getresuid" uid-t never-fails)
   (define-call "getuid" uid-t never-fails)
   (define-call "seteuid" int minusp (uid uid-t))
-  (define-call "setfsuid" int minusp (uid uid-t))
+#-sunos  (define-call "setfsuid" int minusp (uid uid-t))
   (define-call "setreuid" int minusp (ruid uid-t) (euid uid-t))
-  (define-call "setresuid" int minusp (ruid uid-t) (euid uid-t) (suid uid-t))
+#-sunos  (define-call "setresuid" int minusp (ruid uid-t) (euid uid-t) (suid uid-t))
   (define-call "setuid" int minusp (uid uid-t))
   (define-call "getegid" gid-t never-fails)
   (define-call "getgid" gid-t never-fails)
-  (define-call "getresgid" gid-t never-fails)
+#-sunos  (define-call "getresgid" gid-t never-fails)
   (define-call "setegid" int minusp (gid gid-t))
-  (define-call "setfsgid" int minusp (gid gid-t))
+#-sunos  (define-call "setfsgid" int minusp (gid gid-t))
   (define-call "setgid" int minusp (gid gid-t))
   (define-call "setregid" int minusp (rgid gid-t) (egid gid-t))
-  (define-call "setresgid" int minusp (rgid gid-t) (egid gid-t) (sgid gid-t))
+#-sunos  (define-call "setresgid" int minusp (rgid gid-t) (egid gid-t) (sgid gid-t))
 
   ;; processes, signals
   (define-call "alarm" int never-fails (seconds unsigned))
index 78f99ba..95afdd5 100644 (file)
   #.sb-posix:eisdir
   #+win32
   #.sb-posix::eacces
-  #-(or darwin win32)
+  #+sunos
+  #.sb-posix::einval
+  #-(or darwin win32 sunos)
   #.sb-posix::ebusy)
 
 (deftest rmdir.error.4
 
 ;#-(or win32 sunos hpux)
 ;;;; mkdtemp is unimplemented on at least Solaris 10
-#-(or win32 hpux)
+#-(or win32 hpux sunos)
 ;;; But it is implemented on OpenSolaris 2008.11
 (deftest mkdtemp.1
     (let ((pathname
index eaa86fa..c0e67f8 100644 (file)
@@ -32,8 +32,8 @@ SBCL_RUNTIME="$SBCL_PWD/../src/runtime/sbcl"
 SBCL_ARGS="--noinform --no-sysinit --no-userinit --noprint --disable-debugger"
 
 # Scripts that use these variables should quote them.
-TEST_BASENAME="$(basename $0)"
-TEST_FILESTEM="$(echo ${TEST_BASENAME%.sh} | sed 's/\./-/g')"
+TEST_BASENAME="`basename $0`"
+TEST_FILESTEM="`echo ${TEST_BASENAME%.sh} | sed 's/\./-/g'`"
 TEST_DIRECTORY="$SBCL_PWD/$TEST_FILESTEM-$$"
 
 # "Ten four" is the closest numerical slang I can find to "OK", so
index 8b4db62..7d634e0 100644 (file)
@@ -17,4 +17,4 @@
 ;;; checkins which aren't released. (And occasionally for internal
 ;;; versions, especially for internal versions off the main CVS
 ;;; branch, it gets hairier, e.g. "0.pre7.14.flaky4.13".)
-"1.0.41.54"
+"1.0.41.55"