summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2014-02-07gitignore: Ignore html manpageChad Versace1-0/+1
Ignore waffle_feature_test_macros.7.html. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2014-01-25Merge branch 'wflinfo-short-opts'Chad Versace2-25/+43
2014-01-25wflinfo: implement short options for common parametersJordan Justen2-9/+17
-p for --platform -a for --api -V for --version -v for --verbose Signed-off-by: Jordan Justen <jordan.l.justen@intel.com> Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2014-01-25wflinfo man page: highlight 'replaceable' itemsJordan Justen1-3/+3
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com> Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2014-01-25wflinfo: if a parameter is not given, don't print NULL stringJordan Justen1-1/+4
If a parameter was not given for an option, for example: wflinfo --platform Then we would try to print a NULL string. Signed-off-by: Jordan Justen <jordan.l.justen@intel.com> Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2014-01-25wflinfo: Clean usage textJordan Justen1-15/+22
Cleaning up and re-organizing to allow short version parameters to be added. Signed-off-by: Jordan Justen <jljusten@gmail.com> Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2014-01-19Merge branch 'wflinfo-mac'Chad Versace2-12/+6
This series gets wflinfo working on Mac. On Mac we now have the same insight as provided by glxinfo on Linux. Here's the info from my MacBook Pro: Waffle platform: cgl Waffle api: gl OpenGL vendor string: ATI Technologies Inc. OpenGL renderer string: AMD Radeon HD 6750M OpenGL Engine OpenGL version string: 4.1 ATI-1.14.21 OpenGL context flags: FORWARD_COMPATIBLE OpenGL extensions: GL_ARB_blend_func_extended GL_ARB_draw_buffers_blend GL_ARB_draw_indirect GL_ARB_ES2_compatibility GL_ARB_explicit_attrib_location GL_ARB_gpu_shader5 GL_ARB_instanced_arrays GL_ARB_internalformat_query GL_ARB_occlusion_query2 GL_ARB_sample_shading GL_ARB_sampler_objects GL_ARB_separate_shader_objects GL_ARB_shader_bit_encoding GL_ARB_shader_subroutine GL_ARB_shading_language_include GL_ARB_tessellation_shader GL_ARB_texture_buffer_object_rgb32 GL_ARB_texture_cube_map_array GL_ARB_texture_gather GL_ARB_texture_query_lod GL_ARB_texture_rgb10_a2ui GL_ARB_texture_storage GL_ARB_texture_swizzle GL_ARB_timer_query GL_ARB_transform_feedback2 GL_ARB_transform_feedback3 GL_ARB_vertex_type_2_10_10_10_rev GL_ARB_viewport_array GL_EXT_debug_label GL_EXT_debug_marker GL_EXT_texture_compression_s3tc GL_EXT_texture_filter_anisotropic GL_EXT_texture_mirror_clamp GL_EXT_texture_sRGB_decode GL_APPLE_client_storage GL_APPLE_container_object_shareable GL_APPLE_flush_render GL_APPLE_object_purgeable GL_APPLE_rgb_422 GL_APPLE_row_bytes GL_APPLE_texture_range GL_ATI_texture_mirror_once GL_NV_texture_barrier
2014-01-19cgl: Make waffle_get_proc_address() workChad Versace1-4/+6
There is no CGLGetProcAddress, so waffle_get_proc_address() always emitted an error. However, this patch changes it to follow the principle of least surprise. The only supported API on CGL is OpenGL, so assume the user called waffle_get_proc_address() to obtain an OpenGL function pointer and get it with dlsym(). Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2014-01-19wflinfo: Build on MacChad Versace1-8/+0
I tested that wflinfo doesn't break the build on Mac. Despite building, though, it doesn't work. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2014-01-15waffle utils: add Android.mkJordan Justen1-0/+21
This should allow wflinfo to get built for android. v2 (chadv): Fix LOCAL_C_INCLUDES, as pointed out by Juha-Pekka. Signed-off-by: Jordan Justen <jordan.l.justen@intel.com> Signed-off-by: Chad Versace <chad.versace@linux.intel.com> Tested-by: Juha-Pekka Heikkilä <juha-pekka.heikkila@linux.intel.com>
2014-01-15man/wflinfo: Remove trailing commaChad Versace1-1/+1
Trivial change. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2014-01-15waffle: add debian packagingJordan Justen9-0/+124
This builds 4 packages: * libwaffle-1 * libwaffle-dev (pkgconfig, includes) * libwaffle-doc (man pages) * waffle-utils (wflinfo w/man page) v3: * Added to v3 of wflinfo series * Changed copyright to Intel Signed-off-by: Jordan Justen <jordan.l.justen@intel.com> Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2014-01-15waffle utils: add wflinfo man pageJordan Justen9-0/+211
v3: * Move description section up Signed-off-by: Jordan Justen <jordan.l.justen@intel.com> Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2014-01-15waffle utils: add wflinfo utilityJordan Justen4-0/+763
glxinfo for waffle, but using the command line interface of waffle's gl_basic test. v2 (jljusten): * Various cleanups suggested by Chad * Print context flags rather than verifying them. * Only print extensions when --verbose is used v3 (jljusten): * "GL ERROR" => "WFLINFO_GL_ERROR" * print_extensions: fix cases that did not print a newline * In print_context_flags: - print WFLINFO_GL_ERROR when there is an error - print 0x0 rather than (none) * print vendor/renderer/version/context flags before checking for GetStringi * Add 'Waffle platform' and 'Waffle api' output * Change --debug to --debug-context v4 (chadv): * Don't build wflinfo on Mac. Since no one has tested it, so it may break the build. Signed-off-by: Jordan Justen <jordan.l.justen@intel.com> Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2014-01-08wayland: respond to ping requests from the compositorRob Bradford1-0/+33
The ping/pong protocol on the shell surface is used by the compositor to check that the client is responding to requests. This change adds a listener for the shell surface and implements the ping handler to respond to the requests from the compositor. As the wayland dispatch infrastructure does not support having NULL values for the members of the listener it is necessary to provide empty implementations for the other events that the listener handles. Signed-off-by: Rob Bradford <rob@linux.intel.com> Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2014-01-08wayland: add a handler for global remove eventRob Bradford1-1/+8
The Wayland event dispatch infrastructure does not check if the event handler member is NULL before dereferencing the appropriate member in the listener. This change supplies an empty function as the event handler for the global remove event on the wl_registry listener rather than the previously supplied NULL value. Signed-off-by: Rob Bradford <rob@linux.intel.com> Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2013-12-21examples/gl_basic: Rename gl_basic_error() -> error_printf()Chad Versace1-8/+8
The new name better reflects what it does. It accepts a printf format string. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2013-12-02cmake: Fix dependency on cmockaChad Versace1-1/+1
This fixes an error in the Makefile-dependency of unittests, introduced in commit ad40427a864a7436953b319fbfdb2c04ccb7bdab. From the perspective of Waffle's CMake, libcmocka.so is an *imported* library. In other words, it's a virtual target, represented by a '.PHONY' target in Unix Makefiles. To guarantee that libcmocka.so gets built, CMake must declare that the .PHONY 'cmocka' target depends on another .PHONY target, which does the actual building. Making 'cmocka' depend on a non-PHONY target doesn't work. Reported-by: Shazia Rahman <srahman@nvidia.com> Reported-by: Paul Berry <stereotype441@gmail.com> Tested-by: Paul Berry <stereotype441@gmail.com> Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2013-12-02gitignore: Fix .gitignore for recently added tests.Paul Berry1-0/+3
Reviewed-by: Chad Versace <chad.versace@linux.intel.com>
2013-12-02android: Fix Android Kitkat build issueJuha-Pekka Heikkila1-0/+1
Changes in Android Kitkat required one extra include file to allow using ANativeWindow. Signed-off-by: Juha-Pekka Heikkila <juha-pekka.heikkila@linux.intel.com> Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2013-12-01cmake: Don't build unittests when waffle_build_tests=0Chad Versace1-0/+4
Return early from add_unittest() if waffle_build_tests=0, making the function a no-op. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2013-12-01Merge branch 'cmocka'Chad Versace70-674/+10607
This merge makes progress towards killing off libwaffle_test and replacing it with cmocka. - Add subtree 'third_party/cmocka' from tag cmocka-0.3.2. - Convert all unit test executables to use cmocka. They no longer use libwaffle_test. - The only remaining user of libwaffle_test is gl_basic_test, which I will also move to cmocka eventually.
2013-12-01core: Stop linking libwaffle_test into unittest executablesChad Versace1-1/+0
All unittests have been converted to use cmocka. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2013-12-01core: Convert wcore_config_attrs_unittest to use cmockaChad Versace1-512/+638
Convert it away from using libwaffle_test. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2013-12-01core: Convert wcore_error_unittest to use cmockaChad Versace1-64/+55
Convert it away from using libwaffle_test. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2013-12-01core: Convert wcore_attrib_list_unittest to use cmockaChad Versace2-97/+86
Convert it away from using libwaffle_test. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2013-12-01cmake: Add module WaffleCMockaChad Versace2-0/+87
If waffle_build_tests, then this module imports the cmocka library built in 'third_party/cmocka'. When configuring waffle, the module also configures 'third_party/cmocka' by descending into the directory and invoking cmake there. All tests will eventrually be converted from using libwaffle_test to use cmocka. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2013-11-27cmocka: Add subtree from tag cmocka-0.3.2Chad Versace64-0/+9741
Shell-Command: \ git-subtree add --prefix=third_party/cmocka --squash \ git://git.cryptomilk.org/projects/cmocka.git \ refs/tags/cmocka-0.3.2 Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2013-11-27pkg/archlinux: Remove PKGBUILD.templateChad Versace5-61/+0
The build system generated a real PKGBUILD from PKGBUILD.template. Rather than do that, let's just maintain *real* PKGBUILD's from the AUR that are known to work.
2013-11-27pkg/archlinux: Import waffle-1.3.0 PKGBUILD from AURChad Versace1-0/+55
Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2013-11-27Squashed 'third_party/cmocka/' content from commit 9ec5378Chad Versace64-0/+9741
git-subtree-dir: third_party/cmocka git-subtree-split: 9ec537894241fd54bb7bb661ed1af3db7c60b234
2013-11-27cmake: Refactor repeating patterns for unittestsChad Versace2-65/+28
Move all repetition into new function add_unittest(). Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2013-11-27tests: Remove waffle-unittest runnerChad Versace3-58/+0
All unittests have now been moved into separate executables, one executable per unit. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2013-11-27core: Move wcore_error unittests to separate executableChad Versace4-8/+33
Pull the unittests for wcore_error out of the waffle-unittest executable and place them into a new separate executable, 'tests/wcore_error_unittests'. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2013-11-27core: Move wcore_config_attrs unittests to separate executableChad Versace4-7/+33
Pull the unittests for wcore_config_attrs out of the waffle-unittest executable and place them into a new separate executable, 'tests/wcore_config_attrs_unittests'. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2013-11-27core: Move wcore_attrib_list unittests to separate executableChad Versace5-7/+38
Pull the unittests for wcore_attrib_list out of the waffle-unittest executable and place them into a new separate executable, 'tests/wcore_attrib_list_unittests'. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2013-11-27waffle: Fix name of static waffle libraryChad Versace1-0/+1
Rename it 'libwaffle_static.a' -> 'libwaffle-1.a'. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2013-11-27waffle: Fix build location of libwaffle_static.aChad Versace1-1/+1
I intended to place libwaffle_static.a into ${CMAKE_BINARY_DIR}/lib, which is the same directory into which libwaffle.so is placed. However, I failed at CMake-foo for static libraries. The LIBRARY_OUTPUT_DIRECTORY property is ignored for static libraries. Instead, the ARCHIVE_OUTPUT_DIRECTORY property must be used. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2013-11-27waffle: Link external dependencies to libwaffle_static.aChad Versace1-1/+1
The static library is not very useful if it can't call out to required external functions. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2013-11-27waffle_test: Move source from 'tests' to 'src' and 'include'Chad Versace10-8/+14
This moves the waffle_test sources into a more canonical location. Instead of keeping it jailed as a subdir of 'tests' as 'tests/waffle_test', its source is now in 'src/waffle_test' and its public headers in 'include/waffle_test'. Keeping things in canonical locations makes it easier to find things if you don't yet know where they reside. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2013-11-27cmake: Move targets check, check-func to top dirChad Versace4-19/+34
By moving 'check' to the top dir, each subdirectory can now add dependencies to 'check'. Ditto for 'check-func'. This change will allow us to build each unittest file as a separate executable, as well as maintain the CMake rules for the unittest in in the same directory as its sources. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2013-11-27cmake: Add 'include' to include directoriesChad Versace1-0/+1
Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2013-11-27core: Don't call public API waffle_enum_to_string()Chad Versace1-1/+2
Don't call public API from internal functions. That's a recipe for bugs. Replace call to waffle_enum_to_string() with wcore_enum_to_string(). Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2013-11-25waffle: Use enum waffle_error for waffle_error_to_string()Chad Versace3-3/+3
This continues the conversion of int32_t to `enum waffle_error` began in commit a5cd4c7. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2013-11-24cgl: Fix validation of system versionChad Versace2-4/+6
I failed at hex :( For OS X 10.7, check that platform->system_version_full >= 0x0a07, not 0x1070. Ditto for 10.9. Fixes creation of OpenGL 3.2 contexts. Tested on OS X 10.9 Mavericks. Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2013-11-24cgl: Gestalt is deprecated, stop using itChad Versace1-20/+24
Don't use Gestalt() to get system version. Instead, get the 'ProductVersion' key from '/System/Library/CoreServices/SystemVersion.plist'. This is the same fix that Firefox used. Fixes the following compilation warning: warning: 'Gestalt' is deprecated: first deprecated in OS X 10.8 [-Wdeprecated-declarations] Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2013-11-24cgl: Fix warnings -Wtautological-constant-out-of-range-compareChad Versace1-1/+1
In macro cgl_config.m:ADD_ATTR(), cast the compared value to an int before comparing it to WAFFLE_DONT_CARE (which is itself an int). This fixes tautological comparisons when the compared value is a bool. Fixes 2 warnings like the following: src/waffle/cgl/cgl_config.m:207:5: warning: comparison of constant 'WAFFLE_DONT_CARE' (-1) with expression of type 'const bool' is always true [-Wtautological-constant-out-of-range-compare] ADD_ATTR(kCGLPFASampleBuffers, attrs->sample_buffers); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ src/waffle/cgl/cgl_config.m:173:21: note: expanded from macro 'ADD_ATTR' if ((value) != WAFFLE_DONT_CARE) { \ ~~~~~~~ ^ ~~~~~~~~~~~~~~~~ Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2013-11-22waffle: use enum waffle_error instead of intBrian Paul6-14/+14
Using the enum type instead of int makes debugging a little easier. It just seems like the right thing to do anyway. v2[chadv]: Update type of waffle_error_info::code in manpage. Reviewed-by: Chad Versace <chad.versace@linux.intel.com>
2013-11-14gbm: try to open a render node before the card deviceJordan Justen1-3/+18
Since render nodes allow rendering which should not interact with the window system, we attempt to use render nodes first when a gbm device is not directly specified. The main difference as far as gbm is concerned is that render nodes don't require drm master authentication. Signed-off-by: Jordan Justen <jordan.l.justen@intel.com> Reviewed-by: Chad Versace <chad.versace@linux.intel.com>
2013-10-05gitignore: Ignore .ninja_depsChad Versace1-0/+1
Signed-off-by: Chad Versace <chad.versace@linux.intel.com>