From 0b7ac384ca8ca9db0cc6083807f3f8f95ab841d9 Mon Sep 17 00:00:00 2001 From: andrejrabcenko Date: Sun, 10 Sep 2023 23:31:42 +0300 Subject: [PATCH] new file: projects/freedesktop.org/mesa-glu/package.yml new file: projects/freedesktop.org/mesa-glu/test.cpp --- projects/freedesktop.org/mesa-glu/package.yml | 36 +++++++++++++++++++ projects/freedesktop.org/mesa-glu/test.cpp | 18 ++++++++++ 2 files changed, 54 insertions(+) create mode 100644 projects/freedesktop.org/mesa-glu/package.yml create mode 100644 projects/freedesktop.org/mesa-glu/test.cpp diff --git a/projects/freedesktop.org/mesa-glu/package.yml b/projects/freedesktop.org/mesa-glu/package.yml new file mode 100644 index 00000000..a942e7be --- /dev/null +++ b/projects/freedesktop.org/mesa-glu/package.yml @@ -0,0 +1,36 @@ +distributable: + url: https://gitlab.freedesktop.org/mesa/glu/-/archive/glu-{{version}}/glu-glu-{{version}}.tar.gz + strip-components: 1 +versions: + url: https://gitlab.freedesktop.org/mesa/glu/-/tags + match: /glu-\d+\.\d+\.\d+/ + strip: + - /^glu-/ +dependencies: + mesa3d.org: '*' +build: + dependencies: + tea.xyz/gx/cc: c99 + gnu.org/make: '*' + freedesktop.org/pkg-config: '*' + mesonbuild.com: '*' + ninja-build.org: '*' + script: + - meson setup $MESON_ARGS build + - meson compile -C build --verbose + - meson install -C build + env: + MESON_ARGS: + - --prefix="{{prefix}}" + - --libdir="{{prefix}}/lib" + - --buildtype=release + - --wrap-mode=nofallback + - -Dgl_provider=gl +test: + dependencies: + tea.xyz/gx/cc: c99 + freedesktop.org/pkg-config: '*' + script: + - pkg-config --modversion glu | grep {{version}} + - c++ test.cpp -lGLU -o test + - ./test diff --git a/projects/freedesktop.org/mesa-glu/test.cpp b/projects/freedesktop.org/mesa-glu/test.cpp new file mode 100644 index 00000000..12f80d29 --- /dev/null +++ b/projects/freedesktop.org/mesa-glu/test.cpp @@ -0,0 +1,18 @@ +#include + +int main(int argc, char* argv[]) { +static GLUtriangulatorObj *tobj; +GLdouble vertex[3], dx, dy, len; +int i = 0; +int count = 5; +tobj = gluNewTess(); +gluBeginPolygon(tobj); +for (i = 0; i < count; i++) { + vertex[0] = 1; + vertex[1] = 2; + vertex[2] = 0; + gluTessVertex(tobj, vertex, 0); +} +gluEndPolygon(tobj); +return 0; +} \ No newline at end of file