]> git.proxmox.com Git - mirror_lxc.git/commitdiff
fix expansion of LXCPATH,LXCROOTFSMOUNT,LXCTEMPLATEDIR
authorDwight Engen <dwight.engen@oracle.com>
Tue, 11 Sep 2012 21:06:05 +0000 (17:06 -0400)
committerStéphane Graber <stgraber@ubuntu.com>
Thu, 25 Oct 2012 08:34:28 +0000 (10:34 +0200)
These variables are not expanded correctly in doc/lxc-create.sgml.in
and a workaround is in place to ensure ${localstatedir}, and ${datadir}
are set in the various shell scripts that use it. There is no workaround
to ensure ${datadir} is set in src/lxc/lxc-create.in, nor is
${localstatedir} set in templates/lxc-altlinux.in so I think that these
are currently broken.

Using AS_AC_EXPAND instead of AC_SUBST fixes these problems and removes
the need for the workarounds. In addition the lxc-start-ephemeral.in
script can be autoconf'ed instead of sed'ed by the makefile.

Signed-off-by: Dwight Engen <dwight.engen@oracle.com>
configure.ac
src/lxc/lxc-clone.in
src/lxc/lxc-create.in
src/lxc/lxc-destroy.in
src/lxc/lxc-ls.in
src/lxc/lxc-setcap.in
src/lxc/lxc-setuid.in

index 6c61c7926a29532e6aa5c7c6ff76e45ae325962e..32e04678fba0be78b09f43ee1f16852b8864149f 100644 (file)
@@ -70,11 +70,11 @@ AC_ARG_WITH([rootfs-path],
        )], [], [with_rootfs_path=['${libdir}/lxc/rootfs']])
 
 AS_AC_EXPAND(LXC_GENERATE_DATE, "$(date)")
+AS_AC_EXPAND(LXCPATH, "${with_config_path}")
+AS_AC_EXPAND(LXCROOTFSMOUNT, "${with_rootfs_path}")
+AS_AC_EXPAND(LXCTEMPLATEDIR, ['${datadir}/lxc/templates'])
 
-AC_SUBST(LXCPATH, "${with_config_path}")
-AC_SUBST(LXCROOTFSMOUNT, "${with_rootfs_path}")
 AC_SUBST(LXCINITDIR, ['${libexecdir}'])
-AC_SUBST(LXCTEMPLATEDIR, ['${datadir}/lxc/templates'])
 
 AC_CHECK_HEADERS([linux/unistd.h linux/netlink.h linux/genetlink.h],
                                  [],
@@ -170,6 +170,7 @@ AC_CONFIG_FILES([
        src/lxc/lxc-create
        src/lxc/lxc-clone
        src/lxc/lxc-shutdown
+       src/lxc/lxc-start-ephemeral
        src/lxc/lxc-destroy
 
 ])
index c373861fc7d83cab4c680e7796ce4723d66d93ed..920be7b641aed185754c8dcadb9a131ff890caea 100644 (file)
@@ -46,7 +46,6 @@ help() {
 
 shortoptions='ho:n:sL:v:p:t:'
 longoptions='help,orig:,name:,snapshot,fssize:,vgname:,lvprefix:,fstype:'
-localstatedir=@LOCALSTATEDIR@
 lxc_path=@LXCPATH@
 bindir=@BINDIR@
 snapshot=no
index cca415730733aebc4546035b1834e98aea9e5069..b21cdc301e0390e8f6f9ad1a9dc8fd097efc5e72 100644 (file)
@@ -62,10 +62,8 @@ help() {
 
 shortoptions='hn:f:t:B:'
 longoptions='help,name:,config:,template:,backingstore:,fstype:,lvname:,vgname:,fssize:'
-localstatedir=@LOCALSTATEDIR@
 lxc_path=@LXCPATH@
 bindir=@BINDIR@
-libdir=@LIBDIR@
 templatedir=@LXCTEMPLATEDIR@
 backingstore=_unset
 fstype=ext4
index 5ae572213daf43096eb0f315c3a7b7e60f3625b3..683ab28a4833900e4a5caab60a43579438c3405e 100644 (file)
@@ -41,7 +41,6 @@ help() {
 
 shortoptions='hn:f'
 longoptions='help,name:'
-localstatedir=@LOCALSTATEDIR@
 lxc_path=@LXCPATH@
 force=0
 
index ea3805470fdaacd9f970f9a4a37409056f88893b..009bb2ed71f609ee6c850a32a97518fd7b43d381 100644 (file)
@@ -17,7 +17,6 @@
 # License along with this library; if not, write to the Free Software
 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
 
-localstatedir=@LOCALSTATEDIR@
 lxc_path=@LXCPATH@
 
 usage()
index 71e3710cbb76d33714153e55c4db329a2fb7afef..7fd390c0051f56d8f52a9d7e143f8c66d9b4627f 100644 (file)
@@ -83,9 +83,6 @@ lxc_dropcaps()
 
 shortoptions='hd'
 longoptions='help'
-libdir=@LIBDIR@
-libexecdir=@LIBEXECDIR@
-localstatedir=@LOCALSTATEDIR@
 
 getopt=$(getopt -o $shortoptions --longoptions  $longoptions -- "$@")
 if [ $? != 0 ]; then
index 020dfae1768a6a26792ac111ca68662dee5c54cd..84f18af5957d4184648d5138cf2218e21ac57936 100644 (file)
@@ -80,9 +80,6 @@ lxc_dropuid()
 
 shortoptions='hd'
 longoptions='help'
-libdir=@LIBDIR@
-libexecdir=@LIBEXECDIR@
-localstatedir=@LOCALSTATEDIR@
 
 getopt=$(getopt -o $shortoptions --longoptions  $longoptions -- "$@")
 if [ $? != 0 ]; then