Commit dcd86042 authored by Nikodemus Siivola's avatar Nikodemus Siivola
Browse files

1.0.24.12: adding and fixing the HPUX/HPPA build target

 * Patch by Larry Valkama.
parent 1d502618
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -348,6 +348,7 @@
 ;;   :darwin  = We're intended to run under Darwin (including MacOS X).
 ;;   :sunos   = We're intended to run under Solaris user environment
 ;;              with the SunOS kernel.
 ;;   :hpux    = We're intended to run under HP-UX 11.11 or later
 ;;   :osf1    = We're intended to run under Tru64 (aka Digital Unix
 ;;              aka OSF/1).
 ;;   :win32   = We're intended to under some version of Microsoft Windows.
+12 −0
Original line number Diff line number Diff line
@@ -53,6 +53,9 @@ case `uname` in
    CYGWIN* | WindowsNT | MINGW*)
        sbcl_os="win32"
        ;;
    HP-UX)
        sbcl_os="hpux"
        ;;
    *)
        echo unsupported OS type: `uname`
        exit 1
@@ -110,6 +113,7 @@ case `uname -m` in
    ppc64) guessed_sbcl_arch=ppc ;;
    Power*Macintosh) guessed_sbcl_arch=ppc ;;
    parisc) guessed_sbcl_arch=hppa ;;
    9000/800) guessed_sbcl_arch=hppa ;;
    mips*) guessed_sbcl_arch=mips ;;
    *)
        # If we're not building on a supported target architecture, we
@@ -188,6 +192,14 @@ case "$sbcl_os" in
        link_or_copy $sbcl_arch-osf1-os.h target-arch-os.h
        link_or_copy osf1-os.h target-os.h
        ;;
    hpux)
        printf ' :unix' >> $ltf
        printf ' :elf' >> $ltf
        printf ' :hpux' >> $ltf
        link_or_copy Config.$sbcl_arch-hpux Config
        link_or_copy $sbcl_arch-hpux-os.h target-arch-os.h
        link_or_copy hpux-os.h target-os.h
        ;;
    *bsd)
        printf ' :unix' >> $ltf
        printf ' :bsd' >> $ltf
+2 −2
Original line number Diff line number Diff line
@@ -129,7 +129,7 @@

(defun-with-dx dx-value-cell (x)
  ;; Not implemented everywhere, yet.
  #+(or x86 x86-64 mips)
  #+(or x86 x86-64 mips hppa)
  (let ((cell x))
    (declare (sb-int:truly-dynamic-extent cell))
    (flet ((f ()
@@ -463,7 +463,7 @@

(defvar *a-cons* (cons nil nil))

#+(or x86 x86-64 alpha ppc sparc mips)
#+(or x86 x86-64 alpha ppc sparc mips hppa)
(progn
  (assert-no-consing (dxclosure 42))
  (assert-no-consing (dxlength 1 2 3))
+7 −5
Original line number Diff line number Diff line
@@ -47,6 +47,10 @@

#include "genesis/config.h"

#ifdef LISP_FEATURE_HPUX
#include <sys/bsdtty.h> /* for TIOCGPGRP */
#endif

#include "wrap.h"

#define DEFTYPE(lispname,cname) { cname foo; \
@@ -323,11 +327,10 @@ main(int argc, char *argv[])
    printf("\n");

    printf(";;; various ioctl(2) flags\n");
    defconstant("tiocnotty",  TIOCNOTTY);
    defconstant("tiocgwinsz", TIOCGWINSZ);
    defconstant("tiocswinsz", TIOCSWINSZ);
    defconstant("tiocgpgrp",  TIOCGPGRP);
    defconstant("tiocspgrp",  TIOCSPGRP);
    defconstant("tiocgwinsz", TIOCGWINSZ);
    defconstant("tiocswinsz", TIOCSWINSZ);
    /* KLUDGE: These are referenced by old CMUCL-derived code, but
     * Linux doesn't define them.
     *
@@ -399,7 +402,7 @@ main(int argc, char *argv[])
    defsignal("sigwaiting", SIGWAITING);
#endif
    defsignal("sigwinch", SIGWINCH);
#ifndef SIGXCPU
#ifdef SIGXCPU
    defsignal("sigxcpu", SIGXCPU);
#endif
#ifdef SIGXFSZ
@@ -428,7 +431,6 @@ main(int argc, char *argv[])
#else
    defconstant("fpe-fltsub", -1);
#endif

#endif // !WIN32
    return 0;
}
+21 −5
Original line number Diff line number Diff line
@@ -22,16 +22,16 @@
;;;; files for more information.

#!-sparc
(defun ldso-stubify (fct str)
  (format str "LDSO_STUBIFY(~A)~%" fct))
(defun ldso-stubify (fct stream)
  (format stream "LDSO_STUBIFY(~A)~%" fct))

;;; This is an attempt to follow DB's hint of sbcl-devel
;;; 2001-09-18. -- CSR
;;;
;;; And an attempt to work around the Sun toolchain... --ns
#!+sparc
(defun ldso-stubify (fct str)
  (apply #'format str "
(defun ldso-stubify (fct stream)
  (apply #'format stream "
.globl ldso_stub__~A ;                          \\
        FUNCDEF(ldso_stub__~A) ;                \\
ldso_stub__~A: ;                                \\
@@ -42,6 +42,18 @@ ldso_stub__~A: ; \\
        .size    ldso_stub__~A,.L~Ae1-ldso_stub__~A ;~%"
          (make-list 9 :initial-element fct)))

#!+hppa
(defun ldso-stubify (fct stream)
  (let ((stub (format nil "ldso_stub__~a" fct)))
    (apply #'format stream (list
"    .export ~A
~A:
    .proc
    .callinfo
    b,n ~a
    .procend
    .import ~a,code~%" stub stub fct fct))))

(defvar *preludes* '("
/* This is an automatically generated file, please do not hand-edit it.
 * See the program tools-for-build/ldso-stubs.lisp. */
@@ -85,6 +97,10 @@ ldso_stub__ ## fct: ; \\
.L ## fct ## e1: ;                              \\
        .size    ldso_stub__ ## fct,.L ## fct ## e1-ldso_stub__ ## fct ;"

#!+hppa "
        .level  2.0
        .text"

#!+(and (not darwin) ppc) "
#define LDSO_STUBIFY(fct)                       \\
.globl ldso_stub__ ## fct ;                     \\
@@ -271,7 +287,7 @@ ldso_stub__ ## fct: ; \\
                   "tcsetattr"
                   "truncate"
                   "ttyname"
                   "tzname"
                   #!-hpux "tzname"
                   "unlink"
                   "utimes"
                   "wait3"
Loading