Skip to content

Commit

Permalink
Added better support for non-GNU systems.
Browse files Browse the repository at this point in the history
  • Loading branch information
Gustavo Henrique Milaré committed Jan 16, 2012
1 parent 3567f83 commit 9dad09b
Showing 1 changed file with 9 additions and 4 deletions.
13 changes: 9 additions & 4 deletions gettext-loader.lisp
Expand Up @@ -19,7 +19,12 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA

(in-package :cl-gettext)

;; (cffi:define-foreign-library gettext
;; (:unix "libc.so")
;; (t (:default "libintl")))
;; (cffi:use-foreign-library gettext)
(cffi:define-foreign-library gettext
(:unix (or "libintl.so"
"libintl"))
(:windows "libintl.dll")
(t (:default "libintl")))

(handler-case (assert (cffi:foreign-funcall "gettext" :string "abc" :string))
(error ()
(cffi:use-foreign-library gettext)))

0 comments on commit 9dad09b

Please sign in to comment.