summaryrefslogtreecommitdiffstats
path: root/lib/buildsystem.sh
diff options
context:
space:
mode:
authorP. J. McDermott <pjm@nac.net>2012-11-13 11:10:09 (EST)
committer P. J. McDermott <pjm@nac.net>2012-11-13 11:10:09 (EST)
commitd3308a72c42a2be520cfeca4f372119e46b64f76 (patch)
tree548bf20f07a99e9857d774ec430ff616110f6590 /lib/buildsystem.sh
parent1fc71242b873815c7c2d8d50a49169d76b585c12 (diff)
Make the source directory configurable.
Diffstat (limited to 'lib/buildsystem.sh')
-rw-r--r--lib/buildsystem.sh6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/buildsystem.sh b/lib/buildsystem.sh
index 1be5e1d..9524835 100644
--- a/lib/buildsystem.sh
+++ b/lib/buildsystem.sh
@@ -34,8 +34,9 @@ oh_buildsystems_init()
done
_OH_BUILDSYSTEM_WORK_AREA="${PWD}"
- _OH_BUILDSYSTEM_SOURCE_DIR="$(cd src && pwd)"
+ [ -z "${_OH_BUILDSYSTEM_SOURCE_DIR}" ] && \
+ _OH_BUILDSYSTEM_SOURCE_DIR="${PWD}/src"
[ -z "${_OH_BUILDSYSTEM_BUILD_DIR}" ] && \
_OH_BUILDSYSTEM_BUILD_DIR="${PWD}/src"
[ -z "${_OH_BUILDSYSTEM_DESTDIR}" ] && \
@@ -57,6 +58,9 @@ oh_set_buildsystem_option()
fi
case "${_ohsbso_name}" in
+ 'source-dir')
+ _OH_BUILDSYSTEM_SOURCE_DIR="${_ohbsbo_value}"
+ ;;
'build-dir')
_OH_BUILDSYSTEM_BUILD_DIR="${_ohsbso_value}"
;;