-
This commit is contained in:
@@ -4,6 +4,7 @@
|
||||
racket/runtime-path
|
||||
ffi/unsafe
|
||||
setup/dirs
|
||||
"downloader.rkt"
|
||||
)
|
||||
|
||||
(provide while
|
||||
@@ -55,18 +56,12 @@
|
||||
(do-for-f))))))
|
||||
|
||||
|
||||
(define-runtime-path lib-path "..")
|
||||
|
||||
(define (build-lib-path)
|
||||
(let ((os-type (system-type 'os*)))
|
||||
(if (eq? os-type 'windows)
|
||||
(build-path lib-path "lib" "dll")
|
||||
(let* ((arch (symbol->string (system-type 'arch)))
|
||||
(subdir (string-append (symbol->string os-type) "-" arch)))
|
||||
(let ((path (build-path lib-path "lib" subdir)))
|
||||
path)))))
|
||||
(soundlibs-directory))
|
||||
|
||||
(define (get-lib* libs-to-try orig-libs versions)
|
||||
(unless (soundlibs-available?)
|
||||
(download-soundlibs))
|
||||
(if (null? libs-to-try)
|
||||
(error (format "Cannot find library, tried ~a" orig-libs))
|
||||
(ffi-lib (car libs-to-try) versions
|
||||
@@ -77,4 +72,4 @@
|
||||
(define (get-lib libs-to-try versions)
|
||||
(get-lib* libs-to-try libs-to-try versions))
|
||||
|
||||
) ; end of module
|
||||
) ; end of module
|
||||
|
||||
Reference in New Issue
Block a user