summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobin H. Johnson <robbat2@gentoo.org>2015-08-08 13:49:04 -0700
committerRobin H. Johnson <robbat2@gentoo.org>2015-08-08 17:38:18 -0700
commit56bd759df1d0c750a065b8c845e93d5dfa6b549d (patch)
tree3f91093cdb475e565ae857f1c5a7fd339e2d781e /www-client/netsurf/files
downloadgentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.gz
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.bz2
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.zip
proj/gentoo: Initial commit
This commit represents a new era for Gentoo: Storing the gentoo-x86 tree in Git, as converted from CVS. This commit is the start of the NEW history. Any historical data is intended to be grafted onto this point. Creation process: 1. Take final CVS checkout snapshot 2. Remove ALL ChangeLog* files 3. Transform all Manifests to thin 4. Remove empty Manifests 5. Convert all stale $Header$/$Id$ CVS keywords to non-expanded Git $Id$ 5.1. Do not touch files with -kb/-ko keyword flags. Signed-off-by: Robin H. Johnson <robbat2@gentoo.org> X-Thanks: Alec Warner <antarus@gentoo.org> - did the GSoC 2006 migration tests X-Thanks: Robin H. Johnson <robbat2@gentoo.org> - infra guy, herding this project X-Thanks: Nguyen Thai Ngoc Duy <pclouds@gentoo.org> - Former Gentoo developer, wrote Git features for the migration X-Thanks: Brian Harring <ferringb@gentoo.org> - wrote much python to improve cvs2svn X-Thanks: Rich Freeman <rich0@gentoo.org> - validation scripts X-Thanks: Patrick Lauer <patrick@gentoo.org> - Gentoo dev, running new 2014 work in migration X-Thanks: Michał Górny <mgorny@gentoo.org> - scripts, QA, nagging X-Thanks: All of other Gentoo developers - many ideas and lots of paint on the bikeshed
Diffstat (limited to 'www-client/netsurf/files')
-rw-r--r--www-client/netsurf/files/netsurf-2.9-buildsystem.patch13
-rw-r--r--www-client/netsurf/files/netsurf-2.9-conditionally-include-image-headers.patch63
-rw-r--r--www-client/netsurf/files/netsurf-2.9-includes.patch10
-rw-r--r--www-client/netsurf/files/netsurf-3.0-CFLAGS.patch77
-rw-r--r--www-client/netsurf/files/netsurf-3.0-framebuffer-pkgconfig.patch29
-rw-r--r--www-client/netsurf/files/netsurf-3.2-CFLAGS.patch77
-rw-r--r--www-client/netsurf/files/netsurf-3.2-conditionally-include-image-headers.patch67
-rw-r--r--www-client/netsurf/files/netsurf-3.2-glibc2.20.patch30
-rw-r--r--www-client/netsurf/files/netsurf-3.3-CFLAGS.patch85
9 files changed, 451 insertions, 0 deletions
diff --git a/www-client/netsurf/files/netsurf-2.9-buildsystem.patch b/www-client/netsurf/files/netsurf-2.9-buildsystem.patch
new file mode 100644
index 00000000000..14c0070cf59
--- /dev/null
+++ b/www-client/netsurf/files/netsurf-2.9-buildsystem.patch
@@ -0,0 +1,13 @@
+--- netsurf-2.9/framebuffer/Makefile.target
++++ netsurf-2.9/framebuffer/Makefile.target
+@@ -39,6 +39,10 @@
+ $(eval $(call pkg_config_find_and_add,ROSPRITE,librosprite,Sprite))
+ $(eval $(call pkg_config_find_and_add,BMP,libnsbmp,BMP))
+ $(eval $(call pkg_config_find_and_add,GIF,libnsgif,GIF))
++$(eval $(call pkg_config_find_and_add,NSSVG,libsvgtiny,NSSVG))
++$(eval $(call pkg_config_find_and_add,RSVG,librsvg-2.0,RSVG))
++$(eval $(call pkg_config_find_and_add,WEBP,libwebp,WEBP))
++$(eval $(call pkg_config_find_and_add,VIDEO,gstreamer-0.10,VIDEO))
+
+ CFLAGS += -std=c99 -g -I. -Dsmall $(WARNFLAGS) \
+ -D_BSD_SOURCE \
diff --git a/www-client/netsurf/files/netsurf-2.9-conditionally-include-image-headers.patch b/www-client/netsurf/files/netsurf-2.9-conditionally-include-image-headers.patch
new file mode 100644
index 00000000000..6520c7608a6
--- /dev/null
+++ b/www-client/netsurf/files/netsurf-2.9-conditionally-include-image-headers.patch
@@ -0,0 +1,63 @@
+From 7abd1c708d894a67617e60c2f85d6db355a713bb Mon Sep 17 00:00:00 2001
+From: James Le Cuirot <chewi@aura-online.co.uk>
+Date: Sat, 18 Aug 2012 16:10:23 +0100
+Subject: [PATCH] Conditionally include image headers to allow building
+ without some dependencies.
+
+---
+ image/image.c | 32 +++++++++++++++++++++++++++++---
+ 1 files changed, 29 insertions(+), 3 deletions(-)
+
+diff --git a/image/image.c b/image/image.c
+index becf221..70b981b 100644
+--- a/image/image.c
++++ b/image/image.c
+@@ -27,16 +27,42 @@
+ #include "desktop/plotters.h"
+ #include "image/bitmap.h"
+
++#ifdef WITH_BMP
+ #include "image/bmp.h"
+-#include "image/gif.h"
+ #include "image/ico.h"
++#endif
++
++#ifdef WITH_GIF
++#include "image/gif.h"
++#endif
++
++#ifdef WITH_JPEG
+ #include "image/jpeg.h"
++#endif
++
++#ifdef WITH_MNG
+ #include "image/mng.h"
+-#include "image/nssprite.h"
++#endif
++
++#ifdef WITH_PNG
+ #include "image/png.h"
+-#include "image/rsvg.h"
++#endif
++
++#ifdef WITH_NSSPRITE
++#include "image/nssprite.h"
++#endif
++
++#ifdef WITH_NS_SVG
+ #include "image/svg.h"
++#endif
++
++#ifdef WITH_RSVG
++#include "image/rsvg.h"
++#endif
++
++#ifdef WITH_WEBP
+ #include "image/webp.h"
++#endif
+
+ #include "image/image.h"
+
+--
+1.7.8.6
+
diff --git a/www-client/netsurf/files/netsurf-2.9-includes.patch b/www-client/netsurf/files/netsurf-2.9-includes.patch
new file mode 100644
index 00000000000..ca1a7c95fff
--- /dev/null
+++ b/www-client/netsurf/files/netsurf-2.9-includes.patch
@@ -0,0 +1,10 @@
+--- netsurf-2.9/framebuffer/font_internal.c
++++ netsurf-2.9/framebuffer/font_internal.c
+@@ -18,6 +18,7 @@
+ */
+
+ #include <inttypes.h>
++#include <string.h>
+
+ #include <assert.h>
+ #include "css/css.h"
diff --git a/www-client/netsurf/files/netsurf-3.0-CFLAGS.patch b/www-client/netsurf/files/netsurf-3.0-CFLAGS.patch
new file mode 100644
index 00000000000..065148ba15d
--- /dev/null
+++ b/www-client/netsurf/files/netsurf-3.0-CFLAGS.patch
@@ -0,0 +1,77 @@
+--- netsurf-3.0/Makefile.defaults
++++ netsurf-3.0/Makefile.defaults
+@@ -93,7 +93,6 @@
+ NETSURF_USE_LIBICONV_PLUG := YES
+
+ # Initial CFLAGS. Optimisation level etc. tend to be target specific.
+-CFLAGS :=
+
+ # Default installation/execution prefix
+ PREFIX ?= /usr/local
+--- netsurf-3.0/framebuffer/Makefile.defaults
++++ netsurf-3.0/framebuffer/Makefile.defaults
+@@ -3,7 +3,6 @@
+ # ----------------------------------------------------------------------------
+
+ # Optimisation levels
+- CFLAGS += -O2
+
+ # Framebuffer default surface provider.
+ # Valid values are: x, sdl, linux, vnc, able,
+--- netsurf-3.0/framebuffer/Makefile.target
++++ netsurf-3.0/framebuffer/Makefile.target
+@@ -47,12 +47,12 @@
+ $(eval $(call pkg_config_find_and_add_enabled,MOZJS,mozjs185,JavaScript))
+ $(eval $(call pkg_config_find_and_add_enabled,JS,mozilla-js,JavaScript))
+
+-CFLAGS += -std=c99 -g -Dsmall $(WARNFLAGS) \
++CFLAGS += -std=c99 -Dsmall $(WARNFLAGS) \
+ -D_BSD_SOURCE \
+ -D_XOPEN_SOURCE=600 \
+ -D_POSIX_C_SOURCE=200112L \
+ $(shell $(PKG_CONFIG) --cflags libnsfb libhubbub libcss openssl) \
+- $(shell xml2-config --cflags)
++ $(shell ${PKG_CONFIG} libxml-2.0 --cflags)
+
+ LDFLAGS += -lm -Wl,--whole-archive $(shell $(PKG_CONFIG) --libs libnsfb) -Wl,--no-whole-archive
+
+--- netsurf-3.0/gtk/Makefile.defaults
++++ netsurf-3.0/gtk/Makefile.defaults
+@@ -31,4 +31,3 @@
+ NETSURF_GTK_MAJOR := 2
+
+ # Optimisation levels
+- CFLAGS += -O2
+--- netsurf-3.0/gtk/Makefile.target
++++ netsurf-3.0/gtk/Makefile.target
+@@ -51,7 +51,7 @@
+ -D_POSIX_C_SOURCE=200112L \
+ -D_NETBSD_SOURCE \
+ -DGTK_RESPATH=\"$(NETSURF_GTK_RESOURCES)\" \
+- $(WARNFLAGS) -g
++ $(WARNFLAGS)
+
+ # non optional pkg-configed libs
+ $(eval $(call pkg_config_find_and_add,libcss,CSS))
+--- netsurf-3.0/test/Makefile
++++ netsurf-3.0/test/Makefile
+@@ -1,8 +1,8 @@
+-CFLAGS := -std=c99 -g -O0 -D_BSD_SOURCE -D_POSIX_C_SOURCE -I.. \
++CFLAGS := -std=c99 -D_BSD_SOURCE -D_POSIX_C_SOURCE -I.. \
+ $(shell pkg-config --cflags libcurl)
+ LDFLAGS := $(shell pkg-config --libs libcurl) -lz
+
+-llcache_CFLAGS := $(shell pkg-config --cflags libparserutils libwapcaplet libdom) -O2
++llcache_CFLAGS := $(shell pkg-config --cflags libparserutils libwapcaplet libdom)
+ llcache_LDFLAGS := $(shell pkg-config --libs libparserutils libwapcaplet libdom)
+
+ llcache_SRCS := content/fetch.c content/fetchers/curl.c \
+@@ -19,7 +19,7 @@
+ utils/filename.c utils/nsurl.c utils/corestrings.c \
+ test/urldbtest.c
+
+-urldbtest_CFLAGS := $(shell pkg-config --cflags libwapcaplet libdom) -O2
++urldbtest_CFLAGS := $(shell pkg-config --cflags libwapcaplet libdom)
+ urldbtest_LDFLAGS := $(shell pkg-config --libs libwapcaplet libdom)
+
+ nsurl_SRCS := utils/log.c utils/nsurl.c test/nsurl.c
diff --git a/www-client/netsurf/files/netsurf-3.0-framebuffer-pkgconfig.patch b/www-client/netsurf/files/netsurf-3.0-framebuffer-pkgconfig.patch
new file mode 100644
index 00000000000..50c9f8b8a83
--- /dev/null
+++ b/www-client/netsurf/files/netsurf-3.0-framebuffer-pkgconfig.patch
@@ -0,0 +1,29 @@
+--- netsurf-3.0/framebuffer/Makefile.target
++++ netsurf-3.0/framebuffer/Makefile.target
+@@ -13,12 +13,16 @@
+
+ # define additional CFLAGS and LDFLAGS requirements for pkg-configed libs here
+ NETSURF_FEATURE_RSVG_CFLAGS := -DWITH_RSVG
++NETSURF_FEATURE_NSSVG_CFLAGS := -DWITH_NS_SVG
+ NETSURF_FEATURE_ROSPRITE_CFLAGS := -DWITH_NSSPRITE
+ NETSURF_FEATURE_HUBBUB_CFLAGS := -DWITH_HUBBUB
+ NETSURF_FEATURE_BMP_CFLAGS := -DWITH_BMP
+ NETSURF_FEATURE_GIF_CFLAGS := -DWITH_GIF
++NETSURF_FEATURE_PNG_CFLAGS := -DWITH_PNG
++NETSURF_FEATURE_WEBP_CFLAGS := -DWITH_WEBP
+ NETSURF_FEATURE_JS_CFLAGS := -DWITH_JS -DJS_HAS_FILE_OBJECT=0
+ NETSURF_FEATURE_MOZJS_CFLAGS := -DWITH_MOZJS -DJS_HAS_FILE_OBJECT=0
++NETSURF_FEATURE_VIDEO_CFLAGS := -DWITH_VIDEO
+
+ CFLAGS += -Dnsframebuffer
+
+@@ -41,6 +45,9 @@
+ $(eval $(call pkg_config_find_and_add_enabled,ROSPRITE,librosprite,Sprite))
+ $(eval $(call pkg_config_find_and_add_enabled,BMP,libnsbmp,BMP))
+ $(eval $(call pkg_config_find_and_add_enabled,GIF,libnsgif,GIF))
++$(eval $(call pkg_config_find_and_add_enabled,RSVG,librsvg-2.0,SVG))
++$(eval $(call pkg_config_find_and_add_enabled,NSSVG,libsvgtiny,SVG))
++$(eval $(call feature_enabled,WEBP,-DWITH_WEBP,-lwebp,WebP (libwebp)))
+ $(eval $(call pkg_config_find_and_add_enabled,MOZJS,mozjs185,JavaScript))
+ $(eval $(call pkg_config_find_and_add_enabled,JS,mozilla-js,JavaScript))
+
diff --git a/www-client/netsurf/files/netsurf-3.2-CFLAGS.patch b/www-client/netsurf/files/netsurf-3.2-CFLAGS.patch
new file mode 100644
index 00000000000..3d5b8668f53
--- /dev/null
+++ b/www-client/netsurf/files/netsurf-3.2-CFLAGS.patch
@@ -0,0 +1,77 @@
+--- netsurf-3.2/Makefile.defaults
++++ netsurf-3.2/Makefile.defaults
+@@ -91,9 +91,6 @@
+ # Valid options: YES, NO
+ NETSURF_FS_BACKING_STORE := NO
+
+-# Initial CFLAGS. Optimisation level etc. tend to be target specific.
+-CFLAGS :=
+-
+ # Default installation/execution prefix
+ PREFIX ?= /usr/local
+
+--- netsurf-3.2/framebuffer/Makefile.defaults
++++ netsurf-3.2/framebuffer/Makefile.defaults
+@@ -2,9 +2,6 @@
+ # Framebuffer-target-specific options
+ # ----------------------------------------------------------------------------
+
+-# Optimisation levels
+-CFLAGS += -O2
+-
+ # Framebuffer default surface provider.
+ # Valid values are: x, sdl, linux, vnc, able,
+ NETSURF_FB_FRONTEND := sdl
+--- netsurf-3.2/framebuffer/Makefile.target
++++ netsurf-3.2/framebuffer/Makefile.target
+@@ -42,7 +42,7 @@
+ $(eval $(call pkg_config_find_and_add_enabled,MOZJS,mozjs185,JavaScript))
+ $(eval $(call pkg_config_find_and_add_enabled,JS,mozilla-js,JavaScript))
+
+-CFLAGS += -std=c99 -g -Dsmall $(WARNFLAGS) \
++CFLAGS += -std=c99 -Dsmall $(WARNFLAGS) \
+ -D_BSD_SOURCE \
+ -D_XOPEN_SOURCE=600 \
+ -D_POSIX_C_SOURCE=200112L \
+--- netsurf-3.2/gtk/Makefile.defaults
++++ netsurf-3.2/gtk/Makefile.defaults
+@@ -38,6 +38,3 @@
+
+ # Set default GTK version to build for (2 or 3)
+ NETSURF_GTK_MAJOR := 2
+-
+-# Optimisation levels
+-CFLAGS += -O2
+--- netsurf-3.2/gtk/Makefile.target
++++ netsurf-3.2/gtk/Makefile.target
+@@ -51,7 +51,7 @@
+ -D_POSIX_C_SOURCE=200809L \
+ -D_NETBSD_SOURCE \
+ -DGTK_RESPATH=\"$(NETSURF_GTK_RESOURCES)\" \
+- $(WARNFLAGS) -g
++ $(WARNFLAGS)
+
+ # non optional pkg-configed libs
+ $(eval $(call pkg_config_find_and_add,libcss,CSS))
+--- netsurf-3.2/test/Makefile
++++ netsurf-3.2/test/Makefile
+@@ -1,8 +1,8 @@
+-CFLAGS := -std=c99 -g -O0 -D_BSD_SOURCE -D_POSIX_C_SOURCE -I.. \
++CFLAGS := -std=c99 -D_BSD_SOURCE -D_POSIX_C_SOURCE -I.. \
+ $(shell pkg-config --cflags libcurl)
+ LDFLAGS := $(shell pkg-config --libs libcurl) -lz
+
+-llcache_CFLAGS := $(shell pkg-config --cflags libparserutils libwapcaplet libdom) -O2
++llcache_CFLAGS := $(shell pkg-config --cflags libparserutils libwapcaplet libdom)
+ llcache_LDFLAGS := $(shell pkg-config --libs libparserutils libwapcaplet libdom)
+
+ llcache_SRCS := content/fetch.c content/fetchers/curl.c \
+@@ -19,7 +19,7 @@
+ utils/filename.c utils/nsurl.c utils/corestrings.c \
+ test/urldbtest.c
+
+-urldbtest_CFLAGS := $(shell pkg-config --cflags libwapcaplet libdom) -O2
++urldbtest_CFLAGS := $(shell pkg-config --cflags libwapcaplet libdom)
+ urldbtest_LDFLAGS := $(shell pkg-config --libs libwapcaplet libdom)
+
+ nsurl_SRCS := utils/corestrings.c utils/log.c utils/nsurl.c utils/idna.c utils/utf8proc.c test/nsurl.c
diff --git a/www-client/netsurf/files/netsurf-3.2-conditionally-include-image-headers.patch b/www-client/netsurf/files/netsurf-3.2-conditionally-include-image-headers.patch
new file mode 100644
index 00000000000..9c73c233eff
--- /dev/null
+++ b/www-client/netsurf/files/netsurf-3.2-conditionally-include-image-headers.patch
@@ -0,0 +1,67 @@
+--- netsurf-3.2/image/image.c
++++ netsurf-3.2/image/image.c
+@@ -28,15 +28,42 @@
+ #include "content/content.h"
+ #include "image/bitmap.h"
+
++#ifdef WITH_BMP
+ #include "image/bmp.h"
+-#include "image/gif.h"
+ #include "image/ico.h"
++#endif
++
++#ifdef WITH_GIF
++#include "image/gif.h"
++#endif
++
++#ifdef WITH_JPEG
+ #include "image/jpeg.h"
+-#include "image/nssprite.h"
++#endif
++
++#ifdef WITH_MNG
++#include "image/mng.h"
++#endif
++
++#ifdef WITH_PNG
+ #include "image/png.h"
+-#include "image/rsvg.h"
++#endif
++
++#ifdef WITH_NSSPRITE
++#include "image/nssprite.h"
++#endif
++
++#ifdef WITH_NS_SVG
+ #include "image/svg.h"
++#endif
++
++#ifdef WITH_RSVG
++#include "image/rsvg.h"
++#endif
++
++#ifdef WITH_WEBP
+ #include "image/webp.h"
++#endif
+
+ #include "image/image.h"
+
+@@ -73,7 +100,18 @@
+ return error;
+ #endif
+
++#ifdef WITH_MNG
++ error = nsmng_init();
++ if (error != NSERROR_OK)
++ return error;
++
++ error = nsjpng_init();
++ if (error != NSERROR_OK)
++ return error;
++#endif
++
+ #ifdef WITH_PNG
++ /* Prefer libpng over libmng for pngs by registering later */
+ error = nspng_init();
+ if (error != NSERROR_OK)
+ return error;
diff --git a/www-client/netsurf/files/netsurf-3.2-glibc2.20.patch b/www-client/netsurf/files/netsurf-3.2-glibc2.20.patch
new file mode 100644
index 00000000000..e63ec70540a
--- /dev/null
+++ b/www-client/netsurf/files/netsurf-3.2-glibc2.20.patch
@@ -0,0 +1,30 @@
+--- netsurf-3.2/framebuffer/Makefile.target
++++ netsurf-3.2/framebuffer/Makefile.target
+@@ -43,7 +43,7 @@
+ $(eval $(call pkg_config_find_and_add_enabled,JS,mozilla-js,JavaScript))
+
+ CFLAGS += -std=c99 -Dsmall $(WARNFLAGS) \
+- -D_BSD_SOURCE \
++ -D_DEFAULT_SOURCE \
+ -D_XOPEN_SOURCE=600 \
+ -D_POSIX_C_SOURCE=200112L \
+ $(shell $(PKG_CONFIG) --cflags libnsfb libhubbub libcss openssl)
+--- netsurf-3.2/gtk/Makefile.target
++++ netsurf-3.2/gtk/Makefile.target
+@@ -46,7 +46,7 @@
+
+ GTKCFLAGS := -std=c99 -Dgtk -Dnsgtk \
+ $(GTKDEPFLAGS) \
+- -D_BSD_SOURCE \
++ -D_DEFAULT_SOURCE \
+ -D_XOPEN_SOURCE=600 \
+ -D_POSIX_C_SOURCE=200809L \
+ -D_NETBSD_SOURCE \
+--- netsurf-3.2/test/Makefile
++++ netsurf-3.2/test/Makefile
+@@ -1,4 +1,4 @@
+-CFLAGS := -std=c99 -D_BSD_SOURCE -D_POSIX_C_SOURCE -I.. \
++CFLAGS := -std=c99 -D_DEFAULT_SOURCE -D_POSIX_C_SOURCE -I.. \
+ $(shell pkg-config --cflags libcurl)
+ LDFLAGS := $(shell pkg-config --libs libcurl) -lz
+
diff --git a/www-client/netsurf/files/netsurf-3.3-CFLAGS.patch b/www-client/netsurf/files/netsurf-3.3-CFLAGS.patch
new file mode 100644
index 00000000000..3f1c21645d2
--- /dev/null
+++ b/www-client/netsurf/files/netsurf-3.3-CFLAGS.patch
@@ -0,0 +1,85 @@
+--- netsurf-3.3/Makefile.defaults
++++ netsurf-3.3/Makefile.defaults
+@@ -91,12 +91,6 @@
+ # Valid options: YES, NO
+ NETSURF_FS_BACKING_STORE := NO
+
+-# Initial CFLAGS. Optimisation level etc. tend to be target specific.
+-CFLAGS :=
+-
+-# Initial CXXFLAGS. Optimisation level etc. tend to be target specific.
+-CXXFLAGS :=
+-
+ # Default installation/execution prefix
+ PREFIX ?= /usr/local
+
+--- netsurf-3.3/framebuffer/Makefile.defaults
++++ netsurf-3.3/framebuffer/Makefile.defaults
+@@ -2,9 +2,6 @@
+ # Framebuffer-target-specific options
+ # ----------------------------------------------------------------------------
+
+-# Optimisation levels
+-CFLAGS += -O2
+-
+ # Framebuffer default surface provider.
+ # Valid values are: x, sdl, linux, vnc, able,
+ NETSURF_FB_FRONTEND := sdl
+--- netsurf-3.3/framebuffer/Makefile.target
++++ netsurf-3.3/framebuffer/Makefile.target
+@@ -42,8 +42,8 @@
+ $(eval $(call pkg_config_find_and_add_enabled,MOZJS,mozjs185,JavaScript))
+ $(eval $(call pkg_config_find_and_add_enabled,JS,mozilla-js,JavaScript))
+
+-CFLAGS += -std=c99 -g -Dsmall \
+- -D_BSD_SOURCE \
++CFLAGS += -std=c99 -Dsmall \
++ -D_DEFAULT_SOURCE \
+ -D_XOPEN_SOURCE=600 \
+ -D_POSIX_C_SOURCE=200112L \
+ $(shell $(PKG_CONFIG) --cflags libnsfb libhubbub libcss openssl)
+--- netsurf-3.3/gtk/Makefile.defaults
++++ netsurf-3.3/gtk/Makefile.defaults
+@@ -26,6 +26,3 @@
+
+ # Set default GTK version to build for (2 or 3)
+ NETSURF_GTK_MAJOR ?= 2
+-
+-# Optimisation levels
+-CFLAGS += -O2
+--- netsurf-3.3/gtk/Makefile.target
++++ netsurf-3.3/gtk/Makefile.target
+@@ -46,9 +46,9 @@
+ # libsexy currently means we cannot enable this
+ # -DGDK_DISABLE_DEPRECATED
+
+-GTKCFLAGS := -std=c99 -Dgtk -Dnsgtk -g \
++GTKCFLAGS := -std=c99 -Dgtk -Dnsgtk \
+ $(GTKDEPFLAGS) \
+- -D_BSD_SOURCE \
++ -D_DEFAULT_SOURCE \
+ -D_XOPEN_SOURCE=600 \
+ -D_POSIX_C_SOURCE=200809L \
+ -D_NETBSD_SOURCE \
+--- netsurf-3.3/test/Makefile
++++ netsurf-3.3/test/Makefile
+@@ -1,8 +1,8 @@
+-CFLAGS := -std=c99 -g -O0 -D_BSD_SOURCE -D_POSIX_C_SOURCE -I.. \
++CFLAGS := -std=c99 -D_DEFAULT_SOURCE -D_POSIX_C_SOURCE -I.. \
+ $(shell pkg-config --cflags libcurl)
+ LDFLAGS := $(shell pkg-config --libs libcurl) -lz
+
+-llcache_CFLAGS := $(shell pkg-config --cflags libparserutils libwapcaplet libdom) -O2
++llcache_CFLAGS := $(shell pkg-config --cflags libparserutils libwapcaplet libdom)
+ llcache_LDFLAGS := $(shell pkg-config --libs libparserutils libwapcaplet libdom)
+
+ llcache_SRCS := content/fetch.c content/fetchers/curl.c \
+@@ -19,7 +19,7 @@
+ utils/filename.c utils/nsurl.c utils/corestrings.c \
+ test/urldbtest.c
+
+-urldbtest_CFLAGS := $(shell pkg-config --cflags libwapcaplet libdom) -O2
++urldbtest_CFLAGS := $(shell pkg-config --cflags libwapcaplet libdom)
+ urldbtest_LDFLAGS := $(shell pkg-config --libs libwapcaplet libdom)
+
+ nsurl_SRCS := utils/corestrings.c utils/log.c utils/nsurl.c utils/idna.c utils/utf8proc.c test/nsurl.c