extra fix for non /usr/lib libdir
cover extra fix for non /usr/lib libdir
sta-solver and libzypp also need fix to pass the build with non /usr/lib libdir e.g. libdir=/usr/lib64
The following changes since commit 7354fc9213f27aa1b643dbe88070437f1ee4c063:
Paul Eggleton (1):
insane.bbclass: skip rdepends QA checks for kernel / modules
are available in the git repository at:
git://git.pokylinux.org/poky-contrib kyu3/libdir-fix-v3
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=kyu3/libdir-fix-v3
Yu Ke (2):
sat-solver: fix for non /usr/lib libdir case
libzypp: fix for non /usr/lib libdir case
meta/classes/cmake.bbclass | 4 +++ .../libzypp/libzypp/hardcode-lib-fix.patch | 22 ++++++++++++++++++++ meta/recipes-extended/libzypp/libzypp_git.bb | 5 ++- meta/recipes-extended/sat-solver/sat-solver_git.bb | 6 +++- 4 files changed, 33 insertions(+), 4 deletions(-) create mode 100644 meta/recipes-extended/libzypp/libzypp/hardcode-lib-fix.patch
PATCH 2/2 libzypp: fix for non /usr/lib libdir case
this patch has two fixes:
1. the src tool/CMakeLists.txt has hardcode "lib", so add a patch to fix it
2. the recipe has hardcode "-DLIB=lib", so replace it with libdir
--- .../libzypp/libzypp/hardcode-lib-fix.patch | 22 ++++++++++++++++++++ meta/recipes-extended/libzypp/libzypp_git.bb | 5 ++- 2 files changed, 25 insertions(+), 2 deletions(-) create mode 100644 meta/recipes-extended/libzypp/libzypp/hardcode-lib-fix.patch
meta/recipes-extended/libzypp/libzypp/hardcode-lib-fix.patch new file +22 -0
@@ -0,0 +1,22 @@ +tools/CMakeLists.txt: replace the hardcode "lib" + +replace the hardcode "lib" with LIB_INSTALL_DIR +this will work with non /usr/lib libdir case + +Upstream-Status: Pending + +Signed-off-by: Yu Ke <[email protected]> + +Index: libzypp/tools/CMakeLists.txt +=================================================================== +--- libzypp.orig/tools/CMakeLists.txt ++++ libzypp/tools/CMakeLists.txt +@@ -1,7 +1,7 @@ + + ADD_SUBDIRECTORY( package-manager ) + +-INSTALL( FILES notify-message DESTINATION "${CMAKE_INSTALL_PREFIX}/lib/zypp" ) ++INSTALL( FILES notify-message DESTINATION "${LIB_INSTALL_DIR}/zypp" ) + + ## ############################################################ +
meta/recipes-extended/libzypp/libzypp_git.bb +3 -2
@@ -14,7 +14,7 @@ RDEPENDS_${PN} = "sat-solver" S = "${WORKDIR}/git" SRCREV = "15b6c52260bbc52b3d8e585e271b67e10cc7c433" PV = "0.0-git${SRCPV}" -PR = "r10" +PR = "r11" SRC_URI = "git://gitorious.org/opensuse/libzypp.git;protocol=git \ file://no-doc.patch \
@@ -23,6 +23,7 @@ SRC_URI = "git://gitorious.org/opensuse/libzypp.git;protocol=git \ file://config-release.patch \ file://libzypp-pokyarch.patch \ file://fix_for_compile_wth_gcc-4.6.0.patch \ + file://hardcode-lib-fix.patch \ " SRC_URI_append_mips = " file://mips-workaround-gcc-tribool-error.patch"
@@ -33,7 +34,7 @@ SRC_URI_append_arm = " file://arm-workaround-global-constructor.patch" FILES_${PN} += "${libdir}/zypp ${datadir}/zypp ${datadir}/icons" FILES_${PN}-dev += "${datadir}/cmake" -EXTRA_OECMAKE += "-DLIB=lib" +EXTRA_OECMAKE += " -DLIB=${@os.path.basename('${libdir}')}" PACKAGE_ARCH = "${MACHINE_ARCH}"
Signature · 1 line
1.7.0.4
PATCH 1/2 sat-solver: fix for non /usr/lib libdir case
In reply to Yu Kewhen libdir set to non /usr/lib like /usr/lib64, there is do_configure error:
"
-- Libraries will be installed in /usr/lib
CMake Error at /home/kyu3/sdb/lib64/tmp/sysroots/x86_64-linux/usr/share/cmake-2.8/Modules/FindPackageHandleStandardArgs.cmake:91 (MESSAGE):
Please install 'check' and 'check-devel' packages (missing: CHECK_LIBRARY)
Call Stack (most recent call first):
/home/kyu3/sdb/lib64/tmp/sysroots/x86_64-linux/usr/share/cmake-2.8/Modules/FindPackageHandleStandardArgs.cmake:252 (_FPHSA_FAILURE_MESSAGE)
cmake/modules/FindCheck.cmake:17 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
CMakeLists.txt:35 (FIND_PACKAGE)
-- Configuring incomplete, errors occurred!
"
The reason is that cmake did not search /usr/lib64 for libcheck, thus report error
add ${libdir} to the CMAKE_SYSTEM_LIBRARY_PATH can fix this issue.
--- meta/classes/cmake.bbclass | 4 ++++ meta/recipes-extended/sat-solver/sat-solver_git.bb | 6 ++++-- 2 files changed, 8 insertions(+), 2 deletions(-)
meta/classes/cmake.bbclass +4 -0
@@ -55,6 +55,10 @@ set( CMAKE_INSTALL_RPATH ${OECMAKE_RPATH} ) # Use native cmake modules set( CMAKE_MODULE_PATH ${STAGING_DATADIR}/cmake/Modules/ ) + +# add for non /usr/lib libdir, e.g. /usr/lib64 +LIST(APPEND CMAKE_SYSTEM_LIBRARY_PATH ${libdir}) + EOF }
meta/recipes-extended/sat-solver/sat-solver_git.bb +4 -2
@@ -8,7 +8,7 @@ DEPENDS = "libcheck rpm zlib expat db" SRCREV = "0a7378d5f482f477a01cf1690d76871ab8bdcc32" PV = "0.0-git${SRCPV}" -PR = "r10" +PR = "r11" PARALLEL_MAKE=""
@@ -23,7 +23,9 @@ SRC_URI = "git://gitorious.org/opensuse/sat-solver.git;protocol=git \ S = "${WORKDIR}/git" -EXTRA_OECMAKE += "-DLIB=lib -DRPM5=RPM5 -DOE_CORE=OE_CORE" +EXTRA_OECMAKE += "-DRPM5=RPM5 -DOE_CORE=OE_CORE" + +EXTRA_OECMAKE += " -DLIB=${@os.path.basename('${libdir}')}" inherit cmake pkgconfig
Signature · 1 line
1.7.0.4
Richard Purdie
AppliedQuoted 7 lines · Yu Ke
sta-solver and libzypp also need fix to pass the build with non
/usr/liblibdir e.g. libdir=/usr/lib64The following changes since commit
7354fc9213f27aa1b643dbe88070437f1ee4c063:
Paul Eggleton (1):
insane.bbclass: skip rdepends QA checks for kernel / modules
Quoted 8 lines
are available in the git repository at:
git://git.pokylinux.org/poky-contribkyu3/libdir-fix-v3
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=kyu3/libdir-fix-v3Yu Ke (2):
sat-solver: fix for non/usr/liblibdir case
libzypp: fix for non/usr/liblibdir case
Merged to master, thanks.
Richard