summaryrefslogtreecommitdiff
path: root/source4/heimdal_build/et_compile_wrapper.sh
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2007-01-15 13:28:09 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 14:43:32 -0500
commit1d6456fd6087c16bd6587768be6f8d81d94164db (patch)
treefbb7dfceaf5a82cfefc4b47a1b896783bbcdd55b /source4/heimdal_build/et_compile_wrapper.sh
parent5de50f5a66f006bdeae38c7eeb7c6f7e947c10d8 (diff)
downloadsamba-1d6456fd6087c16bd6587768be6f8d81d94164db.tar.gz
samba-1d6456fd6087c16bd6587768be6f8d81d94164db.tar.bz2
samba-1d6456fd6087c16bd6587768be6f8d81d94164db.zip
r20804: work arround HPUX and Tru64 make which don't like $$startdir
we now call asn1_compile and compile_et via a wrapper script metze (This used to be commit a5b67f5c7e78d3cf74668c7c6bf9aecd8e147d41)
Diffstat (limited to 'source4/heimdal_build/et_compile_wrapper.sh')
-rwxr-xr-xsource4/heimdal_build/et_compile_wrapper.sh66
1 files changed, 66 insertions, 0 deletions
diff --git a/source4/heimdal_build/et_compile_wrapper.sh b/source4/heimdal_build/et_compile_wrapper.sh
new file mode 100755
index 0000000000..a1cb5b311c
--- /dev/null
+++ b/source4/heimdal_build/et_compile_wrapper.sh
@@ -0,0 +1,66 @@
+#!/bin/sh
+#
+
+SELF=$0
+SELFDIR=`dirname ${SELF}`
+
+SRCDIR=$1
+BUILDDIR=$2
+DESTDIR=$3
+
+CMD=$4
+FILE=$5
+shift 5
+
+test -z "${SRCDIR}" && {
+ echo "${SELF}:SRCDIR: '${SRCDIR}'" >&2;
+ exit 1;
+}
+
+test -z "${BUILDDIR}" && {
+ echo "${SELF}:BUILDDIR: '${BUILDDIR}'" >&2;
+ exit 1;
+}
+
+test -z "${DESTDIR}" && {
+ echo "${SELF}:DESTDIR: '${DESTDIR}'" >&2;
+ exit 1;
+}
+
+test -z "${CMD}" && {
+ echo "${SELF}:CMD: '${CMD}'" >&2;
+ exit 1;
+}
+
+test -z "${FILE}" && {
+ echo "${SELF}:FILE: '${FILE}'" >&2;
+ exit 1;
+}
+
+CURDIR=`pwd`
+
+cd ${SRCDIR} && {
+ ABS_SRCDIR=`pwd`
+ cd ${CURDIR}
+} || {
+ echo "${SELF}:cannot cd into '${SRCDIR}'" >&2;
+ exit 1;
+}
+
+cd ${BUILDDIR} && {
+ ABS_BUILDDIR=`pwd`
+ cd ${CURDIR}
+} || {
+ echo "${SELF}:cannot cd into '${BUILDDIR}'" >&2;
+ exit 1;
+}
+
+cd ${DESTDIR} && {
+ ${ABS_BUILDDIR}/${CMD} ${ABS_SRCDIR}/${FILE} >&2 || exit 1;
+ cd ${CURDIR}
+} || {
+ echo "${SELF}:cannot cd into '${BUILDDIR}'" >&2;
+ exit 1;
+}
+
+exit 0;