gobject-introspection kernel system vocabs ;
IN: atk.ffi
-<<
-"gobject.ffi" require
->>
+<< "gobject.ffi" require >>
LIBRARY: atk
-<<
-"atk" {
- { [ os windows? ] [ "libatk-1.0-0.dll" cdecl add-library ] }
- { [ os macosx? ] [ "libatk-1.0.dylib" cdecl add-library ] }
- { [ os unix? ] [ "libatk-1.0.so" cdecl add-library ] }
-} cond
->>
+<< "atk" {
+ { [ os windows? ] [ "libatk-1.0-0.dll" ] }
+ { [ os macosx? ] [ "libatk-1.0.dylib" ] }
+ { [ os unix? ] [ "libatk-1.0.so" ] }
+} cond cdecl add-library >>
GIR: vocab:atk/Atk-1.0.gir
! Copyright (C) 2010 Anton Gorenko.
! See http://factorcode.org/license.txt for BSD license.
USING: alien alien.c-types alien.destructors alien.libraries
-alien.syntax classes.struct combinators kernel system ;
+alien.syntax assocs classes.struct combinators kernel system ;
IN: cairo.ffi
! Adapted from cairo.h, version 1.8.10
<< "cairo" {
- { [ os windows? ] [ "libcairo-2.dll" cdecl add-library ] }
- { [ os macosx? ] [ "libcairo.dylib" cdecl add-library ] }
- { [ os unix? ] [ "libcairo.so" cdecl add-library ] }
-} cond >>
+ { [ os windows? ] [ "libcairo-2.dll" ] }
+ { [ os macosx? ] [ "libcairo.dylib" ] }
+ { [ os unix? ] [ "libcairo.so" ] }
+} cond cdecl add-library >>
LIBRARY: cairo
! Copyright (C) 2014 Doug Coleman.
! See http://factorcode.org/license.txt for BSD license.
-USING: alien alien.c-types alien.libraries
-alien.libraries.finder alien.syntax classes.struct ;
-USE: nested-comments
+USING: alien alien.c-types alien.libraries alien.syntax
+combinators classes.struct system ;
IN: compression.snappy.ffi
-<< "snappy" "snappy" find-library cdecl add-library >>
+<< "snappy" {
+ { [ os windows? ] [ "snappy.dll" ] }
+ { [ os macosx? ] [ "libsnappy.dylib" ] }
+ { [ os unix? ] [ "libsnappy.so" ] }
+} cond cdecl add-library >>
LIBRARY: snappy
! Copyright (C) 2009 Doug Coleman.
! See http://factorcode.org/license.txt for BSD license.
-USING: alien alien.c-types alien.syntax combinators system
-alien.libraries ;
+USING: alien alien.c-types alien.libraries alien.syntax
+combinators system ;
IN: compression.zlib.ffi
<< "zlib" {
! Copyright (C) 2007, 2008 Doug Coleman.
! See http://factorcode.org/license.txt for BSD license.
! tested on debian linux with postgresql 8.1
-USING: alien alien.c-types alien.syntax combinators system
-alien.libraries ;
+USING: alien alien.c-types alien.libraries alien.syntax
+combinators system ;
IN: db.postgresql.ffi
<< "postgresql" {
- { [ os windows? ] [ "libpq.dll" ] }
+ { [ os windows? ] [ "libpq.dll" ] }
{ [ os macosx? ] [ "libpq.dylib" ] }
- { [ os unix? ] [ "libpq.so" ] }
+ { [ os unix? ] [ "libpq.so" ] }
} cond cdecl add-library >>
! ConnSatusType
! See http://factorcode.org/license.txt for BSD license.
! An interface to the sqlite database. Tested against sqlite v3.1.3.
! Not all functions have been wrapped.
-USING: alien compiler kernel math namespaces sequences strings alien.syntax
-system combinators alien.c-types alien.libraries ;
+USING: alien alien.c-types alien.libraries alien.syntax
+combinators system ;
IN: db.sqlite.ffi
<< "sqlite" {
- { [ os windows? ] [ "sqlite3.dll" ] }
- { [ os macosx? ] [ "/usr/lib/libsqlite3.dylib" ] }
- { [ os unix? ] [ "libsqlite3.so" ] }
- } cond cdecl add-library >>
+ { [ os windows? ] [ "sqlite3.dll" ] }
+ { [ os macosx? ] [ "libsqlite3.dylib" ] }
+ { [ os unix? ] [ "libsqlite3.so" ] }
+} cond cdecl add-library >>
! Return values from sqlite functions
CONSTANT: SQLITE_OK 0 ! Successful result
! Copyright (C) 2010 Anton Gorenko.
! See http://factorcode.org/license.txt for BSD license.
-USING: alien alien.c-types alien.data alien.libraries alien.syntax
-combinators gio.ffi glib.ffi gobject-introspection
-gobject-introspection.standard-types kernel libc
-sequences system vocabs ;
+USING: alien alien.c-types alien.data alien.libraries
+alien.syntax combinators gio.ffi glib.ffi gobject-introspection
+gobject-introspection.standard-types kernel libc sequences
+system vocabs ;
IN: gdk.pixbuf.ffi
-<<
-"gio.ffi" require
->>
+<< "gio.ffi" require >>
LIBRARY: gdk.pixbuf
-<<
-"gdk.pixbuf" {
- { [ os windows? ] [ "libgdk_pixbuf-2.0-0.dll" cdecl add-library ] }
- { [ os macosx? ] [ "libgdk_pixbuf-2.0.dylib" cdecl add-library ] }
- { [ os unix? ] [ "libgdk_pixbuf-2.0.so" cdecl add-library ] }
-} cond
->>
+<< "gdk.pixbuf" {
+ { [ os windows? ] [ "libgdk_pixbuf-2.0-0.dll" ] }
+ { [ os macosx? ] [ "libgdk_pixbuf-2.0.dylib" ] }
+ { [ os unix? ] [ "libgdk_pixbuf-2.0.so" ] }
+} cond cdecl add-library >>
GIR: vocab:gdk/pixbuf/GdkPixbuf-2.0.gir
gobject-introspection kernel system vocabs ;
IN: gio.ffi
-<<
-"gobject.ffi" require
->>
+<< "gobject.ffi" require >>
LIBRARY: gio
-<<
-"gio" {
- { [ os windows? ] [ "libgio-2.0-0.dll" cdecl add-library ] }
- { [ os macosx? ] [ "libgio-2.0.dylib" cdecl add-library ] }
- { [ os unix? ] [ "libgio-2.0.so" cdecl add-library ] }
-} cond
->>
+<< "gio" {
+ { [ os windows? ] [ "libgio-2.0-0.dll" ] }
+ { [ os macosx? ] [ "libgio-2.0.dylib" ] }
+ { [ os unix? ] [ "libgio-2.0.so" ] }
+} cond cdecl add-library >>
GIR: vocab:gio/Gio-2.0.gir
LIBRARY: glib
-<<
-"glib" {
- { [ os windows? ] [ "libglib-2.0-0.dll" cdecl add-library ] }
- { [ os macosx? ] [ "libglib-2.0.0.dylib" cdecl add-library ] }
- { [ os unix? ] [ "libglib-2.0.so" cdecl add-library ] }
-} cond
->>
+<< "glib" {
+ { [ os windows? ] [ "libglib-2.0-0.dll" ] }
+ { [ os macosx? ] [ "libglib-2.0.0.dylib" ] }
+ { [ os unix? ] [ "libglib-2.0.so" ] }
+} cond cdecl add-library >>
IMPLEMENT-STRUCTS: GError GPollFD GSource GSourceFuncs ;
gobject-introspection kernel system vocabs ;
IN: gmodule.ffi
-<<
-"glib.ffi" require
->>
+<< "glib.ffi" require >>
LIBRARY: gmodule
-<<
-"gmodule" {
- { [ os windows? ] [ "libgmodule-2.0-0.dll" cdecl add-library ] }
- { [ os macosx? ] [ drop ] }
- { [ os unix? ] [ "libgmodule-2.0.so" cdecl add-library ] }
-} cond
->>
+<< "gmodule" {
+ { [ os windows? ] [ "libgmodule-2.0-0.dll" ] }
+ { [ os macosx? ] [ "libgmodule-2.0.dylib" ] }
+ { [ os unix? ] [ "libgmodule-2.0.so" ] }
+} cond cdecl add-library >>
GIR: vocab:gmodule/GModule-2.0.gir
! Copyright (C) 2010 Anton Gorenko.
! See http://factorcode.org/license.txt for BSD license.
-USING: alien alien.destructors alien.libraries alien.syntax kernel
+USING: alien alien.destructors alien.libraries alien.syntax
combinators gobject-introspection literals math system vocabs ;
IN: gobject.ffi
! these two are needed for the definition of GError and others.
! otherwise we generate GError and some others in this vocab as well.
-<<
-"glib.ffi" require
->>
+<< "glib.ffi" require >>
USE: glib.ffi
LIBRARY: gobject
-<<
-"gobject" {
- { [ os windows? ] [ "libobject-2.0-0.dll" cdecl add-library ] }
- { [ os macosx? ] [ "libgobject-2.0.dylib" cdecl add-library ] }
- { [ os unix? ] [ "libgobject-2.0.so" cdecl add-library ] }
-} cond
->>
+<< "gobject" {
+ { [ os windows? ] [ "libobject-2.0-0.dll" ] }
+ { [ os macosx? ] [ "libgobject-2.0.dylib" ] }
+ { [ os unix? ] [ "libgobject-2.0.so" ] }
+} cond cdecl add-library >>
IMPLEMENT-STRUCTS: GValue GParamSpecVariant ;
!
! export LD_LIBRARY_PATH=/opt/local/lib
-USING: alien alien.c-types alien.syntax combinators kernel system
-alien.libraries classes.struct ;
+USING: alien alien.c-types alien.libraries alien.syntax
+classes.struct combinators system ;
IN: openssl.libcrypto
-<<
-{
- { [ os windows? ] [ "libcrypto" "libeay32.dll" cdecl add-library ] }
- { [ os macosx? ] [ "libcrypto" "libcrypto.dylib" cdecl add-library ] }
- { [ os unix? ] [ "libcrypto" "libcrypto.so" cdecl add-library ] }
-} cond
->>
+<< "libcrypto" {
+ { [ os windows? ] [ "libeay32.dll" ] }
+ { [ os macosx? ] [ "libcrypto.dylib" ] }
+ { [ os unix? ] [ "libcrypto.so" ] }
+} cond cdecl add-library >>
STRUCT: bio-method
{ type int }
! Copyright (C) 2007 Elie CHAFTARI
! Portions copyright (C) 2008 Slava Pestov
! See http://factorcode.org/license.txt for BSD license.
-USING: alien alien.c-types alien.parser alien.syntax classes.struct combinators
-kernel openssl.libcrypto system namespaces assocs parser lexer sequences words
-quotations math.bitwise alien.libraries literals ;
+USING: alien alien.c-types alien.libraries alien.parser
+alien.syntax assocs classes.struct combinators kernel lexer
+literals namespaces openssl.libcrypto parser quotations
+sequences system words ;
IN: openssl.libssl
kernel gobject-introspection system vocabs ;
IN: pango.cairo.ffi
-<<
-"pango.ffi" require
->>
+<< "pango.ffi" require >>
LIBRARY: pango.cairo
-<<
-"pango.cairo" {
- { [ os windows? ] [ "libpangocairo-1.0-0.dll" cdecl add-library ] }
- { [ os macosx? ] [ drop ] }
- { [ os unix? ] [ "libpangocairo-1.0.so" cdecl add-library ] }
-} cond
->>
+<< "pango.cairo" {
+ { [ os windows? ] [ "libpangocairo-1.0-0.dll" ] }
+ { [ os macosx? ] [ "libpangocairo-1.0.dylib" ] }
+ { [ os unix? ] [ "libpangocairo-1.0.so" ] }
+} cond cdecl add-library >>
FOREIGN-RECORD-TYPE: cairo.Context cairo_t
FOREIGN-RECORD-TYPE: cairo.ScaledFont cairo_scaled_font_t
! Copyright (C) 2010 Anton Gorenko.
! See http://factorcode.org/license.txt for BSD license.
USING: alien alien.c-types alien.destructors alien.libraries
-alien.syntax combinators kernel gobject-introspection
+alien.syntax combinators gobject-introspection
gobject-introspection.standard-types system vocabs ;
IN: pango.ffi
-<<
-"gobject.ffi" require
->>
+<< "gobject.ffi" require >>
LIBRARY: pango
-<<
-"pango" {
- { [ os windows? ] [ "libpango-1.0-0.dll" cdecl add-library ] }
- { [ os macosx? ] [ drop ] }
- { [ os unix? ] [ "libpango-1.0.so" cdecl add-library ] }
-} cond
->>
+<< "pango" {
+ { [ os windows? ] [ "libpango-1.0-0.dll" ] }
+ { [ os macosx? ] [ "libpango-1.0.dylib" ] }
+ { [ os unix? ] [ "libpango-1.0.so" ] }
+} cond cdecl add-library >>
IMPLEMENT-STRUCTS: PangoRectangle ;
! Copyright (C) 2008, 2010 Slava Pestov, Jorge Acereda Macia.
! See http://factorcode.org/license.txt for BSD license.
-USING: tools.disassembler namespaces combinators alien
-alien.syntax alien.c-types lexer parser kernel sequences layouts
-math math.order alien.libraries math.parser system make fry
-arrays libc destructors tools.memory tools.disassembler.utils
-tools.disassembler.private splitting alien.data classes.struct ;
+USING: alien alien.c-types alien.libraries alien.syntax arrays
+combinators destructors fry kernel layouts libc make math
+math.order math.parser namespaces sequences splitting system
+tools.disassembler.private tools.disassembler.utils tools.memory
+;
IN: tools.disassembler.udis
-<<
-"libudis86" {
- { [ os macosx? ] [ "libudis86.0.dylib" ] }
- { [ os unix? ] [ "libudis86.so.0" ] }
+<< "libudis86" {
{ [ os windows? ] [ "libudis86.dll" ] }
-} cond cdecl add-library
->>
+ { [ os macosx? ] [ "libudis86.dylib" ] }
+ { [ os unix? ] [ "libudis86.so" ] }
+} cond cdecl add-library >>
LIBRARY: libudis86
USING: alien alien.c-types alien.enums alien.libraries
-alien.libraries.finder alien.syntax classes.struct combinators
-kernel math unix.types words ;
+alien.syntax classes.struct combinators kernel math
+system unix.types words ;
IN: curl.ffi
-<< "curl" dup find-library cdecl add-library >>
+<< "curl" {
+ { [ os macosx? ] [ "libcurl.dylib" ] }
+ { [ os unix? ] [ "libcurl.so" ] }
+} cond cdecl add-library >>
LIBRARY: curl
! See http://factorcode.org/license.txt for BSD license.
USING: alien alien.c-types alien.destructors alien.libraries
-alien.libraries.finder alien.syntax kernel ;
+alien.libraries.finder alien.syntax combinators kernel system ;
IN: fftw.ffi
LIBRARY: fftw3
-<< "fftw3" { "fftw3" "libfftw3-3" } find-library-from-list cdecl add-library >>
+<< "fftw3" {
+ { [ os windows? ] [ "libfftw3-3.dll" ] }
+ { [ os macosx? ] [ "libfftw3.dylib" ] }
+ { [ os unix? ] [ "libfftw3.so" ] }
+} cond cdecl add-library >>
TYPEDEF: double[2] fftw_complex
! Copyright (C) 2009 Matthew Willis.
! See http://factorcode.org/license.txt for BSD license.
-USING: alien alien.c-types alien.libraries
-alien.libraries.finder alien.syntax kernel sequences ;
+USING: alien alien.c-types alien.libraries alien.syntax
+combinators kernel sequences system ;
IN: llvm.core
<<
+: add-llvm-library ( name -- )
+ dup {
+ { [ os macosx? ] [ "lib" ".dylib" surround ] }
+ { [ os unix? ] [ "lib" ".so" surround ] }
+ { [ os windows? ] [ ".dll" append ] }
+ } cond cdecl add-library ;
+
{ "LLVMSystem" "LLVMSupport" "LLVMCore" "LLVMBitReader" }
-[ dup find-library cdecl add-library ] each
+[ add-llvm-library ] each
>>
! llvm-c/Core.h
! Copyright (C) 2009 Matthew Willis.
! See http://factorcode.org/license.txt for BSD license.
-USING: alien alien.c-types alien.libraries
-alien.libraries.finder alien.syntax kernel llvm.core sequences ;
+USING: alien alien.c-types alien.libraries alien.syntax kernel
+llvm.core sequences ;
IN: llvm.engine
<<
"LLVMTransformUtils" "LLVMScalarOpts" "LLVMCodeGen"
"LLVMAsmPrinter" "LLVMSelectionDAG" "LLVMX86CodeGen"
"LLVMJIT" "LLVMInterpreter"
-} [ dup find-library cdecl add-library ] each
+} [ add-llvm-library ] each
>>
! llvm-c/ExecutionEngine.h
IN: lua
<< "liblua5.1" {
- { [ os windows? ] [ "lua5.1.dll" ] }
- { [ os macosx? ] [ "liblua5.1.dylib" ] }
- { [ os unix? ] [ "liblua5.1.so" ] }
- } cond cdecl add-library >>
+ { [ os windows? ] [ "lua5.1.dll" ] }
+ { [ os macosx? ] [ "liblua5.1.dylib" ] }
+ { [ os unix? ] [ "liblua5.1.so" ] }
+} cond cdecl add-library >>
+
LIBRARY: liblua5.1
-
+
! luaconf.h
TYPEDEF: double LUA_NUMBER
TYPEDEF: ptrdiff_t LUA_INTEGER
! See http://factorcode.org/license.txt for BSD license
USING: alien alien.c-types alien.destructors alien.libraries
-alien.libraries.finder alien.syntax kernel literals ;
+alien.syntax combinators kernel literals system ;
IN: magic.ffi
-<< "magic" dup find-library cdecl add-library >>
+<< "magic" {
+ { [ os macosx? ] [ "libmagic.dylib" ] }
+ { [ os unix? ] [ "libmagic.so" ] }
+} cond cdecl add-library >>
LIBRARY: magic
USING:
alien alien.c-types alien.data
- alien.libraries alien.libraries.finder
+ alien.libraries
alien.syntax
classes.struct
combinators
system ;
IN: pcre.ffi
-<< "pcre" dup find-library cdecl add-library >>
+<< "pcre" {
+ { [ os windows? ] [ "pcre3.dll" ] }
+ { [ os macosx? ] [ "libpcre.dylib" ] }
+ { [ os unix? ] [ "libpcre.so" ] }
+} cond cdecl add-library >>
LIBRARY: pcre
! Copyright (C) 2010 Erik Charlebois
! See http:// factorcode.org/license.txt for BSD license.
-USING: alien alien.c-types kernel alien.syntax classes.struct
-accessors libc math make unix.types namespaces system
-combinators alien.libraries ;
+USING: accessors alien alien.c-types alien.libraries
+alien.syntax classes.struct combinators kernel libc math
+namespaces system unix.types ;
IN: readline.ffi
-<<
-"readline" {
+<< "readline" {
{ [ os windows? ] [ "readline.dll" ] }
- { [ os macosx? ] [ "libreadline.dylib" ] }
- { [ os unix? ] [ "libreadline.so" ] }
-} cond cdecl add-library
->>
+ { [ os macosx? ] [ "libreadline.dylib" ] }
+ { [ os unix? ] [ "libreadline.so" ] }
+} cond cdecl add-library >>
+
LIBRARY: readline
TYPEDEF: void* histdata_t
! Copyright (C) 2011 Erik Charlebois.
! See http://factorcode.org/license.txt for BSD license.
-USING: alien.strings destructors io.encodings.utf8 kernel libc
-sequences macros quotations words compiler.units fry
-alien.data alien.libraries ;
+USING: alien.data alien.libraries alien.strings compiler.units
+destructors fry io.encodings.utf8 kernel libc sequences words ;
QUALIFIED: readline.ffi
IN: readline
! See http://factorcode.org/license.txt for BSD license.
USING: alien alien.accessors alien.c-types alien.data
-alien.libraries alien.syntax byte-arrays classes.struct
+alien.libraries alien.syntax assocs byte-arrays classes.struct
combinators kernel literals math system ;
IN: zeromq.ffi
<< "zmq" {
- { [ os windows? ] [ "libzmq.dll" cdecl add-library ] }
- { [ os macosx? ] [ "libzmq.dylib" cdecl add-library ] }
- { [ os unix? ] [ "libzmq.so" cdecl add-library ] }
-} cond >>
+ { [ os windows? ] [ "libzmq.dll" ] }
+ { [ os macosx? ] [ "libzmq.dylib" ] }
+ { [ os unix? ] [ "libzmq.so" ] }
+} cond cdecl add-library >>
LIBRARY: zmq