More SB-POSIX test fixes
... allow building as root again, since it seems that's a
desired feature
... test for not having EUID of 0 in EACCES posix tests instead
(this will probably annoy antifuchs, but I forgot to commit
version.lisp-expr for the last fix. Since this is logically a
simple continuation, I haven't bothered to increment it again)
should matter to you only if you rebind the printer control
variables and then find you want different bindings in the
debugger than in the ordinary execution of your program.)
should matter to you only if you rebind the printer control
variables and then find you want different bindings in the
debugger than in the ordinary execution of your program.)
- * minor incompatible change: the system no longer allows itself to
- be built as root. This is primarily to allow the SB-POSIX contrib
- module's test suite to assume that it is being run as an ordinary
- user, with the attendant filesystem permissions semantics that
- entails.
* The runtime build system has been tweaked to support building
(on SPARC/SunOS) using a C compiler which invokes Sun's own
assembler and linker. (thanks to Nikodemus Siivola)
* The runtime build system has been tweaked to support building
(on SPARC/SunOS) using a C compiler which invokes Sun's own
assembler and linker. (thanks to Nikodemus Siivola)
(defconstant +mode-rwx-all+ (logior sb-posix::s-irusr sb-posix::s-iwusr sb-posix::s-ixusr
sb-posix::s-irgrp sb-posix::s-iwgrp sb-posix::s-ixgrp
sb-posix::s-iroth sb-posix::s-iwoth sb-posix::s-ixoth)))
(defconstant +mode-rwx-all+ (logior sb-posix::s-irusr sb-posix::s-iwusr sb-posix::s-ixusr
sb-posix::s-irgrp sb-posix::s-iwgrp sb-posix::s-ixgrp
sb-posix::s-iroth sb-posix::s-iwoth sb-posix::s-ixoth)))
+
+(defmacro define-eacces-test (name form &rest values)
+ `(deftest ,name
+ (block ,name
+ (when (= (sb-posix:geteuid) 0)
+ (return-from ,name (values ,@values)))
+ ,form)
+ ,@values))
\f
(deftest chdir.1
(sb-posix:chdir *test-directory*)
\f
(deftest chdir.1
(sb-posix:chdir *test-directory*)
(sb-posix:syscall-errno c)))
#.sb-posix::eexist)
(sb-posix:syscall-errno c)))
#.sb-posix::eexist)
+(define-eacces-test mkdir.error.3
(let* ((dir (merge-pathnames
(make-pathname :directory '(:relative "mkdir.error.3"))
*test-directory*))
(let* ((dir (merge-pathnames
(make-pathname :directory '(:relative "mkdir.error.3"))
*test-directory*))
(or (= errno sb-posix::eexist) (= errno sb-posix::enotempty))))))
t)
(or (= errno sb-posix::eexist) (= errno sb-posix::enotempty))))))
t)
+(define-eacces-test rmdir.error.5
(let* ((dir (merge-pathnames
(make-pathname :directory '(:relative "rmdir.error.5"))
*test-directory*))
(let* ((dir (merge-pathnames
(make-pathname :directory '(:relative "rmdir.error.5"))
*test-directory*))
(sb-posix:syscall-errno c)))
#.sb-posix::enoent)
(sb-posix:syscall-errno c)))
#.sb-posix::enoent)
+(define-eacces-test stat.error.2
(let* ((dir (merge-pathnames
(make-pathname :directory '(:relative "stat.error.2"))
*test-directory*))
(let* ((dir (merge-pathnames
(make-pathname :directory '(:relative "stat.error.2"))
*test-directory*))
echo //entering make-config.sh
echo //entering make-config.sh
-echo //checking that we are not root
-if [ `id -u` -eq 0 ] ; then echo 'Argh! we are (fake)root!'; exit 1; fi;
-
echo //ensuring the existence of output/ directory
if [ ! -d output ] ; then mkdir output; fi
echo //ensuring the existence of output/ directory
if [ ! -d output ] ; then mkdir output; fi
;;; 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".)
;;; 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".)