THRIFT-784. erl: Fix two problems with "make install"

- Support DESTDIR.
- Pass proper arguments to install.

git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@945898 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
David Reiss 2010-05-18 21:32:16 +00:00
parent 9e2fd7987d
commit d09f09c89d

View File

@ -26,16 +26,16 @@ all clean docs:
done
install: all
mkdir -p $(ERLANG_INSTALL_LIB_DIR_thrift) ; \
mkdir -p $(ERLANG_INSTALL_LIB_DIR_thrift)/ebin ; \
mkdir -p $(ERLANG_INSTALL_LIB_DIR_thrift)/include ; \
mkdir -p $(ERLANG_INSTALL_LIB_DIR_thrift)/src ; \
for i in ebin/*.app* ebin/*.beam include/*.hrl src/*.erl ; \
do $(INSTALL) $$p $(ERLANG_INSTALL_LIB_DIR_thrift)/$$p ; \
mkdir -p $(DESTDIR)$(ERLANG_INSTALL_LIB_DIR_thrift) ; \
mkdir -p $(DESTDIR)$(ERLANG_INSTALL_LIB_DIR_thrift)/ebin ; \
mkdir -p $(DESTDIR)$(ERLANG_INSTALL_LIB_DIR_thrift)/include ; \
mkdir -p $(DESTDIR)$(ERLANG_INSTALL_LIB_DIR_thrift)/src ; \
for p in ebin/*.app* ebin/*.beam include/*.hrl src/*.erl ; \
do $(INSTALL) $$p $(DESTDIR)$(ERLANG_INSTALL_LIB_DIR_thrift)/$$p ; \
done
uninstall:
rm -rf $(ERLANG_INSTALL_LIB_DIR_thrift)
rm -rf $(DESTDIR)$(ERLANG_INSTALL_LIB_DIR_thrift)
maintainer-clean-local: