Commit f419fcb4 authored by Chad Versace's avatar Chad Versace

all: Use shorter #include paths

Short is sweet... and more easily visually parsed.

Replace each include of form
    #include "waffle/$dir/$filename"
with
    #include "$filename"
Signed-off-by: default avatarChad Versace <chad.versace@linux.intel.com>
parent 0078aed0
......@@ -36,7 +36,11 @@ LOCAL_CFLAGS := \
LOCAL_C_INCLUDES := \
$(LOCAL_PATH)/include/waffle \
$(LOCAL_PATH)/src/ \
$(LOCAL_PATH)/src/waffle/api/ \
$(LOCAL_PATH)/src/waffle/core/ \
$(LOCAL_PATH)/src/waffle/egl/ \
$(LOCAL_PATH)/src/waffle/linux/ \
$(LOCAL_PATH)/src/waffle/droid/ \
LOCAL_SRC_FILES := \
src/waffle/core/wcore_tinfo.c \
......
......@@ -3,6 +3,17 @@
# ----------------------------------------------------------------------------
include_directories(
android
api
cgl
core
egl
glx
linux
wayland
x11
xegl
${egl_INCLUDE_DIRS}
${gbm_INCLUDE_DIRS}
${gl_INCLUDE_DIRS}
......
......@@ -23,14 +23,14 @@
// OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "droid_display.h"
#include "droid_platform.h"
#include <stdlib.h>
#include "waffle/linux/linux_platform.h"
#include "waffle/core/wcore_error.h"
#include "wcore_error.h"
#include "linux_platform.h"
#include "droid_display.h"
#include "droid_platform.h"
#include "droid_surfaceflingerlink.h"
struct wcore_display*
......
......@@ -28,7 +28,7 @@
#include <stdbool.h>
#include <stdint.h>
#include "waffle/egl/wegl_display.h"
#include "wegl_display.h"
struct droid_surfaceflinger_container;
......
......@@ -23,18 +23,19 @@
// OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "droid_platform.h"
#include <dlfcn.h>
#include <stdlib.h>
#include "waffle/core/wcore_error.h"
#include "waffle/egl/wegl_config.h"
#include "waffle/egl/wegl_context.h"
#include "waffle/egl/wegl_util.h"
#include "waffle/linux/linux_platform.h"
#include "wcore_error.h"
#include "linux_platform.h"
#include "wegl_config.h"
#include "wegl_context.h"
#include "wegl_util.h"
#include "droid_display.h"
#include "droid_platform.h"
#include "droid_window.h"
static const struct wcore_platform_vtbl droid_platform_vtbl;
......
......@@ -26,8 +26,9 @@
#pragma once
#include <stdbool.h>
#include "waffle/core/wcore_platform.h"
#include "waffle/core/wcore_util.h"
#include "wcore_platform.h"
#include "wcore_util.h"
struct linux_platform;
......
......@@ -36,8 +36,8 @@
#include "droid_surfaceflingerlink.h"
extern "C" {
#include "waffle/core/wcore_util.h"
#include "waffle/core/wcore_error.h"
#include "wcore_util.h"
#include "wcore_error.h"
};
using namespace android;
......
......@@ -23,16 +23,16 @@
// OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "droid_window.h"
#include <stdlib.h>
#include <string.h>
#include "waffle/core/wcore_error.h"
#include "waffle/egl/wegl_config.h"
#include "wcore_error.h"
#include "wegl_config.h"
#include "droid_display.h"
#include "droid_surfaceflingerlink.h"
#include "droid_window.h"
struct wcore_window*
droid_window_create(struct wcore_platform *wc_plat,
......
......@@ -27,7 +27,7 @@
#include <stdbool.h>
#include "waffle/egl/wegl_window.h"
#include "wegl_window.h"
struct wcore_platform;
......
......@@ -28,15 +28,14 @@
/// @file
#include "api_priv.h"
#include <stdio.h>
#include <stdlib.h>
#include "waffle/core/wcore_error.h"
#include "waffle/core/wcore_platform.h"
#include "api_object.h"
#include "api_priv.h"
#include "wcore_error.h"
#include "wcore_platform.h"
struct wcore_platform *api_platform = 0;
......
......@@ -31,7 +31,7 @@
#include "waffle_attrib_list.h"
#include "waffle/core/wcore_error.h"
#include "wcore_error.h"
int32_t
waffle_attrib_list_length(const int32_t attrib_list[])
......
......@@ -26,6 +26,7 @@
#include <string.h>
#include "waffle_attrib_list.h"
#include "waffle_test/waffle_test.h"
TESTGROUP_SIMPLE(waffle_attrib_list_get)
......
......@@ -28,17 +28,17 @@
/// @file
#include "waffle_config.h"
#include <stdlib.h>
#include "waffle/core/wcore_config_attrs.h"
#include "waffle/core/wcore_config.h"
#include "waffle/core/wcore_display.h"
#include "waffle/core/wcore_platform.h"
#include "waffle_config.h"
#include "api_priv.h"
#include "wcore_config_attrs.h"
#include "wcore_config.h"
#include "wcore_display.h"
#include "wcore_platform.h"
struct waffle_config*
waffle_config_choose(
struct waffle_display *dpy,
......
......@@ -28,15 +28,15 @@
/// @file
#include "waffle_context.h"
#include <stdlib.h>
#include "waffle/core/wcore_context.h"
#include "waffle/core/wcore_platform.h"
#include "waffle_context.h"
#include "api_priv.h"
#include "wcore_context.h"
#include "wcore_platform.h"
struct waffle_context*
waffle_context_create(
struct waffle_config *config,
......
......@@ -28,18 +28,18 @@
/// @file
#include "waffle_display.h"
#include <stdlib.h>
#include "waffle_display.h"
#include "waffle_enum.h"
#include "waffle/core/wcore_error.h"
#include "waffle/core/wcore_display.h"
#include "waffle/core/wcore_platform.h"
#include "waffle/core/wcore_util.h"
#include "api_priv.h"
#include "wcore_error.h"
#include "wcore_display.h"
#include "wcore_platform.h"
#include "wcore_util.h"
struct waffle_display*
waffle_display_connect(const char *name)
{
......
......@@ -29,13 +29,13 @@
/// @file
#include "waffle_dl.h"
#include "waffle_enum.h"
#include "waffle/core/wcore_error.h"
#include "waffle/core/wcore_platform.h"
#include "api_priv.h"
#include "wcore_error.h"
#include "wcore_platform.h"
static bool
waffle_dl_check_enum(int32_t dl)
{
......
......@@ -30,7 +30,7 @@
#include "waffle_enum.h"
#include "waffle/core/wcore_error.h"
#include "wcore_error.h"
const char*
waffle_enum_to_string(int32_t e)
......
......@@ -29,7 +29,8 @@
/// @file
#include <string.h>
#include "waffle/core/wcore_error.h"
#include "wcore_error.h"
int32_t
waffle_error_get_code(void)
......
......@@ -28,20 +28,20 @@
/// @file
#include "waffle_gl_misc.h"
#include <stddef.h>
#include <string.h>
#include "waffle_enum.h"
#include "waffle/core/wcore_context.h"
#include "waffle/core/wcore_display.h"
#include "waffle/core/wcore_error.h"
#include "waffle/core/wcore_platform.h"
#include "waffle/core/wcore_window.h"
#include "waffle_gl_misc.h"
#include "api_priv.h"
#include "wcore_context.h"
#include "wcore_display.h"
#include "wcore_error.h"
#include "wcore_platform.h"
#include "wcore_window.h"
bool
waffle_is_extension_in_string(
const char *restrict extension_string,
......
......@@ -28,14 +28,14 @@
/// @file
#include "waffle_init.h"
#include "waffle_enum.h"
#include "waffle/core/wcore_error.h"
#include "waffle/core/wcore_platform.h"
#include "waffle_init.h"
#include "api_priv.h"
#include "wcore_error.h"
#include "wcore_platform.h"
struct wcore_platform* cgl_platform_create(void);
struct wcore_platform* droid_platform_create(void);
struct wcore_platform* glx_platform_create(void);
......
......@@ -28,16 +28,16 @@
/// @file
#include "waffle_window.h"
#include <stdlib.h>
#include "waffle/core/wcore_config.h"
#include "waffle/core/wcore_platform.h"
#include "waffle/core/wcore_window.h"
#include "waffle_window.h"
#include "api_priv.h"
#include "wcore_config.h"
#include "wcore_platform.h"
#include "wcore_window.h"
struct waffle_window*
waffle_window_create(
struct waffle_config *config,
......
......@@ -30,8 +30,8 @@
#include <OpenGL/OpenGL.h>
#include "waffle/core/wcore_config.h"
#include "waffle/core/wcore_util.h"
#include "wcore_config.h"
#include "wcore_util.h"
struct wcore_config_attrs;
struct wcore_platform;
......
......@@ -29,8 +29,8 @@
#include "waffle_enum.h"
#include "waffle/core/wcore_config_attrs.h"
#include "waffle/core/wcore_error.h"
#include "wcore_config_attrs.h"
#include "wcore_error.h"
#include "cgl_config.h"
#include "cgl_error.h"
......
......@@ -30,8 +30,8 @@
#include <Cocoa/Cocoa.h>
#include <OpenGL/OpenGL.h>
#include "waffle/core/wcore_context.h"
#include "waffle/core/wcore_util.h"
#include "wcore_context.h"
#include "wcore_util.h"
struct wcore_config;
struct wcore_platform;
......
......@@ -27,7 +27,8 @@
#include <stdlib.h>
#include "waffle_enum.h"
#include "waffle/core/wcore_error.h"
#include "wcore_error.h"
#include "cgl_config.h"
#include "cgl_context.h"
......
......@@ -28,8 +28,8 @@
#include <stdbool.h>
#include <stdint.h>
#include "waffle/core/wcore_display.h"
#include "waffle/core/wcore_util.h"
#include "wcore_display.h"
#include "wcore_util.h"
struct wcore_platform;
......
......@@ -27,7 +27,8 @@
#include <stdlib.h>
#include "waffle_enum.h"
#include "waffle/core/wcore_error.h"
#include "wcore_error.h"
#include "cgl_display.h"
......
......@@ -28,7 +28,7 @@
#include "waffle_enum.h"
#include "waffle/core/wcore_error.h"
#include "wcore_error.h"
#include "cgl_dl.h"
#include "cgl_platform.h"
......
......@@ -28,15 +28,15 @@
/// @file
#include "cgl_error.h"
#include <assert.h>
#include <stdbool.h>
#include <stdlib.h>
#include <OpenGL/OpenGL.h>
#include "waffle/core/wcore_error.h"
#include "wcore_error.h"
#include "cgl_error.h"
const char*
cgl_error_to_string(int error_code)
......
......@@ -25,8 +25,8 @@
#pragma once
#include "waffle/core/wcore_platform.h"
#include "waffle/core/wcore_util.h"
#include "wcore_platform.h"
#include "wcore_util.h"
struct linux_platform;
......
......@@ -25,14 +25,13 @@
#include <stdlib.h>
#include "waffle/core/wcore_error.h"
#include "wcore_error.h"
#include "cgl_config.h"
#include "cgl_context.h"
#include "cgl_display.h"
#include "cgl_dl.h"
#include "cgl_platform.h"
#include "cgl_window.h"
static const struct wcore_platform_vtbl cgl_platform_vtbl;
......
......@@ -27,8 +27,8 @@
#include <stdbool.h>
#include "waffle/core/wcore_window.h"
#include "waffle/core/wcore_util.h"
#include "wcore_util.h"
#include "wcore_window.h"
#include "WaffleGLView.h"
......
......@@ -26,7 +26,7 @@
#import <Cocoa/Cocoa.h>
#import <OpenGL/OpenGL.h>
#include "waffle/core/wcore_error.h"
#include "wcore_error.h"
#include "cgl_config.h"
#include "cgl_window.h"
......
......@@ -32,7 +32,7 @@
#include "waffle_config.h"
#include "waffle/api/api_object.h"
#include "api_object.h"
#include "wcore_display.h"
#include "wcore_config_attrs.h"
......
......@@ -28,14 +28,14 @@
/// @file
#include "wcore_config_attrs.h"
#include <stdlib.h>
#include <string.h>
#include "waffle_attrib_list.h"
#include "waffle_enum.h"
#include "waffle/core/wcore_error.h"
#include "wcore_config_attrs.h"
#include "wcore_error.h"
/// @brief Attribute defaults that apply to all API's.
static const struct wcore_config_attrs wcore_config_attrs_default_all = {
......
......@@ -27,6 +27,7 @@
#include <string.h>
#include "waffle_enum.h"
#include "waffle_test/waffle_test.h"
#include "wcore_config_attrs.h"
......
......@@ -31,7 +31,7 @@
#include "waffle_context.h"
#include "waffle/api/api_object.h"
#include "api_object.h"
#include "wcore_config.h"
#include "wcore_util.h"
......
......@@ -23,12 +23,12 @@
// OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "wcore_display.h"
#include <assert.h>
#include <pthread.h>
#include <stdio.h>
#include "wcore_display.h"
bool
wcore_display_init(struct wcore_display *self,
struct wcore_platform *platform)
......
......@@ -31,7 +31,7 @@
#include "waffle_display.h"
#include "waffle/api/api_object.h"
#include "api_object.h"
#include "wcore_util.h"
......
......@@ -28,14 +28,13 @@
/// @file
#include "wcore_error.h"
#include <stdarg.h>
#include <stdbool.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "wcore_error.h"
#include "wcore_tinfo.h"
enum {
......
......@@ -40,7 +40,6 @@
#include "waffle_error.h"
/// @brief Thread-local info for the wcore_error module.
struct wcore_error_tinfo;
......
......@@ -28,8 +28,6 @@
/// @file
#include "wcore_tinfo.h"
#include <stdbool.h>
#include <stdio.h>
#include <stdlib.h>
......@@ -37,6 +35,7 @@
#include <pthread.h>
#include "wcore_error.h"
#include "wcore_tinfo.h"
/// @brief Key for @ref wcore_tinfo_tl_singleton.
static pthread_key_t wcore_tinfo_key;
......
......@@ -25,9 +25,9 @@
#include "waffle_enum.h"
#include "waffle/core/wcore_config_attrs.h"
#include "waffle/core/wcore_error.h"
#include "waffle/core/wcore_platform.h"
#include "wcore_config_attrs.h"
#include "wcore_error.h"
#include "wcore_platform.h"
#include "wegl_config.h"
#include "wegl_display.h"
......
......@@ -30,8 +30,8 @@
#include <EGL/egl.h>
#include "waffle/core/wcore_config.h"
#include "waffle/core/wcore_util.h"
#include "wcore_config.h"
#include "wcore_util.h"
#include "wegl_display.h"
......
......@@ -25,7 +25,7 @@
#include "waffle_enum.h"
#include "waffle/core/wcore_error.h"
#include "wcore_error.h"
#include "wegl_config.h"
#include "wegl_context.h"
......
......@@ -30,8 +30,8 @@
#include <EGL/egl.h>
#include "waffle/core/wcore_context.h"
#include "waffle/core/wcore_util.h"
#include "wcore_context.h"
#include "wcore_util.h"
struct wegl_display;
......
......@@ -27,8 +27,8 @@
#include "waffle_enum.h"
#include "waffle/core/wcore_error.h"
#include "waffle/core/wcore_platform.h"
#include "wcore_error.h"
#include "wcore_platform.h"
#include "wegl_display.h"
#include "wegl_util.h"
......
......@@ -30,7 +30,7 @@
#include <EGL/egl.h>
#include "waffle/core/wcore_display.h"
#include "wcore_display.h"
struct wcore_display;
......
......@@ -23,7 +23,7 @@
// OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "waffle/core/wcore_error.h"
#include "wcore_error.h"
#include "wegl_context.h"
#include "wegl_display.h"
......
......@@ -30,7 +30,7 @@
#include <EGL/egl.h>
#include "waffle/core/wcore_window.h"
#include "wcore_window.h"
struct wegl_config;
struct wegl_display;
......
......@@ -23,7 +23,7 @@
// OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "waffle/core/wcore_error.h"
#include "wcore_error.h"
#include "wgbm_config.h"
#include "wgbm_display.h"
......
......@@ -30,7 +30,7 @@
#include <gbm.h>
#include "waffle/egl/wegl_config.h"
#include "wegl_config.h"
union waffle_native_config;
......
......@@ -36,7 +36,7 @@
#include <sys/stat.h>
#include <linux/input.h>
#include "waffle/core/wcore_error.h"
#include "wcore_error.h"