jimtcl: fix compile problem for sparc64
PATCH 1/1 jimtcl: fix compile problem for sparc64
It is general safe to use -fPIC for all architectures. -fpic breaks sparc64 compile.
Runtime tested on Qemu ARM, MIPS and SPARC64.
Fixes:
http://autobuild.buildroot.net/results/98f391ad13f22828c022f185c0166daabdb4c1ad/
It also addresses a problem with the wrong symlink for the shared library recognized while runtime testing.
--- package/jimtcl/jimtcl.mk | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-)
package/jimtcl/jimtcl.mk +4 -2
@@ -33,8 +33,8 @@ else JIMTCL_SHARED = --shared define JIMTCL_INSTALL_LIB $(INSTALL) -m 0755 -D $(@D)/libjim.so.$(JIMTCL_VERSION) \ - $(1)/usr/lib/libjim.$(JIMTCL_VERSION) - ln -s libjim.$(JIMTCL_VERSION) $(1)/usr/lib/libjim.so + $(1)/usr/lib/libjim.so.$(JIMTCL_VERSION) + ln -sf libjim.so.$(JIMTCL_VERSION) $(1)/usr/lib/libjim.so endef endif
@@ -47,6 +47,8 @@ define JIMTCL_CONFIGURE_CMDS endef define JIMTCL_BUILD_CMDS + SH_CFLAGS="-fPIC" \ + SHOBJ_CFLAGS="-fPIC" \ $(MAKE) -C $(@D) endef
Signature · 1 line
1.7.10.4
PATCH 1/1 jimtcl: fix compile problem for sparc64
Waldemar,
Quoted 21 lines · Waldemar Brodkorb
It is general safe to use -fPIC for all architectures. -fpic breaks sparc64 compile.
Runtime tested on Qemu ARM, MIPS and SPARC64.
Fixes:
http://autobuild.buildroot.net/results/98f391ad13f22828c022f185c0166daabdb4c1ad/It also addresses a problem with the wrong symlink for the shared library recognized while runtime testing.
Signed-off-by Waldemar Brodkorb <[email protected]>--- package/jimtcl/jimtcl.mk | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-)package/jimtcl/jimtcl.mk +0
-0
package/jimtcl/jimtcl.mk else · line 37
Quoted 7 lines
package/jimtcl/jimtcl.mk +2
-2@@ -33,8 +33,8 @@ else JIMTCL_SHARED = --shared define JIMTCL_INSTALL_LIB $(INSTALL) -m 0755 -D $(@D)/libjim.so.$(JIMTCL_VERSION) \ - $(1)/usr/lib/libjim.$(JIMTCL_VERSION) - ln -s libjim.$(JIMTCL_VERSION) $(1)/usr/lib/libjim.so + $(1)/usr/lib/libjim.so.$(JIMTCL_VERSION) + ln -sf libjim.so.$(JIMTCL_VERSION) $(1)/usr/lib/libjim.so
This is unrelated to sparc64 fix, so it should be a separate patch (though it is obviously a good fix).
package/jimtcl/jimtcl.mk define JIMTCL_CONFIGURE_CMDS · line 51
Quoted 6 lines
package/jimtcl/jimtcl.mk +2
-0@@ -47,6 +47,8 @@ define JIMTCL_CONFIGURE_CMDS endef define JIMTCL_BUILD_CMDS + SH_CFLAGS="-fPIC" \ + SHOBJ_CFLAGS="-fPIC" \
In other packages (such as elfutils), you made passing -fPIC conditional on sparc64. Why don't we do the same here? I believe on many platforms -fpic and -fPIC are the same, but I think we should be consistent in the way we handle this before the different packages.
Thanks,
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons Embedded Linux, Kernel and Android engineering http://free-electrons.com