* [Buildroot] [PATCH 1/1] lockdev: Fix TARGET_DIR link
@ 2013-12-29 17:31 Bernd Kuhls
2013-12-29 17:43 ` Yann E. MORIN
0 siblings, 1 reply; 3+ messages in thread
From: Bernd Kuhls @ 2013-12-29 17:31 UTC (permalink / raw)
To: buildroot
Signed-off-by: Bernd Kuhls <berndkuhls@hotmail.com>
---
package/lockdev/lockdev.mk | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/package/lockdev/lockdev.mk b/package/lockdev/lockdev.mk
index 004b637..0c10341 100644
--- a/package/lockdev/lockdev.mk
+++ b/package/lockdev/lockdev.mk
@@ -34,7 +34,7 @@ endef
define LOCKDEV_INSTALL_TARGET_CMDS
$(MAKE1) basedir=$(TARGET_DIR)/usr -C $(@D) install_run
- ln -sf liblockdev.$(LOCKDEV_VERSION).so $(STAGING_DIR)/usr/lib/liblockdev.so.1
+ ln -sf liblockdev.$(LOCKDEV_VERSION).so $(TARGET_DIR)/usr/lib/liblockdev.so.1
endef
endif # BR2_PREFER_STATIC_LIB
--
1.7.9.5
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [Buildroot] [PATCH 1/1] lockdev: Fix TARGET_DIR link
2013-12-29 17:31 [Buildroot] [PATCH 1/1] lockdev: Fix TARGET_DIR link Bernd Kuhls
@ 2013-12-29 17:43 ` Yann E. MORIN
2013-12-29 17:57 ` Thomas Petazzoni
0 siblings, 1 reply; 3+ messages in thread
From: Yann E. MORIN @ 2013-12-29 17:43 UTC (permalink / raw)
To: buildroot
Bernd, All,
On 2013-12-29 18:31 +0100, Bernd Kuhls spake thusly:
> Signed-off-by: Bernd Kuhls <berndkuhls@hotmail.com>
> ---
> package/lockdev/lockdev.mk | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/package/lockdev/lockdev.mk b/package/lockdev/lockdev.mk
> index 004b637..0c10341 100644
> --- a/package/lockdev/lockdev.mk
> +++ b/package/lockdev/lockdev.mk
> @@ -34,7 +34,7 @@ endef
>
> define LOCKDEV_INSTALL_TARGET_CMDS
> $(MAKE1) basedir=$(TARGET_DIR)/usr -C $(@D) install_run
> - ln -sf liblockdev.$(LOCKDEV_VERSION).so $(STAGING_DIR)/usr/lib/liblockdev.so.1
> + ln -sf liblockdev.$(LOCKDEV_VERSION).so $(TARGET_DIR)/usr/lib/liblockdev.so.1
The .so symlink is not required at runtime, so we do not even have to
install it in the first place. All we need is a library which filename
is the same as its SONAME.
So, if the SONAME is liblockdev.so.1, just rename the library to .so.1.
If the SONAME is liblockdev.so, just rename the library to .so. If the
library is already installed with the correct filename, no need to
rename it.
Regards,
Yann E. MORIN.
--
.-----------------.--------------------.------------------.--------------------.
| 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] 3+ messages in thread
* [Buildroot] [PATCH 1/1] lockdev: Fix TARGET_DIR link
2013-12-29 17:43 ` Yann E. MORIN
@ 2013-12-29 17:57 ` Thomas Petazzoni
0 siblings, 0 replies; 3+ messages in thread
From: Thomas Petazzoni @ 2013-12-29 17:57 UTC (permalink / raw)
To: buildroot
Dear Yann E. MORIN,
On Sun, 29 Dec 2013 18:43:05 +0100, Yann E. MORIN wrote:
> > define LOCKDEV_INSTALL_TARGET_CMDS
> > $(MAKE1) basedir=$(TARGET_DIR)/usr -C $(@D) install_run
> > - ln -sf liblockdev.$(LOCKDEV_VERSION).so $(STAGING_DIR)/usr/lib/liblockdev.so.1
> > + ln -sf liblockdev.$(LOCKDEV_VERSION).so $(TARGET_DIR)/usr/lib/liblockdev.so.1
>
> The .so symlink is not required at runtime, so we do not even have to
> install it in the first place. All we need is a library which filename
> is the same as its SONAME.
>
> So, if the SONAME is liblockdev.so.1, just rename the library to .so.1.
> If the SONAME is liblockdev.so, just rename the library to .so. If the
> library is already installed with the correct filename, no need to
> rename it.
I've applied the patch, because nowhere in Buildroot we rename
libraries so that they have as filename their SONAME. Therefore, doing
this specifically for liblockdev would be inconsistent with what we do
all over Buildroot.
The SONAME of this library is indeed liblockdev.so.1, so this symbolic
link is needed.
Note that liblockdev.$(LOCKDEV_VERSION).so is *NOT* a symbolic link. It
is the library itself. liblockdev is a bit non-standard: instead of
having its real library binary named liblockdev.so.<version>, it is
named liblockdev.<version>.so. And the liblockdev.so.1 symbolic link is
needed to ensure that there is something matching the SONAME of the
library, as explained above.
Best regards,
Thomas
--
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2013-12-29 17:57 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-12-29 17:31 [Buildroot] [PATCH 1/1] lockdev: Fix TARGET_DIR link Bernd Kuhls
2013-12-29 17:43 ` Yann E. MORIN
2013-12-29 17:57 ` Thomas Petazzoni
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.