Reordering FFI libs
This commit is contained in:
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -3,9 +3,7 @@
|
||||
|
||||
(require ffi/unsafe
|
||||
ffi/unsafe/define
|
||||
setup/dirs
|
||||
"../utils/utils.rkt"
|
||||
racket/runtime-path
|
||||
"libao-ffi.rkt"
|
||||
)
|
||||
|
||||
@@ -17,20 +15,8 @@
|
||||
ao_clear_async
|
||||
)
|
||||
|
||||
(define-runtime-path libao-async-lib-path "./lib")
|
||||
|
||||
(define lib (if (eq? (system-type 'os) 'windows)
|
||||
(build-path libao-async-lib-path "ao-play-async")
|
||||
(build-path libao-async-lib-path "libao-play-async")))
|
||||
|
||||
(define-ffi-definer define-libao-async
|
||||
(ffi-lib lib '("0" #f)
|
||||
#:get-lib-dirs (λ ()
|
||||
(let ((sp (cons (build-path ".") (get-lib-search-dirs))))
|
||||
;(displayln sp)
|
||||
sp))
|
||||
#:fail (λ () (error "Cannot load libao-play-async"))
|
||||
))
|
||||
(define lib (get-lib '("ao-play-async" "libao-play-async") '(#f)))
|
||||
(define-ffi-definer define-libao-async lib)
|
||||
|
||||
(define _libao-async-handle-pointer (_cpointer 'ao-async-handle))
|
||||
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
|
||||
(require ffi/unsafe
|
||||
ffi/unsafe/define
|
||||
setup/dirs
|
||||
"../utils/utils.rkt"
|
||||
)
|
||||
|
||||
@@ -27,16 +26,7 @@
|
||||
)
|
||||
|
||||
|
||||
(define ao_lib (ffi-lib "libao" '("3" "4" "5" #f)
|
||||
#:get-lib-dirs (λ ()
|
||||
(let ((sp (cons (build-path ".") (get-lib-search-dirs))))
|
||||
(displayln sp)
|
||||
sp))
|
||||
#:fail (λ ()
|
||||
(ffi-lib (get-lib-path "libao-4.dll")))
|
||||
))
|
||||
|
||||
|
||||
(define ao_lib (get-lib '("libao") '("5" "4" "3" #f)))
|
||||
(define-ffi-definer define-libao ao_lib)
|
||||
|
||||
(define _libao-pointer (_cpointer 'ao_device))
|
||||
|
||||
Reference in New Issue
Block a user