summaryrefslogtreecommitdiffstats
path: root/c++
diff options
context:
space:
mode:
authorLarry Knox <lrknox@hdfgroup.org>2010-05-12 20:55:52 (GMT)
committerLarry Knox <lrknox@hdfgroup.org>2010-05-12 20:55:52 (GMT)
commitfa416bde84a8c219fa570660bbf3ec8ab16320e7 (patch)
tree5430f5c54b5d4a458859f7e9e10723c09e4e7673 /c++
parenteeeb3937624f7db68680e1074b1154adc780d516 (diff)
downloadhdf5-fa416bde84a8c219fa570660bbf3ec8ab16320e7.zip
hdf5-fa416bde84a8c219fa570660bbf3ec8ab16320e7.tar.gz
hdf5-fa416bde84a8c219fa570660bbf3ec8ab16320e7.tar.bz2
[svn-r18779] Add ${DESTDIR} to scripts and Makefiles so that make DESTDIR=<install directory> install, installcheck and uninstall is supported for installing examples, since they are now installed as part of make install. This was necessary for rpmbuilds, but should also be supported otherwise.
Tested: amani, jam, linew with committest, rpmbuild on jam and amani.
Diffstat (limited to 'c++')
-rw-r--r--c++/Makefile.in10
-rw-r--r--c++/examples/Makefile.am2
-rw-r--r--c++/examples/Makefile.in12
-rwxr-xr-xc++/examples/testh5c++.sh.in2
-rw-r--r--c++/src/Makefile.in10
-rw-r--r--c++/test/Makefile.in10
6 files changed, 23 insertions, 23 deletions
diff --git a/c++/Makefile.in b/c++/Makefile.in
index 3392766..542929d 100644
--- a/c++/Makefile.in
+++ b/c++/Makefile.in
@@ -351,11 +351,11 @@ LIBH5CPP_HL = $(top_builddir)/hl/c++/src/libhdf5_hl_cpp.la
# Scripts used to build examples
# If only shared libraries have been installed, have h5cc build examples with
# shared libraries instead of static libraries
-H5CC = $(bindir)/h5cc
-H5CC_PP = $(bindir)/h5pcc
-H5FC = $(bindir)/h5fc
-H5FC_PP = $(bindir)/h5pfc
-H5CPP = $(bindir)/h5c++
+H5CC = ${DESTDIR}/$(bindir)/h5cc
+H5CC_PP = ${DESTDIR}/$(bindir)/h5pcc
+H5FC = ${DESTDIR}/$(bindir)/h5fc
+H5FC_PP = ${DESTDIR}/$(bindir)/h5pfc
+H5CPP = ${DESTDIR}/$(bindir)/h5c++
# The trace script; this is used on source files from the C library to
# insert tracing macros.
diff --git a/c++/examples/Makefile.am b/c++/examples/Makefile.am
index 481d75f..28af8d5 100644
--- a/c++/examples/Makefile.am
+++ b/c++/examples/Makefile.am
@@ -38,7 +38,7 @@ chunks.chkexe_: extend_ds.chkexe_
CXX_API=yes
# Where to install examples
-EXAMPLEDIR=$(exec_prefix)/examples/c++
+EXAMPLEDIR=${DESTDIR}/$(exec_prefix)/share/hdf5_examples/c++
# How to build programs using h5c++
$(EXTRA_PROG): $(H5CPP)
diff --git a/c++/examples/Makefile.in b/c++/examples/Makefile.in
index e027b00..db470b0 100644
--- a/c++/examples/Makefile.in
+++ b/c++/examples/Makefile.in
@@ -317,11 +317,11 @@ LIBH5CPP_HL = $(top_builddir)/hl/c++/src/libhdf5_hl_cpp.la
# Scripts used to build examples
# If only shared libraries have been installed, have h5cc build examples with
# shared libraries instead of static libraries
-H5CC = $(bindir)/h5cc
-H5CC_PP = $(bindir)/h5pcc
-H5FC = $(bindir)/h5fc
-H5FC_PP = $(bindir)/h5pfc
-H5CPP = $(bindir)/h5c++
+H5CC = ${DESTDIR}/$(bindir)/h5cc
+H5CC_PP = ${DESTDIR}/$(bindir)/h5pcc
+H5FC = ${DESTDIR}/$(bindir)/h5fc
+H5FC_PP = ${DESTDIR}/$(bindir)/h5pfc
+H5CPP = ${DESTDIR}/$(bindir)/h5c++
# The trace script; this is used on source files from the C library to
# insert tracing macros.
@@ -346,7 +346,7 @@ INSTALL_FILES = create.cpp readdata.cpp writedata.cpp compound.cpp \
CXX_API = yes
# Where to install examples
-EXAMPLEDIR = $(exec_prefix)/examples/c++
+EXAMPLEDIR = ${DESTDIR}/$(exec_prefix)/share/hdf5_examples/c++
# Assume that all tests in this directory are examples, and tell
# conclude.am when to build them.
diff --git a/c++/examples/testh5c++.sh.in b/c++/examples/testh5c++.sh.in
index 4281e3c..f6c9fd6 100755
--- a/c++/examples/testh5c++.sh.in
+++ b/c++/examples/testh5c++.sh.in
@@ -25,7 +25,7 @@ EXIT_SUCCESS=0
EXIT_FAILURE=1
# Where the tool is installed.
-prefix="${prefix:-@prefix@}"
+prefix="${prefix:-${DESTDIR}/@prefix@}"
AR="@AR@"
RANLIB="@RANLIB@"
H5TOOL="h5c++" # The tool name
diff --git a/c++/src/Makefile.in b/c++/src/Makefile.in
index 68bdb63..9537005 100644
--- a/c++/src/Makefile.in
+++ b/c++/src/Makefile.in
@@ -373,11 +373,11 @@ LIBH5CPP_HL = $(top_builddir)/hl/c++/src/libhdf5_hl_cpp.la
# Scripts used to build examples
# If only shared libraries have been installed, have h5cc build examples with
# shared libraries instead of static libraries
-H5CC = $(bindir)/h5cc
-H5CC_PP = $(bindir)/h5pcc
-H5FC = $(bindir)/h5fc
-H5FC_PP = $(bindir)/h5pfc
-H5CPP = $(bindir)/h5c++
+H5CC = ${DESTDIR}/$(bindir)/h5cc
+H5CC_PP = ${DESTDIR}/$(bindir)/h5pcc
+H5FC = ${DESTDIR}/$(bindir)/h5fc
+H5FC_PP = ${DESTDIR}/$(bindir)/h5pfc
+H5CPP = ${DESTDIR}/$(bindir)/h5c++
# The trace script; this is used on source files from the C library to
# insert tracing macros.
diff --git a/c++/test/Makefile.in b/c++/test/Makefile.in
index def1b05..4b101e4 100644
--- a/c++/test/Makefile.in
+++ b/c++/test/Makefile.in
@@ -340,11 +340,11 @@ LIBH5CPP_HL = $(top_builddir)/hl/c++/src/libhdf5_hl_cpp.la
# Scripts used to build examples
# If only shared libraries have been installed, have h5cc build examples with
# shared libraries instead of static libraries
-H5CC = $(bindir)/h5cc
-H5CC_PP = $(bindir)/h5pcc
-H5FC = $(bindir)/h5fc
-H5FC_PP = $(bindir)/h5pfc
-H5CPP = $(bindir)/h5c++
+H5CC = ${DESTDIR}/$(bindir)/h5cc
+H5CC_PP = ${DESTDIR}/$(bindir)/h5pcc
+H5FC = ${DESTDIR}/$(bindir)/h5fc
+H5FC_PP = ${DESTDIR}/$(bindir)/h5pfc
+H5CPP = ${DESTDIR}/$(bindir)/h5c++
# The trace script; this is used on source files from the C library to
# insert tracing macros.