Remove add-simple-library

release
slava 2006-07-26 04:36:22 +00:00
parent e201a48a97
commit ad0ae8dc63
7 changed files with 8 additions and 26 deletions

View File

@ -1,5 +1,3 @@
USING: alien ; USING: alien ;
"cairo" "libcairo" add-simple-library
PROVIDE: cairo { "cairo.factor" } ; PROVIDE: cairo { "cairo.factor" } ;

View File

@ -1,7 +1,5 @@
USING: alien ; USING: alien ;
"postgresql" "libpq" add-simple-library
PROVIDE: postgresql PROVIDE: postgresql
{ "libpq.factor" "postgresql.factor" } { "libpq.factor" "postgresql.factor" }
{ "postgresql-test" } ; { "postgresql-test" } ;

View File

@ -1,7 +1,5 @@
USING: alien ; USING: alien ;
"sqlite" "libsqlite3" add-simple-library
PROVIDE: sqlite PROVIDE: sqlite
{ "sqlite.factor" "tuple-db.factor" } { "sqlite.factor" "tuple-db.factor" }
{ "tuple-db-tests.factor" } ; { "tuple-db-tests.factor" } ;

View File

@ -21,6 +21,7 @@ parser sequences sequences-internals words ;
windows? [ windows? [
"/library/ui/windows/load.factor" run-resource "/library/ui/windows/load.factor" run-resource
] when ] when
"native-io" get [ "native-io" get [
unix? [ unix? [
"/library/io/unix/load.factor" run-resource "/library/io/unix/load.factor" run-resource

View File

@ -37,9 +37,5 @@ global [ "libraries" nest drop ] bind
[ "abi" set "name" set ] make-hash swap set [ "abi" set "name" set ] make-hash swap set
] bind ; ] bind ;
: add-simple-library ( name file -- )
windows? ".dll" ".so" ? append
windows? "stdcall" "cdecl" ? add-library ;
: library-abi ( library -- abi ) : library-abi ( library -- abi )
library "abi" swap ?hash [ "cdecl" ] unless* ; library "abi" swap ?hash [ "cdecl" ] unless* ;

View File

@ -1,15 +1,6 @@
IN: scratchpad IN: scratchpad
USING: alien compiler kernel namespaces parser sequences words ; USING: alien compiler kernel namespaces parser sequences words ;
{
{ "gdi32" "gdi32" }
{ "user32" "user32" }
{ "kernel32" "kernel32" }
{ "winsock" "ws2_32" }
{ "mswsock" "mswsock" }
} [ first2 add-simple-library ] each
"libc" "msvcrt.dll" "cdecl" add-library
{ {
"io" "io"
"errors" "errors"

View File

@ -2,13 +2,13 @@ IN: scratchpad
USING: alien compiler kernel namespaces parser sequences words ; USING: alien compiler kernel namespaces parser sequences words ;
{ {
{ "gdi32" "gdi32" } { "gdi32" "gdi32.dll" "stdcall" }
{ "user32" "user32" } { "user32" "user32.dll" "stdcall" }
{ "kernel32" "kernel32" } { "kernel32" "kernel32.dll" "stdcall" }
{ "winsock" "ws2_32" } { "winsock" "ws2_32.dll" "stdcall" }
{ "mswsock" "mswsock" } { "mswsock" "mswsock.dll" "stdcall" }
} [ first2 add-simple-library ] each { "libc" "msvcrt.dll" "cdecl" }
"libc" "msvcrt.dll" "cdecl" add-library } [ first3 add-library ] each
{ {
"windows-messages" "windows-messages"