mirror of
https://git.freebsd.org/ports.git
synced 2025-07-18 01:39:16 -04:00
*/*: add new port NGINX JavaScript (njs) command line utility
NGINX JavaScript, also knows as njs, is a subset of the JavaScript language that allows extending nginx functionality. njs is created in compliance with ECMAScript 5.1 (strict mode) with some ECMAScript 6 and later extensions. It's easy to use njs command line utility to develop and debug additional functionality. Also, it's light-weight and very useful as a shebang in some cases as the nodejs substitutor. Remove build of njs command-line utlity from the www/nginx-devel (*) process. Bump PORTREVISION. (*)
This commit is contained in:
parent
afae6c72d9
commit
a9108d8c08
6 changed files with 61 additions and 8 deletions
|
@ -198,6 +198,7 @@
|
||||||
SUBDIR += nhc98
|
SUBDIR += nhc98
|
||||||
SUBDIR += nickle
|
SUBDIR += nickle
|
||||||
SUBDIR += nim
|
SUBDIR += nim
|
||||||
|
SUBDIR += njs
|
||||||
SUBDIR += nqc
|
SUBDIR += nqc
|
||||||
SUBDIR += nwcc
|
SUBDIR += nwcc
|
||||||
SUBDIR += nx
|
SUBDIR += nx
|
||||||
|
|
49
lang/njs/Makefile
Normal file
49
lang/njs/Makefile
Normal file
|
@ -0,0 +1,49 @@
|
||||||
|
# Created by: Sergey A. Osokin <osa@FreeBSD.org>
|
||||||
|
|
||||||
|
PORTNAME= njs
|
||||||
|
DISTVERSION= 0.7.2
|
||||||
|
CATEGORIES= lang www
|
||||||
|
#DISTFILES= ${DISTNAME}${EXTRACT_SUFX}
|
||||||
|
|
||||||
|
MAINTAINER= osa@FreeBSD.org
|
||||||
|
COMMENT= NGINX JavaScript command line utility
|
||||||
|
|
||||||
|
LICENSE= BSD2CLAUSE
|
||||||
|
LICENSE_FILE= ${WRKSRC}/LICENSE
|
||||||
|
|
||||||
|
USES= cpe
|
||||||
|
|
||||||
|
CONFLICTS_INSTALL= www/nginx
|
||||||
|
|
||||||
|
CPE_VENDOR= f5
|
||||||
|
CPE_PRODUCT= njs
|
||||||
|
|
||||||
|
USE_GITHUB= yes
|
||||||
|
GH_TUPLE= nginx:njs:0.7.2
|
||||||
|
HAS_CONFIGURE= yes
|
||||||
|
|
||||||
|
OPTIONS_DEFINE= SSL
|
||||||
|
OPTIONS_RADIO+= PCRE
|
||||||
|
OPTIONS_RADIO_PCRE= NOPCRE PCRE_ONE PCRE_TWO
|
||||||
|
NOPCRE_CONFIGURE_ON= --no-pcre
|
||||||
|
PCRE_ONE_LIB_DEPENDS= libpcre.so:devel/pcre
|
||||||
|
PCRE_ONE_CONFIGURE_ON= --no-pcre2
|
||||||
|
PCRE_TWO_LIB_DEPENDS= libpcre2-8.so:devel/pcre2
|
||||||
|
OPTIONS_DEFAULT= PCRE_ONE SSL
|
||||||
|
SSL_CONFIGURE_OFF= --no-openssl
|
||||||
|
SSL_USES= ssl
|
||||||
|
|
||||||
|
NOPCRE_DESC= Disable PCRE support
|
||||||
|
PCRE_ONE_DESC= Enable PCRE1 support
|
||||||
|
PCRE_TWO_DESC= Enable PCRE2 support
|
||||||
|
SSL_DESC= Enable OpenSSL support
|
||||||
|
|
||||||
|
PLIST_FILES= bin/njs
|
||||||
|
|
||||||
|
do-build:
|
||||||
|
@cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} ${MAKE_CMD} njs
|
||||||
|
|
||||||
|
do-install:
|
||||||
|
${INSTALL_PROGRAM} ${WRKSRC}/build/njs ${STAGEDIR}${PREFIX}/bin
|
||||||
|
|
||||||
|
.include <bsd.port.mk>
|
3
lang/njs/distinfo
Normal file
3
lang/njs/distinfo
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
TIMESTAMP = 1647025367
|
||||||
|
SHA256 (nginx-njs-0.7.2_GH0.tar.gz) = a1481be96989842ed05d06eab4ae4e79790c552196e5624dd38d42bc2d275829
|
||||||
|
SIZE (nginx-njs-0.7.2_GH0.tar.gz) = 584483
|
6
lang/njs/pkg-descr
Normal file
6
lang/njs/pkg-descr
Normal file
|
@ -0,0 +1,6 @@
|
||||||
|
njs scripting language, or just njs, is a subset of the JavaScript language
|
||||||
|
that allows extending nginx functionality. njs is created in compliance
|
||||||
|
with ECMAScript 5.1 (strict mode) with some ECMAScript 6 and later
|
||||||
|
extensions. The compliance is still evolving.
|
||||||
|
|
||||||
|
WWW: https://nginx.org/en/docs/njs/
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
PORTNAME?= nginx
|
PORTNAME?= nginx
|
||||||
PORTVERSION= 1.21.6
|
PORTVERSION= 1.21.6
|
||||||
PORTREVISION= 6
|
PORTREVISION= 7
|
||||||
CATEGORIES= www
|
CATEGORIES= www
|
||||||
MASTER_SITES= https://nginx.org/download/ \
|
MASTER_SITES= https://nginx.org/download/ \
|
||||||
LOCAL/osa
|
LOCAL/osa
|
||||||
|
@ -325,9 +325,7 @@ pre-configure-SMALL_LIGHT-on:
|
||||||
( cd ${WRKSRC_small_light} && ./setup )
|
( cd ${WRKSRC_small_light} && ./setup )
|
||||||
|
|
||||||
do-configure-NJS-on:
|
do-configure-NJS-on:
|
||||||
( cd ${WRKSRC_njs} && ${SETENV} ${CONFIGURE_ENV} ${CONFIGURE_CMD} ${NJS_CONFIGURE_ARGS} \
|
( cd ${WRKSRC_njs} && ${SETENV} ${CONFIGURE_ENV} ${CONFIGURE_CMD} ${NJS_CONFIGURE_ARGS} )
|
||||||
&& ${SETENV} ${MAKE_ENV} ${MAKE_CMD} njs \
|
|
||||||
&& ${MV} build/njs ${WRKSRC_njs} )
|
|
||||||
|
|
||||||
.if !target(do-install)
|
.if !target(do-install)
|
||||||
do-install:
|
do-install:
|
||||||
|
@ -362,9 +360,6 @@ do-install-NAXSI-on:
|
||||||
${INSTALL_DATA} \
|
${INSTALL_DATA} \
|
||||||
${WRKDIR}/naxsi-${NAXSI_NGINX_VER}/naxsi_config/naxsi_core.rules \
|
${WRKDIR}/naxsi-${NAXSI_NGINX_VER}/naxsi_config/naxsi_core.rules \
|
||||||
${STAGEDIR}${ETCDIR}
|
${STAGEDIR}${ETCDIR}
|
||||||
|
|
||||||
do-install-NJS-on:
|
|
||||||
${INSTALL_PROGRAM} ${WRKSRC_njs}/njs ${STAGEDIR}${PREFIX}/sbin
|
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if !target(post-install)
|
.if !target(post-install)
|
||||||
|
|
|
@ -87,7 +87,6 @@
|
||||||
%%DSO%%%%XSS%%libexec/nginx/ngx_http_xss_filter_module.so
|
%%DSO%%%%XSS%%libexec/nginx/ngx_http_xss_filter_module.so
|
||||||
%%HTTP_PERL%%%%SITE_ARCH%%/auto/nginx/nginx.so
|
%%HTTP_PERL%%%%SITE_ARCH%%/auto/nginx/nginx.so
|
||||||
%%HTTP_PERL%%%%SITE_ARCH%%/nginx.pm
|
%%HTTP_PERL%%%%SITE_ARCH%%/nginx.pm
|
||||||
%%NJS%%sbin/njs
|
|
||||||
sbin/nginx
|
sbin/nginx
|
||||||
share/vim/vimfiles/ftdetect/nginx.vim
|
share/vim/vimfiles/ftdetect/nginx.vim
|
||||||
share/vim/vimfiles/ftplugin/nginx.vim
|
share/vim/vimfiles/ftplugin/nginx.vim
|
||||||
|
|
Loading…
Add table
Reference in a new issue