diff options
author | Ben Gamari <ben@smart-cactus.org> | 2018-04-13 14:18:03 -0400 |
---|---|---|
committer | Ben Gamari <ben@smart-cactus.org> | 2018-04-13 14:18:04 -0400 |
commit | 4b831c27926d643b0b6fad82c1e946d05cde8645 (patch) | |
tree | ae70635e03cab98877a3abeb632c8b24e1259050 /configure.ac | |
parent | 9e89092d4ee1effd558757361fb62b83697f8f42 (diff) | |
download | haskell-4b831c27926d643b0b6fad82c1e946d05cde8645.tar.gz |
Configure option to disable dtrace
Reviewers: hvr, bgamari
Subscribers: lelf, thomie, carter
Differential Revision: https://phabricator.haskell.org/D4575
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 20 |
1 files changed, 15 insertions, 5 deletions
diff --git a/configure.ac b/configure.ac index 062004d904..a8b8681a36 100644 --- a/configure.ac +++ b/configure.ac @@ -806,13 +806,23 @@ dnl if GNU patch is named gpatch, look for it first AC_PATH_PROGS(PatchCmd,gpatch patch, patch) dnl ** check for dtrace (currently only implemented for Mac OS X) +AC_ARG_ENABLE(dtrace, + [AC_HELP_STRING([--enable-dtrace], + [Enable DTrace])], + EnableDtrace=$enableval, + EnableDtrace=yes +) + HaveDtrace=NO + AC_PATH_PROG(DtraceCmd,dtrace) -if test -n "$DtraceCmd"; then - if test "x$TargetOS_CPP-$TargetVendor_CPP" = "xdarwin-apple" \ - -o "x$TargetOS_CPP-$TargetVendor_CPP" = "xfreebsd-portbld" \ - -o "x$TargetOS_CPP-$TargetVendor_CPP" = "xsolaris2-unknown"; then - HaveDtrace=YES +if test "x$EnableDtrace" = "xyes"; then + if test -n "$DtraceCmd"; then + if test "x$TargetOS_CPP-$TargetVendor_CPP" = "xdarwin-apple" \ + -o "x$TargetOS_CPP-$TargetVendor_CPP" = "xfreebsd-portbld" \ + -o "x$TargetOS_CPP-$TargetVendor_CPP" = "xsolaris2-unknown"; then + HaveDtrace=YES + fi fi fi AC_SUBST(HaveDtrace) |