install a pkg-config file, there is one in the distfile but it's not part of

the build for spidermonkey so provide our own. this is needed by gjs to
pickup mozilla-js.

ok martynas@ (MAINTAINER)
This commit is contained in:
jasper 2011-04-11 20:02:19 +00:00
parent e4d479f402
commit 79a213615b
3 changed files with 21 additions and 2 deletions

View File

@ -1,4 +1,4 @@
# $OpenBSD: Makefile,v 1.16 2011/04/10 17:24:38 landry Exp $
# $OpenBSD: Makefile,v 1.17 2011/04/11 20:02:19 jasper Exp $
SHARED_ONLY= Yes
@ -11,6 +11,7 @@ MOZILLA_PROJECT = spidermonkey
DISTNAME = firefox-${FFX_VERSION}.source
PKGNAME = ${MOZILLA_PROJECT}-${MOZILLA_VERSION}
EPOCH = 0
REVISION = 0
SO_VERSION = 0.0
SHARED_LIBS = mozjs ${SO_VERSION}
@ -62,7 +63,14 @@ CONFIGURE_ENV += SO_VERSION="${SO_VERSION}" \
CPPFLAGS=-DJS_C_STRINGS_ARE_UTF8
SUBST_VARS += MOZILLA_VERSION
post-install:
${INSTALL_PROGRAM} ${WRKSRC}/js ${PREFIX}/bin/
# There is a mozilla-js.pc in the tarball, but it's not initialized
# as part of the build. This file is based on that.
${INSTALL_DATA_DIR} ${PREFIX}/lib/pkgconfig/
${SUBST_CMD} -o ${SHAREOWN} -g ${SHAREGRP} -c ${FILESDIR}/mozilla-js.pc \
${PREFIX}/lib/pkgconfig/mozilla-js.pc
.include <bsd.port.mk>

View File

@ -0,0 +1,10 @@
# $OpenBSD: mozilla-js.pc,v 1.1 2011/04/11 20:02:19 jasper Exp $
prefix=${TRUEPREFIX}
includedir=${prefix}/include/js/
Name: JavaScript
Description: The Mozilla JavaScript Library
Version: ${MOZILLA_VERSION}
Requires: nspr
Libs: -L${prefix}/lib -lmozjs -lncurses -lm
Cflags: -I${includedir} -DXP_UNIX -DJS_THREADSAFE

View File

@ -1,4 +1,4 @@
@comment $OpenBSD: PLIST,v 1.4 2011/04/10 17:24:38 landry Exp $
@comment $OpenBSD: PLIST,v 1.5 2011/04/11 20:02:19 jasper Exp $
%%jit%%
%%amd64%%
@bin bin/js
@ -59,3 +59,4 @@ include/js/jsxdrapi.h
include/js/jsxml.h
lib/libjs_static.a
@lib lib/libmozjs.so.${LIBmozjs_VERSION}
lib/pkgconfig/mozilla-js.pc