openbsd-ports/www/fennec/Makefile
landry b715788993 Import fennec 4.0:
Firefox for mobile (codenamed Fennec) is the name of the build of the
Mozilla Firefox web browser for devices such as mobile phones and
personal digital assistants (PDAs).
While it initially targets android and maemo, it also works on desktop
machines, and can be useful on small screens or low-powered devices.

Looks ok to jasper@
2011-04-12 19:48:57 +00:00

77 lines
2.4 KiB
Makefile

# $OpenBSD: Makefile,v 1.1.1.1 2011/04/12 19:48:57 landry Exp $
COMMENT = Mozilla mobile web browser
MOZILLA_VERSION = 4.0
MOZILLA_BRANCH = 2.1
MOZILLA_PROJECT = fennec
MOZILLA_CODENAME = mobile
# XXX rc1 is the final release
DISTNAME = ${MOZILLA_PROJECT}-${MOZILLA_VERSION}rc1.source
SO_VERSION = 0.0
NSS_SO_VERSION = 27.0
# NOTE: Must bump minor version if any shlib's are removed from the
# components dir to avoid pkg_add -r issues.
MOZILLA_LIBS = mozalloc xpcom xul
CATEGORIES = www
# mozilla public license
PERMIT_PACKAGE_CDROM= Yes
PERMIT_PACKAGE_FTP= Yes
PERMIT_DISTFILES_CDROM= Yes
PERMIT_DISTFILES_FTP= Yes
MASTER_SITES = http://releases.mozilla.org/pub/mozilla.org/mobile/releases/${MOZILLA_VERSION}/source/
HOMEPAGE = http://www.mozilla.com/en-US/mobile/
# lots of logic in mozilla.port.mk
MODULES = www/mozilla devel/gettext lang/python
MODPY_RUNDEP = No
USE_GROFF = Yes
# Regression tests are too hard to adapt to run here
NO_REGRESS = Yes
CONFIGURE_STYLE = autoconf no-autoheader
CONFIGURE_ARGS += --enable-official-branding --disable-install-strip
CONFIGURE_ARGS += --with-system-libevent=/usr/
CONFIGURE_ARGS += --with-system-zlib=/usr/ --with-system-bz2=${LOCALBASE}
WANTLIB += event
.if ${MACHINE_ARCH:Msparc64}
CONFIGURE_ARGS += --disable-tracejit --disable-methodjit
.endif
# --with-system-png=${LOCALBASE}
# no system png : apng support not bundled in
MOZILLA_AUTOCONF_DIRS += js/src
MOZILLA_SUBST_FILES += config/autoconf.mk.in services/crypto/modules/WeaveCrypto.js
SUBST_VARS += MOZILLA_VERSION NSS_SO_VERSION
# package target uses gtar options
BUILD_DEPENDS += archivers/gtar
INSTALL_TARGET = package
post-configure:
rm -f ${WRKSRC}/services/crypto/modules/WeaveCrypto.js.{orig,beforesubst}
post-install:
cd ${WRKSRC} && tar -C ${PREFIX}/lib/ -xjf dist/fennec*.tar.bz2
mv ${PREFIX}/lib/${MOZILLA_PROJECT}{,-${MOZILLA_VERSION}}/
echo '#!/bin/sh\ncd ${TRUEPREFIX}/lib/${MOZILLA_PROJECT}-${MOZILLA_VERSION} ; LD_LIBRARY_PATH=. ./fennec "$$@"' \
> ${PREFIX}/bin/fennec
chmod +x ${PREFIX}/bin/fennec
${INSTALL_DATA} ${WRKSRC}/mobile/branding/nightly/content/fennec_72x72.png \
${PREFIX}/lib/${MOZILLA_PROJECT}-${MOZILLA_VERSION}/fennec_icon.png
# install desktop file
${INSTALL_DATA_DIR} ${PREFIX}/share/applications/ ; \
${SUBST_CMD} -o ${SHAREOWN} -g ${SHAREGRP} -c ${FILESDIR}/${_MOZ_PROJECT_SHORT}.desktop \
${PREFIX}/share/applications/${_MOZ_PROJECT_SHORT}.desktop ; \
.include <bsd.port.mk>