summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCorentin Noël <corentin.noel@collabora.com>2022-08-09 11:16:39 +0200
committerCorentin Noël <corentin.noel@collabora.com>2022-08-09 11:43:42 +0200
commitb55a7aad46554658916e57c28e024fa34e0b1e82 (patch)
tree130ffb56ab5e8184e543e23a1dce25f0d45c8ec9
parentc7d7f8e8fed38fee172d46705f50118ec9549fe1 (diff)
downloadlibrest-b55a7aad46554658916e57c28e024fa34e0b1e82.tar.gz
Make the single-header usable
The pkg-config is only declaring the rest-1.0 directory so we always need to use rest/rest-foo.h and not rest-foo.h Also make sure to include all the headers.
-rw-r--r--rest/meson.build5
-rw-r--r--rest/rest-oauth2-proxy-call.c1
-rw-r--r--rest/rest-oauth2-proxy-call.h3
-rw-r--r--rest/rest.h17
4 files changed, 15 insertions, 11 deletions
diff --git a/rest/meson.build b/rest/meson.build
index fd3ae79..224b24a 100644
--- a/rest/meson.build
+++ b/rest/meson.build
@@ -79,13 +79,8 @@ endif
if get_option('introspection')
librest_gir_extra_args = [
'--accept-unprefixed',
- '--c-include=rest/rest-enum-types.h',
]
- foreach header : librest_headers
- librest_gir_extra_args += '--c-include=rest/@0@'.format(header)
- endforeach
-
librest_gir = gnome.generate_gir(librest_lib,
sources: librest_sources + librest_headers + librest_enums,
nsversion: librest_api_version,
diff --git a/rest/rest-oauth2-proxy-call.c b/rest/rest-oauth2-proxy-call.c
index 88840b3..cfed247 100644
--- a/rest/rest-oauth2-proxy-call.c
+++ b/rest/rest-oauth2-proxy-call.c
@@ -17,6 +17,7 @@
*/
#include "rest-oauth2-proxy-call.h"
+#include "rest-oauth2-proxy.h"
G_DEFINE_TYPE (RestOAuth2ProxyCall, rest_oauth2_proxy_call, REST_TYPE_PROXY_CALL)
diff --git a/rest/rest-oauth2-proxy-call.h b/rest/rest-oauth2-proxy-call.h
index 799157d..3da126d 100644
--- a/rest/rest-oauth2-proxy-call.h
+++ b/rest/rest-oauth2-proxy-call.h
@@ -18,7 +18,8 @@
#pragma once
-#include <rest/rest.h>
+#include <glib-object.h>
+#include <rest/rest-proxy-call.h>
G_BEGIN_DECLS
diff --git a/rest/rest.h b/rest/rest.h
index 0c4afbb..4dbd135 100644
--- a/rest/rest.h
+++ b/rest/rest.h
@@ -25,11 +25,18 @@
G_BEGIN_DECLS
#define REST_INSIDE
-# include "rest-proxy.h"
-# include "rest-proxy-call.h"
-# include "rest-oauth2-proxy.h"
-# include "rest-utils.h"
-# include "rest-pkce-code-challenge.h"
+# include <rest/rest-oauth2-proxy.h>
+# include <rest/rest-oauth2-proxy-call.h>
+# include <rest/rest-param.h>
+# include <rest/rest-params.h>
+# include <rest/rest-pkce-code-challenge.h>
+# include <rest/rest-pkce-code-challenge.h>
+# include <rest/rest-proxy.h>
+# include <rest/rest-proxy-auth.h>
+# include <rest/rest-proxy-call.h>
+# include <rest/rest-utils.h>
+# include <rest/rest-xml-node.h>
+# include <rest/rest-xml-parser.h>
#undef REST_INSIDE
G_END_DECLS