summaryrefslogtreecommitdiff
path: root/math/octave-current
diff options
context:
space:
mode:
authordmcmahill <dmcmahill@pkgsrc.org>2004-08-14 01:31:56 +0000
committerdmcmahill <dmcmahill@pkgsrc.org>2004-08-14 01:31:56 +0000
commit9081266196459e56cef13732638e0bbd7fee7de5 (patch)
treee9cd91575244cbc254455364699e5f0d624c655a /math/octave-current
parente813d8944fb76bcb79d61248544ebc09f4564b00 (diff)
downloadpkgsrc-9081266196459e56cef13732638e0bbd7fee7de5.tar.gz
add octave.mk that can be used by other pkgs to find some paths used by octave
Diffstat (limited to 'math/octave-current')
-rw-r--r--math/octave-current/octave.mk25
1 files changed, 25 insertions, 0 deletions
diff --git a/math/octave-current/octave.mk b/math/octave-current/octave.mk
new file mode 100644
index 00000000000..3f35734987d
--- /dev/null
+++ b/math/octave-current/octave.mk
@@ -0,0 +1,25 @@
+# $NetBSD: octave.mk,v 1.1 2004/08/14 01:31:56 dmcmahill Exp $
+#
+
+.include "../../mk/bsd.prefs.mk"
+
+OCTAVE_CONFIG= ${LOCALBASE}/bin/octave-config
+
+# OCTAVE_VARS is a list of variables to define in the make environment.
+# This may be overridden in an octave add-on package Makefile.
+#
+OCTAVE_VARS?= LOCALVERFCNFILEDIR LOCALVEROCTFILEDIR LOCALVERARCHLIBDIR VERSION
+
+# Set OCT_<var> to the value of <var> as returned by octave-config.
+.if !empty(PHASES_AFTER_EXTRACT:M${PKG_PHASE})
+. if exists(${OCTAVE_CONFIG})
+. for _var_ in ${OCTAVE_VARS}
+. if !defined(OCT_${_var_})
+OCT_${_var_}!= ${OCTAVE_CONFIG} -p ${_var_}
+. endif
+. endfor
+. undef _var_
+. endif
+.endif
+
+