[lxc-devel] [PATCH 3/3] lxc-rpm-build
Stéphane Graber
stgraber at ubuntu.com
Tue Sep 11 21:16:17 UTC 2012
On 12-09-11 05:06 PM, Dwight Engen wrote:
> On Tue, 11 Sep 2012 14:30:22 -0400
> Dwight Engen <dwight.engen at oracle.com> wrote:
>
>> On Mon, 10 Sep 2012 13:53:50 -0400
>> Stéphane Graber <stgraber at ubuntu.com> wrote:
>>
>> [...]
>>>> The reason I changed them to expand was so the docs would be right
>>>> (they had SUBST paths with ${var} still in them) but obviously I
>>>> don't want to break code just to make the docs right :)
>>>
>>> I'm not actually expending breakage but I'm expecting some dead
>>> code. For example @LXCPATH@ is used in most scripts using some
>>> workarounds as the value wasn't expanded, like:
>>> libdir=@LIBDIR@
>>> libexecdir=@LIBEXECDIR@
>>> localstatedir=@LOCALSTATEDIR@
>>>
>>> Once we apply your change, we'd have to check for such dead code and
>>> clean it up.
>
> fix expansion of LXCPATH,LXCROOTFSMOUNT,LXCTEMPLATEDIR
>
> 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 at oracle.com>
> ---
> configure.ac | 7 ++++---
> src/lxc/Makefile.am | 4 ----
> src/lxc/lxc-clone.in | 1 -
> src/lxc/lxc-create.in | 2 --
> src/lxc/lxc-destroy.in | 1 -
> src/lxc/lxc-ls.in | 1 -
> src/lxc/lxc-setcap.in | 3 ---
> src/lxc/lxc-setuid.in | 3 ---
> 8 files changed, 4 insertions(+), 18 deletions(-)
Thanks.
Did a quick testbuild and checked a few files, the result looks good and
will simplify things quite a bit.
Pushed to the staging branch.
--
Stéphane Graber
Ubuntu developer
http://www.ubuntu.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 897 bytes
Desc: OpenPGP digital signature
URL: <http://lists.linuxcontainers.org/pipermail/lxc-devel/attachments/20120911/713caaf6/attachment.pgp>
More information about the lxc-devel
mailing list