Timo Aaltonen pushed to branch debian-unstable at X Strike Force / lib / libepoxy
Commits:
-
ef4dbfa7
by Emmanuele Bassi at 2020-12-22T14:49:08+00:00
-
4822fc16
by Emmanuele Bassi at 2020-12-23T13:07:19+00:00
-
c4520d0a
by Emmanuele Bassi at 2020-12-23T13:08:10+00:00
-
14ab6c6b
by Emmanuele Bassi at 2020-12-23T13:11:20+00:00
-
599847df
by Emmanuele Bassi at 2020-12-23T13:17:06+00:00
-
3e35bb86
by Emmanuele Bassi at 2020-12-23T13:17:44+00:00
-
4c686ff5
by Emmanuele Bassi at 2020-12-23T14:06:12+00:00
-
03b9b469
by Emmanuele Bassi at 2020-12-23T19:21:29+00:00
-
642330e8
by Emmanuele Bassi at 2020-12-23T19:43:58+00:00
-
c37b4243
by Emmanuele Bassi at 2020-12-23T19:47:42+00:00
-
1878042c
by Emmanuele Bassi at 2020-12-23T19:48:37+00:00
-
c7973204
by Emmanuele Bassi at 2020-12-23T19:58:50+00:00
-
dbfa4b20
by Yaroslav Isakov at 2021-01-20T12:18:57+00:00
-
4994c481
by Yaroslav Isakov at 2021-01-20T12:23:43+00:00
-
950b9f5b
by Xavier Claessens at 2021-01-20T08:09:14-05:00
-
7ec320d1
by Emmanuele Bassi at 2021-01-20T13:27:36+00:00
-
de08cf34
by Emmanuele Bassi at 2021-01-20T15:18:00+00:00
-
d0b319e2
by Aleksandr at 2021-03-06T09:11:44+06:00
-
144cbc93
by Emmanuele Bassi at 2021-03-21T19:02:58+00:00
-
54f645b0
by Emmanuele Bassi at 2021-03-31T11:16:51+01:00
-
0a304d1a
by Emmanuele Bassi at 2021-04-19T15:46:30+01:00
-
e271edbc
by Emmanuele Bassi at 2021-04-30T10:45:15+01:00
-
1403303e
by Emmanuele Bassi at 2021-04-30T12:15:25+01:00
-
f9e76359
by Emmanuele Bassi at 2021-04-30T12:56:41+01:00
-
6722802c
by Timo Aaltonen at 2021-05-05T23:53:48+03:00
-
e1e57220
by Timo Aaltonen at 2021-05-05T23:56:20+03:00
-
54afddd6
by Timo Aaltonen at 2021-05-05T23:57:01+03:00
-
ae75f389
by Timo Aaltonen at 2021-05-06T00:00:04+03:00
-
cac53356
by Timo Aaltonen at 2021-05-06T00:00:28+03:00
17 changed files:
- − .appveyor.yml
- .travis/epoxy-ci-linux.sh → .github/scripts/epoxy-ci-linux.sh
- .travis/epoxy-ci-osx.sh → .github/scripts/epoxy-ci-osx.sh
- .github/workflows/ci.yml → .github/workflows/linux.yml
- + .github/workflows/macos.yml
- + .github/workflows/msvc-env.yml
- + .github/workflows/msys2.yml
- − .travis.yml
- − .travis/Dockerfile
- − .travis/run-docker.sh
- README.md
- debian/changelog
- debian/control
- meson.build
- src/dispatch_common.c
- src/gen_dispatch.py
- src/meson.build
Changes:
1 |
-version: 1.0.{build}
|
|
2 |
- |
|
3 |
-image: Visual Studio 2015
|
|
4 |
- |
|
5 |
-configuration: Release
|
|
6 |
- |
|
7 |
-# Configure both 32-bit and 64-bit builds
|
|
8 |
-environment:
|
|
9 |
- matrix:
|
|
10 |
- - platform: x86
|
|
11 |
- config: Win32
|
|
12 |
- pout: x86
|
|
13 |
- - platform: x64
|
|
14 |
- config: x64
|
|
15 |
- pout: x64
|
|
16 |
- |
|
17 |
-shallow_clone: true
|
|
18 |
- |
|
19 |
-# Download Meson and Ninja, create install directory
|
|
20 |
-before_build:
|
|
21 |
-- mkdir build
|
|
22 |
-- mkdir libepoxy-shared-%pout%
|
|
23 |
-- cd build
|
|
24 |
-- curl -LsSO https://github.com/mesonbuild/meson/releases/download/0.47.1/meson-0.47.1.tar.gz
|
|
25 |
-- 7z x meson-0.47.1.tar.gz
|
|
26 |
-- move dist\meson-0.47.1.tar .
|
|
27 |
-- 7z x meson-0.47.1.tar
|
|
28 |
-- rmdir dist
|
|
29 |
-- del meson-0.47.1.tar meson-0.47.1.tar.gz
|
|
30 |
-- curl -LsSO https://github.com/ninja-build/ninja/releases/download/v1.7.2/ninja-win.zip
|
|
31 |
-- 7z x ninja-win.zip
|
|
32 |
-- del ninja-win.zip
|
|
33 |
-- cd ..
|
|
34 |
- |
|
35 |
-# Build and install
|
|
36 |
-build_script:
|
|
37 |
-- cd build
|
|
38 |
-- call "C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\vcvarsall.bat" %PLATFORM%
|
|
39 |
-- C:\Python36\python.exe meson-0.47.1\meson.py .. . --backend=ninja --prefix=%APPVEYOR_BUILD_FOLDER%\libepoxy-shared-%pout%
|
|
40 |
-- ninja
|
|
41 |
-- ninja install
|
|
42 |
-- cd ..
|
|
43 |
- |
|
44 |
-# Copy license into install directory and create .zip file
|
|
45 |
-after_build:
|
|
46 |
-- copy COPYING libepoxy-shared-%pout%
|
|
47 |
-- dir libepoxy-shared-%pout% /s /b
|
|
48 |
-- 7z a -tzip libepoxy-shared-%pout%.zip libepoxy-shared-%pout%
|
|
49 |
- |
|
50 |
-artifacts:
|
|
51 |
- - path: libepoxy-shared-%pout%.zip
|
|
52 |
- name: libepoxy-shared-%pout%
|
|
53 |
- |
|
54 |
-test: off
|
|
55 |
- |
|
56 |
-# Upload .zip file to GitHub release
|
|
57 |
-deploy:
|
|
58 |
- release: $(APPVEYOR_REPO_TAG_NAME)
|
|
59 |
- description: "Epoxy $(APPVEYOR_REPO_TAG_NAME)"
|
|
60 |
- provider: GitHub
|
|
61 |
- auth_token:
|
|
62 |
- secure: X7Ro8Y2RWYo/M1AAn93f9X0dEQFvu7gPb6li2eKRtzPYLGj/JKm7MNWRw2cCcjm6
|
|
63 |
- artifact: libepoxy-shared-$(pout)
|
|
64 |
- draft: false
|
|
65 |
- prerelease: false
|
|
66 |
- on:
|
|
67 |
- appveyor_repo_tag: true # deploy on tag push only
|
1 |
-name: Build
|
|
1 |
+name: Ubuntu
|
|
2 | 2 |
on:
|
3 | 3 |
push:
|
4 | 4 |
branches-ignore:
|
... | ... | @@ -10,7 +10,6 @@ jobs: |
10 | 10 |
matrix:
|
11 | 11 |
os:
|
12 | 12 |
- ubuntu-18.04
|
13 |
- - macos-10.15
|
|
14 | 13 |
compiler:
|
15 | 14 |
- gcc
|
16 | 15 |
- clang
|
... | ... | @@ -19,16 +18,10 @@ jobs: |
19 | 18 |
- '-Dglx=no'
|
20 | 19 |
- '-Degl=no'
|
21 | 20 |
- '-Dx11=false'
|
22 |
- exclude:
|
|
23 |
- - os: macos-10.15
|
|
24 |
- compiler: gcc
|
|
25 | 21 |
runs-on: ${{ matrix.os }}
|
26 | 22 |
steps:
|
27 | 23 |
- uses: actions/checkout@v2
|
28 |
- - if: runner.os == 'macOS'
|
|
29 |
- run: brew install ninja
|
|
30 |
- - if: runner.os == 'Linux'
|
|
31 |
- run: >
|
|
24 |
+ - run: >
|
|
32 | 25 |
sudo apt-get update &&
|
33 | 26 |
sudo apt-get install --no-install-recommends
|
34 | 27 |
libgl1-mesa-dev
|
... | ... | @@ -42,7 +35,4 @@ jobs: |
42 | 35 |
- run: |
|
43 | 36 |
python -m pip install --upgrade pip
|
44 | 37 |
pip3 install meson
|
45 |
- - if: runner.os == 'macOS'
|
|
46 |
- run: /bin/sh -c "CC=${{ matrix.compiler }} .travis/epoxy-ci-osx.sh ${{ matrix.build-opts }}"
|
|
47 |
- - if: runner.os == 'Linux'
|
|
48 |
- run: /bin/sh -c "CC=${{ matrix.compiler }} .travis/epoxy-ci-linux.sh ${{ matrix.build-opts }}"
|
|
38 |
+ /bin/sh -c "CC=${{ matrix.compiler }} .github/scripts/epoxy-ci-linux.sh ${{ matrix.build-opts }}"
|
1 |
+name: macOS
|
|
2 |
+on:
|
|
3 |
+ push:
|
|
4 |
+ branches-ignore:
|
|
5 |
+ - debian
|
|
6 |
+ - khronos-registry
|
|
7 |
+jobs:
|
|
8 |
+ build:
|
|
9 |
+ strategy:
|
|
10 |
+ matrix:
|
|
11 |
+ build-opts:
|
|
12 |
+ - ''
|
|
13 |
+ - '-Dglx=no'
|
|
14 |
+ - '-Degl=no'
|
|
15 |
+ - '-Dx11=false'
|
|
16 |
+ runs-on: macos-10.15
|
|
17 |
+ steps:
|
|
18 |
+ - uses: actions/checkout@v2
|
|
19 |
+ - uses: actions/setup-python@v2
|
|
20 |
+ with:
|
|
21 |
+ python-version: 3.x
|
|
22 |
+ - run: |
|
|
23 |
+ brew install ninja
|
|
24 |
+ python -m pip install --upgrade pip
|
|
25 |
+ pip3 install meson
|
|
26 |
+ /bin/sh -c "CC=clang .github/scripts/epoxy-ci-osx.sh ${{ matrix.build-opts }}"
|
1 |
+name: MSVC Build
|
|
2 |
+ |
|
3 |
+on:
|
|
4 |
+ push:
|
|
5 |
+ branches: [ master ]
|
|
6 |
+ pull_request:
|
|
7 |
+ branches: [ master ]
|
|
8 |
+ |
|
9 |
+jobs:
|
|
10 |
+ build:
|
|
11 |
+ runs-on: windows-latest
|
|
12 |
+ env:
|
|
13 |
+ PYTHONIOENCODING: "utf-8"
|
|
14 |
+ steps:
|
|
15 |
+ - uses: actions/checkout@master
|
|
16 |
+ - uses: actions/setup-python@v1
|
|
17 |
+ - uses: seanmiddleditch/gha-setup-vsdevenv@master
|
|
18 |
+ - uses: BSFishy/meson-build@v1.0.1
|
|
19 |
+ with:
|
|
20 |
+ action: test
|
|
21 |
+ directory: _build
|
|
22 |
+ options: --verbose --fatal-meson-warnings
|
|
23 |
+ meson-version: 0.54.3
|
1 |
+name: MSYS2 Build
|
|
2 |
+ |
|
3 |
+on:
|
|
4 |
+ push:
|
|
5 |
+ branches: [ master ]
|
|
6 |
+ pull_request:
|
|
7 |
+ branches: [ master ]
|
|
8 |
+ |
|
9 |
+jobs:
|
|
10 |
+ build:
|
|
11 |
+ runs-on: windows-latest
|
|
12 |
+ defaults:
|
|
13 |
+ run:
|
|
14 |
+ shell: msys2 {0}
|
|
15 |
+ env:
|
|
16 |
+ PYTHONIOENCODING: "utf-8"
|
|
17 |
+ steps:
|
|
18 |
+ - uses: actions/checkout@master
|
|
19 |
+ - uses: msys2/setup-msys2@v2
|
|
20 |
+ with:
|
|
21 |
+ msystem: MINGW64
|
|
22 |
+ update: true
|
|
23 |
+ install: base-devel git mingw-w64-x86_64-meson mingw-w64-x86_64-ninja mingw-w64-x86_64-pkg-config mingw-w64-x86_64-python3 mingw-w64-x86_64-python3-pip mingw-w64-x86_64-toolchain
|
|
24 |
+ - name: Build
|
|
25 |
+ run: |
|
|
26 |
+ meson setup _build
|
|
27 |
+ meson compile -C _build
|
1 |
-sudo: false
|
|
2 |
- |
|
3 |
-branches:
|
|
4 |
- except:
|
|
5 |
- - debian
|
|
6 |
- - khronos-registry
|
|
7 |
- |
|
8 |
-os:
|
|
9 |
- - linux
|
|
10 |
- - osx
|
|
11 |
- |
|
12 |
-compiler:
|
|
13 |
- - gcc
|
|
14 |
- - clang
|
|
15 |
- |
|
16 |
-language:
|
|
17 |
- - c
|
|
18 |
- |
|
19 |
-services:
|
|
20 |
- - docker
|
|
21 |
- |
|
22 |
-matrix:
|
|
23 |
- exclude:
|
|
24 |
- - os: osx
|
|
25 |
- compiler: gcc
|
|
26 |
- |
|
27 |
-before_install:
|
|
28 |
- - |
|
|
29 |
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then
|
|
30 |
- brew update
|
|
31 |
- brew unlink python@2
|
|
32 |
- brew install python@3 meson
|
|
33 |
- # Use a Ninja with QuLogic's patch: https://github.com/ninja-build/ninja/issues/1219
|
|
34 |
- mkdir -p $HOME/tools; curl -L http://nirbheek.in/files/binaries/ninja/macos/ninja -o $HOME/tools/ninja; chmod +x $HOME/tools/ninja
|
|
35 |
- fi
|
|
36 |
- - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then docker pull ebassi/epoxyci ; fi
|
|
37 |
- |
|
38 |
-before_script:
|
|
39 |
- - |
|
|
40 |
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then
|
|
41 |
- echo FROM ebassi/epoxyci > Dockerfile
|
|
42 |
- echo ADD . /root >> Dockerfile
|
|
43 |
- echo WORKDIR /root >> Dockerfile
|
|
44 |
- docker build -t withgit .
|
|
45 |
- fi
|
|
46 |
- |
|
47 |
-env:
|
|
48 |
- - BUILD_OPTS=""
|
|
49 |
- - BUILD_OPTS="-Dglx=no"
|
|
50 |
- - BUILD_OPTS="-Degl=no"
|
|
51 |
- - BUILD_OPTS="-Dx11=false"
|
|
52 |
- |
|
53 |
-script:
|
|
54 |
- - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then docker run withgit /bin/sh -c "CC=$CC .travis/epoxy-ci-linux.sh $BUILD_OPTS" ; fi
|
|
55 |
- - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then /bin/sh -c "CC=$CC .travis/epoxy-ci-osx.sh $BUILD_OPTS" ; fi
|
1 |
-FROM debian:stretch-slim
|
|
2 |
-MAINTAINER Emmanuele Bassi <ebassi@gmail.com>
|
|
3 |
- |
|
4 |
-RUN apt-get update -qq && \
|
|
5 |
- apt-get install --no-install-recommends -qq -y \
|
|
6 |
- ca-certificates \
|
|
7 |
- clang \
|
|
8 |
- gcc \
|
|
9 |
- libgl1-mesa-dev \
|
|
10 |
- libegl1-mesa-dev \
|
|
11 |
- libgles1-mesa-dev \
|
|
12 |
- libgles2-mesa-dev \
|
|
13 |
- libgl1-mesa-dri \
|
|
14 |
- locales \
|
|
15 |
- ninja-build \
|
|
16 |
- pkg-config \
|
|
17 |
- python3 \
|
|
18 |
- python3-pip \
|
|
19 |
- python3-setuptools \
|
|
20 |
- python3-wheel \
|
|
21 |
- xvfb && \
|
|
22 |
- rm -rf /usr/share/doc/* /usr/share/man/*
|
|
23 |
- |
|
24 |
-RUN locale-gen C.UTF-8 && /usr/sbin/update-locale LANG=C.UTF-8
|
|
25 |
-ENV LANG=C.UTF-8 LANGUAGE=C.UTF-8 LC_ALL=C.UTF-8
|
|
26 |
- |
|
27 |
-RUN pip3 install meson
|
|
28 |
- |
|
29 |
-WORKDIR /root
|
1 |
-#!/bin/bash
|
|
2 |
- |
|
3 |
-set -xe
|
|
4 |
- |
|
5 |
-srcdir="$(pwd)/.."
|
|
6 |
- |
|
7 |
-sudo docker build \
|
|
8 |
- --tag "epoxyci" \
|
|
9 |
- --file "Dockerfile" .
|
|
10 |
-sudo docker run --rm \
|
|
11 |
- --volume "${srcdir}:/root/epoxy" \
|
|
12 |
- --tty --interactive "epoxyci" bash
|
1 |
-[![Build Status](https://travis-ci.org/anholt/libepoxy.svg?branch=master)](https://travis-ci.org/anholt/libepoxy)
|
|
2 |
-[![Build status](https://ci.appveyor.com/api/projects/status/xv6y5jurt5v5ngjx/branch/master?svg=true)](https://ci.appveyor.com/project/ebassi/libepoxy/branch/master)
|
|
1 |
+![Ubuntu](https://github.com/anholt/libepoxy/workflows/Ubuntu/badge.svg)
|
|
2 |
+![macOS](https://github.com/anholt/libepoxy/workflows/macOS/badge.svg)
|
|
3 |
+![MSVC Build](https://github.com/anholt/libepoxy/workflows/MSVC%20Build/badge.svg)
|
|
4 |
+![MSYS2 Build](https://github.com/anholt/libepoxy/workflows/MSYS2%20Build/badge.svg)
|
|
5 |
+[![License: MIT](https://img.shields.io/badge/license-MIT-brightgreen.svg)](https://opensource.org/licenses/MIT)
|
|
3 | 6 |
|
4 | 7 |
Epoxy is a library for handling OpenGL function pointer management for
|
5 | 8 |
you.
|
1 |
-libepoxy (1.5.5-2) UNRELEASED; urgency=medium
|
|
1 |
+libepoxy (1.5.7-1) experimental; urgency=medium
|
|
2 | 2 |
|
3 |
+ [ Debian Janitor ]
|
|
3 | 4 |
* Set upstream metadata fields: Bug-Database, Bug-Submit, Repository,
|
4 | 5 |
Repository-Browse.
|
5 | 6 |
|
6 |
- -- Debian Janitor <janitor@jelmer.uk> Fri, 29 Jan 2021 07:10:53 -0000
|
|
7 |
+ [ Alexander Volkov ]
|
|
8 |
+ * Don't run tests when nocheck profile is enabled. (Closes: #918840)
|
|
9 |
+ |
|
10 |
+ [ Timo Aaltonen ]
|
|
11 |
+ * New upstream release.
|
|
12 |
+ * Drop xutils-dev from build-depends, not used. (Closes: #981785)
|
|
13 |
+ |
|
14 |
+ -- Timo Aaltonen <tjaalton@debian.org> Thu, 06 May 2021 00:00:09 +0300
|
|
7 | 15 |
|
8 | 16 |
libepoxy (1.5.5-1) unstable; urgency=medium
|
9 | 17 |
|
... | ... | @@ -3,7 +3,6 @@ Priority: optional |
3 | 3 |
Maintainer: Debian X Strike Force <debian-x@lists.debian.org>
|
4 | 4 |
Build-Depends: debhelper-compat (= 13),
|
5 | 5 |
meson (>= 0.48.0),
|
6 |
- xutils-dev,
|
|
7 | 6 |
pkg-config,
|
8 | 7 |
libx11-dev,
|
9 | 8 |
libgl-dev,
|
1 |
-project('libepoxy', 'c', version: '1.5.5',
|
|
1 |
+project('libepoxy', 'c', version: '1.5.7',
|
|
2 | 2 |
default_options: [
|
3 | 3 |
'buildtype=debugoptimized',
|
4 | 4 |
'c_std=gnu99',
|
5 | 5 |
'warning_level=1',
|
6 | 6 |
],
|
7 | 7 |
license: 'MIT',
|
8 |
- meson_version: '>= 0.48.0')
|
|
8 |
+ meson_version: '>= 0.54.0')
|
|
9 | 9 |
|
10 | 10 |
epoxy_version = meson.project_version().split('.')
|
11 | 11 |
epoxy_major_version = epoxy_version[0].to_int()
|
... | ... | @@ -674,9 +674,13 @@ epoxy_load_gl(void) |
674 | 674 |
if (!api.gl_handle)
|
675 | 675 |
get_dlopen_handle(&api.gl_handle, OPENGL_LIB, false, true);
|
676 | 676 |
#endif
|
677 |
- |
|
678 |
- get_dlopen_handle(&api.glx_handle, GLX_LIB, true, true);
|
|
679 |
- api.gl_handle = api.glx_handle;
|
|
677 |
+ if (!api.gl_handle) {
|
|
678 |
+ get_dlopen_handle(&api.gl_handle, GLX_LIB, true, true);
|
|
679 |
+#if PLATFORM_HAS_GLX
|
|
680 |
+ if (!api.glx_handle)
|
|
681 |
+ api.glx_handle = api.gl_handle;
|
|
682 |
+#endif
|
|
683 |
+ }
|
|
680 | 684 |
#endif
|
681 | 685 |
}
|
682 | 686 |
|
... | ... | @@ -467,6 +467,7 @@ class Generator(object): |
467 | 467 |
func.args_decl))
|
468 | 468 |
|
469 | 469 |
def write_header_header(self, out_file):
|
470 |
+ self.close()
|
|
470 | 471 |
self.out_file = open(out_file, 'w')
|
471 | 472 |
|
472 | 473 |
self.outln('/* GL dispatch header.')
|
... | ... | @@ -515,9 +516,17 @@ class Generator(object): |
515 | 516 |
self.outln('typedef uint32_t khronos_uint32_t;')
|
516 | 517 |
self.outln('typedef uint64_t khronos_uint64_t;')
|
517 | 518 |
self.outln('typedef float khronos_float_t;')
|
518 |
- self.outln('typedef long khronos_intptr_t;')
|
|
519 |
- self.outln('typedef long khronos_ssize_t;')
|
|
520 |
- self.outln('typedef unsigned long khronos_usize_t;')
|
|
519 |
+ self.outln('#ifdef _WIN64')
|
|
520 |
+ self.outln('typedef signed long long int khronos_intptr_t;')
|
|
521 |
+ self.outln('typedef unsigned long long int khronos_uintptr_t;')
|
|
522 |
+ self.outln('typedef signed long long int khronos_ssize_t;')
|
|
523 |
+ self.outln('typedef unsigned long long int khronos_usize_t;')
|
|
524 |
+ self.outln('#else')
|
|
525 |
+ self.outln('typedef signed long int khronos_intptr_t;')
|
|
526 |
+ self.outln('typedef unsigned long int khronos_uintptr_t;')
|
|
527 |
+ self.outln('typedef signed long int khronos_ssize_t;')
|
|
528 |
+ self.outln('typedef unsigned long int khronos_usize_t;')
|
|
529 |
+ self.outln('#endif')
|
|
521 | 530 |
self.outln('typedef uint64_t khronos_utime_nanoseconds_t;')
|
522 | 531 |
self.outln('typedef int64_t khronos_stime_nanoseconds_t;')
|
523 | 532 |
self.outln('#define KHRONOS_MAX_ENUM 0x7FFFFFFF')
|
... | ... | @@ -526,7 +535,6 @@ class Generator(object): |
526 | 535 |
self.outln(' KHRONOS_TRUE = 1,')
|
527 | 536 |
self.outln(' KHRONOS_BOOLEAN_ENUM_FORCE_SIZE = KHRONOS_MAX_ENUM')
|
528 | 537 |
self.outln('} khronos_boolean_enum_t;')
|
529 |
- self.outln('typedef uintptr_t khronos_uintptr_t;')
|
|
530 | 538 |
|
531 | 539 |
if self.target == "glx":
|
532 | 540 |
self.outln('#include <X11/Xlib.h>')
|
... | ... | @@ -757,6 +765,7 @@ class Generator(object): |
757 | 765 |
self.outln('')
|
758 | 766 |
|
759 | 767 |
def write_source(self, f):
|
768 |
+ self.close()
|
|
760 | 769 |
self.out_file = open(f, 'w')
|
761 | 770 |
|
762 | 771 |
self.outln('/* GL dispatch code.')
|
... | ... | @@ -849,6 +858,12 @@ class Generator(object): |
849 | 858 |
for func in self.sorted_functions:
|
850 | 859 |
self.write_function_pointer(func)
|
851 | 860 |
|
861 |
+ def close(self):
|
|
862 |
+ if self.out_file:
|
|
863 |
+ self.out_file.close()
|
|
864 |
+ self.out_file = None
|
|
865 |
+ |
|
866 |
+ |
|
852 | 867 |
argparser = argparse.ArgumentParser(description='Generate GL dispatch wrappers.')
|
853 | 868 |
argparser.add_argument('files', metavar='file.xml', nargs='+', help='GL API XML files to be parsed')
|
854 | 869 |
argparser.add_argument('--outputdir', metavar='dir', required=False, help='Destination directory for files (default to current dir)')
|
... | ... | @@ -913,3 +928,5 @@ for f in args.files: |
913 | 928 |
generator.write_header(os.path.join(includedir, name + '_generated.h'))
|
914 | 929 |
if build_source:
|
915 | 930 |
generator.write_source(os.path.join(srcdir, name + '_generated_dispatch.c'))
|
931 |
+ |
|
932 |
+ generator.close()
|
... | ... | @@ -72,17 +72,22 @@ libepoxy = library( |
72 | 72 |
link_args: common_ldflags,
|
73 | 73 |
)
|
74 | 74 |
|
75 |
+epoxy_has_glx = build_glx ? '1' : '0'
|
|
76 |
+epoxy_has_egl = build_egl ? '1' : '0'
|
|
77 |
+epoxy_has_wgl = build_wgl ? '1' : '0'
|
|
78 |
+ |
|
75 | 79 |
libepoxy_dep = declare_dependency(
|
76 | 80 |
link_with: libepoxy,
|
77 | 81 |
include_directories: libepoxy_inc,
|
78 | 82 |
dependencies: epoxy_deps,
|
79 | 83 |
sources: epoxy_headers,
|
84 |
+ variables: {
|
|
85 |
+ 'epoxy_has_glx': epoxy_has_glx,
|
|
86 |
+ 'epoxy_has_egl': epoxy_has_egl,
|
|
87 |
+ 'epoxy_has_wgl': epoxy_has_wgl,
|
|
88 |
+ },
|
|
80 | 89 |
)
|
81 | 90 |
|
82 |
-epoxy_has_glx = build_glx ? '1' : '0'
|
|
83 |
-epoxy_has_egl = build_egl ? '1' : '0'
|
|
84 |
-epoxy_has_wgl = build_wgl ? '1' : '0'
|
|
85 |
- |
|
86 | 91 |
# We don't want to add these dependencies to the library, as they are
|
87 | 92 |
# not needed when building Epoxy; we do want to add them to the generated
|
88 | 93 |
# pkg-config file, for consumers of Epoxy
|