| @@ -1,272 +1,274 @@ | | | @@ -1,272 +1,274 @@ |
1 | # $NetBSD: mozilla-common.mk,v 1.1 2020/07/30 08:09:28 nia Exp $ | | 1 | # $NetBSD: mozilla-common.mk,v 1.1.2.1 2020/12/10 19:54:33 bsiegert Exp $ |
2 | # | | 2 | # |
3 | # common Makefile fragment for mozilla packages based on gecko 2.0. | | 3 | # common Makefile fragment for mozilla packages based on gecko 2.0. |
4 | # | | 4 | # |
5 | # used by www/firefox/Makefile | | 5 | # used by www/firefox/Makefile |
6 | | | 6 | |
7 | .include "../../mk/bsd.prefs.mk" | | 7 | .include "../../mk/bsd.prefs.mk" |
8 | | | 8 | |
9 | # Python 2.7 and Python 3.6 or later are required simultaneously. | | 9 | # Python 2.7 and Python 3.6 or later are required simultaneously. |
10 | PYTHON_VERSIONS_ACCEPTED= 27 | | 10 | PYTHON_VERSIONS_ACCEPTED= 27 |
11 | PYTHON_FOR_BUILD_ONLY= tool | | 11 | PYTHON_FOR_BUILD_ONLY= tool |
12 | .if !empty(PYTHON_VERSION_DEFAULT:M3[6789]) | | 12 | .if !empty(PYTHON_VERSION_DEFAULT:M3[6789]) |
13 | TOOL_DEPENDS+= python${PYTHON_VERSION_DEFAULT}-[0-9]*:../../lang/python${PYTHON_VERSION_DEFAULT} | | 13 | TOOL_DEPENDS+= python${PYTHON_VERSION_DEFAULT}-[0-9]*:../../lang/python${PYTHON_VERSION_DEFAULT} |
14 | ALL_ENV+= PYTHON3=${LOCALBASE}/bin/python${PYTHON_VERSION_DEFAULT:S/3/3./} | | 14 | ALL_ENV+= PYTHON3=${LOCALBASE}/bin/python${PYTHON_VERSION_DEFAULT:S/3/3./} |
15 | .else | | 15 | .else |
16 | TOOL_DEPENDS+= python37-[0-9]*:../../lang/python37 | | 16 | TOOL_DEPENDS+= python37-[0-9]*:../../lang/python37 |
17 | ALL_ENV+= PYTHON3=${LOCALBASE}/bin/python3.7 | | 17 | ALL_ENV+= PYTHON3=${LOCALBASE}/bin/python3.7 |
18 | .endif | | 18 | .endif |
19 | | | 19 | |
20 | HAS_CONFIGURE= yes | | 20 | HAS_CONFIGURE= yes |
21 | CONFIGURE_ARGS+= --prefix=${PREFIX} | | 21 | CONFIGURE_ARGS+= --prefix=${PREFIX} |
22 | USE_TOOLS+= pkg-config perl gmake autoconf213 unzip zip | | 22 | USE_TOOLS+= pkg-config perl gmake autoconf213 unzip zip |
23 | UNLIMIT_RESOURCES+= datasize virtualsize | | 23 | UNLIMIT_RESOURCES+= datasize virtualsize |
24 | | | 24 | |
25 | # firefox needs a compiler that supports gnu++14 and gnu++17. | | 25 | # firefox needs a compiler that supports gnu++14 and gnu++17. |
26 | # However, passing --std=gnu++17 (from wrappers, as a result of | | 26 | # However, passing --std=gnu++17 (from wrappers, as a result of |
27 | # USE_LANGUAGES), results in problems for some Rust modules (as of | | 27 | # USE_LANGUAGES), results in problems for some Rust modules (as of |
28 | # 74.0). Therefore, do not declare the languages that are actually | | 28 | # 74.0). Therefore, do not declare the languages that are actually |
29 | # needed. | | 29 | # needed. |
30 | # \todo In pkgsrc infrastructure, separate the concept of needing a | | 30 | # \todo In pkgsrc infrastructure, separate the concept of needing a |
31 | # compiler that can implement a standard, and the concept of forcibly | | 31 | # compiler that can implement a standard, and the concept of forcibly |
32 | # adding a --std flag. (The build system of a package should be | | 32 | # adding a --std flag. (The build system of a package should be |
33 | # setting the --std flag that is needed, rather than relying on the | | 33 | # setting the --std flag that is needed, rather than relying on the |
34 | # defaults of a particular compiler version.) | | 34 | # defaults of a particular compiler version.) |
35 | # NB: Even when building firefox with PKGSRC_COMPILER=gcc, the package | | 35 | # NB: Even when building firefox with PKGSRC_COMPILER=gcc, the package |
36 | # will depend on and use clang, doing so outside the normal compiler | | 36 | # will depend on and use clang, doing so outside the normal compiler |
37 | # selection framework. | | 37 | # selection framework. |
38 | USE_LANGUAGES+= c99 c++ | | 38 | USE_LANGUAGES+= c99 c++ |
39 | | | 39 | |
40 | TOOL_DEPENDS+= cbindgen>=0.14.2:../../devel/cbindgen | | 40 | TOOL_DEPENDS+= cbindgen>=0.14.2:../../devel/cbindgen |
41 | .if ${MACHINE_ARCH} == "sparc64" | | 41 | .if ${MACHINE_ARCH} == "sparc64" |
42 | CONFIGURE_ARGS+= --disable-nodejs | | 42 | CONFIGURE_ARGS+= --disable-nodejs |
43 | .else | | 43 | .else |
44 | TOOL_DEPENDS+= nodejs-[0-9]*:../../lang/nodejs | | 44 | TOOL_DEPENDS+= nodejs-[0-9]*:../../lang/nodejs |
45 | .endif | | 45 | .endif |
46 | | | 46 | |
47 | # Depend on Python3 sqlite3 module. | | 47 | # Depend on Python3 sqlite3 module. |
48 | .if !empty(PYTHON_VERSION_DEFAULT:M3[6789]) | | 48 | .if !empty(PYTHON_VERSION_DEFAULT:M3[6789]) |
49 | BUILD_DEPENDS+= py${PYTHON_VERSION_DEFAULT}-sqlite3-[0-9]*:../../databases/py-sqlite3 | | 49 | BUILD_DEPENDS+= py${PYTHON_VERSION_DEFAULT}-sqlite3-[0-9]*:../../databases/py-sqlite3 |
| | | 50 | BUILD_DEPENDS+= py${PYTHON_VERSION_DEFAULT}-expat-[0-9]*:../../textproc/py-expat |
50 | .else | | 51 | .else |
51 | BUILD_DEPENDS+= py37-sqlite3-[0-9]*:../../databases/py-sqlite3 | | 52 | BUILD_DEPENDS+= py37-sqlite3-[0-9]*:../../databases/py-sqlite3 |
| | | 53 | BUILD_DEPENDS+= py37-expat-[0-9]*:../../textproc/py-expat |
52 | .endif | | 54 | .endif |
53 | .if ${MACHINE_ARCH} == "i386" || ${MACHINE_ARCH} == "x86_64" | | 55 | .if ${MACHINE_ARCH} == "i386" || ${MACHINE_ARCH} == "x86_64" |
54 | TOOL_DEPENDS+= nasm>=2.14:../../devel/nasm | | 56 | TOOL_DEPENDS+= nasm>=2.14:../../devel/nasm |
55 | TOOL_DEPENDS+= yasm>=1.1:../../devel/yasm | | 57 | TOOL_DEPENDS+= yasm>=1.1:../../devel/yasm |
56 | .endif | | 58 | .endif |
57 | | | 59 | |
58 | # For rustc/cargo detection | | 60 | # For rustc/cargo detection |
59 | CONFIGURE_ARGS+= --target=${MACHINE_GNU_PLATFORM} | | 61 | CONFIGURE_ARGS+= --target=${MACHINE_GNU_PLATFORM} |
60 | CONFIGURE_ARGS+= --host=${MACHINE_GNU_PLATFORM} | | 62 | CONFIGURE_ARGS+= --host=${MACHINE_GNU_PLATFORM} |
61 | | | 63 | |
62 | CONFIGURE_ENV+= BINDGEN_CFLAGS="-isystem${PREFIX}/include/nspr \ | | 64 | CONFIGURE_ENV+= BINDGEN_CFLAGS="-isystem${PREFIX}/include/nspr \ |
63 | -isystem${X11BASE}/include/pixman-1" | | 65 | -isystem${X11BASE}/include/pixman-1" |
64 | | | 66 | |
65 | test: | | 67 | test: |
66 | cd ${WRKSRC}/${OBJDIR}/dist/bin && \ | | 68 | cd ${WRKSRC}/${OBJDIR}/dist/bin && \ |
67 | ./run-mozilla.sh ${WRKSRC}/mach check-spidermonkey | | 69 | ./run-mozilla.sh ${WRKSRC}/mach check-spidermonkey |
68 | | | 70 | |
69 | # tar(1) of OpenBSD 5.5 has no --exclude command line option. | | 71 | # tar(1) of OpenBSD 5.5 has no --exclude command line option. |
70 | .if ${OPSYS} == "OpenBSD" | | 72 | .if ${OPSYS} == "OpenBSD" |
71 | TOOLS_PLATFORM.tar= ${TOOLS_PATH.bsdtar} | | 73 | TOOLS_PLATFORM.tar= ${TOOLS_PATH.bsdtar} |
72 | USE_TOOLS+= bsdtar | | 74 | USE_TOOLS+= bsdtar |
73 | .endif | | 75 | .endif |
74 | .if ${MACHINE_ARCH} == "i386" | | 76 | .if ${MACHINE_ARCH} == "i386" |
75 | # Fix for PR pkg/48152. | | 77 | # Fix for PR pkg/48152. |
76 | CXXFLAGS+= -march=i586 | | 78 | CXXFLAGS+= -march=i586 |
77 | # This is required for SSE2 code under i386. | | 79 | # This is required for SSE2 code under i386. |
78 | CXXFLAGS+= -mstackrealign | | 80 | CXXFLAGS+= -mstackrealign |
79 | .endif | | 81 | .endif |
80 | | | 82 | |
81 | CHECK_PORTABILITY_SKIP+= ${MOZILLA_DIR}security/nss/tests/libpkix/libpkix.sh | | 83 | CHECK_PORTABILITY_SKIP+= ${MOZILLA_DIR}security/nss/tests/libpkix/libpkix.sh |
82 | CHECK_PORTABILITY_SKIP+= ${MOZILLA_DIR}security/nss/tests/multinit/multinit.sh | | 84 | CHECK_PORTABILITY_SKIP+= ${MOZILLA_DIR}security/nss/tests/multinit/multinit.sh |
83 | CHECK_PORTABILITY_SKIP+= ${MOZILLA_DIR}js/src/tests/update-test262.sh | | 85 | CHECK_PORTABILITY_SKIP+= ${MOZILLA_DIR}js/src/tests/update-test262.sh |
84 | CHECK_PORTABILITY_SKIP+= ${MOZILLA_DIR}intl/icu/source/configure | | 86 | CHECK_PORTABILITY_SKIP+= ${MOZILLA_DIR}intl/icu/source/configure |
85 | CHECK_PORTABILITY_SKIP+= ${MOZILLA_DIR}browser/components/loop/run-all-loop-tests.sh | | 87 | CHECK_PORTABILITY_SKIP+= ${MOZILLA_DIR}browser/components/loop/run-all-loop-tests.sh |
86 | CHECK_PORTABILITY_SKIP+= ${MOZILLA_DIR}browser/extensions/loop/run-all-loop-tests.sh | | 88 | CHECK_PORTABILITY_SKIP+= ${MOZILLA_DIR}browser/extensions/loop/run-all-loop-tests.sh |
87 | #CHECK_PORTABILITY_SKIP+= ${MOZILLA_DIR}modules/pdfium/update.sh | | 89 | #CHECK_PORTABILITY_SKIP+= ${MOZILLA_DIR}modules/pdfium/update.sh |
88 | | | 90 | |
89 | CONFIGURE_ARGS+= --enable-default-toolkit=cairo-gtk3 | | 91 | CONFIGURE_ARGS+= --enable-default-toolkit=cairo-gtk3 |
90 | CONFIGURE_ARGS+= --enable-release | | 92 | CONFIGURE_ARGS+= --enable-release |
91 | # Disable Rust SIMD option to fix build with lang/rust-1.33.0 | | 93 | # Disable Rust SIMD option to fix build with lang/rust-1.33.0 |
92 | # This should be enabled later again. | | 94 | # This should be enabled later again. |
93 | #CONFIGURE_ARGS+= --enable-rust-simd | | 95 | #CONFIGURE_ARGS+= --enable-rust-simd |
94 | CONFIGURE_ARGS+= --disable-tests | | 96 | CONFIGURE_ARGS+= --disable-tests |
95 | # Mozilla Bug 1432751 | | 97 | # Mozilla Bug 1432751 |
96 | #CONFIGURE_ARGS+= --enable-system-cairo | | 98 | #CONFIGURE_ARGS+= --enable-system-cairo |
97 | CONFIGURE_ARGS+= --enable-system-pixman | | 99 | CONFIGURE_ARGS+= --enable-system-pixman |
98 | # webrtc option requires internal libvpx | | 100 | # webrtc option requires internal libvpx |
99 | #CONFIGURE_ARGS+= --with-system-libvpx | | 101 | #CONFIGURE_ARGS+= --with-system-libvpx |
100 | CONFIGURE_ARGS+= --enable-system-ffi | | 102 | CONFIGURE_ARGS+= --enable-system-ffi |
101 | CONFIGURE_ARGS+= --with-system-icu | | 103 | CONFIGURE_ARGS+= --with-system-icu |
102 | CONFIGURE_ARGS+= --with-system-nss | | 104 | CONFIGURE_ARGS+= --with-system-nss |
103 | CONFIGURE_ARGS+= --with-system-nspr | | 105 | CONFIGURE_ARGS+= --with-system-nspr |
104 | #CONFIGURE_ARGS+= --with-system-jpeg | | 106 | #CONFIGURE_ARGS+= --with-system-jpeg |
105 | CONFIGURE_ARGS+= --with-system-zlib | | 107 | CONFIGURE_ARGS+= --with-system-zlib |
106 | CONFIGURE_ARGS+= --with-system-libevent=${BUILDLINK_PREFIX.libevent} | | 108 | CONFIGURE_ARGS+= --with-system-libevent=${BUILDLINK_PREFIX.libevent} |
107 | CONFIGURE_ARGS+= --disable-crashreporter | | 109 | CONFIGURE_ARGS+= --disable-crashreporter |
108 | CONFIGURE_ARGS+= --disable-necko-wifi | | 110 | CONFIGURE_ARGS+= --disable-necko-wifi |
109 | CONFIGURE_ARGS+= --enable-chrome-format=flat | | 111 | CONFIGURE_ARGS+= --enable-chrome-format=flat |
110 | CONFIGURE_ARGS+= --with-system-webp | | 112 | CONFIGURE_ARGS+= --with-system-webp |
111 | | | 113 | |
112 | #CONFIGURE_ARGS+= --enable-readline | | 114 | #CONFIGURE_ARGS+= --enable-readline |
113 | CONFIGURE_ARGS+= --disable-icf | | 115 | CONFIGURE_ARGS+= --disable-icf |
114 | CONFIGURE_ARGS+= --disable-updater | | 116 | CONFIGURE_ARGS+= --disable-updater |
115 | | | 117 | |
116 | #CONFIGURE_ARGS+= --with-libclang-path=${PREFIX}/lib | | 118 | #CONFIGURE_ARGS+= --with-libclang-path=${PREFIX}/lib |
117 | | | 119 | |
118 | SUBST_CLASSES+= fix-paths | | 120 | SUBST_CLASSES+= fix-paths |
119 | SUBST_STAGE.fix-paths= pre-configure | | 121 | SUBST_STAGE.fix-paths= pre-configure |
120 | SUBST_MESSAGE.fix-paths= Fixing absolute paths. | | 122 | SUBST_MESSAGE.fix-paths= Fixing absolute paths. |
121 | SUBST_FILES.fix-paths+= ${MOZILLA_DIR}xpcom/io/nsAppFileLocationProvider.cpp | | 123 | SUBST_FILES.fix-paths+= ${MOZILLA_DIR}xpcom/io/nsAppFileLocationProvider.cpp |
122 | SUBST_SED.fix-paths+= -e 's,/usr/lib/mozilla/plugins,${PREFIX}/lib/netscape/plugins,g' | | 124 | SUBST_SED.fix-paths+= -e 's,/usr/lib/mozilla/plugins,${PREFIX}/lib/netscape/plugins,g' |
123 | | | 125 | |
124 | CONFIG_GUESS_OVERRIDE+= ${MOZILLA_DIR}build/autoconf/config.guess | | 126 | CONFIG_GUESS_OVERRIDE+= ${MOZILLA_DIR}build/autoconf/config.guess |
125 | CONFIG_GUESS_OVERRIDE+= ${MOZILLA_DIR}js/src/build/autoconf/config.guess | | 127 | CONFIG_GUESS_OVERRIDE+= ${MOZILLA_DIR}js/src/build/autoconf/config.guess |
126 | CONFIG_GUESS_OVERRIDE+= ${MOZILLA_DIR}nsprpub/build/autoconf/config.guess | | 128 | CONFIG_GUESS_OVERRIDE+= ${MOZILLA_DIR}nsprpub/build/autoconf/config.guess |
127 | CONFIG_GUESS_OVERRIDE+= ${MOZILLA_DIR}/js/ctypes/libffi/config.guess | | 129 | CONFIG_GUESS_OVERRIDE+= ${MOZILLA_DIR}/js/ctypes/libffi/config.guess |
128 | CONFIG_SUB_OVERRIDE+= ${MOZILLA_DIR}build/autoconf/config.sub | | 130 | CONFIG_SUB_OVERRIDE+= ${MOZILLA_DIR}build/autoconf/config.sub |
129 | CONFIG_SUB_OVERRIDE+= ${MOZILLA_DIR}js/src/build/autoconf/config.sub | | 131 | CONFIG_SUB_OVERRIDE+= ${MOZILLA_DIR}js/src/build/autoconf/config.sub |
130 | CONFIG_SUB_OVERRIDE+= ${MOZILLA_DIR}nsprpub/build/autoconf/config.sub | | 132 | CONFIG_SUB_OVERRIDE+= ${MOZILLA_DIR}nsprpub/build/autoconf/config.sub |
131 | CONFIG_SUB_OVERRIDE+= ${MOZILLA_DIR}/js/ctypes/libffi/config.sub | | 133 | CONFIG_SUB_OVERRIDE+= ${MOZILLA_DIR}/js/ctypes/libffi/config.sub |
132 | | | 134 | |
133 | CONFIGURE_ENV+= CPP=${CPP:Q} | | 135 | CONFIGURE_ENV+= CPP=${CPP:Q} |
134 | ALL_ENV+= SHELL=${CONFIG_SHELL:Q} | | 136 | ALL_ENV+= SHELL=${CONFIG_SHELL:Q} |
135 | | | 137 | |
136 | # Build outside ${WRKSRC} | | 138 | # Build outside ${WRKSRC} |
137 | # Try to avoid conflict with config/makefiles/xpidl/Makefile.in | | 139 | # Try to avoid conflict with config/makefiles/xpidl/Makefile.in |
138 | OBJDIR= ../build | | 140 | OBJDIR= ../build |
139 | CONFIGURE_DIRS= ${OBJDIR} | | 141 | CONFIGURE_DIRS= ${OBJDIR} |
140 | CONFIGURE_SCRIPT= ${WRKSRC}/configure | | 142 | CONFIGURE_SCRIPT= ${WRKSRC}/configure |
141 | | | 143 | |
142 | PLIST_VARS+= sps vorbis tremor glskia throwwrapper mozglue ffvpx | | 144 | PLIST_VARS+= sps vorbis tremor glskia throwwrapper mozglue ffvpx |
143 | | | 145 | |
144 | .include "../../mk/endian.mk" | | 146 | .include "../../mk/endian.mk" |
145 | .if ${MACHINE_ENDIAN} == "little" | | 147 | .if ${MACHINE_ENDIAN} == "little" |
146 | PLIST.glskia= yes | | 148 | PLIST.glskia= yes |
147 | .endif | | 149 | .endif |
148 | | | 150 | |
149 | .if ${MACHINE_ARCH} == "aarch64" || \ | | 151 | .if ${MACHINE_ARCH} == "aarch64" || \ |
150 | !empty(MACHINE_ARCH:M*arm*) || \ | | 152 | !empty(MACHINE_ARCH:M*arm*) || \ |
151 | ${MACHINE_ARCH} == "i386" || \ | | 153 | ${MACHINE_ARCH} == "i386" || \ |
152 | ${MACHINE_ARCH} == "x86_64" | | 154 | ${MACHINE_ARCH} == "x86_64" |
153 | PLIST.ffvpx= yes # see media/ffvpx/ffvpxcommon.mozbuild | | 155 | PLIST.ffvpx= yes # see media/ffvpx/ffvpxcommon.mozbuild |
154 | .endif | | 156 | .endif |
155 | | | 157 | |
156 | .if ${MACHINE_ARCH} != "sparc64" | | 158 | .if ${MACHINE_ARCH} != "sparc64" |
157 | # For some reasons the configure test for GCC bug 26905 still triggers on | | 159 | # For some reasons the configure test for GCC bug 26905 still triggers on |
158 | # sparc64, which makes mozilla skip the installation of a few wrapper headers. | | 160 | # sparc64, which makes mozilla skip the installation of a few wrapper headers. |
159 | # Other archs end up with one additional file in the SDK headers | | 161 | # Other archs end up with one additional file in the SDK headers |
160 | PLIST.throwwrapper= yes | | 162 | PLIST.throwwrapper= yes |
161 | .endif | | 163 | .endif |
162 | | | 164 | |
163 | .if !empty(MACHINE_PLATFORM:S/i386/x86/:MLinux-*-x86*) | | 165 | .if !empty(MACHINE_PLATFORM:S/i386/x86/:MLinux-*-x86*) |
164 | PLIST.sps= yes | | 166 | PLIST.sps= yes |
165 | .endif | | 167 | .endif |
166 | | | 168 | |
167 | .if !empty(MACHINE_PLATFORM:MLinux-*-arm*) | | 169 | .if !empty(MACHINE_PLATFORM:MLinux-*-arm*) |
168 | PLIST.tremor= yes | | 170 | PLIST.tremor= yes |
169 | .else | | 171 | .else |
170 | PLIST.vorbis= yes | | 172 | PLIST.vorbis= yes |
171 | .endif | | 173 | .endif |
172 | | | 174 | |
173 | # See ${WRKSRC}/mozglue/build/moz.build: libmozglue is built and | | 175 | # See ${WRKSRC}/mozglue/build/moz.build: libmozglue is built and |
174 | # installed as a shared library on these platforms. | | 176 | # installed as a shared library on these platforms. |
175 | .if ${OPSYS} == "Cygwin" || ${OPSYS} == "Darwin" # or Android | | 177 | .if ${OPSYS} == "Cygwin" || ${OPSYS} == "Darwin" # or Android |
176 | PLIST.mozglue= yes | | 178 | PLIST.mozglue= yes |
177 | .endif | | 179 | .endif |
178 | | | 180 | |
179 | # See ${WRKSRC}/security/sandbox/mac/Sandbox.mm: On Darwin, sandboxing | | 181 | # See ${WRKSRC}/security/sandbox/mac/Sandbox.mm: On Darwin, sandboxing |
180 | # support is only available when the toolkit is cairo-cocoa. | | 182 | # support is only available when the toolkit is cairo-cocoa. |
181 | CONFIGURE_ARGS.Darwin+= --disable-sandbox | | 183 | CONFIGURE_ARGS.Darwin+= --disable-sandbox |
182 | | | 184 | |
183 | # See ${WRKSRC}/configure.in: It tries to use MacOS X 10.6 SDK by | | 185 | # See ${WRKSRC}/configure.in: It tries to use MacOS X 10.6 SDK by |
184 | # default, which is not always possible. | | 186 | # default, which is not always possible. |
185 | .if !empty(MACHINE_PLATFORM:MDarwin-8.*-*) | | 187 | .if !empty(MACHINE_PLATFORM:MDarwin-8.*-*) |
186 | CONFIGURE_ARGS+= --enable-macos-target=10.4 | | 188 | CONFIGURE_ARGS+= --enable-macos-target=10.4 |
187 | .elif !empty(MACHINE_PLATFORM:MDarwin-9.*-*) | | 189 | .elif !empty(MACHINE_PLATFORM:MDarwin-9.*-*) |
188 | CONFIGURE_ARGS+= --enable-macos-target=10.5 | | 190 | CONFIGURE_ARGS+= --enable-macos-target=10.5 |
189 | .endif | | 191 | .endif |
190 | | | 192 | |
191 | # Makefiles sometimes call "rm -f" without more arguments. Kludge around ... | | 193 | # Makefiles sometimes call "rm -f" without more arguments. Kludge around ... |
192 | .PHONY: create-rm-wrapper | | 194 | .PHONY: create-rm-wrapper |
193 | pre-configure: create-rm-wrapper | | 195 | pre-configure: create-rm-wrapper |
194 | create-rm-wrapper: | | 196 | create-rm-wrapper: |
195 | printf '#!/bin/sh\n[ "$$*" = "-f" ] && exit 0\nexec /bin/rm $$@\n' > \ | | 197 | printf '#!/bin/sh\n[ "$$*" = "-f" ] && exit 0\nexec /bin/rm $$@\n' > \ |
196 | ${WRAPPER_DIR}/bin/rm | | 198 | ${WRAPPER_DIR}/bin/rm |
197 | chmod +x ${WRAPPER_DIR}/bin/rm | | 199 | chmod +x ${WRAPPER_DIR}/bin/rm |
198 | | | 200 | |
199 | # The configure test for __thread succeeds, but later we end up with: | | 201 | # The configure test for __thread succeeds, but later we end up with: |
200 | # dist/bin/libxul.so: undefined reference to `__tls_get_addr' | | 202 | # dist/bin/libxul.so: undefined reference to `__tls_get_addr' |
201 | CONFIGURE_ENV.NetBSD+= ac_cv_thread_keyword=no | | 203 | CONFIGURE_ENV.NetBSD+= ac_cv_thread_keyword=no |
202 | # In unspecified case, clock_gettime(CLOCK_MONOTONIC, ...) fails. | | 204 | # In unspecified case, clock_gettime(CLOCK_MONOTONIC, ...) fails. |
203 | CONFIGURE_ENV.NetBSD+= ac_cv_clock_monotonic= | | 205 | CONFIGURE_ENV.NetBSD+= ac_cv_clock_monotonic= |
204 | | | 206 | |
205 | .if ${OPSYS} == "OpenBSD" | | 207 | .if ${OPSYS} == "OpenBSD" |
206 | PLIST_SUBST+= DLL_SUFFIX=".so.1.0" | | 208 | PLIST_SUBST+= DLL_SUFFIX=".so.1.0" |
207 | .elif ${OPSYS} == "Darwin" | | 209 | .elif ${OPSYS} == "Darwin" |
208 | PLIST_SUBST+= DLL_SUFFIX=".dylib" | | 210 | PLIST_SUBST+= DLL_SUFFIX=".dylib" |
209 | .else | | 211 | .else |
210 | PLIST_SUBST+= DLL_SUFFIX=".so" | | 212 | PLIST_SUBST+= DLL_SUFFIX=".so" |
211 | .endif | | 213 | .endif |
212 | | | 214 | |
213 | # PR pkg/55456 | | 215 | # PR pkg/55456 |
214 | .if ${OPSYS} == "NetBSD" && ${MACHINE_ARCH} == "i386" | | 216 | .if ${OPSYS} == "NetBSD" && ${MACHINE_ARCH} == "i386" |
215 | .include "../../devel/libatomic/buildlink3.mk" | | 217 | .include "../../devel/libatomic/buildlink3.mk" |
216 | CONFIGURE_ENV.NetBSD+= ac_cv_needs_atomic=yes | | 218 | CONFIGURE_ENV.NetBSD+= ac_cv_needs_atomic=yes |
217 | .endif | | 219 | .endif |
218 | BUILDLINK_API_DEPENDS.libevent+= libevent>=1.1 | | 220 | BUILDLINK_API_DEPENDS.libevent+= libevent>=1.1 |
219 | .include "../../devel/libevent/buildlink3.mk" | | 221 | .include "../../devel/libevent/buildlink3.mk" |
220 | .include "../../devel/libffi/buildlink3.mk" | | 222 | .include "../../devel/libffi/buildlink3.mk" |
221 | BUILDLINK_API_DEPENDS.nspr+= nspr>=4.25 | | 223 | BUILDLINK_API_DEPENDS.nspr+= nspr>=4.25 |
222 | .include "../../devel/nspr/buildlink3.mk" | | 224 | .include "../../devel/nspr/buildlink3.mk" |
223 | .include "../../textproc/icu/buildlink3.mk" | | 225 | .include "../../textproc/icu/buildlink3.mk" |
224 | BUILDLINK_API_DEPENDS.nss+= nss>=3.53 | | 226 | BUILDLINK_API_DEPENDS.nss+= nss>=3.53 |
225 | .include "../../devel/nss/buildlink3.mk" | | 227 | .include "../../devel/nss/buildlink3.mk" |
226 | .include "../../devel/zlib/buildlink3.mk" | | 228 | .include "../../devel/zlib/buildlink3.mk" |
227 | #.include "../../mk/jpeg.buildlink3.mk" | | 229 | #.include "../../mk/jpeg.buildlink3.mk" |
228 | .include "../../graphics/MesaLib/buildlink3.mk" | | 230 | .include "../../graphics/MesaLib/buildlink3.mk" |
229 | #BUILDLINK_API_DEPENDS.cairo+= cairo>=1.10.2nb4 | | 231 | #BUILDLINK_API_DEPENDS.cairo+= cairo>=1.10.2nb4 |
230 | #.include "../../graphics/cairo/buildlink3.mk" | | 232 | #.include "../../graphics/cairo/buildlink3.mk" |
231 | BUILDLINK_API_DEPENDS.libwebp+= libwebp>=1.0.2 | | 233 | BUILDLINK_API_DEPENDS.libwebp+= libwebp>=1.0.2 |
232 | .include "../../graphics/libwebp/buildlink3.mk" | | 234 | .include "../../graphics/libwebp/buildlink3.mk" |
233 | # Force the use of clang from pkgsrc, regardless of the setting of | | 235 | # Force the use of clang from pkgsrc, regardless of the setting of |
234 | # PKGSRC_COMPILER. | | 236 | # PKGSRC_COMPILER. |
235 | # \todo This breaks the use of ccache, which should be fixed, probably | | 237 | # \todo This breaks the use of ccache, which should be fixed, probably |
236 | # by adding support for this kind of forcing to pkgsrc infrastructure. | | 238 | # by adding support for this kind of forcing to pkgsrc infrastructure. |
237 | PKG_CC= ${PREFIX}/bin/clang | | 239 | PKG_CC= ${PREFIX}/bin/clang |
238 | PKG_CXX= ${PREFIX}/bin/clang++ | | 240 | PKG_CXX= ${PREFIX}/bin/clang++ |
239 | BUILDLINK_DEPMETHOD.clang= build | | 241 | BUILDLINK_DEPMETHOD.clang= build |
240 | .include "../../lang/clang/buildlink3.mk" | | 242 | .include "../../lang/clang/buildlink3.mk" |
241 | .if !empty(MACHINE_PLATFORM:MNetBSD-8.*-*) | | 243 | .if !empty(MACHINE_PLATFORM:MNetBSD-8.*-*) |
242 | BUILDLINK_DEPMETHOD.gcc8= full | | 244 | BUILDLINK_DEPMETHOD.gcc8= full |
243 | .include "../../lang/gcc8/buildlink3.mk" | | 245 | .include "../../lang/gcc8/buildlink3.mk" |
244 | CWRAPPERS_PREPEND.cxx+= \ | | 246 | CWRAPPERS_PREPEND.cxx+= \ |
245 | -L${BUILDLINK_PREFIX.gcc8}/gcc8/lib \ | | 247 | -L${BUILDLINK_PREFIX.gcc8}/gcc8/lib \ |
246 | ${COMPILER_RPATH_FLAG}${BUILDLINK_PREFIX.gcc8}/gcc8/lib \ | | 248 | ${COMPILER_RPATH_FLAG}${BUILDLINK_PREFIX.gcc8}/gcc8/lib \ |
247 | -stdlib++-isystem \ | | 249 | -stdlib++-isystem \ |
248 | ${BUILDLINK_PREFIX.gcc8}/gcc8/include/c++ \ | | 250 | ${BUILDLINK_PREFIX.gcc8}/gcc8/include/c++ \ |
249 | -stdlib++-isystem \ | | 251 | -stdlib++-isystem \ |
250 | ${BUILDLINK_PREFIX.gcc8}/gcc8/include/c++/${MACHINE_GNU_PLATFORM} \ | | 252 | ${BUILDLINK_PREFIX.gcc8}/gcc8/include/c++/${MACHINE_GNU_PLATFORM} \ |
251 | -stdlib++-isystem \ | | 253 | -stdlib++-isystem \ |
252 | ${BUILDLINK_PREFIX.gcc8}/gcc8/include/c++/backward | | 254 | ${BUILDLINK_PREFIX.gcc8}/gcc8/include/c++/backward |
253 | .endif | | 255 | .endif |
254 | RUST_REQ= 1.41.0 | | 256 | RUST_REQ= 1.41.0 |
255 | .include "../../lang/rust/rust.mk" | | 257 | .include "../../lang/rust/rust.mk" |
256 | # webrtc option requires internal libvpx | | 258 | # webrtc option requires internal libvpx |
257 | #BUILDLINK_API_DEPENDS.libvpx+= libvpx>=1.3.0 | | 259 | #BUILDLINK_API_DEPENDS.libvpx+= libvpx>=1.3.0 |
258 | #.include "../../multimedia/libvpx/buildlink3.mk" | | 260 | #.include "../../multimedia/libvpx/buildlink3.mk" |
259 | .include "../../net/libIDL/buildlink3.mk" | | 261 | .include "../../net/libIDL/buildlink3.mk" |
260 | # textproc/hunspell 1.3 is too old | | 262 | # textproc/hunspell 1.3 is too old |
261 | #.include "../../textproc/hunspell/buildlink3.mk" | | 263 | #.include "../../textproc/hunspell/buildlink3.mk" |
262 | .include "../../multimedia/ffmpeg4/buildlink3.mk" | | 264 | .include "../../multimedia/ffmpeg4/buildlink3.mk" |
263 | .include "../../x11/libXt/buildlink3.mk" | | 265 | .include "../../x11/libXt/buildlink3.mk" |
264 | BUILDLINK_API_DEPENDS.pixman+= pixman>=0.25.2 | | 266 | BUILDLINK_API_DEPENDS.pixman+= pixman>=0.25.2 |
265 | .include "../../x11/pixman/buildlink3.mk" | | 267 | .include "../../x11/pixman/buildlink3.mk" |
266 | .include "../../x11/gtk2/buildlink3.mk" | | 268 | .include "../../x11/gtk2/buildlink3.mk" |
267 | .include "../../x11/gtk3/buildlink3.mk" | | 269 | .include "../../x11/gtk3/buildlink3.mk" |
268 | PLIST_VARS+= wayland | | 270 | PLIST_VARS+= wayland |
269 | .if ${PKG_BUILD_OPTIONS.gtk3:Mwayland} | | 271 | .if ${PKG_BUILD_OPTIONS.gtk3:Mwayland} |
270 | PLIST.wayland= yes | | 272 | PLIST.wayland= yes |
271 | .endif | | 273 | .endif |
272 | .include "../../lang/python/pyversion.mk" | | 274 | .include "../../lang/python/pyversion.mk" |