pantry/projects/github.com/anholt/libepoxy/test.c
Andrew 566def7f7a
github.com/anholt/libepoxy (#2334)
* github.com/anholt/libepoxy

* +x.org/x11: '*'

* meson args

* args

* remove --enable_egl

* egl=false

* test.c

* modified:   projects/github.com/anholt/libepoxy/package.yml

* +dri.freedesktop.org

* modified:   projects/github.com/anholt/libepoxy/package.yml

* sed

* test

* i _assume_ we're finding libGL here.

* +mesa

---------

Co-authored-by: Jacob Heider <jacob@tea.xyz>
2023-09-10 17:49:38 -04:00

25 lines
514 B
C

#include <epoxy/gl.h>
#ifdef OS_MAC
#include <OpenGL/CGLContext.h>
#include <OpenGL/CGLTypes.h>
#include <OpenGL/OpenGL.h>
#endif
int main()
{
#ifdef OS_MAC
CGLPixelFormatAttribute attribs[] = {0};
CGLPixelFormatObj pix;
int npix;
CGLContextObj ctx;
CGLChoosePixelFormat( attribs, &pix, &npix );
CGLCreateContext(pix, (void*)0, &ctx);
#endif
glClear(GL_COLOR_BUFFER_BIT);
#ifdef OS_MAC
CGLReleasePixelFormat(pix);
CGLReleaseContext(pix);
#endif
return 0;
}