Move firefox78's mozilla-common.mk to mail/thunderbird in preparation for removing firefox78.diff -r1.282 -r1.283 pkgsrc/mail/thunderbird/Makefile
(nia)
@@ -1,14 +1,14 @@ | @@ -1,14 +1,14 @@ | |||
1 | # $NetBSD: Makefile,v 1.282 2022/07/02 16:53:25 ryoon Exp $ | 1 | # $NetBSD: Makefile,v 1.283 2022/08/04 15:07:14 nia Exp $ | |
2 | 2 | |||
3 | DISTNAME= thunderbird-${TB_VER}.source | 3 | DISTNAME= thunderbird-${TB_VER}.source | |
4 | PKGNAME= thunderbird-${TB_VER} | 4 | PKGNAME= thunderbird-${TB_VER} | |
5 | PKGREVISION= 5 | 5 | PKGREVISION= 5 | |
6 | TB_VER= 78.12.0 | 6 | TB_VER= 78.12.0 | |
7 | CATEGORIES= mail | 7 | CATEGORIES= mail | |
8 | MASTER_SITES= ${MASTER_SITE_MOZILLA:=thunderbird/releases/${TB_VER}/source/} | 8 | MASTER_SITES= ${MASTER_SITE_MOZILLA:=thunderbird/releases/${TB_VER}/source/} | |
9 | EXTRACT_SUFX= .tar.xz | 9 | EXTRACT_SUFX= .tar.xz | |
10 | 10 | |||
11 | MAINTAINER= pkgsrc-users@NetBSD.org | 11 | MAINTAINER= pkgsrc-users@NetBSD.org | |
12 | HOMEPAGE= https://www.thunderbird.net/en-US/ | 12 | HOMEPAGE= https://www.thunderbird.net/en-US/ | |
13 | COMMENT= Organize, secure and customize your mail | 13 | COMMENT= Organize, secure and customize your mail | |
14 | LICENSE= mpl-1.1 | 14 | LICENSE= mpl-1.1 | |
@@ -101,17 +101,17 @@ post-build: | @@ -101,17 +101,17 @@ post-build: | |||
101 | 101 | |||
102 | INSTALLATION_DIRS+= lib/${MOZILLA_NAME}/extensions | 102 | INSTALLATION_DIRS+= lib/${MOZILLA_NAME}/extensions | |
103 | INSTALLATION_DIRS+= share/applications share/pixmaps | 103 | INSTALLATION_DIRS+= share/applications share/pixmaps | |
104 | post-install: | 104 | post-install: | |
105 | ${ECHO} '#! /bin/sh' > ${DESTDIR}${PREFIX}/bin/${MOZILLA_NAME} | 105 | ${ECHO} '#! /bin/sh' > ${DESTDIR}${PREFIX}/bin/${MOZILLA_NAME} | |
106 | ${ECHO} '${PREFIX}/lib/${MOZILLA_NAME}/${MOZILLA_NAME} "$$@"' >> \ | 106 | ${ECHO} '${PREFIX}/lib/${MOZILLA_NAME}/${MOZILLA_NAME} "$$@"' >> \ | |
107 | ${DESTDIR}${PREFIX}/bin/${MOZILLA_NAME} | 107 | ${DESTDIR}${PREFIX}/bin/${MOZILLA_NAME} | |
108 | ${CHMOD} 755 ${DESTDIR}${PREFIX}/bin/${MOZILLA_NAME} | 108 | ${CHMOD} 755 ${DESTDIR}${PREFIX}/bin/${MOZILLA_NAME} | |
109 | ${INSTALL_DATA} ${WRKDIR}/desktop \ | 109 | ${INSTALL_DATA} ${WRKDIR}/desktop \ | |
110 | ${DESTDIR}${PREFIX}/share/applications/${MOZILLA_NAME}.desktop | 110 | ${DESTDIR}${PREFIX}/share/applications/${MOZILLA_NAME}.desktop | |
111 | ${INSTALL_DATA} ${WRKSRC}/${OBJDIR}/dist/${MOZILLA_NAME}/chrome/icons/default/default48.png \ | 111 | ${INSTALL_DATA} ${WRKSRC}/${OBJDIR}/dist/${MOZILLA_NAME}/chrome/icons/default/default48.png \ | |
112 | ${DESTDIR}${PREFIX}/share/pixmaps/${MOZILLA_NAME}.png | 112 | ${DESTDIR}${PREFIX}/share/pixmaps/${MOZILLA_NAME}.png | |
113 | 113 | |||
114 | .include "../../www/firefox78/mozilla-common.mk" | 114 | .include "mozilla-common.mk" | |
115 | .include "options.mk" | 115 | .include "options.mk" | |
116 | .include "../../sysutils/desktop-file-utils/desktopdb.mk" | 116 | .include "../../sysutils/desktop-file-utils/desktopdb.mk" | |
117 | .include "../../mk/bsd.pkg.mk" | 117 | .include "../../mk/bsd.pkg.mk" |
# $NetBSD: mozilla-common.mk,v 1.1 2022/08/04 15:07:14 nia Exp $
#
# common Makefile fragment for mozilla packages based on gecko 2.0.
#
# used by mail/thunderbird/Makefile
.include "../../mk/bsd.prefs.mk"
PYTHON_VERSIONS_ACCEPTED+= 39 38 37
PYTHON_FOR_BUILD_ONLY= tool
ALL_ENV+= PYTHON3=${PYTHONBIN}
HAS_CONFIGURE= yes
CONFIGURE_ARGS+= --prefix=${PREFIX}
USE_TOOLS+= pkg-config perl gmake autoconf213 unzip zip
UNLIMIT_RESOURCES+= datasize virtualsize
USE_LANGUAGES+= c c++
# ERROR: Only GCC 7.1 or newer is supported (found version 5.5.0).
GCC_REQD+= 7
TOOL_DEPENDS+= cbindgen>=0.14.2:../../devel/cbindgen
.if ${MACHINE_ARCH} == "sparc64"
CONFIGURE_ARGS+= --disable-nodejs
.else
TOOL_DEPENDS+= nodejs-[0-9]*:../../lang/nodejs
.endif
TOOL_DEPENDS+= ${PYPKGPREFIX}-sqlite3-[0-9]*:../../databases/py-sqlite3
TOOL_DEPENDS+= ${PYPKGPREFIX}-expat-[0-9]*:../../textproc/py-expat
.if ${MACHINE_ARCH} == "i386" || ${MACHINE_ARCH} == "x86_64"
TOOL_DEPENDS+= nasm>=2.14:../../devel/nasm
TOOL_DEPENDS+= yasm>=1.1:../../devel/yasm
.endif
# This is to work around build failures where an upstream configuration script
# is confused by having more than one approximate match to MACHINE_GNU_PLATFORM
# "i486" when attempting to select the Rust compiler target.
.if !empty(MACHINE_PLATFORM:MNetBSD-*-i386)
CONFIGURE_ARGS+= --target=i586-unknown-netbsd
CONFIGURE_ARGS+= --host=i586-unknown-netbsd
.else
CONFIGURE_ARGS+= --target=${MACHINE_GNU_PLATFORM}
CONFIGURE_ARGS+= --host=${MACHINE_GNU_PLATFORM}
.endif
CONFIGURE_ENV+= BINDGEN_CFLAGS="-isystem${PREFIX}/include/nspr \
-isystem${X11BASE}/include/pixman-1"
test:
cd ${WRKSRC}/${OBJDIR}/dist/bin && \
./run-mozilla.sh ${WRKSRC}/mach check-spidermonkey
# tar(1) of OpenBSD 5.5 has no --exclude command line option.
.if ${OPSYS} == "OpenBSD"
TOOLS_PLATFORM.tar= ${TOOLS_PATH.bsdtar}
USE_TOOLS+= bsdtar
.endif
.if ${MACHINE_ARCH} == "i386"
# This is required for SSE2 code under i386.
CXXFLAGS+= -mstackrealign
.endif
CHECK_PORTABILITY_SKIP+= ${MOZILLA_DIR}third_party/python/glean_parser/Makefile
CHECK_PORTABILITY_SKIP+= ${MOZILLA_DIR}security/nss/tests/libpkix/libpkix.sh
CHECK_PORTABILITY_SKIP+= ${MOZILLA_DIR}security/nss/tests/multinit/multinit.sh
CHECK_PORTABILITY_SKIP+= ${MOZILLA_DIR}js/src/tests/update-test262.sh
CHECK_PORTABILITY_SKIP+= ${MOZILLA_DIR}intl/icu/source/configure
CHECK_PORTABILITY_SKIP+= ${MOZILLA_DIR}browser/components/loop/run-all-loop-tests.sh
CHECK_PORTABILITY_SKIP+= ${MOZILLA_DIR}browser/extensions/loop/run-all-loop-tests.sh
#CHECK_PORTABILITY_SKIP+= ${MOZILLA_DIR}modules/pdfium/update.sh
CONFIGURE_ARGS+= --enable-default-toolkit=cairo-gtk3
CONFIGURE_ARGS+= --enable-release
# Disable Rust SIMD option to fix build with lang/rust-1.33.0
# This should be enabled later again.
#CONFIGURE_ARGS+= --enable-rust-simd
CONFIGURE_ARGS+= --disable-tests
# Mozilla Bug 1432751
#CONFIGURE_ARGS+= --enable-system-cairo
CONFIGURE_ARGS+= --enable-system-pixman
# webrtc option requires internal libvpx
#CONFIGURE_ARGS+= --with-system-libvpx
CONFIGURE_ARGS+= --enable-system-ffi
CONFIGURE_ARGS+= --with-system-icu
CONFIGURE_ARGS+= --with-system-nss
CONFIGURE_ARGS+= --with-system-nspr
#CONFIGURE_ARGS+= --with-system-jpeg
CONFIGURE_ARGS+= --with-system-zlib
CONFIGURE_ARGS+= --with-system-libevent=${BUILDLINK_PREFIX.libevent}
CONFIGURE_ARGS+= --disable-crashreporter
CONFIGURE_ARGS+= --disable-necko-wifi
CONFIGURE_ARGS+= --enable-chrome-format=flat
CONFIGURE_ARGS+= --with-system-webp
#CONFIGURE_ARGS+= --enable-readline
CONFIGURE_ARGS+= --disable-icf
CONFIGURE_ARGS+= --disable-updater
#CONFIGURE_ARGS+= --with-libclang-path=${PREFIX}/lib
SUBST_CLASSES+= fix-paths
SUBST_STAGE.fix-paths= pre-configure
SUBST_MESSAGE.fix-paths= Fixing absolute paths.
SUBST_FILES.fix-paths+= ${MOZILLA_DIR}xpcom/io/nsAppFileLocationProvider.cpp
SUBST_SED.fix-paths+= -e 's,/usr/lib/mozilla/plugins,${PREFIX}/lib/netscape/plugins,g'
CONFIG_GUESS_OVERRIDE+= ${MOZILLA_DIR}build/autoconf/config.guess
CONFIG_GUESS_OVERRIDE+= ${MOZILLA_DIR}js/src/build/autoconf/config.guess
CONFIG_GUESS_OVERRIDE+= ${MOZILLA_DIR}nsprpub/build/autoconf/config.guess
CONFIG_GUESS_OVERRIDE+= ${MOZILLA_DIR}/js/ctypes/libffi/config.guess
CONFIG_SUB_OVERRIDE+= ${MOZILLA_DIR}build/autoconf/config.sub
CONFIG_SUB_OVERRIDE+= ${MOZILLA_DIR}js/src/build/autoconf/config.sub
CONFIG_SUB_OVERRIDE+= ${MOZILLA_DIR}nsprpub/build/autoconf/config.sub
CONFIG_SUB_OVERRIDE+= ${MOZILLA_DIR}/js/ctypes/libffi/config.sub
CONFIGURE_ENV+= CPP=${CPP:Q}
ALL_ENV+= SHELL=${CONFIG_SHELL:Q}
# Build outside ${WRKSRC}
# Try to avoid conflict with config/makefiles/xpidl/Makefile.in
OBJDIR= ../build
CONFIGURE_DIRS= ${OBJDIR}
CONFIGURE_SCRIPT= ${WRKSRC}/configure
PLIST_VARS+= ffvpx
.if ${MACHINE_ARCH} == "aarch64" || \
!empty(MACHINE_ARCH:M*arm*) || \
${MACHINE_ARCH} == "i386" || \
${MACHINE_ARCH} == "x86_64"
PLIST.ffvpx= yes # see media/ffvpx/ffvpxcommon.mozbuild
.endif
# See ${WRKSRC}/security/sandbox/mac/Sandbox.mm: On Darwin, sandboxing
# support is only available when the toolkit is cairo-cocoa.
CONFIGURE_ARGS.Darwin+= --disable-sandbox
# See ${WRKSRC}/configure.in: It tries to use MacOS X 10.6 SDK by
# default, which is not always possible.
.if !empty(MACHINE_PLATFORM:MDarwin-8.*-*)
CONFIGURE_ARGS+= --enable-macos-target=10.4
.elif !empty(MACHINE_PLATFORM:MDarwin-9.*-*)
CONFIGURE_ARGS+= --enable-macos-target=10.5
.endif
# Makefiles sometimes call "rm -f" without more arguments. Kludge around ...
.PHONY: create-rm-wrapper
pre-configure: create-rm-wrapper
create-rm-wrapper:
printf '#!/bin/sh\n[ "$$*" = "-f" ] && exit 0\nexec /bin/rm $$@\n' > \
${WRAPPER_DIR}/bin/rm
chmod +x ${WRAPPER_DIR}/bin/rm
.PHONY: fix-clang-wrapper
pre-configure: fix-clang-wrapper
fix-clang-wrapper:
.if empty(PKGSRC_COMPILER:M*clang*)
# Firefox requires Clang during the build, even when building with GCC.
# XXX: When using GCC, pkgsrc provides 'clang' wrappers that are actually gcc.
# This breaks the build.
${LN} -sf ${PREFIX}/bin/clang ${WRKDIR}/.cwrapper/bin/clang
${LN} -sf ${PREFIX}/bin/clang++ ${WRKDIR}/.cwrapper/bin/clang++
${LN} -sf ${PREFIX}/bin/clang-cpp ${WRKDIR}/.cwrapper/bin/clang-cpp
.endif
# The configure test for __thread succeeds, but later we end up with:
# dist/bin/libxul.so: undefined reference to `__tls_get_addr'
CONFIGURE_ENV.NetBSD+= ac_cv_thread_keyword=no
# In unspecified case, clock_gettime(CLOCK_MONOTONIC, ...) fails.
CONFIGURE_ENV.NetBSD+= ac_cv_clock_monotonic=
.include "../../mk/atomic64.mk"
BUILDLINK_API_DEPENDS.libevent+= libevent>=1.1
.include "../../devel/libevent/buildlink3.mk"
.include "../../devel/libffi/buildlink3.mk"
BUILDLINK_API_DEPENDS.nspr+= nspr>=4.25
.include "../../devel/nspr/buildlink3.mk"
.include "../../textproc/icu/buildlink3.mk"
BUILDLINK_API_DEPENDS.nss+= nss>=3.53
.include "../../devel/nss/buildlink3.mk"
.include "../../devel/zlib/buildlink3.mk"
#.include "../../mk/jpeg.buildlink3.mk"
.include "../../graphics/MesaLib/buildlink3.mk"
#BUILDLINK_API_DEPENDS.cairo+= cairo>=1.10.2nb4
#.include "../../graphics/cairo/buildlink3.mk"
BUILDLINK_API_DEPENDS.libwebp+= libwebp>=1.0.2
.include "../../graphics/libwebp/buildlink3.mk"
BUILDLINK_DEPMETHOD.clang= build
.include "../../lang/clang/buildlink3.mk"
RUST_REQ= 1.41.0
.include "../../lang/rust/rust.mk"
# webrtc option requires internal libvpx
#BUILDLINK_API_DEPENDS.libvpx+= libvpx>=1.3.0
#.include "../../multimedia/libvpx/buildlink3.mk"
.include "../../net/libIDL/buildlink3.mk"
# textproc/hunspell 1.3 is too old
#.include "../../textproc/hunspell/buildlink3.mk"
.include "../../multimedia/ffmpeg4/buildlink3.mk"
.include "../../x11/libXt/buildlink3.mk"
BUILDLINK_API_DEPENDS.pixman+= pixman>=0.25.2
.include "../../x11/pixman/buildlink3.mk"
.include "../../x11/gtk2/buildlink3.mk"
.include "../../x11/gtk3/buildlink3.mk"
PLIST_VARS+= wayland
.if ${PKG_BUILD_OPTIONS.gtk3:Mwayland}
PLIST.wayland= yes
.endif
.include "../../lang/python/tool.mk"
@@ -1,14 +1,14 @@ | @@ -1,14 +1,14 @@ | |||
1 | # $NetBSD: Makefile,v 1.107 2022/07/09 09:34:17 wiz Exp $ | 1 | # $NetBSD: Makefile,v 1.108 2022/08/04 15:07:14 nia Exp $ | |
2 | # | 2 | # | |
3 | # How to update this package: | 3 | # How to update this package: | |
4 | # | 4 | # | |
5 | # replace all patches with the one from the correspoding www/firefox${ESR_RELEASE} | 5 | # replace all patches with the one from the correspoding www/firefox${ESR_RELEASE} | |
6 | # compare e.g. the output of | 6 | # compare e.g. the output of | |
7 | # diff -r -I NetBSD . ../../www/firefox78 | 7 | # diff -r -I NetBSD . ../../www/firefox78 | |
8 | # BUT keep: | 8 | # BUT keep: | |
9 | # patch-.mozconfig (if still necessary) | 9 | # patch-.mozconfig (if still necessary) | |
10 | # patch-browser_app_profile_000-tor-browser.js | 10 | # patch-browser_app_profile_000-tor-browser.js | |
11 | # patch-toolkit_moz.configure (second chunk) | 11 | # patch-toolkit_moz.configure (second chunk) | |
12 | # patch-xpcom_io_TorFileUtils.cpp | 12 | # patch-xpcom_io_TorFileUtils.cpp | |
13 | # make the patches apply | 13 | # make the patches apply | |
14 | # | 14 | # | |
@@ -71,27 +71,27 @@ BUILDLINK_TRANSFORM.NetBSD+= rm:-fexperi | @@ -71,27 +71,27 @@ BUILDLINK_TRANSFORM.NetBSD+= rm:-fexperi | |||
71 | 71 | |||
72 | # Remove hardcoded build directory. | 72 | # Remove hardcoded build directory. | |
73 | SUBST_CLASSES+= fix-build-dir | 73 | SUBST_CLASSES+= fix-build-dir | |
74 | SUBST_STAGE.fix-build-dir= pre-configure | 74 | SUBST_STAGE.fix-build-dir= pre-configure | |
75 | SUBST_FILES.fix-build-dir+= .mozconfig | 75 | SUBST_FILES.fix-build-dir+= .mozconfig | |
76 | SUBST_SED.fix-build-dir+= -e 's,mk_add_options MOZ_OBJDIR=@TOPSRCDIR@/obj-@CONFIG_GUESS@,,' | 76 | SUBST_SED.fix-build-dir+= -e 's,mk_add_options MOZ_OBJDIR=@TOPSRCDIR@/obj-@CONFIG_GUESS@,,' | |
77 | 77 | |||
78 | SUBST_CLASSES+= fonts | 78 | SUBST_CLASSES+= fonts | |
79 | SUBST_STAGE.fonts= pre-configure | 79 | SUBST_STAGE.fonts= pre-configure | |
80 | SUBST_FILES.fonts+= tor-browser_en-US/Browser/TorBrowser/Data/fontconfig/fonts.conf | 80 | SUBST_FILES.fonts+= tor-browser_en-US/Browser/TorBrowser/Data/fontconfig/fonts.conf | |
81 | SUBST_SED.fonts+= -e 's,<dir>fonts</dir>,<dir>${PREFIX}/lib/tor-browser/browser/fonts</dir>,' | 81 | SUBST_SED.fonts+= -e 's,<dir>fonts</dir>,<dir>${PREFIX}/lib/tor-browser/browser/fonts</dir>,' | |
82 | SUBST_MESSAGE.fonts= Fixing path to bundled fonts directory. | 82 | SUBST_MESSAGE.fonts= Fixing path to bundled fonts directory. | |
83 | 83 | |||
84 | .include "../../www/firefox78/mozilla-common.mk" | 84 | .include "../../mail/thunderbird/mozilla-common.mk" | |
85 | .include "options.mk" | 85 | .include "options.mk" | |
86 | 86 | |||
87 | CHECK_INTERPRETER_SKIP+= lib/firefox-sdk/sdk/bin/header.py | 87 | CHECK_INTERPRETER_SKIP+= lib/firefox-sdk/sdk/bin/header.py | |
88 | CHECK_INTERPRETER_SKIP+= lib/firefox-sdk/sdk/bin/typelib.py | 88 | CHECK_INTERPRETER_SKIP+= lib/firefox-sdk/sdk/bin/typelib.py | |
89 | CHECK_INTERPRETER_SKIP+= lib/firefox-sdk/sdk/bin/xpidl.py | 89 | CHECK_INTERPRETER_SKIP+= lib/firefox-sdk/sdk/bin/xpidl.py | |
90 | CHECK_INTERPRETER_SKIP+= lib/firefox-sdk/sdk/bin/xpt.py | 90 | CHECK_INTERPRETER_SKIP+= lib/firefox-sdk/sdk/bin/xpt.py | |
91 | 91 | |||
92 | CHECK_WRKREF_SKIP+= lib/${PKGBASE}/chrome/toolkit/content/global/buildconfig.html | 92 | CHECK_WRKREF_SKIP+= lib/${PKGBASE}/chrome/toolkit/content/global/buildconfig.html | |
93 | 93 | |||
94 | # | 94 | # | |
95 | # Generate list of subst entries for various .cargo-checksum.json files. These | 95 | # Generate list of subst entries for various .cargo-checksum.json files. These | |
96 | # are all handled together in one big substitution to simplify things rather | 96 | # are all handled together in one big substitution to simplify things rather | |
97 | # than one substitution entry per file, but are kept separate below to ease | 97 | # than one substitution entry per file, but are kept separate below to ease |