From 5b80bfd7bffd4c20d80b7c70a7130529e9a755dd Mon Sep 17 00:00:00 2001 From: ToshikazuOhiwa Date: Mon, 30 Mar 2020 09:24:26 +0900 Subject: agl-basesystem --- .../0001-Fix-convert-from-char-on-ARM-build.patch | 46 +++ .../meta-oe/recipes-test/catch2/catch2_2.4.1.bb | 24 ++ .../meta-oe/recipes-test/cppunit/cppunit_1.13.2.bb | 14 + ...e.am-do-not-preserve-file-flags-when-copy.patch | 31 ++ .../meta-oe/recipes-test/cunit/cunit_2.1-3.bb | 19 + .../cunit/files/fixup-install-docdir.patch | 36 ++ .../meta-oe/recipes-test/cxxtest/cxxtest_4.3.bb | 21 ++ .../meta-oe/recipes-test/evtest/evtest_git.bb | 17 + .../meta-oe/recipes-test/fbtest/fb-test_git.bb | 20 ++ ...01-Add-correct-printf-qualifier-for-off_t.patch | 38 ++ ...e-poll.h-instead-of-deprecated-sys-poll.h.patch | 46 +++ .../fwts/fwts/0001-Remove-Werror-from-build.patch | 52 +++ ...nstant-logical-operand-warning-with-clang.patch | 84 +++++ ...efine-__SWORD_TYPE-if-not-defined-by-libc.patch | 31 ++ .../fwts/fwts/0003-Undefine-PAGE_SIZE.patch | 28 ++ ...ntptr_t-to-fix-pointer-to-int-cast-issues.patch | 74 ++++ .../meta-oe/recipes-test/fwts/fwts_git.bb | 39 ++ .../gtest/gtest/Add-pkg-config-support.patch | 106 ++++++ .../meta-oe/recipes-test/gtest/gtest_1.8.0.bb | 24 ++ .../meta-oe/recipes-test/pm-qa/pm-qa_git.bb | 68 ++++ ...file-force-sync-after-build-in-case-reboo.patch | 31 ++ .../0001-Several-changes-to-fix-musl-build.patch | 132 +++++++ .../recipes-test/stress-ng/stress-ng_0.09.45.bb | 26 ++ ...0001-Makefile-for-cross-compile-SoftFloat.patch | 348 ++++++++++++++++++ ...0002-Makefile-for-cross-compile-TestFloat.patch | 396 +++++++++++++++++++++ .../meta-oe/recipes-test/testfloat/testfloat_3a.bb | 35 ++ 26 files changed, 1786 insertions(+) create mode 100644 external/meta-openembedded/meta-oe/recipes-test/catch2/catch2/0001-Fix-convert-from-char-on-ARM-build.patch create mode 100644 external/meta-openembedded/meta-oe/recipes-test/catch2/catch2_2.4.1.bb create mode 100644 external/meta-openembedded/meta-oe/recipes-test/cppunit/cppunit_1.13.2.bb create mode 100644 external/meta-openembedded/meta-oe/recipes-test/cppunit/files/0001-doc-Makefile.am-do-not-preserve-file-flags-when-copy.patch create mode 100644 external/meta-openembedded/meta-oe/recipes-test/cunit/cunit_2.1-3.bb create mode 100644 external/meta-openembedded/meta-oe/recipes-test/cunit/files/fixup-install-docdir.patch create mode 100644 external/meta-openembedded/meta-oe/recipes-test/cxxtest/cxxtest_4.3.bb create mode 100644 external/meta-openembedded/meta-oe/recipes-test/evtest/evtest_git.bb create mode 100644 external/meta-openembedded/meta-oe/recipes-test/fbtest/fb-test_git.bb create mode 100644 external/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0001-Add-correct-printf-qualifier-for-off_t.patch create mode 100644 external/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0001-Include-poll.h-instead-of-deprecated-sys-poll.h.patch create mode 100644 external/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0001-Remove-Werror-from-build.patch create mode 100644 external/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0001-ignore-constant-logical-operand-warning-with-clang.patch create mode 100644 external/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0002-Define-__SWORD_TYPE-if-not-defined-by-libc.patch create mode 100644 external/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0003-Undefine-PAGE_SIZE.patch create mode 100644 external/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0003-use-intptr_t-to-fix-pointer-to-int-cast-issues.patch create mode 100644 external/meta-openembedded/meta-oe/recipes-test/fwts/fwts_git.bb create mode 100644 external/meta-openembedded/meta-oe/recipes-test/gtest/gtest/Add-pkg-config-support.patch create mode 100644 external/meta-openembedded/meta-oe/recipes-test/gtest/gtest_1.8.0.bb create mode 100644 external/meta-openembedded/meta-oe/recipes-test/pm-qa/pm-qa_git.bb create mode 100644 external/meta-openembedded/meta-oe/recipes-test/stress-ng/stress-ng/0001-Revert-Makefile-force-sync-after-build-in-case-reboo.patch create mode 100644 external/meta-openembedded/meta-oe/recipes-test/stress-ng/stress-ng/0001-Several-changes-to-fix-musl-build.patch create mode 100644 external/meta-openembedded/meta-oe/recipes-test/stress-ng/stress-ng_0.09.45.bb create mode 100644 external/meta-openembedded/meta-oe/recipes-test/testfloat/files/0001-Makefile-for-cross-compile-SoftFloat.patch create mode 100644 external/meta-openembedded/meta-oe/recipes-test/testfloat/files/0002-Makefile-for-cross-compile-TestFloat.patch create mode 100644 external/meta-openembedded/meta-oe/recipes-test/testfloat/testfloat_3a.bb (limited to 'external/meta-openembedded/meta-oe/recipes-test') diff --git a/external/meta-openembedded/meta-oe/recipes-test/catch2/catch2/0001-Fix-convert-from-char-on-ARM-build.patch b/external/meta-openembedded/meta-oe/recipes-test/catch2/catch2/0001-Fix-convert-from-char-on-ARM-build.patch new file mode 100644 index 00000000..30737756 --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-test/catch2/catch2/0001-Fix-convert-from-char-on-ARM-build.patch @@ -0,0 +1,46 @@ +From 5729874fa5059c39aa97cfa08fddf107b7a65c9e Mon Sep 17 00:00:00 2001 +From: Miguel Gaio +Date: Wed, 3 Oct 2018 10:22:16 +0200 +Subject: [PATCH] Fix convert from char on ARM build + +Some platforms set the signedness of char to unsigned (eg. ARM). +Convert from char should not assume the signedness of char. + +Fix build issue with -Werror,-Wtautological-unsigned-zero-compare flags. + +Signed-off-by: Miguel Gaio + +Upstream-Status: Accepted [Commit f1faaa9c107113692301ad8bb56084460ef1a2ff] + +Signed-off-by: Bartosz Golaszewski +--- + include/internal/catch_tostring.cpp | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +diff --git a/include/internal/catch_tostring.cpp b/include/internal/catch_tostring.cpp +index 4e0c027d..8cbabbf2 100644 +--- a/include/internal/catch_tostring.cpp ++++ b/include/internal/catch_tostring.cpp +@@ -205,7 +205,7 @@ std::string StringMaker::convert(bool b) { + return b ? "true" : "false"; + } + +-std::string StringMaker::convert(char value) { ++std::string StringMaker::convert(signed char value) { + if (value == '\r') { + return "'\\r'"; + } else if (value == '\f') { +@@ -222,8 +222,8 @@ std::string StringMaker::convert(char value) { + return chstr; + } + } +-std::string StringMaker::convert(signed char c) { +- return ::Catch::Detail::stringify(static_cast(c)); ++std::string StringMaker::convert(char c) { ++ return ::Catch::Detail::stringify(static_cast(c)); + } + std::string StringMaker::convert(unsigned char c) { + return ::Catch::Detail::stringify(static_cast(c)); +-- +2.19.1 + diff --git a/external/meta-openembedded/meta-oe/recipes-test/catch2/catch2_2.4.1.bb b/external/meta-openembedded/meta-oe/recipes-test/catch2/catch2_2.4.1.bb new file mode 100644 index 00000000..0183c2e4 --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-test/catch2/catch2_2.4.1.bb @@ -0,0 +1,24 @@ +DESCRIPTION = "A modern, C++-native, header-only, test framework for unit-tests, \ +TDD and BDD - using C++11, C++14, C++17 and later." +AUTHOR = "Phil Nash, Martin Horenovsky and others" +HOMEPAGE = "https://github.com/catchorg/Catch2" +LICENSE = "BSL-1.0" +LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=e4224ccaecb14d942c71d31bef20d78c" + +SRC_URI = "git://github.com/catchorg/Catch2.git \ + file://0001-Fix-convert-from-char-on-ARM-build.patch" +SRCREV = "9e1bdca4667295fcb16265eae00efa8423f07007" + +S = "${WORKDIR}/git" + +inherit cmake python3native + +# Header-only library +RDEPENDS_${PN}-dev = "" +RRECOMMENDS_${PN}-dbg = "${PN}-dev (= ${EXTENDPKGV})" + +do_install_append() { + rm ${D}/${datadir}/Catch2/lldbinit + rm ${D}/${datadir}/Catch2/gdbinit + rmdir ${D}/${datadir}/Catch2/ +} diff --git a/external/meta-openembedded/meta-oe/recipes-test/cppunit/cppunit_1.13.2.bb b/external/meta-openembedded/meta-oe/recipes-test/cppunit/cppunit_1.13.2.bb new file mode 100644 index 00000000..65b08b06 --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-test/cppunit/cppunit_1.13.2.bb @@ -0,0 +1,14 @@ +DESCRIPTION = "CppUnit is the C++ port of the famous JUnit framework for unit testing. Test output is in XML for automatic testing and GUI based for supervised tests. " +HOMEPAGE = "http://www.freedesktop.org/wiki/Software/cppunit" +LICENSE = "LGPL-2.1" +SECTION = "libs" + +LIC_FILES_CHKSUM = "file://COPYING;md5=7fbc338309ac38fefcd64b04bb903e34" +SRC_URI = " \ + http://dev-www.libreoffice.org/src/cppunit-${PV}.tar.gz \ + file://0001-doc-Makefile.am-do-not-preserve-file-flags-when-copy.patch \ +" +SRC_URI[md5sum] = "d1c6bdd5a76c66d2c38331e2d287bc01" +SRC_URI[sha256sum] = "3f47d246e3346f2ba4d7c9e882db3ad9ebd3fcbd2e8b732f946e0e3eeb9f429f" + +inherit autotools diff --git a/external/meta-openembedded/meta-oe/recipes-test/cppunit/files/0001-doc-Makefile.am-do-not-preserve-file-flags-when-copy.patch b/external/meta-openembedded/meta-oe/recipes-test/cppunit/files/0001-doc-Makefile.am-do-not-preserve-file-flags-when-copy.patch new file mode 100644 index 00000000..6a20c128 --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-test/cppunit/files/0001-doc-Makefile.am-do-not-preserve-file-flags-when-copy.patch @@ -0,0 +1,31 @@ +From 9d7ce869607d123cd9837890d71f940c5ced3393 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Andreas=20M=C3=BCller?= +Date: Mon, 29 Feb 2016 07:58:20 +0100 +Subject: [PATCH] doc/Makefile.am: do not preserve file flags when copying +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Upstream-Status: Inappropriate [cross specific] + +Signed-off-by: Andreas Müller +--- + doc/Makefile.am | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/doc/Makefile.am b/doc/Makefile.am +index 8815476..3237499 100644 +--- a/doc/Makefile.am ++++ b/doc/Makefile.am +@@ -22,7 +22,7 @@ htmldir += $(pkgdatadir)/html + html_DATA += $(static_pages) html/index.html + + install-data-hook: +- cp -pR html/* $(DESTDIR)$(htmldir) ++ cp -R html/* $(DESTDIR)$(htmldir) + + # Automake's "distcheck" is sensitive to having files left over + # after "make uninstall", so we have to clean up the install hook. +-- +2.5.0 + diff --git a/external/meta-openembedded/meta-oe/recipes-test/cunit/cunit_2.1-3.bb b/external/meta-openembedded/meta-oe/recipes-test/cunit/cunit_2.1-3.bb new file mode 100644 index 00000000..c9d87e36 --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-test/cunit/cunit_2.1-3.bb @@ -0,0 +1,19 @@ +DESCRIPTION = "CUnit is a C framework for unit testing. Test output supports comandline and GUI results reporting" +HOMEPAGE = "http://cunit.sourceforge.net" +LICENSE = "LGPL-2.0" +SECTION = "libs" +LIC_FILES_CHKSUM = "file://COPYING;md5=7734aa853b85d6f935466f081490ddbb" + +S = "${WORKDIR}/CUnit-${PV}" + +SRC_URI = "${SOURCEFORGE_MIRROR}/project/cunit/CUnit/${PV}/CUnit-${PV}.tar.bz2 \ + file://fixup-install-docdir.patch" +SRC_URI[md5sum] = "b5f1a9f6093869c070c6e4a9450cc10c" +SRC_URI[sha256sum] = "f5b29137f845bb08b77ec60584fdb728b4e58f1023e6f249a464efa49a40f214" + +inherit autotools-brokensep remove-libtool + +EXTRA_OECONF = "--enable-memtrace --enable-automated --enable-basic --enable-console" + +FILES_${PN}-dev += "${datadir}/CUnit" +FILES_${PN}-doc += "${docdir}" diff --git a/external/meta-openembedded/meta-oe/recipes-test/cunit/files/fixup-install-docdir.patch b/external/meta-openembedded/meta-oe/recipes-test/cunit/files/fixup-install-docdir.patch new file mode 100644 index 00000000..c3282273 --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-test/cunit/files/fixup-install-docdir.patch @@ -0,0 +1,36 @@ +From: "Mike Holmes" +Date: Thu, 30 October 2014 16:21:03 -0500 +Subject: [PATCH] fixup-install-docdir + +The default configuration macros for CUnit install the documentation and +header files in locations not consistent with the OE filesystem layout. +So here we specify new locations which are consistent with OE filesystems. + +Upstream-Status: Inappropriate - configuration for OE build environment + +Signed-off-by: Mike Holmes +Signed-off-by: Gary S. Robertson +--- + +diff -uNr a/doc/headers/Makefile.am b/doc/headers/Makefile.am +--- a/doc/headers/Makefile.am 2014-10-30 22:06:29.704574162 +0100 ++++ b/doc/headers/Makefile.am 2014-10-30 22:07:43.578524791 +0100 +@@ -1,6 +1,6 @@ + ## Process this file with automake to produce Makefile.in + +-dochdrdir = $(prefix)/doc/@PACKAGE@/headers ++dochdrdir = $(docdir)/headers + + INCLUDE_FILES = \ + Automated.h \ +diff -uNr a/doc/Makefile.am b/doc/Makefile.am +--- a/doc/Makefile.am 2014-10-30 22:06:29.704574162 +0100 ++++ b/doc/Makefile.am 2014-10-30 22:07:01.461412166 +0100 +@@ -1,7 +1,5 @@ + ## Process this file with automake to produce Makefile.in + +-docdir = $(prefix)/doc/@PACKAGE@ +- + doc_DATA = \ + CUnit_doc.css \ + error_handling.html \ diff --git a/external/meta-openembedded/meta-oe/recipes-test/cxxtest/cxxtest_4.3.bb b/external/meta-openembedded/meta-oe/recipes-test/cxxtest/cxxtest_4.3.bb new file mode 100644 index 00000000..29150117 --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-test/cxxtest/cxxtest_4.3.bb @@ -0,0 +1,21 @@ +DESCRIPTION = "CxxTest is a unit testing framework for C++ that is similar in spirit to JUnit, CppUnit, and xUnit." +HOMEPAGE = "http://cxxtest.com/" +LICENSE = "LGPL-2.0" +SECTION = "devel" + +SRC_URI = "http://downloads.sourceforge.net/project/cxxtest/cxxtest/${PV}/cxxtest-${PV}.tar.gz" +SRC_URI[md5sum] = "b3a24b3e1aad9acf6adac37f4c3f83ec" +SRC_URI[sha256sum] = "356d0f4810e8eb5c344147a0cca50fc0d84122c286e7644b61cb365c2ee22083" +LIC_FILES_CHKSUM = "file://${WORKDIR}/cxxtest-${PV}/COPYING;md5=e6a600fd5e1d9cbde2d983680233ad02" +S = "${WORKDIR}/cxxtest-${PV}/python" + +inherit distutils + +do_install_append() { + install -d ${D}${includedir} + cp -a ../cxxtest ${D}${includedir} + sed '1c\ +#!/usr/bin/env python' -i ${D}${bindir}/cxxtestgen +} + +BBCLASSEXTEND = "native nativesdk" diff --git a/external/meta-openembedded/meta-oe/recipes-test/evtest/evtest_git.bb b/external/meta-openembedded/meta-oe/recipes-test/evtest/evtest_git.bb new file mode 100644 index 00000000..fa0d6e2f --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-test/evtest/evtest_git.bb @@ -0,0 +1,17 @@ +SUMMARY = "Simple tool for input event debugging" +HOMEPAGE = "http://people.freedesktop.org/~whot/evtest/" +AUTHOR = "Vojtech Pavlik " +SECTION = "console/utils" +LICENSE = "GPLv2" +LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe" + +DEPENDS = "libxml2" + +SRCREV = "ab140a2dab1547f7deb5233be6d94a388cf08b26" +SRC_URI = "git://anongit.freedesktop.org/evtest;protocol=git" + +PV = "1.33+${SRCPV}" + +S = "${WORKDIR}/git" + +inherit autotools pkgconfig diff --git a/external/meta-openembedded/meta-oe/recipes-test/fbtest/fb-test_git.bb b/external/meta-openembedded/meta-oe/recipes-test/fbtest/fb-test_git.bb new file mode 100644 index 00000000..6a9d4b27 --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-test/fbtest/fb-test_git.bb @@ -0,0 +1,20 @@ +SUMMARY = "Test suite for Linux framebuffer" + +PV = "1.1.0" + +LICENSE = "GPLv2" +LIC_FILES_CHKSUM = "file://COPYING;md5=eb723b61539feef013de476e68b5c50a" + +SRCREV = "063ec650960c2d79ac51f5c5f026cb05343a33e2" +SRC_URI = "git://github.com/prpplague/fb-test-app.git" + +S = "${WORKDIR}/git" + +do_install() { + install -d ${D}${bindir} + install -m 0755 fb-test ${D}${bindir} + # avoid collisions with perf (perf) and mesa-demos (offset) + for prog in perf rect offset ; do + install -m 0755 $prog ${D}${bindir}/fb-$prog + done +} diff --git a/external/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0001-Add-correct-printf-qualifier-for-off_t.patch b/external/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0001-Add-correct-printf-qualifier-for-off_t.patch new file mode 100644 index 00000000..c2d679aa --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0001-Add-correct-printf-qualifier-for-off_t.patch @@ -0,0 +1,38 @@ +From 613e5cfe7751068062cc92f83870e436669fc0a8 Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Thu, 8 Jun 2017 16:49:50 -0700 +Subject: [PATCH] Add correct printf qualifier for off_t + +Signed-off-by: Khem Raj + +--- + src/bios/ebda_region/ebda_region.c | 8 ++++---- + 1 file changed, 4 insertions(+), 4 deletions(-) + +diff --git a/src/bios/ebda_region/ebda_region.c b/src/bios/ebda_region/ebda_region.c +index 16c39357..ad6d635c 100644 +--- a/src/bios/ebda_region/ebda_region.c ++++ b/src/bios/ebda_region/ebda_region.c +@@ -83,9 +83,9 @@ static int ebda_test1(fwts_framework *fw) + if ((entry != NULL) && + (entry->type == FWTS_MEMORY_MAP_RESERVED || + entry->type == FWTS_MEMORY_MAP_ACPI)) { +- fwts_passed(fw, "EBDA region mapped at 0x%lx and reserved as a %" PRId64 ++ fwts_passed(fw, "EBDA region mapped at 0x%jdx and reserved as a %" PRId64 + "K region in the %s table at 0x%" PRIx64 "..0x%" PRIx64 ".", +- ebda_addr, ++ (intmax_t)ebda_addr, + (entry->end_address - entry->start_address) / 1024, + memory_map_name, + entry->start_address, +@@ -93,8 +93,8 @@ static int ebda_test1(fwts_framework *fw) + } else + fwts_failed(fw, LOG_LEVEL_MEDIUM, + "EBDAMappedNotReserved", +- "EBDA region mapped at 0x%lx but not reserved in the %s table.", +- ebda_addr, memory_map_name); ++ "EBDA region mapped at 0x%jdx but not reserved in the %s table.", ++ (intmax_t)ebda_addr, memory_map_name); + + return FWTS_OK; + } diff --git a/external/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0001-Include-poll.h-instead-of-deprecated-sys-poll.h.patch b/external/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0001-Include-poll.h-instead-of-deprecated-sys-poll.h.patch new file mode 100644 index 00000000..4baefe4a --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0001-Include-poll.h-instead-of-deprecated-sys-poll.h.patch @@ -0,0 +1,46 @@ +From ed988c27efde5355c3ba9d0de8a14a4a40f798cc Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Tue, 6 Jun 2017 07:25:09 -0700 +Subject: [PATCH] Include poll.h instead of deprecated sys/poll.h + +Upstream-Status: Pending + +Signed-off-by: Khem Raj + +--- + src/lib/src/fwts_ipmi.c | 3 ++- + src/lib/src/fwts_pipeio.c | 2 +- + 2 files changed, 3 insertions(+), 2 deletions(-) + +diff --git a/src/lib/src/fwts_ipmi.c b/src/lib/src/fwts_ipmi.c +index a4c8a511..e298969e 100644 +--- a/src/lib/src/fwts_ipmi.c ++++ b/src/lib/src/fwts_ipmi.c +@@ -18,10 +18,11 @@ + * + */ + ++#include ++ + #include + #include + #include +-#include + #include + #include + +diff --git a/src/lib/src/fwts_pipeio.c b/src/lib/src/fwts_pipeio.c +index 3b3cfaff..289564d1 100644 +--- a/src/lib/src/fwts_pipeio.c ++++ b/src/lib/src/fwts_pipeio.c +@@ -30,9 +30,9 @@ + #include + #include + #include ++#include + + #include +-#include + #include + #include + #include diff --git a/external/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0001-Remove-Werror-from-build.patch b/external/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0001-Remove-Werror-from-build.patch new file mode 100644 index 00000000..611ccc8f --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0001-Remove-Werror-from-build.patch @@ -0,0 +1,52 @@ +From 475979cf5c1af978f4e8409666365ec75b3320ea Mon Sep 17 00:00:00 2001 +From: Benjamin Berg +Date: Mon, 21 Aug 2017 10:34:40 +0200 +Subject: [PATCH] Remove -Werror from build + +Upstream-Status: Pending + +--- + src/Makefile.am | 2 +- + src/lib/src/Makefile.am | 2 +- + src/utilities/Makefile.am | 2 +- + 3 files changed, 3 insertions(+), 3 deletions(-) + +diff --git a/src/Makefile.am b/src/Makefile.am +index 4daa9e8f..873f23eb 100644 +--- a/src/Makefile.am ++++ b/src/Makefile.am +@@ -14,7 +14,7 @@ AM_CPPFLAGS = \ + `pkg-config --silence-errors --cflags json` \ + `pkg-config --silence-errors --cflags json-c` \ + -pthread `pkg-config --cflags glib-2.0 gio-2.0` \ +- -Wall -Werror -Wextra ++ -Wall -Wextra + + bin_PROGRAMS = fwts + +diff --git a/src/lib/src/Makefile.am b/src/lib/src/Makefile.am +index fa232451..082403a2 100644 +--- a/src/lib/src/Makefile.am ++++ b/src/lib/src/Makefile.am +@@ -24,7 +24,7 @@ AM_CPPFLAGS = \ + `pkg-config --silence-errors --cflags json-c` \ + `pkg-config --cflags glib-2.0 gio-2.0` \ + -DDATAROOTDIR=\"$(datarootdir)\" \ +- -Wall -Werror -Wextra ++ -Wall -Wextra + + pkglib_LTLIBRARIES = libfwts.la + +diff --git a/src/utilities/Makefile.am b/src/utilities/Makefile.am +index aa37de55..4d5297cc 100644 +--- a/src/utilities/Makefile.am ++++ b/src/utilities/Makefile.am +@@ -16,7 +16,7 @@ + # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + # + +-AM_CPPFLAGS = -Wall -Werror -Wextra -DDATAROOTDIR=\"$(datarootdir)\" \ ++AM_CPPFLAGS = -Wall -Wextra -DDATAROOTDIR=\"$(datarootdir)\" \ + `pkg-config --silence-errors --cflags json` \ + `pkg-config --silence-errors --cflags json-c` + diff --git a/external/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0001-ignore-constant-logical-operand-warning-with-clang.patch b/external/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0001-ignore-constant-logical-operand-warning-with-clang.patch new file mode 100644 index 00000000..ae3665b4 --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0001-ignore-constant-logical-operand-warning-with-clang.patch @@ -0,0 +1,84 @@ +From 5bd05ad8569880985ddf6d4c06ed927d388c297f Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Wed, 19 Oct 2016 01:57:16 +0000 +Subject: [PATCH] ignore constant-logical-operand warning with clang + +Signed-off-by: Khem Raj + +--- + src/dmi/dmicheck/dmicheck.c | 3 +++ + src/lib/src/fwts_acpi_tables.c | 5 +++++ + src/uefi/uefirtauthvar/uefirtauthvar.c | 5 +++++ + 3 files changed, 13 insertions(+) + +diff --git a/src/dmi/dmicheck/dmicheck.c b/src/dmi/dmicheck/dmicheck.c +index 3cca9db9..60fb758f 100644 +--- a/src/dmi/dmicheck/dmicheck.c ++++ b/src/dmi/dmicheck/dmicheck.c +@@ -211,6 +211,8 @@ static const char *uuid_patterns[] = { + "0A0A0A0A-0A0A-0A0A-0A0A-0A0A0A0A0A0A", + NULL, + }; ++#pragma clang diagnostic push ++#pragma clang diagnostic ignored "-Wunneeded-internal-declaration" + + static const fwts_chassis_type_map fwts_dmi_chassis_type[] = { + { "Invalid", FWTS_SMBIOS_CHASSIS_INVALID }, +@@ -251,6 +253,7 @@ static const fwts_chassis_type_map fwts_dmi_chassis_type[] = { + { "Mini PC", FWTS_SMBIOS_CHASSIS_MINI_PC }, + { "Stick PC", FWTS_SMBIOS_CHASSIS_STICK_PC }, + }; ++#pragma clang diagnostic pop + + /* Remapping table from buggy version numbers to correct values */ + static const fwts_dmi_version dmi_versions[] = { +diff --git a/src/lib/src/fwts_acpi_tables.c b/src/lib/src/fwts_acpi_tables.c +index c7ba59be..bdd224aa 100644 +--- a/src/lib/src/fwts_acpi_tables.c ++++ b/src/lib/src/fwts_acpi_tables.c +@@ -393,10 +393,14 @@ static int fwts_acpi_handle_fadt( + /* Determine FACS addr and load it. + * Will ignore the missing FACS in the hardware-reduced mode. + */ ++#pragma clang diagnostic push ++#pragma clang diagnostic ignored "-Waddress-of-packed-member" ++ + result = fwts_acpi_handle_fadt_tables(fw, fadt, + "FACS", "FIRMWARE_CTRL", "X_FIRMWARE_CTRL", + &fadt->firmware_control, &fadt->x_firmware_ctrl, + provenance); ++ + if (result != FWTS_OK) { + if ((result == FWTS_NULL_POINTER) && + fwts_acpi_is_reduced_hardware(fadt)) { +@@ -415,6 +419,7 @@ static int fwts_acpi_handle_fadt( + return FWTS_ERROR; + } + return FWTS_OK; ++#pragma clang diagnostic pop + } + + /* +diff --git a/src/uefi/uefirtauthvar/uefirtauthvar.c b/src/uefi/uefirtauthvar/uefirtauthvar.c +index c2031741..7a33d19d 100644 +--- a/src/uefi/uefirtauthvar/uefirtauthvar.c ++++ b/src/uefi/uefirtauthvar/uefirtauthvar.c +@@ -142,6 +142,9 @@ static int uefirtauthvar_deinit(fwts_framework *fw) + return FWTS_OK; + } + ++#pragma clang diagnostic push ++#pragma clang diagnostic ignored "-Wconstant-logical-operand" ++ + static int check_fw_support(fwts_framework *fw, uint64_t status) + { + if ((status == EFI_INVALID_PARAMETER) && +@@ -172,6 +175,8 @@ static int check_fw_support(fwts_framework *fw, uint64_t status) + return FWTS_OK; + } + ++#pragma clang diagnostic pop ++ + /* + * Set the created authenticated variable, AuthVarCreate, + * and checking the data size and data. diff --git a/external/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0002-Define-__SWORD_TYPE-if-not-defined-by-libc.patch b/external/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0002-Define-__SWORD_TYPE-if-not-defined-by-libc.patch new file mode 100644 index 00000000..b45e46a3 --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0002-Define-__SWORD_TYPE-if-not-defined-by-libc.patch @@ -0,0 +1,31 @@ +From 1112e51d240a206bdcf253878ef1f4963b92da8a Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Tue, 6 Jun 2017 07:37:20 -0700 +Subject: [PATCH] Define __SWORD_TYPE if not defined by libc + +__SWORD_TYPE is internal to glibc, therefore +check and define it if needed e.g. on musl + +Upstream-Status: Pending + +Signed-off-by: Khem Raj + +--- + src/lib/src/fwts_uefi.c | 4 ++++ + 1 file changed, 4 insertions(+) + +diff --git a/src/lib/src/fwts_uefi.c b/src/lib/src/fwts_uefi.c +index 544145fa..460b0b77 100644 +--- a/src/lib/src/fwts_uefi.c ++++ b/src/lib/src/fwts_uefi.c +@@ -59,6 +59,10 @@ typedef struct { + #define UEFI_IFACE_SYSFS (2) /* sysfs */ + #define UEFI_IFACE_EFIVARS (3) /* efivar fs */ + ++#ifndef __SWORD_TYPE ++typedef __typeof__( ((struct statfs *)0)->f_type ) __SWORD_TYPE; ++#endif ++ + /* File system magic numbers */ + #define PSTOREFS_MAGIC ((__SWORD_TYPE)0x6165676C) + #define EFIVARFS_MAGIC ((__SWORD_TYPE)0xde5e81e4) diff --git a/external/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0003-Undefine-PAGE_SIZE.patch b/external/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0003-Undefine-PAGE_SIZE.patch new file mode 100644 index 00000000..1d8c620e --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0003-Undefine-PAGE_SIZE.patch @@ -0,0 +1,28 @@ +From 244e9551ab9bbc1dfa91d19cd472ef254a94ae41 Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Tue, 6 Jun 2017 07:39:28 -0700 +Subject: [PATCH] Undefine PAGE_SIZE + +musl defines PAGE_SIZE and build complains +of multiple definitions + +Upstream-Status: Pending + +Signed-off-by: Khem Raj + +--- + src/lib/src/fwts_acpi_tables.c | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/src/lib/src/fwts_acpi_tables.c b/src/lib/src/fwts_acpi_tables.c +index bdd224aa..58e982a6 100644 +--- a/src/lib/src/fwts_acpi_tables.c ++++ b/src/lib/src/fwts_acpi_tables.c +@@ -42,6 +42,7 @@ + #define BIOS_START (0x000e0000) /* Start of BIOS memory */ + #define BIOS_END (0x000fffff) /* End of BIOS memory */ + #define BIOS_LENGTH (BIOS_END - BIOS_START) /* Length of BIOS memory */ ++#undef PAGE_SIZE + #define PAGE_SIZE (4096) + + static fwts_acpi_table_info tables[ACPI_MAX_TABLES]; diff --git a/external/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0003-use-intptr_t-to-fix-pointer-to-int-cast-issues.patch b/external/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0003-use-intptr_t-to-fix-pointer-to-int-cast-issues.patch new file mode 100644 index 00000000..bebbfa4a --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0003-use-intptr_t-to-fix-pointer-to-int-cast-issues.patch @@ -0,0 +1,74 @@ +From 1848b8f8b9be500046ca5d632789a068d6151815 Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Thu, 8 Jun 2017 16:50:59 -0700 +Subject: [PATCH] use intptr_t to fix pointer-to-int-cast issues + +uintptr_t is guaranteed to be wide enough that +converting a void* to uintptr_t and back again +will yield the original pointer value + +Signed-off-by: Khem Raj + +--- + src/lib/src/fwts_acpi_tables.c | 4 ++-- + src/lib/src/fwts_mmap.c | 2 +- + src/lib/src/fwts_smbios.c | 4 ++-- + 3 files changed, 5 insertions(+), 5 deletions(-) + +diff --git a/src/lib/src/fwts_acpi_tables.c b/src/lib/src/fwts_acpi_tables.c +index 58e982a6..6522032f 100644 +--- a/src/lib/src/fwts_acpi_tables.c ++++ b/src/lib/src/fwts_acpi_tables.c +@@ -156,7 +156,7 @@ static fwts_acpi_table_rsdp *fwts_acpi_get_rsdp(fwts_framework *fw, void *addr, + return NULL; + } + +- if ((mem = fwts_mmap((off_t)addr, sizeof(fwts_acpi_table_rsdp))) == FWTS_MAP_FAILED) ++ if ((mem = fwts_mmap((uintptr_t)addr, sizeof(fwts_acpi_table_rsdp))) == FWTS_MAP_FAILED) + return NULL; + + if (fwts_safe_memcpy(rsdp, mem, sizeof(fwts_acpi_table_rsdp)) != FWTS_OK) { +@@ -455,7 +455,7 @@ static int fwts_acpi_load_tables_from_firmware(fwts_framework *fw) + if ((rsdp = fwts_acpi_get_rsdp(fw, rsdp_addr, &rsdp_len)) == NULL) + return FWTS_ERROR; + +- fwts_acpi_add_table("RSDP", rsdp, (uint64_t)(off_t)rsdp_addr, rsdp_len, FWTS_ACPI_TABLE_FROM_FIRMWARE); ++ fwts_acpi_add_table("RSDP", rsdp, (uint64_t)(uintptr_t)rsdp_addr, rsdp_len, FWTS_ACPI_TABLE_FROM_FIRMWARE); + + /* Load any tables from XSDT if it's valid */ + if (rsdp->xsdt_address) { +diff --git a/src/lib/src/fwts_mmap.c b/src/lib/src/fwts_mmap.c +index e28abf87..2180b2cc 100644 +--- a/src/lib/src/fwts_mmap.c ++++ b/src/lib/src/fwts_mmap.c +@@ -81,7 +81,7 @@ int fwts_munmap(void *mem, const size_t size) + off_t offset; + + page_size = fwts_page_size(); +- offset = ((off_t)(mem)) & (page_size - 1); ++ offset = ((uintptr_t)(mem)) & (page_size - 1); + + if (munmap((void *)((uint8_t *)mem - offset), size + offset) < 0) + return FWTS_ERROR; +diff --git a/src/lib/src/fwts_smbios.c b/src/lib/src/fwts_smbios.c +index e5b3c774..c8134926 100644 +--- a/src/lib/src/fwts_smbios.c ++++ b/src/lib/src/fwts_smbios.c +@@ -55,7 +55,7 @@ static void *fwts_smbios_find_entry_uefi(fwts_framework *fw, fwts_smbios_entry * + fwts_smbios_entry *mapped_entry; + const size_t size = sizeof(fwts_smbios_entry); + +- if ((mapped_entry = fwts_mmap((off_t)addr, size)) != FWTS_MAP_FAILED) { ++ if ((mapped_entry = fwts_mmap((uintptr_t)addr, size)) != FWTS_MAP_FAILED) { + if (fwts_safe_memcpy(entry, mapped_entry, size) == FWTS_OK) { + (void)fwts_munmap(mapped_entry, size); + *type = FWTS_SMBIOS; +@@ -91,7 +91,7 @@ static void *fwts_smbios30_find_entry_uefi(fwts_framework *fw, fwts_smbios30_ent + fwts_smbios30_entry *mapped_entry; + const size_t size = sizeof(fwts_smbios30_entry); + +- if ((mapped_entry = fwts_mmap((off_t)addr, size)) != FWTS_MAP_FAILED) { ++ if ((mapped_entry = fwts_mmap((uintptr_t)addr, size)) != FWTS_MAP_FAILED) { + if (fwts_safe_memread(mapped_entry, size) == FWTS_OK) { + *entry = *mapped_entry; + (void)fwts_munmap(mapped_entry, size); diff --git a/external/meta-openembedded/meta-oe/recipes-test/fwts/fwts_git.bb b/external/meta-openembedded/meta-oe/recipes-test/fwts/fwts_git.bb new file mode 100644 index 00000000..d3fb644d --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-test/fwts/fwts_git.bb @@ -0,0 +1,39 @@ +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=31da590f3e9f3bd34dcdb9e4db568519" + +PV = "18.05.00+git${SRCPV}" + +SRCREV = "b0ec7aa2ef743d113fd8c5e57c0ca3d5edd86f0e" +SRC_URI = "git://kernel.ubuntu.com/hwe/fwts.git \ + file://0001-ignore-constant-logical-operand-warning-with-clang.patch \ + file://0001-Include-poll.h-instead-of-deprecated-sys-poll.h.patch \ + file://0002-Define-__SWORD_TYPE-if-not-defined-by-libc.patch \ + file://0003-Undefine-PAGE_SIZE.patch \ + file://0001-Add-correct-printf-qualifier-for-off_t.patch \ + file://0003-use-intptr_t-to-fix-pointer-to-int-cast-issues.patch \ + file://0001-Remove-Werror-from-build.patch \ + " + +S = "${WORKDIR}/git" + +COMPATIBLE_HOST = "(i.86|x86_64|aarch64|powerpc64).*-linux" + +DEPENDS = "libpcre json-c glib-2.0 dtc bison-native" +DEPENDS_append_libc-musl = " libexecinfo" + +inherit autotools bash-completion pkgconfig + +CFLAGS += "-I${STAGING_INCDIR}/json-c -Wno-error=unknown-pragmas" +LDFLAGS_append_libc-musl = " -lexecinfo" + +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" + +TOOLCHAIN = "gcc" + diff --git a/external/meta-openembedded/meta-oe/recipes-test/gtest/gtest/Add-pkg-config-support.patch b/external/meta-openembedded/meta-oe/recipes-test/gtest/gtest/Add-pkg-config-support.patch new file mode 100644 index 00000000..4c8977b4 --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-test/gtest/gtest/Add-pkg-config-support.patch @@ -0,0 +1,106 @@ +From ec9256bb704e94f41407fc8ace6a580491430196 Mon Sep 17 00:00:00 2001 +From: Andre McCurdy +Date: Thu, 15 Dec 2016 04:35:41 -0800 +Subject: [PATCH] Add pkg-config support + +Signed-off-by: Mario Domenech Goulart +Signed-off-by: Rodrigo Caimi +Signed-off-by: Andre McCurdy +--- + googlemock/CMakeLists.txt | 9 +++++++-- + googlemock/gmock.pc.in | 9 +++++++++ + googletest/CMakeLists.txt | 9 +++++++-- + googletest/gtest.pc.in | 9 +++++++++ + 4 files changed, 32 insertions(+), 4 deletions(-) + create mode 100644 googlemock/gmock.pc.in + create mode 100644 googletest/gtest.pc.in + +diff --git a/googlemock/CMakeLists.txt b/googlemock/CMakeLists.txt +index beb259a..f17e2d7 100644 +--- a/googlemock/CMakeLists.txt ++++ b/googlemock/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 +@@ -104,9 +107,11 @@ endif() + # + # Install rules + install(TARGETS gmock gmock_main +- DESTINATION lib) ++ DESTINATION ${CMAKE_INSTALL_LIBDIR}) + install(DIRECTORY ${gmock_SOURCE_DIR}/include/gmock +- DESTINATION include) ++ DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}) ++install(FILES "${CMAKE_CURRENT_BINARY_DIR}/gmock.pc" ++ DESTINATION "${CMAKE_INSTALL_LIBDIR}/pkgconfig/") + + ######################################################################## + # +diff --git a/googlemock/gmock.pc.in b/googlemock/gmock.pc.in +new file mode 100644 +index 0000000..04bc0b4 +--- /dev/null ++++ b/googlemock/gmock.pc.in +@@ -0,0 +1,9 @@ ++Name: libgmock ++Version: 1.8.0 ++Description: Google's framework for writing C++ tests on a variety of platforms ++ ++prefix=@CMAKE_INSTALL_PREFIX@ ++includedir=@CMAKE_INSTALL_INCLUDEDIR@ ++libdir=@CMAKE_INSTALL_LIBDIR@ ++Cflags:-I${includedir}/gmock ++Libs: -L${libdir} -lgmock -lgmock_main +diff --git a/googletest/CMakeLists.txt b/googletest/CMakeLists.txt +index 621d0f0..58aaf54 100644 +--- a/googletest/CMakeLists.txt ++++ b/googletest/CMakeLists.txt +@@ -34,6 +34,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 +@@ -103,9 +106,11 @@ endif() + # + # Install rules + install(TARGETS gtest gtest_main +- DESTINATION lib) ++ DESTINATION ${CMAKE_INSTALL_LIBDIR}) + install(DIRECTORY ${gtest_SOURCE_DIR}/include/gtest +- DESTINATION include) ++ DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}) ++install(FILES "${CMAKE_CURRENT_BINARY_DIR}/gtest.pc" ++ DESTINATION "${CMAKE_INSTALL_LIBDIR}/pkgconfig/") + + ######################################################################## + # +diff --git a/googletest/gtest.pc.in b/googletest/gtest.pc.in +new file mode 100644 +index 0000000..fb95152 +--- /dev/null ++++ b/googletest/gtest.pc.in +@@ -0,0 +1,9 @@ ++Name: libgtest ++Version: 1.8.0 ++Description: Google's framework for writing C++ tests on a variety of platforms ++ ++prefix=@CMAKE_INSTALL_PREFIX@ ++includedir=@CMAKE_INSTALL_INCLUDEDIR@ ++libdir=@CMAKE_INSTALL_LIBDIR@ ++Cflags:-I${includedir}/gtest ++Libs: -L${libdir} -lgtest -lgtest_main +-- +1.9.1 + diff --git a/external/meta-openembedded/meta-oe/recipes-test/gtest/gtest_1.8.0.bb b/external/meta-openembedded/meta-oe/recipes-test/gtest/gtest_1.8.0.bb new file mode 100644 index 00000000..48cf4e04 --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-test/gtest/gtest_1.8.0.bb @@ -0,0 +1,24 @@ +DESCRIPTION = "Google's framework for writing C++ tests" +HOMEPAGE = "https://github.com/google/googletest" +SECTION = "libs" +LICENSE = "BSD-3-Clause" +LIC_FILES_CHKSUM = "file://googlemock/LICENSE;md5=cbbd27594afd089daa160d3a16dd515a \ + file://googletest/LICENSE;md5=cbbd27594afd089daa160d3a16dd515a" + +PROVIDES += "gmock" + +S = "${WORKDIR}/git" +SRCREV = "ec44c6c1675c25b9827aacd08c02433cccde7780" +SRC_URI = "\ + git://github.com/google/googletest.git;protocol=https; \ + file://Add-pkg-config-support.patch \ +" + +inherit cmake + +ALLOW_EMPTY_${PN} = "1" +ALLOW_EMPTY_${PN}-dbg = "1" + +RDEPENDS_${PN}-dev += "${PN}-staticdev" + +BBCLASSEXTEND = "native nativesdk" diff --git a/external/meta-openembedded/meta-oe/recipes-test/pm-qa/pm-qa_git.bb b/external/meta-openembedded/meta-oe/recipes-test/pm-qa/pm-qa_git.bb new file mode 100644 index 00000000..09290909 --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-test/pm-qa/pm-qa_git.bb @@ -0,0 +1,68 @@ +DESCRIPTION = "Utilities for testing Power Management" +HOMEPAGE = "https://wiki.linaro.org/WorkingGroups/PowerManagement/Resources/TestSuite/PmQa" + +LICENSE = "GPLv2" +LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263" + +PV = "0.5.2" + +BRANCH ?= "master" + +SRCREV = "05710ec5032be4c8edafb4109d4d908d31243906" + +SRC_URI = "git://git.linaro.org/power/pm-qa.git;protocol=git;branch=${BRANCH}" + +S = "${WORKDIR}/git" + +CFLAGS += "-pthread" + +do_compile () { + # Find all the .c files in this project and build them. + for x in `find . -name "*.c"` + do + util=`echo ${x} | sed s/.c$//` + oe_runmake ${util} + done +} + +do_install () { + install -d ${D}${bindir} + install -d ${D}${libdir}/${BPN} + + # Install the compiled binaries that were built in the previous step + for x in `find . -name "*.c"` + do + util=`echo ${x} | sed s/.c$//` + util_basename=`basename ${util}` + install -m 0755 ${util} ${D}${bindir}/${util_basename} + done + + # Install the helper scripts in a subdirectory of $libdir + for script in `find . -name "*.sh" | grep include` + do + # Remove hardcoded relative paths + sed -i -e 's#..\/utils\/##' ${script} + + script_basename=`basename ${script}` + install -m 0755 $script ${D}${libdir}/${BPN}/${script_basename} + done + + # Install the shell scripts NOT in the $libdir directory since those + # will be installed elsewhere + for script in `find . -name "*.sh" | grep -v include` + do + # if the script includes any helper scripts from the $libdir + # directory then change the source path to the absolute path + # to reflect the install location of the helper scripts. + sed -i -e "s#source ../include#source ${libdir}/${BPN}#g" ${script} + # Remove hardcoded relative paths + sed -i -e 's#..\/utils\/##' ${script} + + script_basename=`basename ${script}` + install -m 0755 $script ${D}${bindir}/${script_basename} + done +} +RDEPENDS_${PN} +="bash" + +# http://errors.yoctoproject.org/Errors/Details/186956/ +EXCLUDE_FROM_WORLD_libc-musl = "1" diff --git a/external/meta-openembedded/meta-oe/recipes-test/stress-ng/stress-ng/0001-Revert-Makefile-force-sync-after-build-in-case-reboo.patch b/external/meta-openembedded/meta-oe/recipes-test/stress-ng/stress-ng/0001-Revert-Makefile-force-sync-after-build-in-case-reboo.patch new file mode 100644 index 00000000..469791d8 --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-test/stress-ng/stress-ng/0001-Revert-Makefile-force-sync-after-build-in-case-reboo.patch @@ -0,0 +1,31 @@ +From 7c97710bfc44d895b7111bef9c55866f00a3589c Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Mon, 13 Aug 2018 11:54:27 -0700 +Subject: [PATCH] Revert "Makefile: force sync after build in case reboot loses + executable" + +This reverts commit ae6322b1baea56a589207c96e358daae8edd0a8f. + +Not needed for cross-builds + +Upstream-Status: Inappropriate [Cross compile specific] +Signed-off-by: Khem Raj +--- + Makefile | 1 - + 1 file changed, 1 deletion(-) + +diff --git a/Makefile b/Makefile +index c0db72c0..5781dda6 100644 +--- a/Makefile ++++ b/Makefile +@@ -348,7 +348,6 @@ endif + stress-ng: $(OBJS) + @echo "LD $@" + @$(CC) $(CPPFLAGS) $(CFLAGS) $(OBJS) -lm $(LDFLAGS) -o $@ +- @sync + + makeconfig: + @if [ ! -s config ]; then \ +-- +2.17.0 + diff --git a/external/meta-openembedded/meta-oe/recipes-test/stress-ng/stress-ng/0001-Several-changes-to-fix-musl-build.patch b/external/meta-openembedded/meta-oe/recipes-test/stress-ng/stress-ng/0001-Several-changes-to-fix-musl-build.patch new file mode 100644 index 00000000..c0b34490 --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-test/stress-ng/stress-ng/0001-Several-changes-to-fix-musl-build.patch @@ -0,0 +1,132 @@ +From 9bcb4e170f01dbe0a9e7bf6b899c5d9b5283d4c6 Mon Sep 17 00:00:00 2001 +From: Randy MacLeod +Date: Sun, 11 Nov 2018 23:00:53 -0500 +Subject: [PATCH] Several changes to fix musl build +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Rebased patch for: + +stress-{context, stackmmap}.c: Set tests to non-implemented because uses +swapcontext, musl provide the definition but not the implementation due + to that functions are pre-POSIX and set to be deprecated. + stress-{resources, pty}.c: Doesn't include termio.h and remove stress + operations that uses struct termio, musl doesn't provide that struct. +stress-malloc.c: Check for definition of M_MMAP_THRESHOLD musl doesn't + ptovide that constant. +stress-madvise.c: Add static poision_count integer, definition of + MADV_SOFT_OFFLINE doesn't grauntee MADV_HWPOISON to be defined. +cache.c: Define GLOB_ONLYDIR not available on MUSL. + +Signed-off-by: Aníbal Limón +Signed-off-by: Tim Orling +Signed-off-by: Randy MacLeod + +Upstream-status: Pending +--- + cache.c | 4 ++++ + stress-madvise.c | 1 + + stress-pty.c | 18 ------------------ + stress-resources.c | 1 - + stress-stackmmap.c | 2 +- + 5 files changed, 6 insertions(+), 20 deletions(-) + +diff --git a/cache.c b/cache.c +index e8a0f791..4c7bb486 100644 +--- a/cache.c ++++ b/cache.c +@@ -28,6 +28,10 @@ typedef struct { + + #include + ++#ifndef GLOB_ONLYDIR ++#define GLOB_ONLYDIR 0x100 ++#endif ++ + #if defined(__linux__) + #define SYS_CPU_PREFIX "/sys/devices/system/cpu" + #define GLOB_PATTERN SYS_CPU_PREFIX "/cpu[0-9]*" +diff --git a/stress-madvise.c b/stress-madvise.c +index b2e3497f..77e43a91 100644 +--- a/stress-madvise.c ++++ b/stress-madvise.c +@@ -146,6 +146,7 @@ static int stress_random_advise(const args_t *args) + #if defined(MADV_SOFT_OFFLINE) + if (advise == MADV_SOFT_OFFLINE) { + static int soft_offline_count; ++ static int poison_count; + + /* ..and minimize number of soft offline pages */ + if ((soft_offline_count >= NUM_SOFT_OFFLINE_MAX) || +diff --git a/stress-pty.c b/stress-pty.c +index 4dd88ab9..c79a7021 100644 +--- a/stress-pty.c ++++ b/stress-pty.c +@@ -26,7 +26,6 @@ + + #if defined(__linux__) + +-#include + #include + + typedef struct { +@@ -111,7 +110,6 @@ static int stress_pty(const args_t *args) + */ + for (i = 0; i < n; i++) { + struct termios ios; +- struct termio io; + struct winsize ws; + int arg; + +@@ -133,22 +131,6 @@ static int stress_pty(const args_t *args) + if (ioctl(ptys[i].slave, TCSETSF, &ios) < 0) + pr_fail_err("ioctl TCSETSF on slave pty"); + #endif +-#if defined(TCGETA) +- if (ioctl(ptys[i].slave, TCGETA, &io) < 0) +- pr_fail_err("ioctl TCGETA on slave pty"); +-#endif +-#if defined(TCSETA) +- if (ioctl(ptys[i].slave, TCSETA, &io) < 0) +- pr_fail_err("ioctl TCSETA on slave pty"); +-#endif +-#if defined(TCSETAW) +- if (ioctl(ptys[i].slave, TCSETAW, &io) < 0) +- pr_fail_err("ioctl TCSETAW on slave pty"); +-#endif +-#if defined(TCSETAF) +- if (ioctl(ptys[i].slave, TCSETAF, &io) < 0) +- pr_fail_err("ioctl TCSETAF on slave pty"); +-#endif + #if defined(TIOCGLCKTRMIOS) + if (ioctl(ptys[i].slave, TIOCGLCKTRMIOS, &ios) < 0) + pr_fail_err("ioctl TIOCGLCKTRMIOS on slave pty"); +diff --git a/stress-resources.c b/stress-resources.c +index f3dcfb38..86f9a5ba 100644 +--- a/stress-resources.c ++++ b/stress-resources.c +@@ -28,7 +28,6 @@ + #include + #endif + #if defined(__linux__) +-#include + #include + #endif + #if defined(HAVE_LIB_PTHREAD) && defined(__linux__) +diff --git a/stress-stackmmap.c b/stress-stackmmap.c +index c2f4c31d..54308777 100644 +--- a/stress-stackmmap.c ++++ b/stress-stackmmap.c +@@ -24,7 +24,7 @@ + */ + #include "stress-ng.h" + +-#if defined(__linux__) ++#if defined(__linux__) && False + + #include + +-- +2.17.0 + diff --git a/external/meta-openembedded/meta-oe/recipes-test/stress-ng/stress-ng_0.09.45.bb b/external/meta-openembedded/meta-oe/recipes-test/stress-ng/stress-ng_0.09.45.bb new file mode 100644 index 00000000..3e8f2d4f --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-test/stress-ng/stress-ng_0.09.45.bb @@ -0,0 +1,26 @@ +SUMMARY = "A tool to load and stress a computer system" +HOMEPAGE = "http://kernel.ubuntu.com/~cking/stress-ng/" +LICENSE = "GPLv2" +LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263" + +DEPENDS = "zlib libaio" + +SRC_URI = "http://kernel.ubuntu.com/~cking/tarballs/${BPN}/${BP}.tar.xz \ + file://0001-Revert-Makefile-force-sync-after-build-in-case-reboo.patch \ + " +SRC_URI_append_libc-musl = " \ + file://0001-Several-changes-to-fix-musl-build.patch \ + " + +SRC_URI[md5sum] = "b03744c2eb68bf7e9a300e78e397f348" +SRC_URI[sha256sum] = "0741e3004bf590bb7af3db979a46fe89bee7aaad6065cd1d87d0b7fa49046cb2" + +UPSTREAM_CHECK_URI ?= "http://kernel.ubuntu.com/~cking/tarballs/${BPN}/" +UPSTREAM_CHECK_REGEX ?= "(?P\d+(\.\d+)+)\.tar" + +CFLAGS += "-Wall -Wextra -DVERSION='"$(VERSION)"'" + +do_install_append() { + install -d ${D}${bindir} + install -m 755 ${S}/stress-ng ${D}${bindir}/stress-ng +} diff --git a/external/meta-openembedded/meta-oe/recipes-test/testfloat/files/0001-Makefile-for-cross-compile-SoftFloat.patch b/external/meta-openembedded/meta-oe/recipes-test/testfloat/files/0001-Makefile-for-cross-compile-SoftFloat.patch new file mode 100644 index 00000000..71782c5b --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-test/testfloat/files/0001-Makefile-for-cross-compile-SoftFloat.patch @@ -0,0 +1,348 @@ +Upstream-Status: Inappropriate [configuration] + +From 07f2528d93f44fe1d8080a4225f29f4ada9f4663 Mon Sep 17 00:00:00 2001 +From: Fabio Berton +Date: Thu, 4 Feb 2016 09:15:37 -0200 +Subject: [PATCH 1/2] Makefile for cross compile SoftFloat + +Signed-off-by: Fabio Berton +--- + SoftFloat-3a/build/Linux-Cross-Compile/Makefile | 274 ++++++++++++++++++++++ + SoftFloat-3a/build/Linux-Cross-Compile/platform.h | 44 ++++ + 2 files changed, 318 insertions(+) + create mode 100644 SoftFloat-3a/build/Linux-Cross-Compile/Makefile + create mode 100644 SoftFloat-3a/build/Linux-Cross-Compile/platform.h + +diff --git a/SoftFloat-3a/build/Linux-Cross-Compile/Makefile b/SoftFloat-3a/build/Linux-Cross-Compile/Makefile +new file mode 100644 +index 0000000..c4d0a60 +--- /dev/null ++++ b/SoftFloat-3a/build/Linux-Cross-Compile/Makefile +@@ -0,0 +1,274 @@ ++ ++#============================================================================= ++# ++# This Makefile is part of the SoftFloat IEEE Floating-Point Arithmetic ++# Package, Release 3a, by John R. Hauser. ++# ++# Copyright 2011, 2012, 2013, 2014 The Regents of the University of ++# California. All rights reserved. ++# ++# Redistribution and use in source and binary forms, with or without ++# modification, are permitted provided that the following conditions are met: ++# ++# 1. Redistributions of source code must retain the above copyright notice, ++# this list of conditions, and the following disclaimer. ++# ++# 2. Redistributions in binary form must reproduce the above copyright ++# notice, this list of conditions, and the following disclaimer in the ++# documentation and/or other materials provided with the distribution. ++# ++# 3. Neither the name of the University nor the names of its contributors ++# may be used to endorse or promote products derived from this software ++# without specific prior written permission. ++# ++# THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS "AS IS", AND ANY ++# EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED ++# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE, ARE ++# DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR ANY ++# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES ++# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; ++# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ++# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT ++# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF ++# THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. ++# ++#============================================================================= ++ ++SOURCE_DIR = ../../source ++SPECIALIZE_TYPE = 8086 ++ ++SOFTFLOAT_OPTS = -DINLINE_LEVEL=5 -DSOFTFLOAT_FAST_DIV64TO32 -fgnu89-inline ++ ++DELETE = rm -f ++C_INCLUDES = -I. -I$(SOURCE_DIR)/$(SPECIALIZE_TYPE) -I$(SOURCE_DIR)/include ++COMPILE_C = \ ++ ${CC} -c -Werror-implicit-function-declaration $(SOFTFLOAT_OPTS) \ ++ $(C_INCLUDES) -O2 -o $@ ++MAKELIB = ${AR} crs $@ ++ ++OBJ = .o ++LIB = .a ++ ++.PHONY: all ++all: softfloat$(LIB) ++ ++OBJS_PRIMITIVES = \ ++ s_compare96M$(OBJ) \ ++ s_compare128M$(OBJ) \ ++ s_shortShiftLeft64To96M$(OBJ) \ ++ s_shortShiftLeftM$(OBJ) \ ++ s_shiftLeftM$(OBJ) \ ++ s_shortShiftRightM$(OBJ) \ ++ s_shortShiftRightJam64$(OBJ) \ ++ s_shortShiftRightJamM$(OBJ) \ ++ s_shiftRightJam32$(OBJ) \ ++ s_shiftRightJam64$(OBJ) \ ++ s_shiftRightJamM$(OBJ) \ ++ s_shiftRightM$(OBJ) \ ++ s_countLeadingZeros8$(OBJ) \ ++ s_countLeadingZeros32$(OBJ) \ ++ s_countLeadingZeros64$(OBJ) \ ++ s_addM$(OBJ) \ ++ s_addCarryM$(OBJ) \ ++ s_addComplCarryM$(OBJ) \ ++ s_negXM$(OBJ) \ ++ s_sub1XM$(OBJ) \ ++ s_subM$(OBJ) \ ++ s_mul64To128M$(OBJ) \ ++ s_mul128MTo256M$(OBJ) \ ++ s_approxRecip32_1$(OBJ) \ ++ s_approxRecipSqrt32_1$(OBJ) \ ++ s_remStepMBy32$(OBJ) \ ++ ++OBJS_SPECIALIZE = \ ++ softfloat_raiseFlags$(OBJ) \ ++ s_f32UIToCommonNaN$(OBJ) \ ++ s_commonNaNToF32UI$(OBJ) \ ++ s_propagateNaNF32UI$(OBJ) \ ++ s_f64UIToCommonNaN$(OBJ) \ ++ s_commonNaNToF64UI$(OBJ) \ ++ s_propagateNaNF64UI$(OBJ) \ ++ extF80M_isSignalingNaN$(OBJ) \ ++ s_extF80MToCommonNaN$(OBJ) \ ++ s_commonNaNToExtF80M$(OBJ) \ ++ s_propagateNaNExtF80M$(OBJ) \ ++ f128M_isSignalingNaN$(OBJ) \ ++ s_f128MToCommonNaN$(OBJ) \ ++ s_commonNaNToF128M$(OBJ) \ ++ s_propagateNaNF128M$(OBJ) \ ++ ++OBJS_OTHERS = \ ++ s_roundPackToUI32$(OBJ) \ ++ s_roundPackMToUI64$(OBJ) \ ++ s_roundPackToI32$(OBJ) \ ++ s_roundPackMToI64$(OBJ) \ ++ s_normSubnormalF32Sig$(OBJ) \ ++ s_roundPackToF32$(OBJ) \ ++ s_normRoundPackToF32$(OBJ) \ ++ s_addMagsF32$(OBJ) \ ++ s_subMagsF32$(OBJ) \ ++ s_mulAddF32$(OBJ) \ ++ s_normSubnormalF64Sig$(OBJ) \ ++ s_roundPackToF64$(OBJ) \ ++ s_normRoundPackToF64$(OBJ) \ ++ s_addMagsF64$(OBJ) \ ++ s_subMagsF64$(OBJ) \ ++ s_mulAddF64$(OBJ) \ ++ s_tryPropagateNaNExtF80M$(OBJ) \ ++ s_invalidExtF80M$(OBJ) \ ++ s_normExtF80SigM$(OBJ) \ ++ s_roundPackMToExtF80M$(OBJ) \ ++ s_normRoundPackMToExtF80M$(OBJ) \ ++ s_addExtF80M$(OBJ) \ ++ s_compareNonnormExtF80M$(OBJ) \ ++ s_isNaNF128M$(OBJ) \ ++ s_tryPropagateNaNF128M$(OBJ) \ ++ s_invalidF128M$(OBJ) \ ++ s_shiftNormSigF128M$(OBJ) \ ++ s_roundPackMToF128M$(OBJ) \ ++ s_normRoundPackMToF128M$(OBJ) \ ++ s_addF128M$(OBJ) \ ++ s_mulAddF128M$(OBJ) \ ++ softfloat_state$(OBJ) \ ++ ui32_to_f32$(OBJ) \ ++ ui32_to_f64$(OBJ) \ ++ ui32_to_extF80M$(OBJ) \ ++ ui32_to_f128M$(OBJ) \ ++ ui64_to_f32$(OBJ) \ ++ ui64_to_f64$(OBJ) \ ++ ui64_to_extF80M$(OBJ) \ ++ ui64_to_f128M$(OBJ) \ ++ i32_to_f32$(OBJ) \ ++ i32_to_f64$(OBJ) \ ++ i32_to_extF80M$(OBJ) \ ++ i32_to_f128M$(OBJ) \ ++ i64_to_f32$(OBJ) \ ++ i64_to_f64$(OBJ) \ ++ i64_to_extF80M$(OBJ) \ ++ i64_to_f128M$(OBJ) \ ++ f32_to_ui32$(OBJ) \ ++ f32_to_ui64$(OBJ) \ ++ f32_to_i32$(OBJ) \ ++ f32_to_i64$(OBJ) \ ++ f32_to_ui32_r_minMag$(OBJ) \ ++ f32_to_ui64_r_minMag$(OBJ) \ ++ f32_to_i32_r_minMag$(OBJ) \ ++ f32_to_i64_r_minMag$(OBJ) \ ++ f32_to_f64$(OBJ) \ ++ f32_to_extF80M$(OBJ) \ ++ f32_to_f128M$(OBJ) \ ++ f32_roundToInt$(OBJ) \ ++ f32_add$(OBJ) \ ++ f32_sub$(OBJ) \ ++ f32_mul$(OBJ) \ ++ f32_mulAdd$(OBJ) \ ++ f32_div$(OBJ) \ ++ f32_rem$(OBJ) \ ++ f32_sqrt$(OBJ) \ ++ f32_eq$(OBJ) \ ++ f32_le$(OBJ) \ ++ f32_lt$(OBJ) \ ++ f32_eq_signaling$(OBJ) \ ++ f32_le_quiet$(OBJ) \ ++ f32_lt_quiet$(OBJ) \ ++ f32_isSignalingNaN$(OBJ) \ ++ f64_to_ui32$(OBJ) \ ++ f64_to_ui64$(OBJ) \ ++ f64_to_i32$(OBJ) \ ++ f64_to_i64$(OBJ) \ ++ f64_to_ui32_r_minMag$(OBJ) \ ++ f64_to_ui64_r_minMag$(OBJ) \ ++ f64_to_i32_r_minMag$(OBJ) \ ++ f64_to_i64_r_minMag$(OBJ) \ ++ f64_to_f32$(OBJ) \ ++ f64_to_extF80M$(OBJ) \ ++ f64_to_f128M$(OBJ) \ ++ f64_roundToInt$(OBJ) \ ++ f64_add$(OBJ) \ ++ f64_sub$(OBJ) \ ++ f64_mul$(OBJ) \ ++ f64_mulAdd$(OBJ) \ ++ f64_div$(OBJ) \ ++ f64_rem$(OBJ) \ ++ f64_sqrt$(OBJ) \ ++ f64_eq$(OBJ) \ ++ f64_le$(OBJ) \ ++ f64_lt$(OBJ) \ ++ f64_eq_signaling$(OBJ) \ ++ f64_le_quiet$(OBJ) \ ++ f64_lt_quiet$(OBJ) \ ++ f64_isSignalingNaN$(OBJ) \ ++ extF80M_to_ui32$(OBJ) \ ++ extF80M_to_ui64$(OBJ) \ ++ extF80M_to_i32$(OBJ) \ ++ extF80M_to_i64$(OBJ) \ ++ extF80M_to_ui32_r_minMag$(OBJ) \ ++ extF80M_to_ui64_r_minMag$(OBJ) \ ++ extF80M_to_i32_r_minMag$(OBJ) \ ++ extF80M_to_i64_r_minMag$(OBJ) \ ++ extF80M_to_f32$(OBJ) \ ++ extF80M_to_f64$(OBJ) \ ++ extF80M_to_f128M$(OBJ) \ ++ extF80M_roundToInt$(OBJ) \ ++ extF80M_add$(OBJ) \ ++ extF80M_sub$(OBJ) \ ++ extF80M_mul$(OBJ) \ ++ extF80M_div$(OBJ) \ ++ extF80M_rem$(OBJ) \ ++ extF80M_sqrt$(OBJ) \ ++ extF80M_eq$(OBJ) \ ++ extF80M_le$(OBJ) \ ++ extF80M_lt$(OBJ) \ ++ extF80M_eq_signaling$(OBJ) \ ++ extF80M_le_quiet$(OBJ) \ ++ extF80M_lt_quiet$(OBJ) \ ++ f128M_to_ui32$(OBJ) \ ++ f128M_to_ui64$(OBJ) \ ++ f128M_to_i32$(OBJ) \ ++ f128M_to_i64$(OBJ) \ ++ f128M_to_ui32_r_minMag$(OBJ) \ ++ f128M_to_ui64_r_minMag$(OBJ) \ ++ f128M_to_i32_r_minMag$(OBJ) \ ++ f128M_to_i64_r_minMag$(OBJ) \ ++ f128M_to_f32$(OBJ) \ ++ f128M_to_f64$(OBJ) \ ++ f128M_to_extF80M$(OBJ) \ ++ f128M_roundToInt$(OBJ) \ ++ f128M_add$(OBJ) \ ++ f128M_sub$(OBJ) \ ++ f128M_mul$(OBJ) \ ++ f128M_mulAdd$(OBJ) \ ++ f128M_div$(OBJ) \ ++ f128M_rem$(OBJ) \ ++ f128M_sqrt$(OBJ) \ ++ f128M_eq$(OBJ) \ ++ f128M_le$(OBJ) \ ++ f128M_lt$(OBJ) \ ++ f128M_eq_signaling$(OBJ) \ ++ f128M_le_quiet$(OBJ) \ ++ f128M_lt_quiet$(OBJ) \ ++ ++OBJS_ALL = $(OBJS_PRIMITIVES) $(OBJS_SPECIALIZE) $(OBJS_OTHERS) ++ ++$(OBJS_ALL): \ ++ platform.h $(SOURCE_DIR)/include/primitiveTypes.h \ ++ $(SOURCE_DIR)/include/primitives.h ++$(OBJS_SPECIALIZE) $(OBJS_OTHERS): \ ++ $(SOURCE_DIR)/include/softfloat_types.h $(SOURCE_DIR)/include/internals.h \ ++ $(SOURCE_DIR)/$(SPECIALIZE_TYPE)/specialize.h \ ++ $(SOURCE_DIR)/include/softfloat.h ++ ++$(OBJS_PRIMITIVES) $(OBJS_OTHERS): %$(OBJ): $(SOURCE_DIR)/%.c ++ $(COMPILE_C) $(SOURCE_DIR)/$*.c ++ ++$(OBJS_SPECIALIZE): %$(OBJ): $(SOURCE_DIR)/$(SPECIALIZE_TYPE)/%.c ++ $(COMPILE_C) $(SOURCE_DIR)/$(SPECIALIZE_TYPE)/$*.c ++ ++softfloat$(LIB): $(OBJS_ALL) ++ $(DELETE) $@ ++ $(MAKELIB) $^ ++ ++.PHONY: clean ++clean: ++ $(DELETE) $(OBJS_ALL) softfloat$(LIB) ++ +diff --git a/SoftFloat-3a/build/Linux-Cross-Compile/platform.h b/SoftFloat-3a/build/Linux-Cross-Compile/platform.h +new file mode 100644 +index 0000000..5e566fc +--- /dev/null ++++ b/SoftFloat-3a/build/Linux-Cross-Compile/platform.h +@@ -0,0 +1,44 @@ ++ ++/*============================================================================ ++ ++This C header file is part of the SoftFloat IEEE Floating-Point Arithmetic ++Package, Release 3a, by John R. Hauser. ++ ++Copyright 2011, 2012, 2013, 2014 The Regents of the University of California. ++All rights reserved. ++ ++Redistribution and use in source and binary forms, with or without ++modification, are permitted provided that the following conditions are met: ++ ++ 1. Redistributions of source code must retain the above copyright notice, ++ this list of conditions, and the following disclaimer. ++ ++ 2. Redistributions in binary form must reproduce the above copyright notice, ++ this list of conditions, and the following disclaimer in the documentation ++ and/or other materials provided with the distribution. ++ ++ 3. Neither the name of the University nor the names of its contributors may ++ be used to endorse or promote products derived from this software without ++ specific prior written permission. ++ ++THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS "AS IS", AND ANY ++EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED ++WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE, ARE ++DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR ANY ++DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES ++(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; ++LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ++ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT ++(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS ++SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. ++ ++=============================================================================*/ ++ ++/*---------------------------------------------------------------------------- ++*----------------------------------------------------------------------------*/ ++#define LITTLEENDIAN 1 ++ ++/*---------------------------------------------------------------------------- ++*----------------------------------------------------------------------------*/ ++#define INLINE extern inline ++ +-- +2.1.4 + diff --git a/external/meta-openembedded/meta-oe/recipes-test/testfloat/files/0002-Makefile-for-cross-compile-TestFloat.patch b/external/meta-openembedded/meta-oe/recipes-test/testfloat/files/0002-Makefile-for-cross-compile-TestFloat.patch new file mode 100644 index 00000000..71ca343c --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-test/testfloat/files/0002-Makefile-for-cross-compile-TestFloat.patch @@ -0,0 +1,396 @@ +Upstream-Status: Inappropriate [configuration] + +From 9aa4a416f05967320c1aa52bdccfe105a3bf3269 Mon Sep 17 00:00:00 2001 +From: Fabio Berton +Date: Thu, 4 Feb 2016 09:16:09 -0200 +Subject: [PATCH 2/2] Makefile for cross compile TestFloat + +Signed-off-by: Fabio Berton +--- + TestFloat-3a/build/Linux-Cross-Compile/Makefile | 321 ++++++++++++++++++++++ + TestFloat-3a/build/Linux-Cross-Compile/platform.h | 45 +++ + 2 files changed, 366 insertions(+) + create mode 100644 TestFloat-3a/build/Linux-Cross-Compile/Makefile + create mode 100644 TestFloat-3a/build/Linux-Cross-Compile/platform.h + +diff --git a/TestFloat-3a/build/Linux-Cross-Compile/Makefile b/TestFloat-3a/build/Linux-Cross-Compile/Makefile +new file mode 100644 +index 0000000..a89326a +--- /dev/null ++++ b/TestFloat-3a/build/Linux-Cross-Compile/Makefile +@@ -0,0 +1,321 @@ ++ ++#============================================================================= ++# ++# This Makefile is part of TestFloat, Release 3a, a package of programs for ++# testing the correctness of floating-point arithmetic complying with the IEEE ++# Standard for Floating-Point, by John R. Hauser. ++# ++# Copyright 2011, 2012, 2013, 2014, 2015 The Regents of the University of ++# California. All rights reserved. ++# ++# Redistribution and use in source and binary forms, with or without ++# modification, are permitted provided that the following conditions are met: ++# ++# 1. Redistributions of source code must retain the above copyright notice, ++# this list of conditions, and the following disclaimer. ++# ++# 2. Redistributions in binary form must reproduce the above copyright ++# notice, this list of conditions, and the following disclaimer in the ++# documentation and/or other materials provided with the distribution. ++# ++# 3. Neither the name of the University nor the names of its contributors ++# may be used to endorse or promote products derived from this software ++# without specific prior written permission. ++# ++# THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS "AS IS", AND ANY ++# EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED ++# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE, ARE ++# DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR ANY ++# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES ++# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; ++# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ++# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT ++# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF ++# THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. ++# ++#============================================================================= ++ ++SOURCE_DIR = ../../source ++SUBJ_SOURCE_DIR = $(SOURCE_DIR)/subj-C ++SOFTFLOAT_DIR = ../../../SoftFloat-3a ++SOFTFLOAT_INCLUDE_DIR = $(SOFTFLOAT_DIR)/source/include ++PLATFORM = Linux-Cross-Compile ++ ++SOFTFLOAT_H = \ ++ $(SOFTFLOAT_INCLUDE_DIR)/softfloat_types.h \ ++ $(SOFTFLOAT_INCLUDE_DIR)/softfloat.h ++SOFTFLOAT_LIB = $(SOFTFLOAT_DIR)/build/$(PLATFORM)/softfloat$(LIB) ++ ++TESTFLOAT_OPTS = -DEXTFLOAT80 -DFLOAT128 -DLONG_DOUBLE_IS_EXTFLOAT80 -fgnu89-inline ++ ++DELETE = rm -f ++C_INCLUDES = \ ++ -I. -I$(SUBJ_SOURCE_DIR) -I$(SOURCE_DIR) -I$(SOFTFLOAT_INCLUDE_DIR) ++COMPILE_C = \ ++ ${CC} -c -Werror-implicit-function-declaration $(TESTFLOAT_OPTS) \ ++ $(C_INCLUDES) -O2 -o $@ ++COMPILE_SLOWFLOAT_C = \ ++ ${CC} -c -Werror-implicit-function-declaration $(TESTFLOAT_OPTS) \ ++ $(C_INCLUDES) -O3 -o $@ ++MAKELIB = ${AR} crs $@ ++LINK = ${CC} -o $@ ${LDFLAGS} ++OTHER_LIBS = -lm ++ ++OBJ = .o ++LIB = .a ++EXE = ++ ++.PHONY: all ++all: \ ++ testsoftfloat$(EXE) \ ++ timesoftfloat$(EXE) \ ++ testfloat_gen$(EXE) \ ++ testfloat_ver$(EXE) \ ++ testfloat$(EXE) \ ++ ++OBJS_GENCASES = \ ++ genCases_ui32$(OBJ) \ ++ genCases_ui64$(OBJ) \ ++ genCases_i32$(OBJ) \ ++ genCases_i64$(OBJ) \ ++ genCases_f32$(OBJ) \ ++ genCases_f64$(OBJ) \ ++ genCases_extF80$(OBJ) \ ++ genCases_f128$(OBJ) \ ++ ++OBJS_WRITECASE = \ ++ writeCase_a_ui32$(OBJ) \ ++ writeCase_a_ui64$(OBJ) \ ++ writeCase_a_f32$(OBJ) \ ++ writeCase_ab_f32$(OBJ) \ ++ writeCase_abc_f32$(OBJ) \ ++ writeCase_a_f64$(OBJ) \ ++ writeCase_ab_f64$(OBJ) \ ++ writeCase_abc_f64$(OBJ) \ ++ writeCase_a_extF80M$(OBJ) \ ++ writeCase_ab_extF80M$(OBJ) \ ++ writeCase_abc_extF80M$(OBJ) \ ++ writeCase_a_f128M$(OBJ) \ ++ writeCase_ab_f128M$(OBJ) \ ++ writeCase_abc_f128M$(OBJ) \ ++ writeCase_z_bool$(OBJ) \ ++ writeCase_z_ui32$(OBJ) \ ++ writeCase_z_ui64$(OBJ) \ ++ writeCase_z_f32$(OBJ) \ ++ writeCase_z_f64$(OBJ) \ ++ writeCase_z_extF80M$(OBJ) \ ++ writeCase_z_f128M$(OBJ) \ ++ ++OBJS_TEST = \ ++ test_a_ui32_z_f32$(OBJ) \ ++ test_a_ui32_z_f64$(OBJ) \ ++ test_a_ui32_z_extF80$(OBJ) \ ++ test_a_ui32_z_f128$(OBJ) \ ++ test_a_ui64_z_f32$(OBJ) \ ++ test_a_ui64_z_f64$(OBJ) \ ++ test_a_ui64_z_extF80$(OBJ) \ ++ test_a_ui64_z_f128$(OBJ) \ ++ test_a_i32_z_f32$(OBJ) \ ++ test_a_i32_z_f64$(OBJ) \ ++ test_a_i32_z_extF80$(OBJ) \ ++ test_a_i32_z_f128$(OBJ) \ ++ test_a_i64_z_f32$(OBJ) \ ++ test_a_i64_z_f64$(OBJ) \ ++ test_a_i64_z_extF80$(OBJ) \ ++ test_a_i64_z_f128$(OBJ) \ ++ test_a_f32_z_ui32_rx$(OBJ) \ ++ test_a_f32_z_ui64_rx$(OBJ) \ ++ test_a_f32_z_i32_rx$(OBJ) \ ++ test_a_f32_z_i64_rx$(OBJ) \ ++ test_a_f32_z_ui32_x$(OBJ) \ ++ test_a_f32_z_ui64_x$(OBJ) \ ++ test_a_f32_z_i32_x$(OBJ) \ ++ test_a_f32_z_i64_x$(OBJ) \ ++ test_a_f32_z_f64$(OBJ) \ ++ test_a_f32_z_extF80$(OBJ) \ ++ test_a_f32_z_f128$(OBJ) \ ++ test_az_f32$(OBJ) \ ++ test_az_f32_rx$(OBJ) \ ++ test_abz_f32$(OBJ) \ ++ test_abcz_f32$(OBJ) \ ++ test_ab_f32_z_bool$(OBJ) \ ++ test_a_f64_z_ui32_rx$(OBJ) \ ++ test_a_f64_z_ui64_rx$(OBJ) \ ++ test_a_f64_z_i32_rx$(OBJ) \ ++ test_a_f64_z_i64_rx$(OBJ) \ ++ test_a_f64_z_ui32_x$(OBJ) \ ++ test_a_f64_z_ui64_x$(OBJ) \ ++ test_a_f64_z_i32_x$(OBJ) \ ++ test_a_f64_z_i64_x$(OBJ) \ ++ test_a_f64_z_f32$(OBJ) \ ++ test_a_f64_z_extF80$(OBJ) \ ++ test_a_f64_z_f128$(OBJ) \ ++ test_az_f64$(OBJ) \ ++ test_az_f64_rx$(OBJ) \ ++ test_abz_f64$(OBJ) \ ++ test_abcz_f64$(OBJ) \ ++ test_ab_f64_z_bool$(OBJ) \ ++ test_a_extF80_z_ui32_rx$(OBJ) \ ++ test_a_extF80_z_ui64_rx$(OBJ) \ ++ test_a_extF80_z_i32_rx$(OBJ) \ ++ test_a_extF80_z_i64_rx$(OBJ) \ ++ test_a_extF80_z_ui32_x$(OBJ) \ ++ test_a_extF80_z_ui64_x$(OBJ) \ ++ test_a_extF80_z_i32_x$(OBJ) \ ++ test_a_extF80_z_i64_x$(OBJ) \ ++ test_a_extF80_z_f32$(OBJ) \ ++ test_a_extF80_z_f64$(OBJ) \ ++ test_a_extF80_z_f128$(OBJ) \ ++ test_az_extF80$(OBJ) \ ++ test_az_extF80_rx$(OBJ) \ ++ test_abz_extF80$(OBJ) \ ++ test_ab_extF80_z_bool$(OBJ) \ ++ test_a_f128_z_ui32_rx$(OBJ) \ ++ test_a_f128_z_ui64_rx$(OBJ) \ ++ test_a_f128_z_i32_rx$(OBJ) \ ++ test_a_f128_z_i64_rx$(OBJ) \ ++ test_a_f128_z_ui32_x$(OBJ) \ ++ test_a_f128_z_ui64_x$(OBJ) \ ++ test_a_f128_z_i32_x$(OBJ) \ ++ test_a_f128_z_i64_x$(OBJ) \ ++ test_a_f128_z_f32$(OBJ) \ ++ test_a_f128_z_f64$(OBJ) \ ++ test_a_f128_z_extF80$(OBJ) \ ++ test_az_f128$(OBJ) \ ++ test_az_f128_rx$(OBJ) \ ++ test_abz_f128$(OBJ) \ ++ test_abcz_f128$(OBJ) \ ++ test_ab_f128_z_bool$(OBJ) \ ++ ++OBJS_LIB = \ ++ uint128$(OBJ) \ ++ fail$(OBJ) \ ++ functions_common$(OBJ) \ ++ functionInfos$(OBJ) \ ++ standardFunctionInfos$(OBJ) \ ++ random$(OBJ) \ ++ genCases_common$(OBJ) \ ++ $(OBJS_GENCASES) \ ++ genCases_writeTestsTotal$(OBJ) \ ++ verCases_common$(OBJ) \ ++ verCases_writeFunctionName$(OBJ) \ ++ readHex$(OBJ) \ ++ writeHex$(OBJ) \ ++ $(OBJS_WRITECASE) \ ++ testLoops_common$(OBJ) \ ++ $(OBJS_TEST) \ ++ ++uint128$(OBJ): $(SOURCE_DIR)/uint128.h ++fail$(OBJ): $(SOURCE_DIR)/fail.h ++functions_common$(OBJ): $(SOFTFLOAT_H) $(SOURCE_DIR)/functions.h ++functionInfos$(OBJ): $(SOURCE_DIR)/functions.h ++standardFunctionInfos$(OBJ): $(SOURCE_DIR)/functions.h ++random$(OBJ): $(SOURCE_DIR)/random.h ++genCases_common$(OBJ): $(SOURCE_DIR)/fail.h $(SOURCE_DIR)/genCases.h ++$(OBJS_GENCASES): \ ++ $(SOURCE_DIR)/random.h $(SOFTFLOAT_H) $(SOURCE_DIR)/genCases.h ++genCases_f128$(OBJ): $(SOURCE_DIR)/uint128.h ++genCases_writeTestsTotal$(OBJ): $(SOURCE_DIR)/genCases.h ++verCases_common$(OBJ): $(SOURCE_DIR)/verCases.h ++verCases_writeFunctionName$(OBJ): $(SOURCE_DIR)/verCases.h ++readHex$(OBJ): $(SOURCE_DIR)/readHex.h ++writeHex$(OBJ): $(SOURCE_DIR)/uint128.h $(SOFTFLOAT_H) $(SOURCE_DIR)/writeHex.h ++$(OBJS_WRITECASE): \ ++ $(SOFTFLOAT_H) $(SOURCE_DIR)/writeHex.h $(SOURCE_DIR)/writeCase.h ++testLoops_common$(OBJ): $(SOURCE_DIR)/testLoops.h ++$(OBJS_TEST): \ ++ $(SOURCE_DIR)/uint128.h $(SOFTFLOAT_H) $(SOURCE_DIR)/genCases.h \ ++ $(SOURCE_DIR)/verCases.h $(SOURCE_DIR)/writeCase.h $(SOURCE_DIR)/testLoops.h ++$(OBJS_LIB): %$(OBJ): platform.h $(SOURCE_DIR)/%.c ++ $(COMPILE_C) $(SOURCE_DIR)/$*.c ++testfloat$(LIB): $(OBJS_LIB) ++ $(MAKELIB) $^ ++ ++OBJS_TESTSOFTFLOAT = slowfloat$(OBJ) testsoftfloat$(OBJ) ++ ++slowfloat$(OBJ): \ ++ platform.h $(SOURCE_DIR)/uint128.h $(SOFTFLOAT_H) \ ++ $(SOURCE_DIR)/slowfloat.h $(SOURCE_DIR)/slowfloat.c ++ $(COMPILE_SLOWFLOAT_C) $(SOURCE_DIR)/slowfloat.c ++testsoftfloat$(OBJ): \ ++ platform.h $(SOURCE_DIR)/uint128.h $(SOURCE_DIR)/fail.h $(SOFTFLOAT_H) \ ++ $(SOURCE_DIR)/slowfloat.h $(SOURCE_DIR)/functions.h \ ++ $(SOURCE_DIR)/genCases.h $(SOURCE_DIR)/verCases.h $(SOURCE_DIR)/writeCase.h \ ++ $(SOURCE_DIR)/testLoops.h $(SOURCE_DIR)/testsoftfloat.c ++ $(COMPILE_C) $(SOURCE_DIR)/testsoftfloat.c ++ ++testsoftfloat$(EXE): $(OBJS_TESTSOFTFLOAT) testfloat$(LIB) $(SOFTFLOAT_LIB) ++ $(LINK) $^ $(OTHER_LIBS) ++ ++OBJS_TIMESOFTFLOAT = timesoftfloat$(OBJ) ++ ++timesoftfloat$(OBJ): \ ++ platform.h $(SOURCE_DIR)/uint128.h $(SOURCE_DIR)/fail.h $(SOFTFLOAT_H) \ ++ $(SOURCE_DIR)/functions.h $(SOURCE_DIR)/timesoftfloat.c ++ $(COMPILE_C) $(SOURCE_DIR)/timesoftfloat.c ++ ++timesoftfloat$(EXE): $(OBJS_TIMESOFTFLOAT) testfloat$(LIB) $(SOFTFLOAT_LIB) ++ $(LINK) $^ $(OTHER_LIBS) ++ ++OBJS_TESTFLOAT_GEN = genLoops$(OBJ) testfloat_gen$(OBJ) ++ ++genLoops$(OBJ): \ ++ platform.h $(SOURCE_DIR)/uint128.h $(SOURCE_DIR)/fail.h $(SOFTFLOAT_H) \ ++ $(SOURCE_DIR)/genCases.h $(SOURCE_DIR)/writeHex.h $(SOURCE_DIR)/genLoops.h \ ++ $(SOURCE_DIR)/genLoops.c ++ $(COMPILE_C) $(SOURCE_DIR)/genLoops.c ++testfloat_gen$(OBJ): \ ++ $(SOURCE_DIR)/fail.h $(SOFTFLOAT_H) $(SOURCE_DIR)/functions.h \ ++ $(SOURCE_DIR)/genCases.h $(SOURCE_DIR)/genLoops.h \ ++ $(SOURCE_DIR)/testfloat_gen.c ++ $(COMPILE_C) $(SOURCE_DIR)/testfloat_gen.c ++ ++testfloat_gen$(EXE): $(OBJS_TESTFLOAT_GEN) testfloat$(LIB) $(SOFTFLOAT_LIB) ++ $(LINK) $^ $(OTHER_LIBS) ++ ++OBJS_TESTFLOAT_VER = verLoops$(OBJ) testfloat_ver$(OBJ) ++ ++verLoops$(OBJ): \ ++ platform.h $(SOURCE_DIR)/uint128.h $(SOURCE_DIR)/fail.h $(SOFTFLOAT_H) \ ++ $(SOURCE_DIR)/readHex.h $(SOURCE_DIR)/verCases.h $(SOURCE_DIR)/writeCase.h \ ++ $(SOURCE_DIR)/verLoops.h $(SOURCE_DIR)/verLoops.c ++ $(COMPILE_C) $(SOURCE_DIR)/verLoops.c ++testfloat_ver$(OBJ): \ ++ platform.h $(SOURCE_DIR)/uint128.h $(SOURCE_DIR)/fail.h $(SOFTFLOAT_H) \ ++ $(SOURCE_DIR)/functions.h $(SOURCE_DIR)/verCases.h \ ++ $(SOURCE_DIR)/writeCase.h $(SOURCE_DIR)/verLoops.h \ ++ $(SOURCE_DIR)/testfloat_ver.c ++ $(COMPILE_C) $(SOURCE_DIR)/testfloat_ver.c ++ ++testfloat_ver$(EXE): $(OBJS_TESTFLOAT_VER) testfloat$(LIB) $(SOFTFLOAT_LIB) ++ $(LINK) $^ $(OTHER_LIBS) ++ ++OBJS_TESTFLOAT = subjfloat$(OBJ) subjfloat_functions$(OBJ) testfloat$(OBJ) ++ ++subjfloat$(OBJ): \ ++ platform.h $(SOFTFLOAT_H) $(SUBJ_SOURCE_DIR)/subjfloat_config.h \ ++ $(SOURCE_DIR)/subjfloat.h $(SUBJ_SOURCE_DIR)/subjfloat.c ++ $(COMPILE_C) $(SUBJ_SOURCE_DIR)/subjfloat.c ++subjfloat_functions$(OBJ): \ ++ platform.h $(SUBJ_SOURCE_DIR)/subjfloat_config.h $(SOURCE_DIR)/subjfloat.h \ ++ $(SOURCE_DIR)/functions.h $(SOURCE_DIR)/subjfloat_functions.c ++ $(COMPILE_C) $(SOURCE_DIR)/subjfloat_functions.c ++testfloat$(OBJ): \ ++ platform.h $(SOURCE_DIR)/uint128.h $(SOURCE_DIR)/fail.h $(SOFTFLOAT_H) \ ++ $(SUBJ_SOURCE_DIR)/subjfloat_config.h $(SOURCE_DIR)/subjfloat.h \ ++ $(SOURCE_DIR)/functions.h $(SOURCE_DIR)/genCases.h $(SOURCE_DIR)/verCases.h \ ++ $(SOURCE_DIR)/testLoops.h $(SOURCE_DIR)/testfloat.c ++ $(COMPILE_C) $(SOURCE_DIR)/testfloat.c ++ ++testfloat$(EXE): $(OBJS_TESTFLOAT) testfloat$(LIB) $(SOFTFLOAT_LIB) ++ $(LINK) $^ $(OTHER_LIBS) ++ ++.PHONY: clean ++clean: ++ $(DELETE) $(OBJS_LIB) testfloat$(LIB) ++ $(DELETE) $(OBJS_TESTSOFTFLOAT) testsoftfloat$(EXE) ++ $(DELETE) $(OBJS_TIMESOFTFLOAT) timesoftfloat$(EXE) ++ $(DELETE) $(OBJS_TESTFLOAT_GEN) testfloat_gen$(EXE) ++ $(DELETE) $(OBJS_TESTFLOAT_VER) testfloat_ver$(EXE) ++ $(DELETE) $(OBJS_TESTFLOAT) testfloat$(EXE) ++ +diff --git a/TestFloat-3a/build/Linux-Cross-Compile/platform.h b/TestFloat-3a/build/Linux-Cross-Compile/platform.h +new file mode 100644 +index 0000000..09e63a0 +--- /dev/null ++++ b/TestFloat-3a/build/Linux-Cross-Compile/platform.h +@@ -0,0 +1,45 @@ ++ ++/*============================================================================ ++ ++This C header file is part of TestFloat, Release 3a, a package of programs for ++testing the correctness of floating-point arithmetic complying with the IEEE ++Standard for Floating-Point, by John R. Hauser. ++ ++Copyright 2011, 2012, 2013, 2014 The Regents of the University of California. ++All rights reserved. ++ ++Redistribution and use in source and binary forms, with or without ++modification, are permitted provided that the following conditions are met: ++ ++ 1. Redistributions of source code must retain the above copyright notice, ++ this list of conditions, and the following disclaimer. ++ ++ 2. Redistributions in binary form must reproduce the above copyright notice, ++ this list of conditions, and the following disclaimer in the documentation ++ and/or other materials provided with the distribution. ++ ++ 3. Neither the name of the University nor the names of its contributors may ++ be used to endorse or promote products derived from this software without ++ specific prior written permission. ++ ++THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS "AS IS", AND ANY ++EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED ++WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE, ARE ++DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR ANY ++DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES ++(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; ++LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ++ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT ++(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS ++SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. ++ ++=============================================================================*/ ++ ++/*---------------------------------------------------------------------------- ++*----------------------------------------------------------------------------*/ ++#define LITTLEENDIAN 1 ++ ++/*---------------------------------------------------------------------------- ++*----------------------------------------------------------------------------*/ ++#define INLINE extern inline ++ +-- +2.1.4 + diff --git a/external/meta-openembedded/meta-oe/recipes-test/testfloat/testfloat_3a.bb b/external/meta-openembedded/meta-oe/recipes-test/testfloat/testfloat_3a.bb new file mode 100644 index 00000000..28e96776 --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-test/testfloat/testfloat_3a.bb @@ -0,0 +1,35 @@ +DESCRIPTION = "Berkeley TestFloat is a small collection of programs for \ + testing that an implementation of binary floating-point conforms to the \ + IEEE Standard for Floating-Point Arithmetic." + +HOMEPAGE = "http://www.jhauser.us/arithmetic/TestFloat.html" + +LICENSE = "BSD" +LIC_FILES_CHKSUM = "file://TestFloat-${PV}/COPYING.txt;md5=e45c175a323b5727777fb6bd4b26eafc" + +SRC_URI = "\ + http://www.jhauser.us/arithmetic/TestFloat-3a.zip;name=TestFloat \ + http://www.jhauser.us/arithmetic/SoftFloat-3a.zip;name=SoftFloat \ + file://0001-Makefile-for-cross-compile-SoftFloat.patch \ + file://0002-Makefile-for-cross-compile-TestFloat.patch \ +" +SRC_URI[TestFloat.md5sum] = "5a124e85ab74c5e52da27d401cea6cc3" +SRC_URI[TestFloat.sha256sum] = "fa258b5b3c751656a372051adee4183e19ad4763032322eb7a87dfb9e2c22c75" +SRC_URI[SoftFloat.md5sum] = "e53bd4550cf99690642c41374d188517" +SRC_URI[SoftFloat.sha256sum] = "946fd23180559d60eb6683dda1cf8b142f5426dedfefb97b03c6afdfd70ee9e0" + +S = "${WORKDIR}" + +do_compile(){ + oe_runmake -C SoftFloat-${PV}/build/Linux-Cross-Compile/ + oe_runmake -C TestFloat-${PV}/build/Linux-Cross-Compile/ +} + +do_install(){ + install -d ${D}/${bindir} + install ${S}/TestFloat-${PV}/build/Linux-Cross-Compile/testfloat ${D}/${bindir} + install ${S}/TestFloat-${PV}/build/Linux-Cross-Compile/testfloat_gen ${D}/${bindir} + install ${S}/TestFloat-${PV}/build/Linux-Cross-Compile/testfloat_ver ${D}/${bindir} + install ${S}/TestFloat-${PV}/build/Linux-Cross-Compile/testsoftfloat ${D}/${bindir} + install ${S}/TestFloat-${PV}/build/Linux-Cross-Compile/timesoftfloat ${D}/${bindir} +} -- cgit 1.2.3-korg