diff options
author | Jimmy Olgeni <olgeni@FreeBSD.org> | 2016-08-08 08:07:15 +0000 |
---|---|---|
committer | Jimmy Olgeni <olgeni@FreeBSD.org> | 2016-08-08 08:07:15 +0000 |
commit | 4122188df766c0042eaf772b1a3716b5702c4aa5 (patch) | |
tree | 4793054b7784bb022c9df5686cb03f5a897447d3 /lang | |
parent | 5e9abe473c2a66689298c0eeb8e1285d4a37caed (diff) |
Notes
Diffstat (limited to 'lang')
-rw-r--r-- | lang/Makefile | 1 | ||||
-rw-r--r-- | lang/erlang-runtime19/Makefile | 262 | ||||
-rw-r--r-- | lang/erlang-runtime19/distinfo | 11 | ||||
-rw-r--r-- | lang/erlang-runtime19/files/patch-Makefile.in | 20 | ||||
-rw-r--r-- | lang/erlang-runtime19/files/patch-erts_etc_unix_run__erl.c | 12 | ||||
-rw-r--r-- | lang/erlang-runtime19/files/patch-lib_crypto_c__src_Makefile.in | 11 | ||||
-rw-r--r-- | lang/erlang-runtime19/files/patch-lib_crypto_priv_Makefile | 11 | ||||
-rw-r--r-- | lang/erlang-runtime19/files/patch-lib_erl__interface_src_connect_ei__resolve.c | 12 | ||||
-rw-r--r-- | lang/erlang-runtime19/files/patch-lib_stdlib_src_calendar.erl | 26 | ||||
-rw-r--r-- | lang/erlang-runtime19/files/pkg-message.in | 6 | ||||
-rw-r--r-- | lang/erlang-runtime19/pkg-descr | 10 |
11 files changed, 382 insertions, 0 deletions
diff --git a/lang/Makefile b/lang/Makefile index aaf282874a32..074e0a7f4a76 100644 --- a/lang/Makefile +++ b/lang/Makefile @@ -66,6 +66,7 @@ SUBDIR += erlang-runtime16 SUBDIR += erlang-runtime17 SUBDIR += erlang-runtime18 + SUBDIR += erlang-runtime19 SUBDIR += erlang-wx SUBDIR += execline SUBDIR += expect diff --git a/lang/erlang-runtime19/Makefile b/lang/erlang-runtime19/Makefile new file mode 100644 index 000000000000..f4352f967ec4 --- /dev/null +++ b/lang/erlang-runtime19/Makefile @@ -0,0 +1,262 @@ +# Created by: ruslan@shevchenko.kiev.ua +# $FreeBSD$ + +PORTNAME= erlang +PORTVERSION= 19.0.2 +CATEGORIES= lang parallel java +MASTER_SITES= http://www.erlang.org/download/:erlangorg \ + http://erlang.stacken.kth.se/download/:erlangorg \ + http://www.csd.uu.se/ftp/mirror/erlang/download/:erlangorg +PKGNAMESUFFIX= -runtime19 +DISTNAME= otp_src_${ERL_RELEASE} +DISTFILES= ${DISTNAME}${EXTRACT_SUFX}:erlangorg \ + ${ERLANG_MAN}:erlangorg +DIST_SUBDIR= erlang +EXTRACT_ONLY= ${DISTNAME}${EXTRACT_SUFX} + +PATCH_SITES= http://olgeni.olgeni.com/~olgeni/distfiles/ \ + LOCAL/olgeni +PATCHFILES= patch-otp-19.0.1 patch-otp-19.0.2 + +MAINTAINER= olgeni@FreeBSD.org +COMMENT= Functional programming language from Ericsson + +LICENSE= APACHE20 + +WRKSRC= ${WRKDIR}/otp_src_${ERL_RELEASE} + +ERLANG_LIB= ${PORTNAME}${PORTVERSION:C/\..*//} + +SUB_FILES= pkg-message +SUB_LIST= ERLANG_LIB=${ERLANG_LIB} + +MAKE_JOBS_UNSAFE=yes + +OPTIONS_DEFINE= DOCS DTRACE GCC GS HIPE JAVA KQUEUE ODBC OPENSSL SCTP SMP THREADS WX DIRTY + +DIRTY_DESC= Enable Dirty schedulers (experimental) +DTRACE_DESC= Enable DTrace support +GS_DESC= Enable GS application (deprecated) +HIPE_DESC= Build native HiPE compiler +KQUEUE_DESC= Enable Kernel Poll (kqueue) support +SCTP_DESC= Enable SCTP support +SMP_DESC= Enable SMP support +WX_DESC= Enable WX application + +OPTIONS_DEFAULT=HIPE KQUEUE OPENSSL SCTP SMP THREADS +OPTIONS_EXCLUDE_DragonFly= HIPE SCTP + +ERL_RELEASE= 19.0 + +USES= gmake ncurses perl5 +USE_PERL5= build +GNU_CONFIGURE= yes +LDFLAGS+= -L${LOCALBASE}/lib + +.include <bsd.port.options.mk> + +.if ${PORT_OPTIONS:MDOCS} +DISTFILES+= ${ERLANG_DOCS}:erlangorg +.endif + +# If you run Erlang and get a message resembling "WARNING: number of +# probes fixed does not match the number of defined probes (54 != 132, +# respectively)" you probably misconfigured DTrace in some way. + +.if ${OSVERSION} < 1000000 +.if ${ARCH} == "amd64" && ${PORT_OPTIONS:MDTRACE} && ! ${PORT_OPTIONS:MGCC} +IGNORE= support for DTrace on amd64 requires GCC option +.endif +.endif + +.if ${PORT_OPTIONS:MGCC} +USE_GCC?= yes +.endif + +.if ${PORT_OPTIONS:MDTRACE} +CONFIGURE_ARGS+=--with-dynamic-trace=dtrace +CFLAGS+= -fno-omit-frame-pointer +STRIP= +.else +CONFIGURE_ARGS+=--without-dynamic-trace +.endif + +.if ${PORT_OPTIONS:MOPENSSL} +USES+= ssl +CONFIGURE_ARGS+=--with-ssl=${OPENSSLBASE} +.else +CONFIGURE_ARGS+=--without-ssl +.endif + +.if ${PORT_OPTIONS:MJAVA} +USE_JAVA= yes +CONFIGURE_ARGS+=--with-javac +CONFIGURE_ENV+= ac_cv_prog_JAVAC="${JAVAC}" +.else +CONFIGURE_ARGS+=--without-javac +.endif + +.if ${PORT_OPTIONS:MHIPE} +CONFIGURE_ARGS+=--enable-hipe +.else +CONFIGURE_ARGS+=--disable-hipe +.endif + +.if ${PORT_OPTIONS:MKQUEUE} +CONFIGURE_ARGS+=--enable-kernel-poll +.else +CONFIGURE_ARGS+=--disable-kernel-poll +.endif + +.if ${PORT_OPTIONS:MGS} +USES+= tk:run +.endif + +.if ${PORT_OPTIONS:MWX} +USE_WX= 2.8+ +WX_COMPS= wx contrib +WX_UNICODE= yes +CONFIGURE_ARGS+=--with-wx-config=${WX_CONFIG} +.endif + +.if ${PORT_OPTIONS:MODBC} +CONFIGURE_ARGS+=--with-odbc +LIB_DEPENDS+= libodbc.so:databases/unixODBC +.else +CONFIGURE_ARGS+=--without-odbc +.endif + +ERLANG_MAN= otp_doc_man_${ERL_RELEASE}.tar.gz +ERLANG_DOCS= otp_doc_html_${ERL_RELEASE}.tar.gz + +.if ${PORT_OPTIONS:MTHREADS} +CONFIGURE_ARGS+=--enable-threads +.else +CONFIGURE_ARGS+=--disable-threads +.endif + +.if ${PORT_OPTIONS:MSCTP} +CONFIGURE_ARGS+=--enable-sctp +.else +CONFIGURE_ARGS+=--disable-sctp +.endif + +# enabling --enable-smp-support crashes the OS when +# net_kernel:start([node_name, shortnames]) invoked repeatedly +# TODO verify if it still applies + +.if ${PORT_OPTIONS:MSMP} +CONFIGURE_ARGS+=--enable-smp-support +.else +CONFIGURE_ARGS+=--disable-smp-support +.endif + +.if ${PORT_OPTIONS:MDIRTY} +CONFIGURE_ARGS+=--enable-dirty-schedulers +.endif + +.if ${ARCH} == i386 +MAKE_ARGS+= ARCH=x86 +.endif + +.if ${ARCH} == armv6 +MAKE_ARGS+= ARCH=arm +.endif + +# The man-pages are put (in spite of FreeBSD's port convention) in a private +# subdir. This is to avoid cluttering up the man page name space. Also the +# Erlang man pages are more of internal documentation using the man format than +# actual system man pages. (erl.1 and epmd.1 perhaps being the exception). + +# Install documentation. (HTML docs need to be in same dir as the +# rest, not in share/doc/erlang as it should, because of relative +# links in the documentation. + +pre-configure: +.if ${PORT_OPTIONS:MDTRACE} + @if ! /sbin/kldstat | ${GREP} dtraceall >/dev/null 2>&1; then \ + ${ECHO_CMD}; \ + ${ECHO_CMD} "DTRACE option requires kernel module \"dtraceall\" to be loaded."; \ + ${ECHO_CMD}; \ + exit 1; \ + fi +.endif +.if ! ${PORT_OPTIONS:MWX} + echo "disabled by port options" > ${WRKSRC}/lib/wx/SKIP +.endif + +post-configure: +.if ${PORT_OPTIONS:MODBC} + ${RM} ${WRKSRC}/lib/odbc/SKIP +.endif + +post-install: + for SECTION in 1 3 4 6 7; do \ + ${TAR} --unlink -xzpf ${DISTDIR}/${DIST_SUBDIR}/${ERLANG_MAN} \ + -C ${STAGEDIR}${PREFIX}/lib/${ERLANG_LIB} \ + "man/man$${SECTION}/*.$${SECTION}" || ${TRUE}; \ + done + ${RM} -rf ${STAGEDIR}${PREFIX}/lib/${ERLANG_LIB}/man/cat? +.if ${PORT_OPTIONS:MDOCS} + ${TAR} --unlink -xzpf ${DISTDIR}/${DIST_SUBDIR}/${ERLANG_DOCS} \ + -C ${STAGEDIR}${PREFIX}/lib/${ERLANG_LIB} + + ${MV} ${STAGEDIR}${PREFIX}/lib/${ERLANG_LIB}/erts-8.0/* \ + ${STAGEDIR}${PREFIX}/lib/${ERLANG_LIB}/erts-8.0.2 + ${RMDIR} ${STAGEDIR}${PREFIX}/lib/${ERLANG_LIB}/erts-8.0 + + ${MV} ${STAGEDIR}${PREFIX}/lib/${ERLANG_LIB}/lib/compiler-7.0/* \ + ${STAGEDIR}${PREFIX}/lib/${ERLANG_LIB}/lib/compiler-7.0.1 + ${RMDIR} ${STAGEDIR}${PREFIX}/lib/${ERLANG_LIB}/lib/compiler-7.0 + + ${MV} ${STAGEDIR}${PREFIX}/lib/${ERLANG_LIB}/lib/dialyzer-3.0/* \ + ${STAGEDIR}${PREFIX}/lib/${ERLANG_LIB}/lib/dialyzer-3.0.1 + ${RMDIR} ${STAGEDIR}${PREFIX}/lib/${ERLANG_LIB}/lib/dialyzer-3.0 + + ${MV} ${STAGEDIR}${PREFIX}/lib/${ERLANG_LIB}/lib/inets-6.3/* \ + ${STAGEDIR}${PREFIX}/lib/${ERLANG_LIB}/lib/inets-6.3.1 + ${RMDIR} ${STAGEDIR}${PREFIX}/lib/${ERLANG_LIB}/lib/inets-6.3 + + ${MV} ${STAGEDIR}${PREFIX}/lib/${ERLANG_LIB}/lib/observer-2.2/* \ + ${STAGEDIR}${PREFIX}/lib/${ERLANG_LIB}/lib/observer-2.2.1 + ${RMDIR} ${STAGEDIR}${PREFIX}/lib/${ERLANG_LIB}/lib/observer-2.2 + + ${MV} ${STAGEDIR}${PREFIX}/lib/${ERLANG_LIB}/lib/ssh-4.3/* \ + ${STAGEDIR}${PREFIX}/lib/${ERLANG_LIB}/lib/ssh-4.3.1 + ${RMDIR} ${STAGEDIR}${PREFIX}/lib/${ERLANG_LIB}/lib/ssh-4.3 + + ${MV} ${STAGEDIR}${PREFIX}/lib/${ERLANG_LIB}/lib/stdlib-3.0/* \ + ${STAGEDIR}${PREFIX}/lib/${ERLANG_LIB}/lib/stdlib-3.0.1 + ${RMDIR} ${STAGEDIR}${PREFIX}/lib/${ERLANG_LIB}/lib/stdlib-3.0 + + ${MV} ${STAGEDIR}${PREFIX}/lib/${ERLANG_LIB}/lib/tools-2.8.4/* \ + ${STAGEDIR}${PREFIX}/lib/${ERLANG_LIB}/lib/tools-2.8.5 + ${RMDIR} ${STAGEDIR}${PREFIX}/lib/${ERLANG_LIB}/lib/tools-2.8.4 + + ${INSTALL_DATA} ${WRKSRC}/lib/dialyzer/doc/*.txt \ + ${STAGEDIR}${PREFIX}/lib/${ERLANG_LIB}/lib/dialyzer-*/doc/ +.endif +.if ! ${PORT_OPTIONS:MGS} + ${RM} -r ${STAGEDIR}${PREFIX}/lib/erlang/lib/gs-* +.endif +.if ! ${PORT_OPTIONS:MJAVA} + ${RM} -r ${STAGEDIR}${PREFIX}/lib/erlang/lib/jinterface-* +.endif +.if ! ${PORT_OPTIONS:MODBC} + ${RM} -r ${STAGEDIR}${PREFIX}/lib/erlang/lib/odbc-* +.endif +.if ! ${PORT_OPTIONS:MOPENSSL} + ${RM} -r ${STAGEDIR}${PREFIX}/lib/erlang/lib/crypto-* + ${RM} -r ${STAGEDIR}${PREFIX}/lib/erlang/lib/ssh-* + ${RM} -r ${STAGEDIR}${PREFIX}/lib/erlang/lib/ssl-* +.endif +.if ! ${PORT_OPTIONS:MWX} + ${RM} -r ${STAGEDIR}${PREFIX}/lib/erlang/lib/wx-* +.endif + ${FIND} ${STAGEDIR}${PREFIX}/lib/${ERLANG_LIB}/* -type d -empty -delete + + @cd ${STAGEDIR}${PREFIX}; ${FIND} lib/${ERLANG_LIB}/* -type f -o -type l \ + | ${SORT} \ + >> ${TMPPLIST} + +.include <bsd.port.mk> diff --git a/lang/erlang-runtime19/distinfo b/lang/erlang-runtime19/distinfo new file mode 100644 index 000000000000..65d8cfc74a8e --- /dev/null +++ b/lang/erlang-runtime19/distinfo @@ -0,0 +1,11 @@ +TIMESTAMP = 1470572356 +SHA256 (erlang/otp_src_19.0.tar.gz) = 3fdc27a2a826e7f3d9cda43302d27d98704d6b41ce29a8a5df747a161da53bb1 +SIZE (erlang/otp_src_19.0.tar.gz) = 68022550 +SHA256 (erlang/otp_doc_man_19.0.tar.gz) = c7a3d6d85a5a2b96d844297a3fa1bee448c3dd86237734688466249fd5a1401e +SIZE (erlang/otp_doc_man_19.0.tar.gz) = 1405918 +SHA256 (erlang/otp_doc_html_19.0.tar.gz) = b6f7c4e964673333f6c3eea8530dd988b41339b8912ae293f6f1b429489159ff +SIZE (erlang/otp_doc_html_19.0.tar.gz) = 34550919 +SHA256 (erlang/patch-otp-19.0.1) = e5090928dfbcd1f7064bc50cf4230ad9b21853a649a9c88fc38ed994f1099161 +SIZE (erlang/patch-otp-19.0.1) = 46724 +SHA256 (erlang/patch-otp-19.0.2) = dc1da716bef342d56ec68afaad240680926c68b9503b1ebfe239d6ddd4d49f49 +SIZE (erlang/patch-otp-19.0.2) = 16791 diff --git a/lang/erlang-runtime19/files/patch-Makefile.in b/lang/erlang-runtime19/files/patch-Makefile.in new file mode 100644 index 000000000000..4b0bbf6fbd07 --- /dev/null +++ b/lang/erlang-runtime19/files/patch-Makefile.in @@ -0,0 +1,20 @@ +--- Makefile.in.orig 2015-06-23 18:56:21 UTC ++++ Makefile.in +@@ -60,7 +60,7 @@ bindir = @bindir@ + libdir = @libdir@ + + # Where Erlang/OTP is located +-libdir_suffix = /erlang ++libdir_suffix = /erlang19 + erlang_libdir = $(libdir)$(libdir_suffix) + erlang_bindir = $(erlang_libdir)/bin + +@@ -1013,7 +1013,7 @@ $(TEST_DIRS): + # + # Order is important here, don't change it! + # +-INST_DEP += install.dirs install.emulator install.libs install.Install install.otp_version install.bin ++INST_DEP += install.dirs install.emulator install.libs install.Install install.otp_version + + install: $(INST_DEP) + diff --git a/lang/erlang-runtime19/files/patch-erts_etc_unix_run__erl.c b/lang/erlang-runtime19/files/patch-erts_etc_unix_run__erl.c new file mode 100644 index 000000000000..b76c5127d2a8 --- /dev/null +++ b/lang/erlang-runtime19/files/patch-erts_etc_unix_run__erl.c @@ -0,0 +1,12 @@ +--- erts/etc/unix/run_erl.c.orig 2015-03-31 12:32:52 UTC ++++ erts/etc/unix/run_erl.c +@@ -73,9 +73,6 @@ + #ifdef HAVE_UTMP_H + # include <utmp.h> + #endif +-#ifdef HAVE_UTIL_H +-# include <util.h> +-#endif + #ifdef HAVE_SYS_IOCTL_H + # include <sys/ioctl.h> + #endif diff --git a/lang/erlang-runtime19/files/patch-lib_crypto_c__src_Makefile.in b/lang/erlang-runtime19/files/patch-lib_crypto_c__src_Makefile.in new file mode 100644 index 000000000000..65e1b759ad66 --- /dev/null +++ b/lang/erlang-runtime19/files/patch-lib_crypto_c__src_Makefile.in @@ -0,0 +1,11 @@ +--- lib/crypto/c_src/Makefile.in.orig 2016-03-14 20:11:15 UTC ++++ lib/crypto/c_src/Makefile.in +@@ -90,7 +90,7 @@ endif + DYNAMIC_CRYPTO_LIB=@SSL_DYNAMIC_ONLY@ + + ifeq ($(DYNAMIC_CRYPTO_LIB),yes) +-SSL_DED_LD_RUNTIME_LIBRARY_PATH = @SSL_DED_LD_RUNTIME_LIBRARY_PATH@ ++SSL_DED_LD_RUNTIME_LIBRARY_PATH = + CRYPTO_LINK_LIB=$(SSL_DED_LD_RUNTIME_LIBRARY_PATH) -L$(SSL_LIBDIR) -l$(SSL_CRYPTO_LIBNAME) + EXTRA_FLAGS = -DHAVE_DYNAMIC_CRYPTO_LIB + else diff --git a/lang/erlang-runtime19/files/patch-lib_crypto_priv_Makefile b/lang/erlang-runtime19/files/patch-lib_crypto_priv_Makefile new file mode 100644 index 000000000000..26f2c38e360d --- /dev/null +++ b/lang/erlang-runtime19/files/patch-lib_crypto_priv_Makefile @@ -0,0 +1,11 @@ +--- lib/crypto/priv/Makefile.orig 2016-03-14 20:11:15 UTC ++++ lib/crypto/priv/Makefile +@@ -61,7 +61,7 @@ OBJS = $(OBJDIR)/crypto.o + # ---------------------------------------------------- + + $(SO_NIFLIB): $(OBJS) +- $(SO_LD) $(SO_LDFLAGS) -L$(SO_SSL_LIBDIR) -Wl,-R$(SO_SSL_LIBDIR) \ ++ $(SO_LD) $(SO_LDFLAGS) -L$(SO_SSL_LIBDIR) \ + -o $@ $^ -lcrypto + + $(DLL_NIFLIB): $(OBJS) diff --git a/lang/erlang-runtime19/files/patch-lib_erl__interface_src_connect_ei__resolve.c b/lang/erlang-runtime19/files/patch-lib_erl__interface_src_connect_ei__resolve.c new file mode 100644 index 000000000000..16046e8e4934 --- /dev/null +++ b/lang/erlang-runtime19/files/patch-lib_erl__interface_src_connect_ei__resolve.c @@ -0,0 +1,12 @@ +--- lib/erl_interface/src/connect/ei_resolve.c.orig 2015-03-31 12:32:52 UTC ++++ lib/erl_interface/src/connect/ei_resolve.c +@@ -649,7 +649,8 @@ struct hostent *ei_gethostbyname_r(const + + return result; + #else +- return gethostbyname_r(name,hostp,buffer,buflen,h_errnop); ++ struct hostent *dummy; ++ return gethostbyname_r(name,hostp,buffer,buflen,&dummy,h_errnop); + #endif + #endif + #endif diff --git a/lang/erlang-runtime19/files/patch-lib_stdlib_src_calendar.erl b/lang/erlang-runtime19/files/patch-lib_stdlib_src_calendar.erl new file mode 100644 index 000000000000..34b753d85b27 --- /dev/null +++ b/lang/erlang-runtime19/files/patch-lib_stdlib_src_calendar.erl @@ -0,0 +1,26 @@ +--- lib/stdlib/src/calendar.erl.orig 2015-03-31 12:32:52 UTC ++++ lib/stdlib/src/calendar.erl +@@ -279,11 +279,19 @@ local_time_to_universal_time(DateTime, I + DateTime1 :: datetime1970(), + DateTime :: datetime1970(). + local_time_to_universal_time_dst(DateTime) -> +- UtDst = erlang:localtime_to_universaltime(DateTime, true), +- Ut = erlang:localtime_to_universaltime(DateTime, false), + %% Reverse check the universal times +- LtDst = erlang:universaltime_to_localtime(UtDst), +- Lt = erlang:universaltime_to_localtime(Ut), ++ {UtDst, LtDst} = ++ try ++ UtDst0 = erlang:localtime_to_universaltime(DateTime, true), ++ {UtDst0, erlang:universaltime_to_localtime(UtDst0)} ++ catch error:badarg -> {error, error} ++ end, ++ {Ut, Lt} = ++ try ++ Ut0 = erlang:localtime_to_universaltime(DateTime, false), ++ {Ut0, erlang:universaltime_to_localtime(Ut0)} ++ catch error:badarg -> {error, error} ++ end, + %% Return the valid universal times + case {LtDst,Lt} of + {DateTime,DateTime} when UtDst =/= Ut -> diff --git a/lang/erlang-runtime19/files/pkg-message.in b/lang/erlang-runtime19/files/pkg-message.in new file mode 100644 index 000000000000..fe91d05701d4 --- /dev/null +++ b/lang/erlang-runtime19/files/pkg-message.in @@ -0,0 +1,6 @@ +=========================================================================== + +To use this runtime port for development or testing, just prepend +its binary path ("%%LOCALBASE%%/lib/%%ERLANG_LIB%%/bin") to your PATH variable. + +=========================================================================== diff --git a/lang/erlang-runtime19/pkg-descr b/lang/erlang-runtime19/pkg-descr new file mode 100644 index 000000000000..3d60aa326c5d --- /dev/null +++ b/lang/erlang-runtime19/pkg-descr @@ -0,0 +1,10 @@ +Erlang is a programming language used to build massively scalable soft +real-time systems with requirements on high availability. Some of its +uses are in telecoms, banking, e-commerce, computer telephony and +instant messaging. Erlang's runtime system has built-in support for +concurrency, distribution and fault tolerance. + +This port contains a standalone runtime environment of Erlang 19 +to be used during the development of OTP applications. + +WWW: http://www.erlang.org/ |