summaryrefslogtreecommitdiff
path: root/content
diff options
context:
space:
mode:
authorAshish Gupta <ashmew2@gmail.com>2017-04-21 23:18:15 +0200
committerAshish Gupta <ashmew2@gmail.com>2017-10-25 22:04:54 +0200
commite94504c0d57e0cc3f6508c489762d7ffea3242be (patch)
treed38488d1cd055d2ba3b81a75a1cf4ad317057777 /content
parent476423b2ec5479efd3fbe5a83689dfad6622036a (diff)
downloadnetsurf-e94504c0d57e0cc3f6508c489762d7ffea3242be.tar.gz
netsurf-e94504c0d57e0cc3f6508c489762d7ffea3242be.tar.bz2
Move port for kolibrios ahead.
Look at diff from master and reconcile.
Diffstat (limited to 'content')
-rw-r--r--content/fetch.c24
-rw-r--r--content/fetchers/Makefile1
2 files changed, 21 insertions, 4 deletions
diff --git a/content/fetch.c b/content/fetch.c
index 37b28106b..598ac8dd7 100644
--- a/content/fetch.c
+++ b/content/fetch.c
@@ -54,16 +54,27 @@
#include "content/fetchers.h"
#include "content/fetchers/resource.h"
#include "content/fetchers/about.h"
-#if defined(_TARGET_IS_KOLIBRIOS)
-#include "content/fetchers/http_kolibri.h"
-#else
+#ifdef WITH_CURL
#include "content/fetchers/curl.h"
#endif
+#if defined(_TARGET_IS_KOLIBRIOS)
+#include "content/fetchers/httplib_kolibri.h"
+#endif
#include "content/fetchers/data.h"
#include "content/fetchers/file.h"
#include "javascript/fetcher.h"
#include "content/urldb.h"
+/* Define this to turn on verbose fetch logging */
+#define DEBUG_FETCH_VERBOSE
+
+/** Verbose fetcher logging */
+#ifdef DEBUG_FETCH_VERBOSE
+#define FETCH_LOG(x...) debug_board_printf(x); debug_board_printf("\n");
+#else
+#define FETCH_LOG(x...)
+#endif
+
/** The maximum number of fetchers that can be added */
#define MAX_FETCHERS 10
@@ -296,7 +307,12 @@ nserror fetcher_init(void)
return ret;
}
#endif
-
+#ifdef _TARGET_IS_KOLIBRIOS
+ ret = fetch_httplib_kolibri_register();
+ if (ret != NSERROR_OK) {
+ return ret;
+ }
+#endif
ret = fetch_data_register();
if (ret != NSERROR_OK) {
return ret;
diff --git a/content/fetchers/Makefile b/content/fetchers/Makefile
index 9c8479320..5d9b7ad00 100644
--- a/content/fetchers/Makefile
+++ b/content/fetchers/Makefile
@@ -3,6 +3,7 @@
S_FETCHERS_YES := data.c file.c about.c resource.c
S_FETCHERS_NO :=
S_FETCHERS_$(NETSURF_USE_CURL) += curl.c
+S_FETCHERS_$(NETSURF_USE_KOLIBRI_HTTPLIB) += httplib_kolibri.c
S_FETCHERS := $(addprefix content/fetchers/,$(S_FETCHERS_YES))