Merge branch 'master' of git://factorcode.org/git/factor

db4
Slava Pestov 2009-01-30 16:52:11 -06:00
commit e36376b432
2 changed files with 10 additions and 4 deletions

View File

@ -1,13 +1,19 @@
USING: alien alien.c-types alien.syntax kernel system combinators ;
IN: math.blas.cblas
<< "cblas" {
<<
: load-atlas ( -- )
"atlas" "libatlas.so" "cdecl" add-library
"atlas" load-library drop ;
"cblas" {
{ [ os macosx? ] [ "libblas.dylib" "cdecl" add-library ] }
{ [ os windows? ] [ "blas.dll" "cdecl" add-library ] }
{ [ os openbsd? ] [ "libcblas.so" "cdecl" add-library ] }
{ [ os freebsd? ] [ "libcblas.so" "cdecl" add-library ] }
{ [ os freebsd? ] [ "libcblas.so" "cdecl" add-library load-atlas ] }
[ "libblas.so" "cdecl" add-library ]
} cond >>
} cond
>>
LIBRARY: cblas

View File

@ -36,7 +36,7 @@ void init_ffi(void)
void ffi_dlopen(F_DLL *dll)
{
dll->dll = dlopen(alien_offset(dll->path), RTLD_LAZY);
dll->dll = dlopen(alien_offset(dll->path), RTLD_LAZY|RTLD_GLOBAL);
}
void *ffi_dlsym(F_DLL *dll, F_SYMBOL *symbol)