2023-05-23 07:04:40 +03:00
|
|
|
distributable:
|
2024-01-24 22:13:46 +03:00
|
|
|
- url: https://github.com/g-truc/glm/releases/download/{{version.tag}}/glm-{{version.tag}}.zip
|
|
|
|
# v1.0.0 added -light
|
|
|
|
- url: https://github.com/g-truc/glm/releases/download/{{version.tag}}/glm-{{version.tag}}-light.zip
|
2023-05-23 07:04:40 +03:00
|
|
|
|
|
|
|
versions:
|
|
|
|
github: g-truc/glm
|
|
|
|
|
|
|
|
build:
|
|
|
|
dependencies:
|
|
|
|
cmake.org: ^3
|
2024-01-24 22:13:46 +03:00
|
|
|
working-directory: glm
|
2023-05-23 07:04:40 +03:00
|
|
|
script:
|
2024-01-24 22:13:46 +03:00
|
|
|
- cmake -S . -B build $ARGS
|
|
|
|
- cmake --build build -- all
|
2023-05-23 07:04:40 +03:00
|
|
|
|
2024-01-24 22:13:46 +03:00
|
|
|
- mkdir -p {{prefix}}/include {{prefix}}/lib/pkgconfig
|
|
|
|
- cp -a detail ext gtc gtx simd *.hpp '{{prefix}}/include'
|
|
|
|
- run: ln -s . glm
|
|
|
|
working-directory: '{{prefix}}/include'
|
2023-05-23 07:04:40 +03:00
|
|
|
env:
|
|
|
|
ARGS:
|
|
|
|
- -DCMAKE_INSTALL_PREFIX={{prefix}}
|
|
|
|
- -DCMAKE_BUILD_TYPE=Release
|
|
|
|
- -DCMAKE_VERBOSE_MAKEFILE=ON
|
2024-01-24 22:13:46 +03:00
|
|
|
- -DBUILD_SHARED_LIBS=ON
|
2023-05-23 07:04:40 +03:00
|
|
|
CXXFLAGS:
|
|
|
|
- -std=c++17
|
|
|
|
# or fails to build with clang 15
|
|
|
|
- -Wno-error=implicit-int-conversion
|
|
|
|
- -Wno-error=unused-but-set-variable
|
|
|
|
- -Wno-error=deprecated-declarations
|
|
|
|
linux:
|
|
|
|
CXXFLAGS:
|
2023-10-02 03:41:57 +03:00
|
|
|
- -Wno-error=implicit-int-float-conversion
|
2023-05-23 07:04:40 +03:00
|
|
|
linux/x86-64:
|
|
|
|
CXXFLAGS:
|
2023-10-02 03:41:57 +03:00
|
|
|
- -fPIC
|
2023-05-23 07:04:40 +03:00
|
|
|
|
|
|
|
test:
|
2024-01-24 22:13:46 +03:00
|
|
|
script:
|
|
|
|
- run: c++ $FIXTURE
|
|
|
|
fixture:
|
|
|
|
extname: cpp
|
|
|
|
content: |
|
|
|
|
#include <glm/vec2.hpp>// glm::vec2
|
|
|
|
int main() {
|
|
|
|
std::size_t const VertexCount = 4;
|
|
|
|
std::size_t const PositionSizeF32 = VertexCount * sizeof(glm::vec2);
|
|
|
|
glm::vec2 const PositionDataF32[VertexCount] = {
|
|
|
|
glm::vec2(-1.0f,-1.0f),
|
|
|
|
glm::vec2( 1.0f,-1.0f),
|
|
|
|
glm::vec2( 1.0f, 1.0f),
|
|
|
|
glm::vec2(-1.0f, 1.0f)
|
|
|
|
};
|
|
|
|
return 0;
|
|
|
|
}
|
|
|
|
|
|
|
|
- ./a.out
|