summaryrefslogtreecommitdiff
path: root/lang
diff options
context:
space:
mode:
authorfhajny <fhajny@pkgsrc.org>2012-04-16 07:28:14 +0000
committerfhajny <fhajny@pkgsrc.org>2012-04-16 07:28:14 +0000
commit5cb8d1254303fa40623fb271f170b6077a449666 (patch)
treefbe7dd985fda3146822346ee72a38cb7d0b119ce /lang
parent01da6dc29f358beb4ad6f8a9713badd9a7bf4e56 (diff)
downloadpkgsrc-5cb8d1254303fa40623fb271f170b6077a449666.tar.gz
Add DTrace (SystemTap resp.) support for relevant platforms
Diffstat (limited to 'lang')
-rw-r--r--lang/erlang/PLIST3
-rw-r--r--lang/erlang/options.mk21
2 files changed, 21 insertions, 3 deletions
diff --git a/lang/erlang/PLIST b/lang/erlang/PLIST
index 4bf10f6c3d8..72e54a8b38a 100644
--- a/lang/erlang/PLIST
+++ b/lang/erlang/PLIST
@@ -1,4 +1,4 @@
-@comment $NetBSD: PLIST,v 1.9 2012/04/12 12:14:12 asau Exp $
+@comment $NetBSD: PLIST,v 1.10 2012/04/16 07:28:14 fhajny Exp $
bin/ct_run
bin/dialyzer
bin/epmd
@@ -3481,6 +3481,7 @@ lib/erlang/lib/runtime_tools-${VERSION.runtime_tools}/include/observer_backend.h
lib/erlang/lib/runtime_tools-${VERSION.runtime_tools}/priv/lib/dyntrace.so
lib/erlang/lib/runtime_tools-${VERSION.runtime_tools}/priv/lib/trace_file_drv.so
lib/erlang/lib/runtime_tools-${VERSION.runtime_tools}/priv/lib/trace_ip_drv.so
+${PLIST.dtrace}lib/erlang/lib/runtime_tools-${VERSION.runtime_tools}/priv/obj/dtrace_user.o
lib/erlang/lib/runtime_tools-${VERSION.runtime_tools}/priv/obj/dyntrace.o
lib/erlang/lib/runtime_tools-${VERSION.runtime_tools}/src/dbg.erl
lib/erlang/lib/runtime_tools-${VERSION.runtime_tools}/src/dyntrace.erl
diff --git a/lang/erlang/options.mk b/lang/erlang/options.mk
index 4fbcbebc7bb..0cf0ef094f1 100644
--- a/lang/erlang/options.mk
+++ b/lang/erlang/options.mk
@@ -1,4 +1,4 @@
-# $NetBSD: options.mk,v 1.4 2011/04/14 19:34:07 asau Exp $
+# $NetBSD: options.mk,v 1.5 2012/04/16 07:28:14 fhajny Exp $
PKG_OPTIONS_VAR= PKG_OPTIONS.erlang
PKG_SUPPORTED_OPTIONS= java erlang-hipe
@@ -16,9 +16,14 @@ PKG_SUGGESTED_OPTIONS= # empty
PKG_SUGGESTED_OPTIONS+= erlang-hipe
.endif
+.if ${OPSYS} == "SunOS" || ${OPSYS} == "Darwin" || ${OPSYS} == "FreeBSD" || \
+ ${OPSYS} == "Linux"
+PKG_SUPPORTED_OPTIONS+= dtrace
+.endif
+
.include "../../mk/bsd.options.mk"
-PLIST_VARS+= odbc
+PLIST_VARS+= odbc dtrace
.if !empty(PKG_OPTIONS:Mjava)
USE_JAVA= yes
@@ -51,6 +56,18 @@ CONFIGURE_ARGS+= --with-odbc=${BUILDLINK_PREFIX.unixodbc}
PLIST.odbc= yes
.endif
+###
+### DTrace support
+###
+.if !empty(PKG_OPTIONS:Mdtrace)
+. if ${OPSYS} == "SunOS" || ${OPSYS} == "Darwin" || ${OPSYS} == "FreeBSD"
+CONFIGURE_ARGS+= --with-dynamic-trace=dtrace
+. elif ${OPSYS} == "Linux"
+CONFIGURE_ARGS+= --with-dynamic-trace=systemtap
+. endif
+PLIST.dtrace= yes
+.endif
+
# Help generate optional PLIST parts:
PRINT_PLIST_AWK+= {if ($$0 ~ /\/erlang\/lib\/hipe-${VERSION.hipe}\//) {$$0 = "$${PLIST.hipe}" $$0;}}
PRINT_PLIST_AWK+= {if ($$0 ~ /\/erlang\/lib\/odbc-${VERSION.odbc}\//) {$$0 = "$${PLIST.odbc}" $$0;}}