gtk, opengl: try out update-library

opengl.gl: Only find the opengl library if we are on unix and not on macosx.
db4
Doug Coleman 2015-06-16 18:44:29 -07:00
parent 5908f301b9
commit 4eb6fd6624
2 changed files with 10 additions and 20 deletions

View File

@ -1,9 +1,8 @@
! Copyright (C) 2010 Anton Gorenko. ! Copyright (C) 2010 Anton Gorenko.
! See http://factorcode.org/license.txt for BSD license. ! See http://factorcode.org/license.txt for BSD license.
USING: alien alien.c-types alien.destructors alien.libraries USING: alien alien.c-types alien.destructors alien.libraries
alien.syntax combinators gobject-introspection alien.libraries.finder alien.syntax gobject-introspection
gobject-introspection.standard-types kernel pango.ffi system gobject-introspection.standard-types init pango.ffi vocabs ;
vocabs ;
IN: gtk.ffi IN: gtk.ffi
<< <<
@ -13,13 +12,7 @@ IN: gtk.ffi
LIBRARY: gtk LIBRARY: gtk
<< [ "gtk" "gtk-x11-2.0" find-library cdecl update-library ] "gtk" add-startup-hook
"gtk" {
{ [ os windows? ] [ "libgtk-win32-2.0-0.dll" cdecl add-library ] }
{ [ os macosx? ] [ drop ] }
{ [ os unix? ] [ "libgtk-x11-2.0.so" cdecl add-library ] }
} cond
>>
IMPLEMENT-STRUCTS: GtkTreeIter ; IMPLEMENT-STRUCTS: GtkTreeIter ;

View File

@ -3,9 +3,9 @@
! This file is based on the gl.h that comes with xorg-x11 6.8.2 ! This file is based on the gl.h that comes with xorg-x11 6.8.2
USING: alien alien.c-types alien.libraries alien.syntax USING: alien alien.c-types alien.libraries
combinators kernel parser sequences system words alien.libraries.finder alien.syntax init io.encodings.ascii
opengl.gl.extensions io.encodings.ascii ; kernel opengl.gl.extensions system ;
FROM: alien.c-types => short ; FROM: alien.c-types => short ;
IN: opengl.gl IN: opengl.gl
@ -629,13 +629,10 @@ CONSTANT: GL_CLIENT_ALL_ATTRIB_BITS 0xFFFFFFFF
LIBRARY: gl LIBRARY: gl
<< [
"gl" { os [ linux? ] [ macosx? not ] bi and
{ [ os windows? ] [ drop ] } [ "gl" "GL" find-library cdecl update-library ] when
{ [ os macosx? ] [ drop ] } ] "find-gl" add-startup-hook
{ [ os unix? ] [ "libGL.so" cdecl add-library ] }
} cond
>>
! Miscellaneous ! Miscellaneous