diff options
author | Joel Sherrill <joel.sherrill@OARcorp.com> | 2009-02-19 19:55:40 +0000 |
---|---|---|
committer | Joel Sherrill <joel.sherrill@OARcorp.com> | 2009-02-19 19:55:40 +0000 |
commit | 89376b7141edb6f927fb940c27391cda6e67c785 (patch) | |
tree | 57dd01fd9328b879289493ba848ae5c34c607b91 /m4/rtems-trim-builddir.m4 | |
download | libbsdport-89376b7141edb6f927fb940c27391cda6e67c785.tar.bz2 |
Initial import.initial
Diffstat (limited to 'm4/rtems-trim-builddir.m4')
-rw-r--r-- | m4/rtems-trim-builddir.m4 | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/m4/rtems-trim-builddir.m4 b/m4/rtems-trim-builddir.m4 new file mode 100644 index 0000000..ffd94d6 --- /dev/null +++ b/m4/rtems-trim-builddir.m4 @@ -0,0 +1,26 @@ +# Takes one argument +# +# TILLAC_RTEMS_TRIM_CONFIG_DIR(dirvar) +# +# If 'srcdir' is a absolute path (a string +# starting with '/' then set 'dirvar' to the +# empty string; otherwise (srcdir is a relative path) +# set 'dirvar' to '../'. +# +# This macro can be used to find 'srcdir' should +# configure decide to step into a subdirectory inside +# a build tree. +# +AC_DEFUN([TILLAC_RTEMS_TRIM_CONFIG_DIR], + [AC_MSG_NOTICE([Trimming source directory]) + # leave absolute path alone, relative path needs + # to step one level up + case $srcdir in + /* ) + $1= + ;; + *) + $1=../ + ;; + esac]dnl +) |