diff options
author | Baptiste Durand <baptiste.durand@open.eurogiciel.org> | 2015-03-12 14:22:15 +0100 |
---|---|---|
committer | Baptiste Durand <baptiste.durand@open.eurogiciel.org> | 2015-03-12 14:23:25 +0100 |
commit | e7b12f5427f663751910c6e2d3c9e72aa78c9701 (patch) | |
tree | d44bd7eca2130c275d222c926be32f063cbc4618 | |
parent | 7f61baf0da0a485016dc1a3023a3ced06a218a11 (diff) | |
download | tizen-distro-e7b12f5427f663751910c6e2d3c9e72aa78c9701.tar.gz tizen-distro-e7b12f5427f663751910c6e2d3c9e72aa78c9701.tar.bz2 tizen-distro-e7b12f5427f663751910c6e2d3c9e72aa78c9701.zip |
Add gmock & gtest for cyanara packagesandbox/xroche/toybox
Change-Id: I175326e523b04e2cd3f17f9050f01cb685ddfe44
Signed-off-by: Baptiste Durand <baptiste.durand@open.eurogiciel.org>
7 files changed, 260 insertions, 0 deletions
diff --git a/meta-openembedded/meta-oe/recipes-test/fwts/fwts_git.bb b/meta-openembedded/meta-oe/recipes-test/fwts/fwts_git.bb new file mode 100644 index 0000000000..b943d6d48e --- /dev/null +++ b/meta-openembedded/meta-oe/recipes-test/fwts/fwts_git.bb @@ -0,0 +1,24 @@ +SUMMARY = "Firmware testsuite" +DESCRIPTION = "The tool fwts comprises of over fifty tests that are designed to exercise and test different aspects of a machine's firmware. Many of these tests need super user access to read BIOS data and ACPI tables, so the tool requires running with super user privileges (e.g. with sudo)." +HOMEPAGE = "https://wiki.ubuntu.com/Kernel/Reference/fwts" + +LICENSE = "GPLv2+" +LIC_FILES_CHKSUM = "file://src/main.c;beginline=1;endline=16;md5=deb8af5388e838d133eaa036f4d1496f" + +PV = "14.12.00" + +SRCREV = "efc18d16294f492b7f72bba64344b2eed50e6a69" +SRC_URI = "git://kernel.ubuntu.com/hwe/fwts.git" + +S = "${WORKDIR}/git" + +DEPENDS = "libpcre json-c glib-2.0" + +inherit autotools-brokensep + +CFLAGS += "-I${STAGING_INCDIR}/json-c" + +FILES_${PN} += "${libdir}/fwts/lib*${SOLIBS}" +FILES_${PN}-dev += "${libdir}/fwts/lib*${SOLIBSDEV} ${libdir}/fwts/lib*.la" +FILES_${PN}-staticdev += "${libdir}/fwts/lib*a" +FILES_${PN}-dbg += "${libdir}/fwts/.debug" diff --git a/meta-openembedded/meta-oe/recipes-test/gmock/gmock/cmake-Add-install-command-for-libraries-and-headers.patch b/meta-openembedded/meta-oe/recipes-test/gmock/gmock/cmake-Add-install-command-for-libraries-and-headers.patch new file mode 100644 index 0000000000..92a6393655 --- /dev/null +++ b/meta-openembedded/meta-oe/recipes-test/gmock/gmock/cmake-Add-install-command-for-libraries-and-headers.patch @@ -0,0 +1,40 @@ +From ba0a7d65c918cb7e3f2073553c4cc7af5858ed03 Mon Sep 17 00:00:00 2001 +From: Otavio Salvador <otavio@ossystems.com.br> +Date: Thu, 31 Jul 2014 16:54:00 -0300 +Subject: [PATCH] cmake: Add install command for libraries and headers +Organization: O.S. Systems Software LTDA. + +Upstream-Status: Inappropriate [embedded specific] + +Signed-off-by: Otavio Salvador <otavio@ossystems.com.br> +--- + CMakeLists.txt | 6 ++++++ + 1 file changed, 6 insertions(+) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 572d044..90e797a 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -63,6 +63,8 @@ include_directories("${gmock_SOURCE_DIR}/include" + # Test sources. + "${gtest_SOURCE_DIR}") + ++install(DIRECTORY ${gmock_SOURCE_DIR}/include/gmock DESTINATION include) ++ + ######################################################################## + # + # Defines the gmock & gmock_main libraries. User tests should link +@@ -82,6 +84,10 @@ cxx_library(gmock_main + src/gmock-all.cc + src/gmock_main.cc) + ++ ++install(TARGETS gmock DESTINATION lib) ++install(TARGETS gmock_main DESTINATION lib) ++ + ######################################################################## + # + # Google Mock's own tests. +-- +1.9.1 + diff --git a/meta-openembedded/meta-oe/recipes-test/gmock/gmock/cmake-gmock.pc.in-Add-pkg-config-support.patch b/meta-openembedded/meta-oe/recipes-test/gmock/gmock/cmake-gmock.pc.in-Add-pkg-config-support.patch new file mode 100644 index 0000000000..aa38fe49ff --- /dev/null +++ b/meta-openembedded/meta-oe/recipes-test/gmock/gmock/cmake-gmock.pc.in-Add-pkg-config-support.patch @@ -0,0 +1,56 @@ +From 45661183a7c78d8c4f75adcf53c6ddd663dc8b2d Mon Sep 17 00:00:00 2001 +From: Mario Domenech Goulart <mario@ossystems.com.br> +Date: Mon, 20 Oct 2014 17:12:58 -0200 +Subject: [PATCH] CMakeLists, gmock.pc.in: Add pkg-config support +Organization: O.S. Systems Software LTDA. + +Signed-off-by: Mario Domenech Goulart <mario@ossystems.com.br> +--- + CMakeLists.txt | 7 ++++++- + gmock.pc.in | 9 +++++++++ + 2 files changed, 15 insertions(+), 1 deletion(-) + create mode 100644 gmock.pc.in + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 90e797a..98fd824 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -27,6 +27,9 @@ if (COMMAND pre_project_set_up_hermetic_build) + pre_project_set_up_hermetic_build() + endif() + ++# pkg-config support ++configure_file("gmock.pc.in" "gmock.pc" @ONLY) ++ + ######################################################################## + # + # Project-wide settings +@@ -87,7 +90,9 @@ cxx_library(gmock_main + + install(TARGETS gmock DESTINATION lib) + install(TARGETS gmock_main DESTINATION lib) +- ++install(FILES "${CMAKE_CURRENT_BINARY_DIR}/gmock.pc" ++ DESTINATION "${CMAKE_INSTALL_PREFIX}/lib/pkgconfig/" ++) + ######################################################################## + # + # Google Mock's own tests. +diff --git a/gmock.pc.in b/gmock.pc.in +new file mode 100644 +index 0000000..08ad8d2 +--- /dev/null ++++ b/gmock.pc.in +@@ -0,0 +1,9 @@ ++Name: libgmock ++Version: 1.7.0 ++Description: Google's framework for writing C++ tests on a variety of platforms ++ ++prefix=@CMAKE_INSTALL_PREFIX@ ++includedir=${prefix}/include ++libdir=${prefix}/lib ++Cflags:-I${includedir}/gmock ++Libs: -L${libdir} -lgmock -lgmock_main +-- +1.9.1 + diff --git a/meta-openembedded/meta-oe/recipes-test/gmock/gmock_1.7.0.bb b/meta-openembedded/meta-oe/recipes-test/gmock/gmock_1.7.0.bb new file mode 100644 index 0000000000..bd5cf4e200 --- /dev/null +++ b/meta-openembedded/meta-oe/recipes-test/gmock/gmock_1.7.0.bb @@ -0,0 +1,23 @@ +DESCRIPTION = "Google C++ Mocking Framework" +SECTION = "libs" +HOMEPAGE = "http://code.google.com/p/googlemock/" +LICENSE = "BSD-3-Clause" +LIC_FILES_CHKSUM = "file://LICENSE;md5=cbbd27594afd089daa160d3a16dd515a" + +SRC_URI = "\ + http://googlemock.googlecode.com/files/${BPN}-${PV}.zip \ + file://cmake-Add-install-command-for-libraries-and-headers.patch \ + file://cmake-gmock.pc.in-Add-pkg-config-support.patch \ +" + +SRC_URI[md5sum] = "073b984d8798ea1594f5e44d85b20d66" +SRC_URI[sha256sum] = "26fcbb5925b74ad5fc8c26b0495dfc96353f4d553492eb97e85a8a6d2f43095b" + +inherit lib_package cmake + +ALLOW_EMPTY_${PN} = "1" +ALLOW_EMPTY_${PN}-dbg = "1" + +RDEPENDS_${PN}-dev += "${PN}-staticdev" + +BBCLASSEXTEND = "nativesdk" diff --git a/meta-openembedded/meta-oe/recipes-test/gtest/gtest/CMakeLists-gtest.pc.in-Add-pkg-config-support-to-gte.patch b/meta-openembedded/meta-oe/recipes-test/gtest/gtest/CMakeLists-gtest.pc.in-Add-pkg-config-support-to-gte.patch new file mode 100644 index 0000000000..1ece136b6a --- /dev/null +++ b/meta-openembedded/meta-oe/recipes-test/gtest/gtest/CMakeLists-gtest.pc.in-Add-pkg-config-support-to-gte.patch @@ -0,0 +1,55 @@ +From d4b25ce723812faf78d8ee038b7cbed00cbba682 Mon Sep 17 00:00:00 2001 +From: Rodrigo Caimi <caimi@datacom.ind.br> +Date: Tue, 7 Oct 2014 15:37:10 -0300 +Subject: [PATCH] CMakeLists, gtest.pc.in: Add pkg-config support to gtest + 1.7.0 + +Signed-off-by: Rodrigo Caimi <caimi@datacom.ind.br> +--- + CMakeLists.txt | 6 ++++++ + gtest.pc.in | 9 +++++++++ + 2 files changed, 15 insertions(+) + create mode 100644 gtest.pc.in + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 281c4c2..e4354a8 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -29,6 +29,9 @@ if (COMMAND pre_project_set_up_hermetic_build) + pre_project_set_up_hermetic_build() + endif() + ++# pkg-config support ++configure_file("gtest.pc.in" "gtest.pc" @ONLY) ++ + ######################################################################## + # + # Project-wide settings +@@ -75,6 +78,9 @@ target_link_libraries(gtest_main gtest) + + install(TARGETS gtest DESTINATION lib) + install(TARGETS gtest_main DESTINATION lib) ++install(FILES "${CMAKE_CURRENT_BINARY_DIR}/gtest.pc" ++ DESTINATION "${CMAKE_INSTALL_PREFIX}/lib/pkgconfig/" ++) + + ######################################################################## + # +diff --git a/gtest.pc.in b/gtest.pc.in +new file mode 100644 +index 0000000..57b1049 +--- /dev/null ++++ b/gtest.pc.in +@@ -0,0 +1,9 @@ ++Name: libgtest ++Version: 1.7.0 ++Description: Google's framework for writing C++ tests on a variety of platforms ++ ++prefix=@CMAKE_INSTALL_PREFIX@ ++includedir=${prefix}/include ++libdir=${prefix}/lib ++Cflags:-I${includedir}/gtest ++Libs: -L${libdir} -lgtest -lgtest_main +-- +1.9.1 + diff --git a/meta-openembedded/meta-oe/recipes-test/gtest/gtest/cmake-Add-install-command-for-libraries-and-headers.patch b/meta-openembedded/meta-oe/recipes-test/gtest/gtest/cmake-Add-install-command-for-libraries-and-headers.patch new file mode 100644 index 0000000000..0c160b02a9 --- /dev/null +++ b/meta-openembedded/meta-oe/recipes-test/gtest/gtest/cmake-Add-install-command-for-libraries-and-headers.patch @@ -0,0 +1,39 @@ +From 5318983562be6babeb5a6996e7dda4b31acfdba8 Mon Sep 17 00:00:00 2001 +From: Otavio Salvador <otavio@ossystems.com.br> +Date: Wed, 30 Jul 2014 16:49:53 -0300 +Subject: [PATCH] cmake: Add install command for libraries and headers +Organization: O.S. Systems Software LTDA. + +Upstream-Status: Inappropriate [embedded specific] + +Signed-off-by: Otavio Salvador <otavio@ossystems.com.br> +--- + CMakeLists.txt | 5 +++++ + 1 file changed, 5 insertions(+) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 57470c8..281c4c2 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -56,6 +56,8 @@ include_directories( + ${gtest_SOURCE_DIR}/include + ${gtest_SOURCE_DIR}) + ++install(DIRECTORY ${gtest_SOURCE_DIR}/include/gtest DESTINATION include) ++ + # Where Google Test's libraries can be found. + link_directories(${gtest_BINARY_DIR}/src) + +@@ -71,6 +73,9 @@ cxx_library(gtest "${cxx_strict}" src/gtest-all.cc) + cxx_library(gtest_main "${cxx_strict}" src/gtest_main.cc) + target_link_libraries(gtest_main gtest) + ++install(TARGETS gtest DESTINATION lib) ++install(TARGETS gtest_main DESTINATION lib) ++ + ######################################################################## + # + # Samples on how to link user tests with gtest or gtest_main. +-- +1.9.1 + diff --git a/meta-openembedded/meta-oe/recipes-test/gtest/gtest_1.7.0.bb b/meta-openembedded/meta-oe/recipes-test/gtest/gtest_1.7.0.bb new file mode 100644 index 0000000000..9f148d549e --- /dev/null +++ b/meta-openembedded/meta-oe/recipes-test/gtest/gtest_1.7.0.bb @@ -0,0 +1,23 @@ +DESCRIPTION = "Google's framework for writing C++ tests" +HOMEPAGE = "http://code.google.com/p/googletest/" +SECTION = "libs" +LICENSE = "BSD-3-Clause" +LIC_FILES_CHKSUM = "file://LICENSE;md5=cbbd27594afd089daa160d3a16dd515a" + +SRC_URI = "\ + http://googletest.googlecode.com/files/${BPN}-${PV}.zip \ + file://cmake-Add-install-command-for-libraries-and-headers.patch \ + file://CMakeLists-gtest.pc.in-Add-pkg-config-support-to-gte.patch \ +" + +SRC_URI[md5sum] = "2d6ec8ccdf5c46b05ba54a9fd1d130d7" +SRC_URI[sha256sum] = "247ca18dd83f53deb1328be17e4b1be31514cedfc1e3424f672bf11fd7e0d60d" + +inherit lib_package cmake + +ALLOW_EMPTY_${PN} = "1" +ALLOW_EMPTY_${PN}-dbg = "1" + +RDEPENDS_${PN}-dev += "${PN}-staticdev" + +BBCLASSEXTEND = "nativesdk" |