uffi/tests foreign-loader.lisp,NONE,1.1
"Kevin M. Rosenberg" <[email protected]> Thu, 1 May 2003 20:54:57 -0600
| Newsgroups | gmane.lisp.uffi.cvs |
|---|---|
| Message-ID | <[email protected]> |
Update of /pubcvs/uffi/tests
In directory boa.b9.com:/tmp/cvs-serv32274
Added Files:
foreign-loader.lisp
Log Message:
--- NEW FILE: foreign-loader.lisp ---
;;;; -*- Mode: Lisp; Syntax: ANSI-Common-Lisp; Base: 10 -*-
;;;; *************************************************************************
;;;; FILE IDENTIFICATION
;;;;
;;;; Name: foreign-loader.lisp
;;;; Purpose: Loads foreign libraries
;;;; Author: Kevin M. Rosenberg
;;;; Date Started: Feb 2002
;;;;
;;;; $Id: foreign-loader.lisp,v 1.1 2003/05/02 02:54:55 kevin Exp $
;;;;
;;;; This file, part of UFFI, is Copyright (c) 2002 by Kevin M. Rosenberg
;;;;
;;;; UFFI users are granted the rights to distribute and use this software
;;;; as governed by the terms of the Lisp Lesser GNU Public License
;;;; (http://opensource.franz.com/preamble.html), also known as the LLGPL.
;;;; *************************************************************************
;;; For CMUCL, it's necessary to load foreign files separate from their
;;; usage
(in-package :uffi-tests)
(eval-when (:compile-toplevel :load-toplevel :execute)
(unless (uffi:load-foreign-library
#-(or macosx darwin)
(uffi:find-foreign-library
"libz"
'("/usr/local/lib/" "/usr/lib/" "/zlib/")
:types '("so" "a"))
#+(or macosx darwin)
(uffi:find-foreign-library "z"
`(,(pathname-directory *load-pathname*)))
:module "zlib"
:supporting-libraries '("c"))
(warn "Unable to load zlib")))
(unless (uffi:load-foreign-library
(uffi:find-foreign-library "uffi-c-test-lib"
(list *load-truename*
"/usr/lib/"))
:supporting-libraries '("c"))
(warn "Unable to load uffi-c-test-lib library"))