[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] build: omit "source" symlink when building hypervisor in-tree
- To: Jan Beulich <jbeulich@xxxxxxxx>
- From: Anthony PERARD <anthony.perard@xxxxxxxxxx>
- Date: Wed, 15 Mar 2023 15:20:43 +0000
- Authentication-results: esa3.hc3370-68.iphmx.com; dkim=none (message not signed) header.i=none
- Cc: "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>, "Andrew Cooper" <andrew.cooper3@xxxxxxxxxx>, George Dunlap <george.dunlap@xxxxxxxxxx>, Julien Grall <julien@xxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, Wei Liu <wl@xxxxxxx>
- Delivery-date: Wed, 15 Mar 2023 15:21:06 +0000
- Ironport-data: A9a23:xjAsSKIIAeGXmmGuFE+RHJUlxSXFcZb7ZxGr2PjKsXjdYENShjxUy jEeW2uOOv2LYWWmKd4nbt++o09Uv8CHndE3SwplqX01Q3x08seUXt7xwmUcnc+xBpaaEB84t ZV2hv3odp1coqr0/0/1WlTZhSAgk/rOHvykU7Ss1hlZHWdMUD0mhQ9oh9k3i4tphcnRKw6Ws Jb5rta31GWNglaYCUpJrfPTwP9TlK6q4mhA5QVjPakjUGL2zBH5MrpOfcldEFOgKmVkNrbSb /rOyri/4lTY838FYj9yuu+mGqGiaue60Tmm0hK6aYD76vRxjnVaPpIAHOgdcS9qZwChxLid/ jnvWauYEm/FNoWU8AgUvoIx/ytWZcWq85efSZSzXFD6I+QrvBIAzt03ZHzaM7H09c5mGkZe/ NsjFAsNbzmNrOOskK6bdMtV05FLwMnDZOvzu1llxDDdS/0nXYrCU+PB4towMDUY354UW6yEP oxANGQpNU6bC/FMEg5/5JYWleG0hn75YntApUicv6Yf6GnP1g1hlrPqNbI5f/TTHZ0EwRnE+ jKuE2LRBywDEt+ujhu8+CyWgcrvzQPWVJ0tPejtnhJtqALKnTFCYPEMbnO5q/Skjk+1W/pEN lcZvCEpqMAa5EGtC9XwQRC8iHqFpQIHHcpdFfUg7wOAwbaS5ByWbkAGUzpAZdoOpMIwAzsw2 TehhMj1DDZitLmUT3O19bqOqz62fy8PIgcqeissXQYDpd75r+kbhwrCVN95HIapj9f+Hnf7x DXikcQlr+xN14hRjfz9pA2ZxWv2/fAlUzLZ+C3GRUW15yRCWLWlZqWmwlnBvepgEqSgGwzpU Gc/p+CS6+UHDJeonSOLQfkQELzB28tpIAEwknY0QcB/qm3FF2qLONkJvWogfBsB3tMsI2eBX aPFhe9GCHa/1lOOZLQ/XY++At9CIUPIRYW8DaC8gjajj/FMmO67EMNGPxL4M4PFyhJEfUQD1 XCzIK6R4Y4yU/gP8dZPb751PUUX7i4/33jPYpvw0g6q17GTDFbMF+hVYALfN7lhtPzeyOkwz zq4H5ri9vmieLemPnm/HXA7dDjm0kTX9bip8pcKJ4Zv0yJtGX07Cu+5/I7Nj7dNxvwP/s+Rp yHVZ6Ot4Aan7ZExAVnQOy8LhXKGdcoXkE/XygR1Zwf5gidzPdzzhErdHrNuFYQaGCVY5aYcZ 5E4lw+oWZyjlhyvF+whUKTA
- Ironport-hdrordr: A9a23:ralXgqsEOJ35lj08yHcQwOGI7skDSdV00zEX/kB9WHVpmwKj5r mTdZUgpGfJYVMqMk3I9urwXZVoLUmsl6KdpLNhXotKPzOGhILLFvAH0WKK+VSJcBEWtNQ86U 4KSdkYNDSfNykdsS842mWF+hQbreVvPJrGuQ4W9RlQcT0=
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
On Wed, Mar 15, 2023 at 03:56:21PM +0100, Jan Beulich wrote:
> This symlink is getting in the way of using e.g. "find" on the xen/
> subtree, and it isn't really needed when not building out-of-tree:
> the one use that there was can easily be avoided.
>
> Signed-off-by: Jan Beulich <jbeulich@xxxxxxxx>
>
> --- a/xen/common/efi/efi-common.mk
> +++ b/xen/common/efi/efi-common.mk
> @@ -5,11 +5,16 @@ CFLAGS-y += -fshort-wchar
> CFLAGS-y += -iquote $(srctree)/common/efi
> CFLAGS-y += -iquote $(srcdir)
>
> +source :=
> +ifneq ($(abs_objtree),$(abs_srctree))
Could you use "ifdef building_out_of_srctree" instead, or at least use
the variable $(building_out_of_srctree)? At least that mean there's a
single way in the tree to differentiate between both kind of build.
> +source := source/
> +endif
> +
> # Part of the command line transforms $(obj)
> # e.g.: It transforms "dir/foo/bar" into successively
> # "dir foo bar", ".. .. ..", "../../.."
> $(obj)/%.c: $(srctree)/common/efi/%.c FORCE
> - $(Q)ln -nfs $(subst $(space),/,$(patsubst %,..,$(subst /,
> ,$(obj))))/source/common/efi/$(<F) $@
> + $(Q)ln -nfs $(subst $(space),/,$(patsubst %,..,$(subst /,
> ,$(obj))))/$(source)common/efi/$(<F) $@
Instead of $(source), I did proposed initially
"$(if $(building_out_of_srctree),source/)" for here, or it that making
the command line too long?
https://lore.kernel.org/xen-devel/YebpHJk1JIArcdvW@perard/t/#u
Having "source := $(if $(building_out_of_srctree),source/)" might be an
ok alternative in place of the use if "ifneq/endif" which take 4 lines?
Thanks,
--
Anthony PERARD
|