X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=tools-for-build%2Fldso-stubs.lisp;h=bff22d834435aff4b6a284be3f907005e957ad64;hb=743831e679b673a5680a0afd8402911516bf50e2;hp=45d24256093750ccc302e72b41e6b8deabb9b8c3;hpb=c2ac5ba3964165ee2d21ccd4c6bf8bdc48e1a165;p=sbcl.git diff --git a/tools-for-build/ldso-stubs.lisp b/tools-for-build/ldso-stubs.lisp index 45d2425..bff22d8 100644 --- a/tools-for-build/ldso-stubs.lisp +++ b/tools-for-build/ldso-stubs.lisp @@ -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 ; \\ @@ -117,8 +133,8 @@ ldso_stub__ ## fct ## $lazy_ptr: @\\ #define LDSO_STUBIFY(fct) \\ .text ; \\ .align 4 ; \\ -.globl _ldso_stub___ ## fct ; \\ -_ldso_stub___ ## fct: ; \\ +.globl _ldso_stub__ ## fct ; \\ +_ldso_stub__ ## fct: ; \\ jmp L ## fct ## $stub ; \\ .section __IMPORT,__jump_table,symbol_stubs,self_modifying_code+pure_instructions,5 ; \\ L ## fct ## $stub: ; \\ @@ -134,8 +150,8 @@ L ## fct ## $stub: ; \\ #!+(and darwin x86-64) " #define LDSO_STUBIFY(fct) \\ .align 4 ; \\ -.globl _ldso_stub___ ## fct ; \\ -_ldso_stub___ ## fct: ; \\ +.globl _ldso_stub__ ## fct ; \\ +_ldso_stub__ ## fct: ; \\ jmp _ ## fct ; \\ .L ## fct ## e1: ; " @@ -204,6 +220,7 @@ ldso_stub__ ## fct: ; \\ "fork" "free" "fstat" + #!+inode64 "fstat$INODE64" "fsync" "ftruncate" "getcwd" @@ -234,6 +251,7 @@ ldso_stub__ ## fct: ; \\ "log1p" "lseek" "lstat" + #!+inode64 "lstat$INODE64" "malloc" "memmove" "mkdir" @@ -258,6 +276,7 @@ ldso_stub__ ## fct: ; \\ "sinh" "socket" "stat" + #!+inode64 "stat$INODE64" "strerror" "strlen" "symlink" @@ -271,7 +290,7 @@ ldso_stub__ ## fct: ; \\ "tcsetattr" "truncate" "ttyname" - "tzname" + #!-hpux "tzname" "unlink" "utimes" "wait3" @@ -305,11 +324,13 @@ ldso_stub__ ## fct: ; \\ "unlockpt") #!+openbsd '("openpty") - #!-darwin + #!-dlshim '("dlclose" "dlerror" "dlopen" "dlsym") + #!+bsd + '("sysctl") #!+os-provides-dladdr '("dladdr") #!-sunos ;; !defined(SVR4)