]> git.ipfire.org Git - thirdparty/lxc.git/commitdiff
Q: general lxc architecture
authorAndrian Nord <nightnord@gmail.com>
Fri, 13 Nov 2009 10:48:29 +0000 (11:48 +0100)
committerDaniel Lezcano <dlezcano@fr.ibm.com>
Fri, 13 Nov 2009 10:48:29 +0000 (11:48 +0100)
Patch moves etc/* contents into doc/examples/ and adds
--disable-examples configure switch which may be used not to install
examples. Default is to install them into ${docdir}/examples (commonly:
/usr/share/doc/lxc/examples)

Signed-off-by: Andrian Nord <NightNord@gmail.com>
Signed-off-by: Daniel Lezcano <dlezcano@fr.ibm.com>
Makefile.am
configure.ac
doc/Makefile.am
doc/examples/Makefile.am [moved from etc/Makefile.am with 70% similarity]
doc/examples/lxc-complex-config.in [moved from etc/lxc-complex-config.in with 99% similarity]
doc/examples/lxc-empty-netns.conf.in [moved from etc/lxc-empty-netns.conf.in with 100% similarity]
doc/examples/lxc-macvlan.conf.in [moved from etc/lxc-macvlan.conf.in with 100% similarity]
doc/examples/lxc-no-netns.conf.in [moved from etc/lxc-no-netns.conf.in with 100% similarity]
doc/examples/lxc-phys.conf.in [moved from etc/lxc-phys.conf.in with 100% similarity]
doc/examples/lxc-veth.conf.in [moved from etc/lxc-veth.conf.in with 100% similarity]
etc/.cvsignore [deleted file]

index 3933d2a9520cacf3e08e5ad32bcb6820982446f4..90b771bd1efec4ec4bba5431ab2c726d04c7ee52 100644 (file)
@@ -2,8 +2,8 @@
 
 ACLOCAL_AMFLAGS = -I config
 
-SUBDIRS = src etc scripts doc
-DIST_SUBDIRS = config src etc scripts doc
+SUBDIRS = src scripts doc
+DIST_SUBDIRS = config src scripts doc
 EXTRA_DIST = autogen.sh lxc.spec CONTRIBUTING MAINTAINERS ChangeLog
 
 pcdatadir = $(datadir)/pkgconfig
index 75c8fd0ccbb731bcad68bd2688cf8b128a8d5556..2713053c7cbaf4d69d914a13e80d808ca492be15 100644 (file)
@@ -25,6 +25,12 @@ fi
 
 AM_CONDITIONAL([ENABLE_DOCBOOK], [test "x$have_docbook" = "xyes"])
 
+AC_ARG_ENABLE([examples],
+       [AC_HELP_STRING([--disable-examples], [do not install configuration examples])],
+       [], [enable_examples=yes])
+
+AM_CONDITIONAL([ENABLE_EXAMPLES], [test "x$enable_examples" = "xyes"])
+
 AS_AC_EXPAND(PREFIX, $prefix)
 AS_AC_EXPAND(LIBDIR, $libdir)
 AS_AC_EXPAND(BINDIR, $bindir)
@@ -103,13 +109,13 @@ AC_CONFIG_FILES([
        src/lxc/lxc-create
        src/lxc/lxc-destroy
 
-       etc/Makefile
-       etc/lxc-macvlan.conf
-       etc/lxc-no-netns.conf
-       etc/lxc-empty-netns.conf
-       etc/lxc-phys.conf
-       etc/lxc-veth.conf
-       etc/lxc-complex-config
+       doc/examples/Makefile
+       doc/examples/lxc-macvlan.conf
+       doc/examples/lxc-no-netns.conf
+       doc/examples/lxc-empty-netns.conf
+       doc/examples/lxc-phys.conf
+       doc/examples/lxc-veth.conf
+       doc/examples/lxc-complex-config
 ])
 AC_CONFIG_COMMANDS([default],[[]],[[]])
 AC_OUTPUT
index 9f7bf695e89cc19ff4e405871a43716cef85e595..bd96c9933a98dbd280edb7f6a0fedbe459ca0657 100644 (file)
@@ -1,3 +1,5 @@
+SUBDIRS = examples
+DIST_SUBDIRS = examples
 
 EXTRA_DIST = \
        FAQ.txt \
similarity index 70%
rename from etc/Makefile.am
rename to doc/examples/Makefile.am
index aa7cc66d5ebf411792bb06a635d578bfbce2701c..0490a8b2100441e7f530b07fb35ae5303bad391a 100644 (file)
@@ -1,11 +1,17 @@
-pkgsysconfdir = $(sysconfdir)/$(PACKAGE)
-pkgsysconf_DATA = \
+EXTRA_DIST = $(pkgexamples_DATA)
+
+if ENABLE_EXAMPLES
+pkgexamplesdir=$(docdir)/examples
+
+pkgexamples_DATA = \
        lxc-macvlan.conf \
        lxc-no-netns.conf \
        lxc-empty-netns.conf \
        lxc-phys.conf \
        lxc-veth.conf \
        lxc-complex-config
+endif
+
 noinst_DATA = \
        lxc-macvlan.conf.in \
        lxc-empty-netns.conf.in \
similarity index 99%
rename from etc/lxc-complex-config.in
rename to doc/examples/lxc-complex-config.in
index f2e8ea31ca031c0a43d15bd5d035d482f74bc1b4..9d761cb2d5d342967be516a38d72c1c0938fb273 100644 (file)
@@ -1,4 +1,4 @@
-# Container with network a complex network mixing macvlan, veth and 
+# Container with network a complex network mixing macvlan, veth and
 # physical network devices
 lxc.utsname = complex
 lxc.network.type = veth
diff --git a/etc/.cvsignore b/etc/.cvsignore
deleted file mode 100644 (file)
index 72d0ae4..0000000
+++ /dev/null
@@ -1,9 +0,0 @@
-Makefile
-Makefile.in
-lxc-complex-config
-lxc-empty-netns.conf
-lxc-macvlan.conf
-lxc-no-netns.conf
-lxc-phys.conf
-lxc-veth.conf
-