mirror of
https://github.com/openembedded/meta-openembedded.git
synced 2025-12-14 14:25:53 +01:00
libsquish: Fix build when libdir != 'lib'
Fixes build when libdir is something like lib64 or lib32 Signed-off-by: Khem Raj <raj.khem@gmail.com>
This commit is contained in:
parent
fc13caaa52
commit
8df60dc8d6
|
|
@ -0,0 +1,70 @@
|
|||
From 20d14f323c877eca631f0a75efcf19727fb18dd9 Mon Sep 17 00:00:00 2001
|
||||
From: Khem Raj <raj.khem@gmail.com>
|
||||
Date: Tue, 22 Mar 2022 09:17:06 -0700
|
||||
Subject: [PATCH] Add support for variable libdir
|
||||
|
||||
sometimes libdir is not 'lib' in such cases set LIBDIR_SUFFIX to 32 or
|
||||
64 to append to it.
|
||||
|
||||
Upstream-Status: Pending
|
||||
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
||||
---
|
||||
Makefile | 9 +++++----
|
||||
config.in | 2 ++
|
||||
squish.pc.in | 3 ++-
|
||||
3 files changed, 9 insertions(+), 5 deletions(-)
|
||||
|
||||
diff --git a/Makefile b/Makefile
|
||||
index 1c01f89..768a4a7 100644
|
||||
--- a/Makefile
|
||||
+++ b/Makefile
|
||||
@@ -10,13 +10,13 @@ LIB = libsquish.a
|
||||
all : $(LIB) squish.pc
|
||||
|
||||
install : $(LIB) squish.pc
|
||||
- install squish.h $(INSTALL_DIR)/include
|
||||
- install libsquish.a $(INSTALL_DIR)/lib
|
||||
- install squish.pc $(INSTALL_DIR)/lib/pkgconfig
|
||||
+ install squish.h $(INSTALL_DIR)/include
|
||||
+ install libsquish.a $(INSTALL_DIR)/lib$(LIBDIR_SUFFIX)
|
||||
+ install squish.pc $(INSTALL_DIR)/lib$(LIBDIR_SUFFIX)/pkgconfig
|
||||
|
||||
uninstall:
|
||||
$(RM) $(INSTALL_DIR)/include/squish.h
|
||||
- $(RM) $(INSTALL_DIR)/lib/libsquish.a
|
||||
+ $(RM) $(INSTALL_DIR)/lib$(LIBDIR_SUFFIX)/libsquish.a
|
||||
|
||||
$(LIB) : $(OBJ)
|
||||
$(AR) cr $@ $?
|
||||
@@ -30,4 +30,5 @@ clean :
|
||||
|
||||
squish.pc:
|
||||
sed 's|@PREFIX@|$(PREFIX)|' $@.in > $@
|
||||
+ sed 's|@LIBDIR_SUFFIX@|$(LIBDIR_SUFFIX)|' $@.in > $@
|
||||
|
||||
diff --git a/config.in b/config.in
|
||||
index fdca022..a6cf833 100644
|
||||
--- a/config.in
|
||||
+++ b/config.in
|
||||
@@ -19,3 +19,5 @@ endif
|
||||
|
||||
# where should we install to
|
||||
INSTALL_DIR ?= @PREFIX@
|
||||
+# libdir is architecture specific
|
||||
+LIBDIR_SUFFIX ?= @LIBDIR_SUFFIX@
|
||||
diff --git a/squish.pc.in b/squish.pc.in
|
||||
index ca04334..73c21bb 100644
|
||||
--- a/squish.pc.in
|
||||
+++ b/squish.pc.in
|
||||
@@ -1,6 +1,7 @@
|
||||
prefix=@PREFIX@
|
||||
+suffix=@LIBDIR_SUFFIX@
|
||||
exec_prefix=${prefix}
|
||||
-libdir=${prefix}/lib
|
||||
+libdir=${prefix}/lib${suffix}
|
||||
sharedlibdir=${libdir}
|
||||
includedir=${prefix}/include
|
||||
|
||||
--
|
||||
2.35.1
|
||||
|
||||
|
|
@ -6,11 +6,13 @@ LIC_FILES_CHKSUM = "file://alpha.cpp;beginline=3;endline=22;md5=6665e479f71feb92
|
|||
PV = "1.10+git${SRCPV}"
|
||||
|
||||
SRCREV = "52e7d93c5947f72380521116c05d97c528863ba8"
|
||||
SRC_URI = "git://github.com/OpenELEC/libsquish.git;protocol=https;branch=master"
|
||||
SRC_URI = "git://github.com/OpenELEC/libsquish.git;protocol=https;branch=master \
|
||||
file://0001-Add-support-for-variable-libdir.patch \
|
||||
"
|
||||
|
||||
S = "${WORKDIR}/git"
|
||||
|
||||
EXTRA_OEMAKE = "INSTALL_DIR=${D}${prefix} LIBDIR=${base_libdir} \
|
||||
EXTRA_OEMAKE = "INSTALL_DIR=${D}${prefix} LIBDIR_SUFFIX=${@d.getVar('baselib').replace('lib', '')} \
|
||||
${@bb.utils.contains('TUNE_FEATURES', 'altivec', 'USE_ALTIVEC=1', '', d)}"
|
||||
|
||||
do_install() {
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user