* [Buildroot] [PATCH] HOST_DIR/lib: symlink respectively to lib32/64
@ 2017-10-03 18:12 Matt Weber
2017-10-03 18:40 ` Matthew Weber
2017-10-03 20:43 ` Yann E. MORIN
0 siblings, 2 replies; 4+ messages in thread
From: Matt Weber @ 2017-10-03 18:12 UTC (permalink / raw)
To: buildroot
Modeled after system/system.mk creation of
TARGET_DIR equivalent.
Discovered the issue on a RHEL7.4 machine where
the cmake build dynamically selected HOST_DIR/lib64
as the installation path for the lzo2 library.
Fixes failures like the following:
host-mtd
http://autobuild.buildroot.net/results/d31/d31581d2e60f35cf70312683df99c768e2ea8516/
host-squashfs
http://autobuild.buildroot.net/results/d9c/d9c95231ac774ed71580754a15ebb3b121764310/
Signed-off-by: Matthew Weber <matthew.weber@rockwellcollins.com>
---
Makefile | 11 ++++++++++-
1 file changed, 10 insertions(+), 1 deletion(-)
diff --git a/Makefile b/Makefile
index 9b09589..d51f8ce 100644
--- a/Makefile
+++ b/Makefile
@@ -542,7 +542,7 @@ endif
.PHONY: dirs
dirs: $(BUILD_DIR) $(STAGING_DIR) $(TARGET_DIR) \
- $(HOST_DIR) $(HOST_DIR)/usr $(BINARIES_DIR)
+ $(HOST_DIR) $(HOST_DIR)/usr $(HOST_DIR)/lib $(BINARIES_DIR)
$(BUILD_DIR)/buildroot-config/auto.conf: $(BR2_CONFIG)
$(MAKE1) $(EXTRAMAKEARGS) HOSTCC="$(HOSTCC_NOCCACHE)" HOSTCXX="$(HOSTCXX_NOCCACHE)" silentoldconfig
@@ -565,6 +565,15 @@ sdk: world
$(HOST_DIR)/usr: $(HOST_DIR)
@ln -snf . $@
+$(HOST_DIR)/lib: $(HOST_DIR)
+# Make a symlink lib32->lib or lib64->lib as appropriate.
+# MIPS64/n32 requires lib32 even though it's a 64-bit arch.
+ifeq ($(BR2_ARCH_IS_64)$(BR2_MIPS_NABI32),y)
+ @ln -snf lib $@64
+else
+ @ln -snf lib $@32
+endif
+
# Populating the staging with the base directories is handled by the skeleton package
$(STAGING_DIR):
@mkdir -p $(STAGING_DIR)
--
1.9.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [Buildroot] [PATCH] HOST_DIR/lib: symlink respectively to lib32/64
2017-10-03 18:12 [Buildroot] [PATCH] HOST_DIR/lib: symlink respectively to lib32/64 Matt Weber
@ 2017-10-03 18:40 ` Matthew Weber
2017-10-03 20:43 ` Yann E. MORIN
1 sibling, 0 replies; 4+ messages in thread
From: Matthew Weber @ 2017-10-03 18:40 UTC (permalink / raw)
To: buildroot
Yann,
On Tue, Oct 3, 2017 at 1:12 PM, Matt Weber
<matthew.weber@rockwellcollins.com> wrote:
> Modeled after system/system.mk creation of
> TARGET_DIR equivalent.
>
> Discovered the issue on a RHEL7.4 machine where
> the cmake build dynamically selected HOST_DIR/lib64
> as the installation path for the lzo2 library.
>
> Fixes failures like the following:
> host-mtd
> http://autobuild.buildroot.net/results/d31/d31581d2e60f35cf70312683df99c768e2ea8516/
>
> host-squashfs
> http://autobuild.buildroot.net/results/d9c/d9c95231ac774ed71580754a15ebb3b121764310/
>
> Signed-off-by: Matthew Weber <matthew.weber@rockwellcollins.com>
> ---
> Makefile | 11 ++++++++++-
> 1 file changed, 10 insertions(+), 1 deletion(-)
>
> diff --git a/Makefile b/Makefile
> index 9b09589..d51f8ce 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -542,7 +542,7 @@ endif
>
> .PHONY: dirs
> dirs: $(BUILD_DIR) $(STAGING_DIR) $(TARGET_DIR) \
> - $(HOST_DIR) $(HOST_DIR)/usr $(BINARIES_DIR)
> + $(HOST_DIR) $(HOST_DIR)/usr $(HOST_DIR)/lib $(BINARIES_DIR)
>
> $(BUILD_DIR)/buildroot-config/auto.conf: $(BR2_CONFIG)
> $(MAKE1) $(EXTRAMAKEARGS) HOSTCC="$(HOSTCC_NOCCACHE)" HOSTCXX="$(HOSTCXX_NOCCACHE)" silentoldconfig
> @@ -565,6 +565,15 @@ sdk: world
> $(HOST_DIR)/usr: $(HOST_DIR)
> @ln -snf . $@
>
> +$(HOST_DIR)/lib: $(HOST_DIR)
> +# Make a symlink lib32->lib or lib64->lib as appropriate.
> +# MIPS64/n32 requires lib32 even though it's a 64-bit arch.
> +ifeq ($(BR2_ARCH_IS_64)$(BR2_MIPS_NABI32),y)
> + @ln -snf lib $@64
> +else
> + @ln -snf lib $@32
> +endif
> +
Good catch, wasn't thinking about the conditional. Here's my proposed
update (testing it now).
$(HOST_DIR)/lib: $(HOST_DIR)
ifeq ($(HOSTARCH),x86)
@ln -snf lib $@32
else
@ln -snf lib $@64
endif
Matt
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Buildroot] [PATCH] HOST_DIR/lib: symlink respectively to lib32/64
2017-10-03 18:12 [Buildroot] [PATCH] HOST_DIR/lib: symlink respectively to lib32/64 Matt Weber
2017-10-03 18:40 ` Matthew Weber
@ 2017-10-03 20:43 ` Yann E. MORIN
2017-10-03 21:00 ` Matthew Weber
1 sibling, 1 reply; 4+ messages in thread
From: Yann E. MORIN @ 2017-10-03 20:43 UTC (permalink / raw)
To: buildroot
Matthew, All,
On 2017-10-03 13:12 -0500, Matt Weber spake thusly:
> Modeled after system/system.mk creation of
> TARGET_DIR equivalent.
>
> Discovered the issue on a RHEL7.4 machine where
> the cmake build dynamically selected HOST_DIR/lib64
> as the installation path for the lzo2 library.
>
> Fixes failures like the following:
> host-mtd
> http://autobuild.buildroot.net/results/d31/d31581d2e60f35cf70312683df99c768e2ea8516/
>
> host-squashfs
> http://autobuild.buildroot.net/results/d9c/d9c95231ac774ed71580754a15ebb3b121764310/
>
> Signed-off-by: Matthew Weber <matthew.weber@rockwellcollins.com>
> ---
> Makefile | 11 ++++++++++-
> 1 file changed, 10 insertions(+), 1 deletion(-)
>
> diff --git a/Makefile b/Makefile
> index 9b09589..d51f8ce 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -542,7 +542,7 @@ endif
>
> .PHONY: dirs
> dirs: $(BUILD_DIR) $(STAGING_DIR) $(TARGET_DIR) \
> - $(HOST_DIR) $(HOST_DIR)/usr $(BINARIES_DIR)
> + $(HOST_DIR) $(HOST_DIR)/usr $(HOST_DIR)/lib $(BINARIES_DIR)
>
> $(BUILD_DIR)/buildroot-config/auto.conf: $(BR2_CONFIG)
> $(MAKE1) $(EXTRAMAKEARGS) HOSTCC="$(HOSTCC_NOCCACHE)" HOSTCXX="$(HOSTCXX_NOCCACHE)" silentoldconfig
> @@ -565,6 +565,15 @@ sdk: world
> $(HOST_DIR)/usr: $(HOST_DIR)
> @ln -snf . $@
>
> +$(HOST_DIR)/lib: $(HOST_DIR)
> +# Make a symlink lib32->lib or lib64->lib as appropriate.
> +# MIPS64/n32 requires lib32 even though it's a 64-bit arch.
> +ifeq ($(BR2_ARCH_IS_64)$(BR2_MIPS_NABI32),y)
As discussed on IRC, BR2_ARCH_IS_64 and BR2_MIPS_NABI32 are about the
target, while here we are concerned about the host.
So, the symlink should probably be based on the value of $(HOSTARCH).
Therefore, I've marked this patch as chages requested.
Regards,
Yann E. MORIN.
> + @ln -snf lib $@64
> +else
> + @ln -snf lib $@32
> +endif
> +
> # Populating the staging with the base directories is handled by the skeleton package
> $(STAGING_DIR):
> @mkdir -p $(STAGING_DIR)
> --
> 1.9.1
>
> _______________________________________________
> buildroot mailing list
> buildroot at busybox.net
> http://lists.busybox.net/mailman/listinfo/buildroot
--
.-----------------.--------------------.------------------.--------------------.
| Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ |
| +33 223 225 172 `------------.-------: X AGAINST | \e/ There is no |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. |
'------------------------------^-------^------------------^--------------------'
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Buildroot] [PATCH] HOST_DIR/lib: symlink respectively to lib32/64
2017-10-03 20:43 ` Yann E. MORIN
@ 2017-10-03 21:00 ` Matthew Weber
0 siblings, 0 replies; 4+ messages in thread
From: Matthew Weber @ 2017-10-03 21:00 UTC (permalink / raw)
To: buildroot
Yann,
On Tue, Oct 3, 2017 at 3:43 PM, Yann E. MORIN <yann.morin.1998@free.fr> wrote:
> Matthew, All,
>
> On 2017-10-03 13:12 -0500, Matt Weber spake thusly:
>> Modeled after system/system.mk creation of
>> TARGET_DIR equivalent.
>>
>> Discovered the issue on a RHEL7.4 machine where
>> the cmake build dynamically selected HOST_DIR/lib64
>> as the installation path for the lzo2 library.
>>
>> Fixes failures like the following:
>> host-mtd
>> http://autobuild.buildroot.net/results/d31/d31581d2e60f35cf70312683df99c768e2ea8516/
>>
>> host-squashfs
>> http://autobuild.buildroot.net/results/d9c/d9c95231ac774ed71580754a15ebb3b121764310/
>>
>> Signed-off-by: Matthew Weber <matthew.weber@rockwellcollins.com>
>> ---
>> Makefile | 11 ++++++++++-
>> 1 file changed, 10 insertions(+), 1 deletion(-)
>>
>> diff --git a/Makefile b/Makefile
>> index 9b09589..d51f8ce 100644
>> --- a/Makefile
>> +++ b/Makefile
>> @@ -542,7 +542,7 @@ endif
>>
>> .PHONY: dirs
>> dirs: $(BUILD_DIR) $(STAGING_DIR) $(TARGET_DIR) \
>> - $(HOST_DIR) $(HOST_DIR)/usr $(BINARIES_DIR)
>> + $(HOST_DIR) $(HOST_DIR)/usr $(HOST_DIR)/lib $(BINARIES_DIR)
>>
>> $(BUILD_DIR)/buildroot-config/auto.conf: $(BR2_CONFIG)
>> $(MAKE1) $(EXTRAMAKEARGS) HOSTCC="$(HOSTCC_NOCCACHE)" HOSTCXX="$(HOSTCXX_NOCCACHE)" silentoldconfig
>> @@ -565,6 +565,15 @@ sdk: world
>> $(HOST_DIR)/usr: $(HOST_DIR)
>> @ln -snf . $@
>>
>> +$(HOST_DIR)/lib: $(HOST_DIR)
>> +# Make a symlink lib32->lib or lib64->lib as appropriate.
>> +# MIPS64/n32 requires lib32 even though it's a 64-bit arch.
>> +ifeq ($(BR2_ARCH_IS_64)$(BR2_MIPS_NABI32),y)
>
> As discussed on IRC, BR2_ARCH_IS_64 and BR2_MIPS_NABI32 are about the
> target, while here we are concerned about the host.
>
> So, the symlink should probably be based on the value of $(HOSTARCH).
>
> Therefore, I've marked this patch as chages requested.
Superseded by:
https://patchwork.ozlabs.org/patch/821016/
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2017-10-03 21:00 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-10-03 18:12 [Buildroot] [PATCH] HOST_DIR/lib: symlink respectively to lib32/64 Matt Weber
2017-10-03 18:40 ` Matthew Weber
2017-10-03 20:43 ` Yann E. MORIN
2017-10-03 21:00 ` Matthew Weber
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.