Makefile.am     |  5 +++++
 Makefile.common |  2 ++
 2 files changed, 7 insertions(+), 0 deletions(-)


New make system variable for pkgetfxml added to make it possible to install
template ETF xml files. Such files will be installed by default in:
/usr[/local]/share/opensaf/etfxml/services

If the string xxCLCCLIDIRxx is used in the ETF it will be replaced after install
with the real CLCCLIDIR (typically /usr/lib/opensaf/clc-cli)

This is the same pattern as for IMM xml files.

diff --git a/Makefile.am b/Makefile.am
--- a/Makefile.am
+++ b/Makefile.am
@@ -87,6 +87,8 @@ configmake.h: Makefile
        echo '#define MANDIR "$(mandir)"'; \
        echo '#define MANEXT "$(manext)"'; \
        echo '#define PKGDATADIR "$(pkgdatadir)"'; \
+       echo '#define PKGETFXMLDIR "$(pkgetfxmldir)"'; \
+       echo '#define PKGETFXMLSVCDIR "$(pkgetfxmldir_svcdir)"'; \
        echo '#define PKGINCLUDEDIR "$(pkgincludedir)"'; \
        echo '#define PKGLIBDIR "$(pkglibdir)"'; \
        echo '#define PKGLIBEXECDIR "$(pkglibexecdir)"'; \
@@ -232,6 +234,9 @@ install-data-hook:
                sed --follow-symlinks -i 's|xxLIBDIRxx|$(pkglibdir)|g' "$$i"; \
                sed --follow-symlinks -i 's|xxCLCCLIDIRxx|$(pkgclcclidir)|g' 
"$$i"; \
        done
+       @for i in $$(grep -lr -e 'xxCLCCLIDIRxx' 
$(DESTDIR)$(pkgetfxml_svcdir)/*.xml) ; do \
+               sed -i 's|xxCLCCLIDIRxx|$(pkgclcclidir)|g' "$$i"; \
+       done
 
 uninstall-hook:
        -rm -rf $(DESTDIR)$(pkgsysconfdir)
diff --git a/Makefile.common b/Makefile.common
--- a/Makefile.common
+++ b/Makefile.common
@@ -24,6 +24,8 @@ pkglocalstatedir = $(localstatedir)/lib/
 pkgpiddir = $(localstatedir)/run/$(PACKAGE_NAME)
 pkglogdir = $(localstatedir)/log/$(PACKAGE_NAME)
 pkgconfigdir = $(libdir)/pkgconfig
+pkgetfxmldir = $(pkgdatadir)/etfxml
+pkgetfxml_svcdir = $(pkgetfxmldir)/services
 pkgimmxmldir = $(pkgdatadir)/immxml
 pkgimmxml_svcdir = $(pkgimmxmldir)/services
 pkgclcclidir = $(pkglibdir)/clc-cli

------------------------------------------------------------------------------
Start Your Social Network Today - Download eXo Platform
Build your Enterprise Intranet with eXo Platform Software
Java Based Open Source Intranet - Social, Extensible, Cloud Ready
Get Started Now And Turn Your Intranet Into A Collaboration Platform
http://p.sf.net/sfu/ExoPlatform
_______________________________________________
Opensaf-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/opensaf-devel

Reply via email to