View | Details | Raw Unified | Return to bug 223597 | Differences between
and this patch

Collapse All | Expand All

(-)www/palemoon/Makefile (+69 lines)
Line 0 Link Here
1
# Created by: Zhihao Yuan <lichray@gmail.com>
2
# $FreeBSD$
3
4
PORTNAME=	palemoon
5
DISTVERSION=	27.6.0
6
DISTVERSIONSUFFIX=_Release
7
CATEGORIES=	www ipv6
8
9
MAINTAINER=	gecko@FreeBSD.org
10
COMMENT=	Open Source Goanna-based web browser
11
12
BUILD_DEPENDS=	nspr>=4.13.1:devel/nspr \
13
		nss>=3.29.5:security/nss \
14
		libevent>=2.0.21_2:devel/libevent \
15
		harfbuzz>=1.4.1:print/harfbuzz \
16
		graphite2>=1.3.8:graphics/graphite2 \
17
		png>=1.6.28:graphics/png \
18
		libvorbis>=1.3.5,3:audio/libvorbis \
19
		libvpx>=1.5.0:multimedia/libvpx \
20
		sqlite3>=3.17.0:databases/sqlite3 \
21
		${PYTHON_PKGNAMEPREFIX}sqlite3>0:databases/py-sqlite3 \
22
		v4l_compat>0:multimedia/v4l_compat \
23
		autoconf-2.13:devel/autoconf213 \
24
		yasm:devel/yasm \
25
		zip:archivers/zip
26
#		soundtouch>=1.9.0:audio/soundtouch \
27
28
LIB_DEPENDS=	libv4l2.so:multimedia/libv4l
29
30
USE_GITHUB=	yes
31
GH_ACCOUNT=	MoonchildProductions
32
GH_PROJECT=	Pale-Moon
33
34
USE_GECKO=	gecko
35
MOZ_PKGCONFIG_FILES=	# empty
36
USE_MOZILLA=	-soundtouch
37
38
USE_GL=		gl
39
40
PM_ICON=	${PORTNAME}.png
41
PM_ICON_SRC=	${PREFIX}/lib/${PORTNAME}/browser/icons/mozicon128.png
42
PM_DESKTOP=	${WRKSRC}/browser/branding/official/${PORTNAME}.desktop
43
MOZ_OPTIONS=	--enable-application=browser \
44
		--enable-official-branding \
45
		--enable-devtools \
46
		--enable-jemalloc \
47
		--enable-jemalloc-lib
48
LDFLAGS+=	-Wl,-rpath,${PREFIX}/lib/${PORTNAME}
49
50
OPTIONS_DEFAULT=	BUNDLED_CAIRO GTK2
51
52
.include "${.CURDIR}/../../www/firefox/Makefile.options"
53
54
WRKSRC:=	${WRKDIR}/${GH_PROJECT}-${DISTVERSIONFULL}
55
56
post-patch:
57
	@${REINPLACE_CMD} -e 's|%%LOCALBASE%%|${LOCALBASE}|g' \
58
		${WRKSRC}/browser/app/nsBrowserApp.cpp
59
60
pre-configure:
61
	(cd ${WRKSRC} && ${LOCALBASE}/bin/autoconf-2.13)
62
	(cd ${WRKSRC}/js/src/ && ${LOCALBASE}/bin/autoconf-2.13)
63
64
post-install:
65
	${MKDIR} ${STAGEDIR}${PREFIX}/share/pixmaps
66
	${INSTALL_DATA} ${PM_DESKTOP} ${STAGEDIR}${PREFIX}/share/applications/
67
	${LN} -sf ${PM_ICON_SRC} ${STAGEDIR}${PREFIX}/share/pixmaps/${PM_ICON}
68
69
.include <bsd.port.mk>
(-)www/palemoon/distinfo (+3 lines)
Line 0 Link Here
1
TIMESTAMP = 1510282722
2
SHA256 (MoonchildProductions-Pale-Moon-27.6.0_Release_GH0.tar.gz) = 91aab9b78b9d771d2c292532ddb06b9d43883fa6f62d5a8457e68cd1f1241ee9
3
SIZE (MoonchildProductions-Pale-Moon-27.6.0_Release_GH0.tar.gz) = 179629800
(-)www/palemoon/files/patch-browser-app-nsBrowserApp.cpp (+12 lines)
Line 0 Link Here
1
--- browser/app/nsBrowserApp.cpp.orig	2017-11-05 12:13:54 UTC
2
+++ browser/app/nsBrowserApp.cpp
3
@@ -409,6 +409,9 @@ int main(int argc, char* argv[])
4
 #endif
5
   uint64_t start = TimeStamp_Now();
6
 
7
+  setenv("MOZ_GMP_PATH", "%%LOCALBASE%%/lib/browser_plugins/symlinks/gecko", 0);
8
+  setenv("MOZ_PLUGIN_PATH", "%%LOCALBASE%%/lib/browser_plugins/symlinks/gecko", 0);
9
+
10
 #ifdef XP_MACOSX
11
   TriggerQuirks();
12
 #endif
(-)www/palemoon/files/patch-browser_installer_Makefile.in (+13 lines)
Line 0 Link Here
1
--- browser/installer/Makefile.in.orig	2017-11-05 12:13:54 UTC
2
+++ browser/installer/Makefile.in
3
@@ -108,10 +108,6 @@ MOZ_PKG_MAC_ICON=branding/disk.icns
4
 MOZ_PKG_MAC_EXTRA=--symlink '/Applications:/ '
5
 endif
6
 
7
-ifndef LIBXUL_SDK
8
-INSTALL_SDK = 1
9
-endif
10
-
11
 include $(topsrcdir)/toolkit/mozapps/installer/signing.mk
12
 include $(topsrcdir)/toolkit/mozapps/installer/packager.mk
13
 
(-)www/palemoon/files/patch-bug847568 (+216 lines)
Line 0 Link Here
1
# Allow building against system-wide graphite2/harfbuzz.
2
3
--- config/Makefile.in.orig	2017-11-05 12:13:54 UTC
4
+++ config/Makefile.in
5
@@ -78,6 +78,8 @@ export:: $(export-preqs)
6
 		-DMOZ_NATIVE_LIBVPX=$(MOZ_NATIVE_LIBVPX) \
7
 		-DMOZ_NATIVE_LIBWEBP=$(MOZ_NATIVE_LIBWEBP) \
8
 		-DMOZ_NATIVE_ICU=$(MOZ_NATIVE_ICU) \
9
+		-DMOZ_NATIVE_GRAPHITE2=$(MOZ_NATIVE_GRAPHITE2) \
10
+		-DMOZ_NATIVE_HARFBUZZ=$(MOZ_NATIVE_HARFBUZZ) \
11
 		$(srcdir)/system-headers | $(PERL) $(topsrcdir)/nsprpub/config/make-system-wrappers.pl system_wrappers
12
 	$(INSTALL) system_wrappers $(DIST)
13
 
14
--- config/system-headers.orig	2017-11-05 12:13:54 UTC
15
+++ config/system-headers
16
@@ -1359,3 +1359,11 @@ unicode/utypes.h
17
 #endif
18
 libutil.h
19
 unwind.h
20
+#if MOZ_NATIVE_GRAPHITE2==1
21
+graphite2/Font.h
22
+graphite2/Segment.h
23
+#endif
24
+#if MOZ_NATIVE_HARFBUZZ==1
25
+harfbuzz/hb-ot.h
26
+harfbuzz/hb.h
27
+#endif
28
--- configure.in.orig	2017-11-05 12:13:54 UTC
29
+++ configure.in
30
@@ -7746,6 +7746,49 @@ if test "$USE_FC_FREETYPE"; then
31
 fi
32
 
33
 dnl ========================================================
34
+dnl Check for harfbuzz
35
+dnl ========================================================
36
+
37
+MOZ_ARG_WITH_BOOL(system-harfbuzz,
38
+[  --with-system-harfbuzz  Use system harfbuzz (located with pkgconfig)],
39
+MOZ_NATIVE_HARFBUZZ=1,
40
+MOZ_NATIVE_HARFBUZZ=)
41
+
42
+if test -n "$MOZ_NATIVE_HARFBUZZ"; then
43
+    PKG_CHECK_MODULES(MOZ_HARFBUZZ, harfbuzz >= 0.9.34)
44
+fi
45
+
46
+AC_SUBST(MOZ_NATIVE_HARFBUZZ)
47
+
48
+dnl ========================================================
49
+dnl Check for graphite2
50
+dnl ========================================================
51
+
52
+MOZ_ARG_WITH_BOOL(system-graphite2,
53
+[  --with-system-graphite2 Use system graphite2 (located with pkgconfig)],
54
+MOZ_NATIVE_GRAPHITE2=1,
55
+MOZ_NATIVE_GRAPHITE2=)
56
+
57
+if test -n "$MOZ_NATIVE_GRAPHITE2"; then
58
+    PKG_CHECK_MODULES(MOZ_GRAPHITE2, graphite2)
59
+
60
+    dnl graphite2.pc has bogus version, check manually
61
+    AC_TRY_COMPILE([ #include <graphite2/Font.h>
62
+                     #define GR2_VERSION_REQUIRE(major,minor,bugfix)  \
63
+                             ( GR2_VERSION_MAJOR * 10000 + GR2_VERSION_MINOR \
64
+                               * 100 + GR2_VERSION_BUGFIX >= \
65
+                               (major) * 10000 + (minor) * 100 + (bugfix) )
66
+                   ], [
67
+                     #if !GR2_VERSION_REQUIRE(1,2,4)
68
+                     #error "Insufficient graphite2 version."
69
+                     #endif
70
+                   ], [],
71
+                   [AC_MSG_ERROR([--with-system-graphite2 requested but no working libgraphite2 found])])
72
+fi
73
+
74
+AC_SUBST(MOZ_NATIVE_GRAPHITE2)
75
+
76
+dnl ========================================================
77
 dnl Check for pixman and cairo
78
 dnl ========================================================
79
 
80
--- dom/base/moz.build.orig	2017-11-05 12:13:54 UTC
81
+++ dom/base/moz.build
82
@@ -366,6 +366,9 @@ if CONFIG['INTEL_ARCHITECTURE']:
83
     SOURCES += ['nsTextFragmentSSE2.cpp']
84
     SOURCES['nsTextFragmentSSE2.cpp'].flags += CONFIG['SSE2_FLAGS']
85
 
86
+if CONFIG['MOZ_NATIVE_HARFBUZZ']:
87
+    SOURCES['nsContentUtils.cpp'].flags += CONFIG['MOZ_HARFBUZZ_CFLAGS']
88
+
89
 EXTRA_COMPONENTS += [
90
     'ConsoleAPI.manifest',
91
     'ConsoleAPIStorage.js',
92
--- gfx/graphite2/moz-gr-update.sh.orig	2017-11-05 12:13:54 UTC
93
+++ gfx/graphite2/moz-gr-update.sh
94
@@ -37,6 +37,9 @@ echo "See" $0 "for update procedure." >>
95
 #find gfx/graphite2/ -name "*.cpp" -exec perl -p -i -e "s/<cstdio>/<stdio.h>/;s/Windows.h/windows.h/;" {} \;
96
 #find gfx/graphite2/ -name "*.h" -exec perl -p -i -e "s/<cstdio>/<stdio.h>/;s/Windows.h/windows.h/;" {} \;
97
 
98
+perl -p -i -e "s/[0-9]+\,[0-9]+\,[0-9]+/$RELEASE/ and tr/./,/ \
99
+  if /GR2_VERSION_REQUIRE/" configure.in
100
+
101
 # summarize what's been touched
102
 echo Updated to $RELEASE.
103
 echo Here is what changed in the gfx/graphite2 directory:
104
--- gfx/harfbuzz/README-mozilla.orig	2017-11-05 12:13:54 UTC
105
+++ gfx/harfbuzz/README-mozilla
106
@@ -19,3 +19,8 @@ the mozilla tree.
107
 
108
 If the collection of source files changes, manual updates to moz.build may be
109
 needed, as we don't use the upstream makefiles.
110
+
111
+The in-tree copy may be omitted during build by --with-system-harfbuzz.
112
+Make sure to keep pkg-config version check within configure.in in sync
113
+with checkout version or increment latest tag by one if it's not based
114
+on upstream release.
115
--- gfx/moz.build.orig	2017-11-05 12:13:54 UTC
116
+++ gfx/moz.build
117
@@ -7,6 +7,12 @@
118
 if CONFIG['MOZ_TREE_CAIRO']:
119
     DIRS += ['cairo']
120
 
121
+if not CONFIG['MOZ_NATIVE_GRAPHITE2']:
122
+    DIRS += ['graphite2/src' ]
123
+
124
+if not CONFIG['MOZ_NATIVE_HARFBUZZ']:
125
+    DIRS += ['harfbuzz/src']
126
+
127
 DIRS += [
128
     '2d',
129
     'ycbcr',
130
@@ -15,8 +21,6 @@ DIRS += [
131
     'qcms',
132
     'gl',
133
     'layers',
134
-    'graphite2/src',
135
-    'harfbuzz/src',
136
     'ots/src',
137
     'thebes',
138
     'ipc',
139
--- gfx/skia/generate_mozbuild.py.orig	2017-11-05 12:13:54 UTC
140
+++ gfx/skia/generate_mozbuild.py
141
@@ -157,6 +157,9 @@ if CONFIG['CLANG_CXX']:
142
             '-Wno-unused-private-field',
143
         ]
144
 
145
+if CONFIG['MOZ_NATIVE_HARFBUZZ']:
146
+    CXXFLAGS += CONFIG['MOZ_HARFBUZZ_CFLAGS']
147
+
148
 if CONFIG['MOZ_WIDGET_TOOLKIT'] in ('gtk2', 'gtk3', 'android', 'gonk', 'qt'):
149
     CXXFLAGS += CONFIG['MOZ_CAIRO_CFLAGS']
150
     CXXFLAGS += CONFIG['CAIRO_FT_CFLAGS']
151
--- gfx/skia/moz.build.orig	2017-11-05 12:13:54 UTC
152
+++ gfx/skia/moz.build
153
@@ -987,6 +987,9 @@ if CONFIG['CLANG_CXX']:
154
         '-Wno-unused-private-field',
155
     ]
156
 
157
+if CONFIG['MOZ_NATIVE_HARFBUZZ']:
158
+    CXXFLAGS += CONFIG['MOZ_HARFBUZZ_CFLAGS']
159
+
160
 if CONFIG['MOZ_WIDGET_TOOLKIT'] in ('gtk2', 'gtk3', 'android', 'gonk', 'qt'):
161
     CXXFLAGS += CONFIG['MOZ_CAIRO_CFLAGS']
162
     CXXFLAGS += CONFIG['CAIRO_FT_CFLAGS']
163
--- gfx/thebes/moz.build.orig	2017-11-05 12:13:54 UTC
164
+++ gfx/thebes/moz.build
165
@@ -298,7 +298,13 @@ if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'andr
166
 if CONFIG['MOZ_WIDGET_TOOLKIT'] in ('gtk2', 'gtk3', 'qt'):
167
     CXXFLAGS += CONFIG['MOZ_PANGO_CFLAGS']
168
 
169
-DEFINES['GRAPHITE2_STATIC'] = True
170
+if CONFIG['MOZ_NATIVE_HARFBUZZ']:
171
+    CXXFLAGS += CONFIG['MOZ_HARFBUZZ_CFLAGS']
172
+
173
+if CONFIG['MOZ_NATIVE_GRAPHITE2']:
174
+    CXXFLAGS += CONFIG['MOZ_GRAPHITE2_CFLAGS']
175
+else:
176
+    DEFINES['GRAPHITE2_STATIC'] = True
177
 
178
 if CONFIG['GKMEDIAS_SHARED_LIBRARY']:
179
     DEFINES['OTS_DLL'] = True
180
--- intl/unicharutil/util/moz.build.orig	2017-11-05 12:13:54 UTC
181
+++ intl/unicharutil/util/moz.build
182
@@ -38,5 +38,8 @@ if CONFIG['_MSC_VER']:
183
 if CONFIG['ENABLE_INTL_API']:
184
     CXXFLAGS += CONFIG['MOZ_ICU_CFLAGS']
185
 
186
+if CONFIG['MOZ_NATIVE_HARFBUZZ']:
187
+    CXXFLAGS += CONFIG['MOZ_HARFBUZZ_CFLAGS']
188
+
189
 if CONFIG['GNU_CXX']:
190
     FAIL_ON_WARNINGS = True
191
--- netwerk/dns/moz.build.orig	2017-11-05 12:13:54 UTC
192
+++ netwerk/dns/moz.build
193
@@ -68,5 +68,8 @@ LOCAL_INCLUDES += [
194
     '/netwerk/base',
195
 ]
196
 
197
+if CONFIG['MOZ_NATIVE_HARFBUZZ']:
198
+    CXXFLAGS += CONFIG['MOZ_HARFBUZZ_CFLAGS']
199
+
200
 if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'gonk' and CONFIG['ANDROID_VERSION'] > '19':
201
     CXXFLAGS += ['-I%s/bionic/libc/dns/include' % CONFIG['ANDROID_SOURCE']]
202
--- toolkit/library/moz.build.orig	2017-11-05 12:13:54 UTC
203
+++ toolkit/library/moz.build
204
@@ -230,6 +230,12 @@ if CONFIG['MOZ_NATIVE_LIBVPX']:
205
 if not CONFIG['MOZ_TREE_PIXMAN']:
206
     OS_LIBS += CONFIG['MOZ_PIXMAN_LIBS']
207
 
208
+if CONFIG['MOZ_NATIVE_GRAPHITE2']:
209
+    OS_LIBS += CONFIG['MOZ_GRAPHITE2_LIBS']
210
+
211
+if CONFIG['MOZ_NATIVE_HARFBUZZ']:
212
+    OS_LIBS += CONFIG['MOZ_HARFBUZZ_LIBS']
213
+
214
 if CONFIG['MOZ_ALSA']:
215
     OS_LIBS += CONFIG['MOZ_ALSA_LIBS']
216
 
(-)www/palemoon/files/patch-bug991253 (+17 lines)
Line 0 Link Here
1
--- extensions/spellcheck/hunspell/glue/mozHunspell.cpp.orig	2017-11-05 12:13:54 UTC
2
+++ extensions/spellcheck/hunspell/glue/mozHunspell.cpp
3
@@ -400,6 +400,14 @@ mozHunspell::LoadDictionaryList(bool aNo
4
     }
5
   }
6
 
7
+  // load system hunspell dictionaries
8
+  nsCOMPtr<nsIFile> hunDir;
9
+  NS_NewNativeLocalFile(NS_LITERAL_CSTRING("%%LOCALBASE%%/share/hunspell"),
10
+                        true, getter_AddRefs(hunDir));
11
+  if (hunDir) {
12
+      LoadDictionariesFromDir(hunDir);
13
+  }
14
+
15
   // find dictionaries from extensions requiring restart
16
   nsCOMPtr<nsISimpleEnumerator> dictDirs;
17
   rv = dirSvc->Get(DICTIONARY_SEARCH_DIRECTORY_LIST,
(-)www/palemoon/files/patch-config-baseconfig.mk (+17 lines)
Line 0 Link Here
1
--- config/baseconfig.mk.orig	2017-11-05 12:13:54 UTC
2
+++ config/baseconfig.mk
3
@@ -2,10 +2,10 @@
4
 # directly in python/mozbuild/mozbuild/base.py for gmake validation.
5
 # We thus use INCLUDED_AUTOCONF_MK to enable/disable some parts depending
6
 # whether a normal build is happening or whether the check is running.
7
-includedir := $(includedir)/$(MOZ_APP_NAME)-$(MOZ_APP_VERSION)
8
-idldir = $(datadir)/idl/$(MOZ_APP_NAME)-$(MOZ_APP_VERSION)
9
-installdir = $(libdir)/$(MOZ_APP_NAME)-$(MOZ_APP_VERSION)
10
-sdkdir = $(libdir)/$(MOZ_APP_NAME)-devel-$(MOZ_APP_VERSION)
11
+includedir := $(includedir)/%%MOZILLA%%
12
+idldir = $(datadir)/idl/%%MOZILLA%%
13
+installdir = $(libdir)/%%MOZILLA%%
14
+sdkdir = $(libdir)/%%MOZILLA%%
15
 ifndef TOP_DIST
16
 TOP_DIST = dist
17
 endif
(-)www/palemoon/files/patch-media_libnestegg_src_align.h (+21 lines)
Line 0 Link Here
1
--- media/libnestegg/src/align.h.orig	2017-11-05 12:13:54 UTC
2
+++ media/libnestegg/src/align.h
3
@@ -15,14 +15,16 @@
4
 #ifndef _LIBP_ALIGN_H_
5
 #define _LIBP_ALIGN_H_
6
 
7
-#ifdef _MSC_VER
8
+#include <stddef.h>
9
+
10
+#if defined(_MSC_VER)
11
 
12
 /*
13
  * MSVC defines max_align_t as a double.
14
  */
15
 typedef double max_align_t;
16
 
17
-#else
18
+#elif !defined(_GCC_MAX_ALIGN_T)
19
 
20
 /*
21
  *	a type with the most strict alignment requirements
(-)www/palemoon/files/patch-xpcom_io_nsLocalFileUnix.cpp (+23 lines)
Line 0 Link Here
1
--- xpcom/io/nsLocalFileUnix.cpp.orig	2017-11-05 12:13:54 UTC
2
+++ xpcom/io/nsLocalFileUnix.cpp
3
@@ -13,9 +13,6 @@
4
 
5
 #include <sys/types.h>
6
 #include <sys/stat.h>
7
-#if !defined(XP_MACOSX)
8
-#include <sys/sysmacros.h> // No longer implicitly included in later glibc
9
-#endif
10
 #include <unistd.h>
11
 #include <fcntl.h>
12
 #include <errno.h>
13
@@ -31,6 +28,10 @@
14
 #define USE_LINUX_QUOTACTL
15
 #include <sys/mount.h>
16
 #include <sys/quota.h>
17
+#include <sys/sysmacros.h>
18
+#ifndef BLOCK_SIZE
19
+#define BLOCK_SIZE 1024 /* kernel block size */
20
+#endif
21
 #endif
22
 
23
 #include "xpcom-private.h"
(-)www/palemoon/pkg-descr (+15 lines)
Line 0 Link Here
1
Pale Moon offers you a browsing experience in a browser completely built
2
from its own, independently developed source that has been forked off
3
from Firefox/Mozilla code a number of years ago, with carefully selected
4
features and optimizations to improve the browser's stability and user
5
experience, while offering full customization and a growing collection
6
of extensions and themes to make the browser truly your own.
7
8
Main features:
9
10
 o Support for many Firefox extensions
11
 o Support for a growing number of Pale Moon exclusive extensions
12
 o Secure: Additional security features and security-aware development
13
 o Extensive and growing support for HTML5 and CSS3
14
15
WWW: https://www.palemoon.org/
(-)www/palemoon/pkg-message (+18 lines)
Line 0 Link Here
1
======================================================================
2
3
Any bug reports should be addressed to the maintainers at:
4
	gecko@FreeBSD.org
5
You may also Cc: freebsd-ports@FreeBSD.org. Please do not send
6
bug reports to any other addresses.
7
8
Please include the following information with any bug report:
9
* Output from 'uname -a'.
10
* Output from 'ident /usr/ports/www/palemoon/Makefile'
11
* Where/when did the problem occur: configuring, building, or
12
  running palemoon
13
* How can you reproduce the problem?
14
15
Thank you for your help in testing and reporting bugs, and we hope you
16
enjoy using Firefox.
17
The Maintainers (gecko@)
18
======================================================================

Return to bug 223597