mirror of
https://github.com/openembedded/meta-openembedded.git
synced 2026-05-07 05:10:20 +00:00
libmusicbrainz: Rework native and target pieces
Build the native tools via a proper native recipe Once done this way we do not need any patches Bump SRCREV to latest which brings in one fix [1] [1] https://github.com/metabrainz/libmusicbrainz/commit/8be45b12a86bc0e46f2f836c8ac88e1e98d82aee Signed-off-by: Khem Raj <raj.khem@gmail.com> Cc: Andreas Müller <schnitzeltony@gmail.com>
This commit is contained in:
@@ -1,21 +0,0 @@
|
|||||||
Allow LIB_INSTALL_DIR to be set by the the cmake configure invocation. We dont
|
|
||||||
easily have a way of determining something that patches ${LIB_SUFFIX} so we'll
|
|
||||||
set LIB_INSTALL_DIR.
|
|
||||||
|
|
||||||
Upstream-Status: Inappropriate [configuration]
|
|
||||||
|
|
||||||
Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
|
|
||||||
|
|
||||||
Index: git/CMakeLists.txt
|
|
||||||
===================================================================
|
|
||||||
--- git.orig/CMakeLists.txt
|
|
||||||
+++ git/CMakeLists.txt
|
|
||||||
@@ -36,7 +36,7 @@ FIND_PACKAGE(LibXml2 REQUIRED)
|
|
||||||
SET(LIB_SUFFIX "" CACHE STRING "Define suffix of directory name (32/64)")
|
|
||||||
SET(EXEC_INSTALL_PREFIX ${CMAKE_INSTALL_PREFIX} CACHE PATH "Installation prefix for executables and object code libraries" FORCE)
|
|
||||||
SET(BIN_INSTALL_DIR ${EXEC_INSTALL_PREFIX}/bin CACHE PATH "Installation prefix for user executables" FORCE)
|
|
||||||
-SET(LIB_INSTALL_DIR ${EXEC_INSTALL_PREFIX}/lib${LIB_SUFFIX} CACHE PATH "Installation prefix for object code libraries" FORCE)
|
|
||||||
+SET(LIB_INSTALL_DIR ${EXEC_INSTALL_PREFIX}/lib${LIB_SUFFIX} CACHE PATH "Installation prefix for object code libraries")
|
|
||||||
SET(INCLUDE_INSTALL_DIR ${CMAKE_INSTALL_PREFIX}/include CACHE PATH "Installation prefix for C header files" FORCE)
|
|
||||||
|
|
||||||
CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/libmusicbrainz5.pc.cmake ${CMAKE_CURRENT_BINARY_DIR}/libmusicbrainz5.pc)
|
|
||||||
@@ -3,38 +3,23 @@ DESCRIPTION = "The MusicBrainz client is a library which can be built into other
|
|||||||
HOMEPAGE = "http://musicbrainz.org"
|
HOMEPAGE = "http://musicbrainz.org"
|
||||||
LICENSE = "LGPLv2.1+"
|
LICENSE = "LGPLv2.1+"
|
||||||
LIC_FILES_CHKSUM = "file://COPYING.txt;md5=fbc093901857fcd118f065f900982c24"
|
LIC_FILES_CHKSUM = "file://COPYING.txt;md5=fbc093901857fcd118f065f900982c24"
|
||||||
DEPENDS = "expat libxml2 libxml2-native neon neon-native"
|
DEPENDS = "expat libxml2 libxml2-native neon neon-native libmusicbrainz-native"
|
||||||
|
|
||||||
PV = "5.1.0+git${SRCPV}"
|
PV = "5.1.0+git${SRCPV}"
|
||||||
|
|
||||||
SRCREV = "44c05779dd996035758f5ec426766aeedce29cc3"
|
SRCREV = "8be45b12a86bc0e46f2f836c8ac88e1e98d82aee"
|
||||||
SRC_URI = "git://github.com/metabrainz/libmusicbrainz.git \
|
SRC_URI = "git://github.com/metabrainz/libmusicbrainz.git"
|
||||||
file://allow-libdir-override.patch "
|
|
||||||
|
|
||||||
S = "${WORKDIR}/git"
|
S = "${WORKDIR}/git"
|
||||||
|
|
||||||
inherit cmake pkgconfig
|
inherit cmake pkgconfig
|
||||||
|
|
||||||
do_configure_prepend() {
|
EXTRA_OECMAKE_append_class-target = " -DIMPORT_EXECUTABLES=${STAGING_LIBDIR_NATIVE}/cmake/${BPN}/ImportExecutables.cmake"
|
||||||
# The native build really doesn't like being rebuilt, so delete
|
|
||||||
# it if it's already present. Also delete all other files not
|
do_install_append_class-native() {
|
||||||
# known to Git to fix subsequent invocations of do_configure.
|
install -Dm 0755 ${B}/src/make-c-interface ${D}${bindir}/make-c-interface
|
||||||
git clean -dfx -e /.pc/ -e /patches/ .
|
install -Dm 0644 ${B}/ImportExecutables.cmake ${D}${libdir}/cmake/${BPN}/ImportExecutables.cmake
|
||||||
mkdir build-native
|
sed -i -e s:'${B}'/src/::g ${D}${libdir}/cmake/${BPN}/ImportExecutables.cmake
|
||||||
cd build-native
|
|
||||||
LDFLAGS="${BUILD_LDFLAGS}" \
|
|
||||||
cmake -DCMAKE_C_FLAGS=${BUILD_CFLAGS} \
|
|
||||||
-DCMAKE_C_COMPILER=${BUILD_CC} \
|
|
||||||
-DCMAKE_CXX_FLAGS=${BUILD_CXXFLAGS} \
|
|
||||||
-DCMAKE_CXX_COMPILER=${BUILD_CXX} \
|
|
||||||
-DCMAKE_EXE_LINKER_FLAGS=${BUILD_LDFLAGS} \
|
|
||||||
..
|
|
||||||
make make-c-interface
|
|
||||||
cd ..
|
|
||||||
}
|
}
|
||||||
|
|
||||||
EXTRA_OECMAKE = "-DLIB_INSTALL_DIR:PATH=${libdir} \
|
BBCLASSEXTEND = "native"
|
||||||
-DIMPORT_EXECUTABLES=build-native/ImportExecutables.cmake"
|
|
||||||
|
|
||||||
# out-of-tree building doesn't appear to work for this package.
|
|
||||||
B = "${S}"
|
|
||||||
|
|||||||
Reference in New Issue
Block a user