diff options
author | Bill Wendling <wendling@ncsa.uiuc.edu> | 2001-09-21 23:50:15 (GMT) |
---|---|---|
committer | Bill Wendling <wendling@ncsa.uiuc.edu> | 2001-09-21 23:50:15 (GMT) |
commit | 5e834c4cbc2353be2c9efd0f55dbdb23f87d9650 (patch) | |
tree | dc41435e33d8ef43faf0626d5083b0baa028d8da /config | |
parent | 813dfea5147f18f01f8326d9de8eff85536824a5 (diff) | |
download | hdf5-5e834c4cbc2353be2c9efd0f55dbdb23f87d9650.zip hdf5-5e834c4cbc2353be2c9efd0f55dbdb23f87d9650.tar.gz hdf5-5e834c4cbc2353be2c9efd0f55dbdb23f87d9650.tar.bz2 |
[svn-r4466]
Purpose:
Feature Add
Description:
Added "install-example" and "install-all" to the Makefile system.
The behaviour of the "make install*" options:
make install - Installs binaries, libraries, include
files, and example programs.
make install-examples - Installs only the example programs.
The directories are:
${prefix}/doc/hdf5/examples/{c,c++,fortran}
make install-all - Install the binaries, libraries, include
files, example programs, and
documentation. The whole kit-n'-caboodle.
make uninstall-examples - Get rid of those example files (but not
the ${prefix}/doc/hdf5/examples/...
directories)
There's a new bin/ program which helps create directories which are
deeply nested called "mkdirs". It's a simple shell script.
Platforms tested:
Linux
Diffstat (limited to 'config')
-rw-r--r-- | config/commence.in | 1 | ||||
-rw-r--r-- | config/conclude.in | 26 |
2 files changed, 23 insertions, 4 deletions
diff --git a/config/commence.in b/config/commence.in index b0b987c..878bd89 100644 --- a/config/commence.in +++ b/config/commence.in @@ -59,6 +59,7 @@ LT_UNINSTALL=$(LT) --mode=uninstall $(RM) ## defined. The main makefile is free to redefine these to something else. DOCDIR=$(docdir) SUBDOCDIR= +EXAMPLEDIR=$(docdir) LIB= LIB_SRC= LIB_OBJ= diff --git a/config/conclude.in b/config/conclude.in index c24a87e..07a9040 100644 --- a/config/conclude.in +++ b/config/conclude.in @@ -84,13 +84,19 @@ check test _test: tests ## Make installation directories directories if they don't exist. ## $(libdir): - mkdir $@ && chmod 755 $@ + $(top_srcdir)/bin/mkdirs $@ $(includedir): - mkdir $@ && chmod 755 $@ + $(top_srcdir)/bin/mkdirs $@ $(bindir): - mkdir $@ && chmod 755 $@ + $(top_srcdir)/bin/mkdirs $@ + +$(DOCDIR): + $(top_srcdir)/bin/mkdirs $@ + +$(EXAMPLEDIR): + $(top_srcdir)/bin/mkdirs $@ ## Install the library, the public header files, and public programs. ## @@ -124,9 +130,21 @@ install: $(PUB_LIB) $(PUB_HDR) $(PUB_PROGS) $(libdir) $(includedir) $(bindir) fi; \ done +install-examples: $(EXAMPLE_PROGS) $(EXAMPLEDIR) + @for f in X $(EXAMPLE_PROGS); do \ + if test $$f != X; then \ + (set -x; $(INSTALL_DATA) $(srcdir)/$$f $(EXAMPLEDIR)/. || exit 1);\ + fi; \ + done + +uninstall-examples: + @if test -n "$(EXAMPLE_PROGS)"; then \ + set -x; cd $(EXAMPLEDIR) && $(RM) $(EXAMPLE_PROGS); \ + fi + ## Install the documents. ## -install-doc: $(PUB_DOCS) +install-doc: $(PUB_DOCS) $(DOCDIR) @if test -n "$(DOCDIR)"; then \ if test -d "$(DOCDIR)"; then \ :; \ |