A small library for building JSON strings.
Signed-off-by: Frank Henigman
---
src/waffle/CMakeLists.txt | 1 +
src/waffle/core/json.c| 235 ++
src/waffle/core/json.h| 93 ++
3 files changed, 329 insertions(+)
create mode 1006
Add a platform hook so platform-specific information can be included
by waffle_display_info_json().
Signed-off-by: Frank Henigman
---
src/waffle/api/waffle_display.c | 10 +-
src/waffle/core/wcore_platform.h | 4
2 files changed, 13 insertions(+), 1 deletion(-)
diff --git a/src/w
Implement the platform hook of waffle_display_info_json() so it can
pick up egl-specific information.
Signed-off-by: Frank Henigman
---
src/waffle/egl/wegl_display.c | 32 ++--
src/waffle/egl/wegl_display.h | 4
src/waffle/egl/wegl_platform.h | 3 +++
3 files
When given a "-s" flag wflinfo will now also print some platform-specific
information. This affects only JSON output, not other formats.
Signed-off-by: Frank Henigman
---
src/utils/wflinfo.c | 14 --
1 file changed, 12 insertions(+), 2 deletions(-)
diff --git a/src/utils/wflinfo.c
With "-f json" wflinfo will now print the result of
waffle_display_info_json().
Signed-off-by: Frank Henigman
---
src/utils/wflinfo.c | 40
1 file changed, 36 insertions(+), 4 deletions(-)
diff --git a/src/utils/wflinfo.c b/src/utils/wflinfo.c
index 268d
Implement the platform hook of waffle_display_info_json() so it can
pick up glx-specific information.
Signed-off-by: Frank Henigman
---
src/waffle/glx/glx_display.c | 41 +
src/waffle/glx/glx_display.h | 4
src/waffle/glx/glx_platform.c | 4
Facilitates platform-specific code in core functions, like the forthcoming
wflinfo-like function.
Signed-off-by: Frank Henigman
---
src/waffle/api/waffle_init.c | 32 +---
src/waffle/core/wcore_platform.h | 1 +
2 files changed, 22 insertions(+), 11 deletions(-)
Implement the platform hook of waffle_display_info_json() so it can
pick up x11_egl-specific information. So far only egl information is
provided, nothing specific to x11.
Signed-off-by: Frank Henigman
---
src/waffle/xegl/xegl_platform.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/src/w
Implement the platform hook of waffle_display_info_json() so it can
pick up gbm-specific information. So far only egl information is
provided, nothing specific to gbm.
Signed-off-by: Frank Henigman
---
src/waffle/gbm/wgbm_platform.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/src/waffle
This patch set does two main things, the second of which could just as
well be a separate patch set.
1-6: Move wflinfo functionality into the api, info returned as a json string.
7-12: Extend the functionality to include platform-specific info, such as
provided by glxinfo.
After 1-6 wflinfo
Facilitates api-specific code in core functions, like the forthcoming
wflinfo-like function.
Signed-off-by: Frank Henigman
---
src/waffle/core/wcore_context.h | 2 ++
1 file changed, 2 insertions(+)
diff --git a/src/waffle/core/wcore_context.h b/src/waffle/core/wcore_context.h
index 3800113..45
Duplicate wflinfo functionality in the API, with the difference that the
information is returned in JSON form.
The function has a parameter for including platform-specific information,
but it is ignored for now.
Signed-off-by: Frank Henigman
---
include/waffle/waffle.h | 5 +
man/waffl
For core functions that need to know the current context, like the
forthcoming wflinfo-like function.
Signed-off-by: Frank Henigman
---
src/waffle/api/waffle_gl_misc.c | 11 +++
src/waffle/core/wcore_display.c | 1 +
src/waffle/core/wcore_display.h | 2 ++
3 files changed, 10 insertion
Hi all,
Recently I had the chance to finish a lenghty series started some months
ago. Namely - rework gl_basic_tests and kick waffle_test out the door.
It starts with a couple of symbol fixes (maint material afaict), caught
while experimenting with Travis-CI.
Patch 3 adds a trivial --platform
Signed-off-by: Emil Velikov
---
tests/functional/gl_basic_test.c | 66 ++--
1 file changed, 30 insertions(+), 36 deletions(-)
diff --git a/tests/functional/gl_basic_test.c b/tests/functional/gl_basic_test.c
index a14ce32..9ccf822 100644
--- a/tests/functional/
Signed-off-by: Emil Velikov
---
tests/functional/gl_basic_test.c | 27 ---
1 file changed, 16 insertions(+), 11 deletions(-)
diff --git a/tests/functional/gl_basic_test.c b/tests/functional/gl_basic_test.c
index c95ae39..55d078d 100644
--- a/tests/functional/gl_basic_test
Signed-off-by: Emil Velikov
---
tests/functional/gl_basic_test.c | 192 +++
1 file changed, 73 insertions(+), 119 deletions(-)
diff --git a/tests/functional/gl_basic_test.c b/tests/functional/gl_basic_test.c
index 03c4a0b..a14ce32 100644
--- a/tests/functional
From: Emil Velikov
This will allow us to selectively run the tests we want, and even run
the sets in parallel.
Fixes #33: https://github.com/waffle-gl/waffle/issues/33
Signed-off-by: Emil Velikov
---
tests/functional/CMakeLists.txt | 51 +--
tests/functional/gl_basic_test.c | 193 +++
... and use it to minimise the duplication across the file.
Signed-off-by: Emil Velikov
---
tests/functional/gl_basic_test.c | 168 ---
1 file changed, 52 insertions(+), 116 deletions(-)
diff --git a/tests/functional/gl_basic_test.c b/tests/functional/gl_basi
Signed-off-by: Emil Velikov
---
tests/functional/gl_basic_test.c | 141 ---
1 file changed, 56 insertions(+), 85 deletions(-)
diff --git a/tests/functional/gl_basic_test.c b/tests/functional/gl_basic_test.c
index 55d078d..03c4a0b 100644
--- a/tests/functional/
libwayland has broken its ABI by replacing wl_proxy_create +
wl_proxy_marshal with wfl_wl_proxy_marshal_constructor with commit
853c24e6998(client: Introduce functions to allocate and marshal proxies
atomically).
Add the wrapper to keep compatibility with wayland 1.3.90 and earlier.
Signed-off-by
Signed-off-by: Emil Velikov
---
tests/functional/gl_basic_test.c | 93
1 file changed, 36 insertions(+), 57 deletions(-)
diff --git a/tests/functional/gl_basic_test.c b/tests/functional/gl_basic_test.c
index f753276..10b9c71 100644
--- a/tests/functional/
Signed-off-by: Emil Velikov
---
tests/functional/gl_basic_test.c | 86
1 file changed, 34 insertions(+), 52 deletions(-)
diff --git a/tests/functional/gl_basic_test.c b/tests/functional/gl_basic_test.c
index 10b9c71..5e6b518 100644
--- a/tests/functional/
... and use it to minimise the duplication across the file.
Signed-off-by: Emil Velikov
---
tests/functional/gl_basic_test.c | 170 ---
1 file changed, 52 insertions(+), 118 deletions(-)
diff --git a/tests/functional/gl_basic_test.c b/tests/functional/gl_basi
Signed-off-by: Emil Velikov
---
tests/functional/gl_basic_test.c | 7 ++-
1 file changed, 2 insertions(+), 5 deletions(-)
diff --git a/tests/functional/gl_basic_test.c b/tests/functional/gl_basic_test.c
index d19b8ae..c95ae39 100644
--- a/tests/functional/gl_basic_test.c
+++ b/tests/function
Signed-off-by: Emil Velikov
---
tests/functional/gl_basic_test.c | 34 --
1 file changed, 16 insertions(+), 18 deletions(-)
diff --git a/tests/functional/gl_basic_test.c b/tests/functional/gl_basic_test.c
index 5e6b518..d151d44 100644
--- a/tests/functional/gl_bas
XXX: should we squash this with the previous commit ?
Signed-off-by: Emil Velikov
---
cmake/Modules/WaffleCMocka.cmake | 15 ++-
cmake/Modules/WaffleDefineCompilerFlags.cmake | 2 +-
2 files changed, 15 insertions(+), 2 deletions(-)
diff --git a/cmake/Modules/WaffleCMoc
Use cmocka macros and rework gl_basic_{init,fini}, by keeping
track of the state and tearing things down as needed.
Nuke the (no longer to be used) run_testsuite().
Signed-off-by: Emil Velikov
---
tests/functional/CMakeLists.txt | 2 +-
tests/functional/gl_basic_test.c | 336
... and use it to minimise the duplication across the file.
Add the equivalent CGL test while we're here :)
Signed-off-by: Emil Velikov
---
tests/functional/gl_basic_test.c | 31 ++-
1 file changed, 18 insertions(+), 13 deletions(-)
diff --git a/tests/functional/gl_
Neither one of these is (or has been) used. Remove them for now and
introduce back when needed.
Presently this causes run-time issues whenever someone attempts to use an
old version of libgbm (mesa circa 9.2) as the gbm_bo_get_fd symbol is
missing.
Due to the multiple gbm provides and their incon
Signed-off-by: Emil Velikov
---
third_party/cmocka/src/cmocka.c | 4
1 file changed, 4 insertions(+)
diff --git a/third_party/cmocka/src/cmocka.c b/third_party/cmocka/src/cmocka.c
index fc83b57..2a63f82 100644
--- a/third_party/cmocka/src/cmocka.c
+++ b/third_party/cmocka/src/cmocka.c
@@ -3
Signed-off-by: Emil Velikov
---
src/waffle/core/wcore_attrib_list_unittest.c | 40 +--
src/waffle/core/wcore_config_attrs_unittest.c | 18
src/waffle/core/wcore_error_unittest.c| 26 -
3 files changed, 45 insertions(+), 39 deletions(-)
From: Emil Velikov
With this patch in place, all the existing tests are fully converted to
cmocka.
With this in place, one can get a 'clean bill of health' according to
valgrind. The odd remaining memory leak(s) are likely due to the driver.
Fixes #35: https://github.com/waffle-gl/waffle/issues
From: Emil Velikov
Signed-off-by: Emil Velikov
---
tests/functional/gl_basic_test.c | 66
1 file changed, 6 insertions(+), 60 deletions(-)
diff --git a/tests/functional/gl_basic_test.c b/tests/functional/gl_basic_test.c
index c4faa11..9a2bfff 100644
---
From: Emil Velikov
There is no need to (potentially) call the function twice in a roll, as
there are no waffle calls inbetween that can trigger a change.
Use a switch (as opposed to if-else 'spaghetti'), which has the
benefit of slightly improved readability.
While we're here, fix the copy/past
From: Emil Velikov
Signed-off-by: Emil Velikov
---
tests/functional/gl_basic_test.c | 67 +++-
1 file changed, 5 insertions(+), 62 deletions(-)
diff --git a/tests/functional/gl_basic_test.c b/tests/functional/gl_basic_test.c
index 9a2bfff..970f299 100644
---
From: Emil Velikov
This way we can also run waffle's tests through headless CI ;-)
Fixes #34: https://github.com/waffle-gl/waffle/issues/34
Signed-off-by: Emil Velikov
---
tests/functional/gl_basic_test.c | 21 +++--
1 file changed, 19 insertions(+), 2 deletions(-)
diff --git
From: Emil Velikov
Signed-off-by: Emil Velikov
---
tests/functional/gl_basic_test.c | 140 ++-
1 file changed, 80 insertions(+), 60 deletions(-)
diff --git a/tests/functional/gl_basic_test.c b/tests/functional/gl_basic_test.c
index 75d9c20..283489c 100644
--
From: Emil Velikov
Signed-off-by: Emil Velikov
---
tests/functional/gl_basic_test.c | 67
1 file changed, 6 insertions(+), 61 deletions(-)
diff --git a/tests/functional/gl_basic_test.c b/tests/functional/gl_basic_test.c
index 283489c..c4faa11 100644
---
Signed-off-by: Emil Velikov
---
src/waffle/core/wcore_config_attrs_unittest.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/waffle/core/wcore_config_attrs_unittest.c
b/src/waffle/core/wcore_config_attrs_unittest.c
index e6a2af0..14eec01 100644
--- a/src/waffle/core/
From: Emil Velikov
During context setup we prioritise as follows
1. expected error (!= NO_ERROR), check it
2. otherwise (if call fails) check for
a) UNSUPPORTED_ON_PLATFORM and
b) ERROR_UNKNOWN (winsys implementation has rejected the request)
and skip the test. If other error is returned, f
No longer used/needed.
Signed-off-by: Emil Velikov
---
.gitignore | 1 -
include/waffle_test/priv/wt_runner.h | 46
include/waffle_test/priv/wt_test.h | 52 -
include/waffle_test/waffle_test.h| 76 -
src/CMakeLists.txt
On 5 January 2016 at 19:46, wrote:
> From: Dylan Baker
>
> This is groundwork for adding a json interface to wflinfo.
>
> v2: - remove extra return statement (Frank)
> - rename flags to context_flags (Chad)
> ---
> src/utils/wflinfo.c | 33 +
> 1 file changed
On 5 January 2016 at 19:46, wrote:
> From: Dylan Baker
>
> Pull these out into helper functions, this change will be used in a
> following patch to add a JSON printer.
>
> Signed-off-by: Dylan Baker
>
> v2: - change "const char * name" to "const char *name" (Frank)
> ---
> src/utils/wflinfo.c
On Wed, Jan 6, 2016 at 4:27 PM, Emil Velikov wrote:
> Neither one of these is (or has been) used. Remove them for now and
> introduce back when needed.
>
> Presently this causes run-time issues whenever someone attempts to use an
> old version of libgbm (mesa circa 9.2) as the gbm_bo_get_fd symbol
On Wed, Jan 6, 2016 at 1:30 PM, Emil Velikov
wrote:
> On 5 January 2016 at 19:46, wrote:
> > From: Dylan Baker
> >
> > Pull these out into helper functions, this change will be used in a
> > following patch to add a JSON printer.
> >
> > Signed-off-by: Dylan Baker
> >
> > v2: - change "const
Hi Frank,
It looks like your series is going to achieve the same result (for my use)
as mine did, but yours is probably better. With that in mind I'll be
withdrawing mine in favour of yours.
Dylan
On Wed, Jan 6, 2016 at 11:56 AM, Frank Henigman
wrote:
> This patch set does two main things, the
Okay, I have some comments:
When I run wflinfo -p gbm -a gl -f json | jsontidy (a small python script I
have that formats JSON to be human readable)
I get this:
{
"generic": {
"waffle": {
"api": "WAFFLE_CONTEXT_OPENGL",
"platform": "WAFFLE_PLATFORM_GBM"
On Wed, Jan 6, 2016 at 6:43 PM, Dylan Baker wrote:
> Okay, I have some comments:
>
> When I run wflinfo -p gbm -a gl -f json | jsontidy (a small python script I
> have that formats JSON to be human readable)
> I get this:
> {
> "generic": {
> "waffle": {
> "api": "WAFFLE_CO
On Wed, Jan 6, 2016 at 4:12 PM, Frank Henigman
wrote:
> On Wed, Jan 6, 2016 at 6:43 PM, Dylan Baker
> wrote:
> > Okay, I have some comments:
> >
> > When I run wflinfo -p gbm -a gl -f json | jsontidy (a small python
> script I
> > have that formats JSON to be human readable)
> > I get this:
> >
50 matches
Mail list logo