From: Ben Webb Date: Mon, 13 Jun 2011 12:13:44 +0000 (+0100) Subject: Revert "Respect DESTDIR during install" X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=refs%2Fheads%2Fpackaging;p=opensrf%2Fbjwebb.git Revert "Respect DESTDIR during install" This reverts commit 82960e21029d4fcf2af69a6ebf94b46eb8c98e49. --- diff --git a/Makefile.am b/Makefile.am index 7b137aa..048b766 100644 --- a/Makefile.am +++ b/Makefile.am @@ -118,10 +118,10 @@ endif SUBDIRS = src tests jserver: - $(MAKE) -s -C src jserver + make -s -C src jserver jserver-install: - $(MAKE) -s -C src jserver-install + make -s -C src jserver-install distclean-local: rm -rf ./autom4te.cache diff --git a/src/Makefile.am b/src/Makefile.am index 74227f6..18fe85c 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -57,11 +57,11 @@ endif SUBDIRS = $(MAYBE_CORE) $(MAYBE_PY) $(MAYBE_JA) install-exec-local: - $(MKDIR_P) $(DESTDIR)$(VAR) - $(MKDIR_P) $(DESTDIR)$(PID) - $(MKDIR_P) $(DESTDIR)$(LOG) - $(MKDIR_P) $(DESTDIR)$(SOCK) - $(MKDIR_P) $(DESTDIR)$(jsdir) + $(MKDIR_P) $(VAR) + $(MKDIR_P) $(PID) + $(MKDIR_P) $(LOG) + $(MKDIR_P) $(SOCK) + $(MKDIR_P) $(jsdir) install-exec-hook: if [ "$(MAYBE_CORE)" ]; then \ @@ -72,7 +72,7 @@ install-exec-hook: rm "$(DESTDIR)@sysconfdir@/$${f}.bak" ; \ done; \ fi - cp -r @srcdir@/javascript/* $(DESTDIR)$(jsdir)/ + cp -r @srcdir@/javascript/* $(jsdir)/ uninstall-hook: rm -f @includedir@/opensrf/apachetools.h diff --git a/src/gateway/Makefile.am b/src/gateway/Makefile.am index f777b06..0eb5706 100644 --- a/src/gateway/Makefile.am +++ b/src/gateway/Makefile.am @@ -19,18 +19,16 @@ AM_LDFLAGS = -L$(LIBDIR) -L@top_builddir@/src/libopensrf DISTCLEANFILES = Makefile.in Makefile -APACHE_DEPS = apachetools.c apachetools.h -LIBS=libopensrf.so -TARGETS = osrf_json_gateway.la osrf_http_translator.la - -all: $(TARGETS) - -osrf_json_gateway.la: osrf_json_gateway.c $(APACHE_DEPS) - $(APXS2) -c $(DEF_LDLIBS) $(AM_CFLAGS) $(AM_LDFLAGS) $^ $(LIBS) - -osrf_http_translator.la: osrf_http_translator.c $(APACHE_DEPS) - $(APXS2) -c $(DEF_LDLIBS) $(AM_CFLAGS) $(AM_LDFLAGS) $^ $(LIBS) - +install-exec-local: + d=`$(APXS2) -q SYSCONFDIR` && \ + if ! grep mod_placeholder $${d}/httpd.conf 2>&1 >/dev/null ; \ + then echo -e "#\n#LoadModule mod_placeholder /usr/lib/apache2/modules/mod_placeholder.so" \ + >> $${d}/httpd.conf; \ + fi + $(APXS2) -c $(DEF_LDLIBS) $(AM_CFLAGS) $(AM_LDFLAGS) @srcdir@/osrf_json_gateway.c apachetools.c apachetools.h libopensrf.so + $(APXS2) -c $(DEF_LDLIBS) $(AM_CFLAGS) $(AM_LDFLAGS) @srcdir@/osrf_http_translator.c apachetools.c apachetools.h libopensrf.so + $(APXS2) -i -a @srcdir@/osrf_json_gateway.la + $(APXS2) -i -a @srcdir@/osrf_http_translator.la clean-local: rm -f @srcdir@/osrf_http_translator.la @srcdir@/osrf_http_translator.lo @srcdir@/osrf_http_translator.slo @srcdir@/osrf_json_gateway.la @srcdir@/osrf_json_gateway.lo @srcdir@/osrf_json_gateway.slo diff --git a/src/perl/Makefile.am b/src/perl/Makefile.am index 3a24eaa..0d27bfa 100644 --- a/src/perl/Makefile.am +++ b/src/perl/Makefile.am @@ -21,7 +21,6 @@ check: build-perl ./Build test || make -s build-perl-fail install: build-perl - perl Build.PL --destdir $(DESTDIR) || make -s build-perl-fail ./Build install build-perl: