diff --git a/DEVELOPERS b/DEVELOPERS index d4a6637671..51e7e3439d 100644 --- a/DEVELOPERS +++ b/DEVELOPERS @@ -1716,6 +1716,7 @@ F: package/libjxl/ F: package/octave/ F: package/ola/ F: package/openblas/ +F: package/opencsd/ F: package/openmpi/ F: package/perftest/ F: package/ptm2human/ diff --git a/package/Config.in b/package/Config.in index 908806db41..43c38d7d99 100644 --- a/package/Config.in +++ b/package/Config.in @@ -1722,6 +1722,7 @@ menu "Hardware handling" source "package/mtdev/Config.in" source "package/ne10/Config.in" source "package/neardal/Config.in" + source "package/opencsd/Config.in" source "package/opensc/Config.in" source "package/owfs/Config.in" source "package/pcsc-lite/Config.in" diff --git a/package/opencsd/Config.in b/package/opencsd/Config.in new file mode 100644 index 0000000000..6e400cc2ae --- /dev/null +++ b/package/opencsd/Config.in @@ -0,0 +1,27 @@ +config BR2_PACKAGE_OPENCSD_ARCH_SUPPORTS + bool + default y if BR2_arm + default y if BR2_armeb + default y if BR2_aarch64 + default y if BR2_aarch64_be + +config BR2_PACKAGE_OPENCSD + bool "opencsd" + depends on BR2_PACKAGE_OPENCSD_ARCH_SUPPORTS + depends on !BR2_STATIC_LIBS + depends on BR2_INSTALL_LIBSTDCPP + depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_8 # C++11 + help + This library provides an API suitable for the decode of + ARM(r) CoreSight(tm) trace streams. + + OpenCSD is for example an optional dependency in the Linux + "perf" tool, starting from kernel version 5.1. + + https://github.com/Linaro/OpenCSD + +comment "opencsd needs a toolchain w/ C++11, gcc >= 4.8, dynamic library" + depends on BR2_PACKAGE_OPENCSD_ARCH_SUPPORTS + depends on BR2_STATIC_LIBS \ + || !BR2_INSTALL_LIBSTDCPP \ + || !BR2_TOOLCHAIN_GCC_AT_LEAST_4_8 diff --git a/package/opencsd/opencsd.hash b/package/opencsd/opencsd.hash new file mode 100644 index 0000000000..84a762fb36 --- /dev/null +++ b/package/opencsd/opencsd.hash @@ -0,0 +1,3 @@ +# Locally Computed: +sha256 e1bb6d8d09e87974cb5ca6db2a13b0e1ba9e51117ca2ed71879df07ff7af4de2 opencsd-1.4.0.tar.gz +sha256 980eef4b0744e63834e3ec0d50c2a4ff6d81d7ec62dd8ba8c66acae0ec5a2e88 LICENSE diff --git a/package/opencsd/opencsd.mk b/package/opencsd/opencsd.mk new file mode 100644 index 0000000000..680364d01d --- /dev/null +++ b/package/opencsd/opencsd.mk @@ -0,0 +1,31 @@ +################################################################################ +# +# opencsd +# +################################################################################ + +OPENCSD_VERSION = 1.4.0 +OPENCSD_SITE = $(call github,Linaro,OpenCSD,v$(OPENCSD_VERSION)) +OPENCSD_LICENSE = BSD-3-Clause +OPENCSD_LICENSE_FILES = LICENSE +OPENCSD_INSTALL_STAGING = YES + +OPENCSD_MAKE_OPTS = \ + CROSS_COMPILE="$(TARGET_CROSS)" + +define OPENCSD_BUILD_CMDS + $(TARGET_CONFIGURE_OPTS) $(MAKE) -C $(@D)/decoder/build/linux \ + $(OPENCSD_MAKE_OPTS) all +endef + +define OPENCSD_INSTALL_TARGET_CMDS + $(TARGET_CONFIGURE_OPTS) $(MAKE) -C $(@D)/decoder/build/linux \ + $(OPENCSD_MAKE_OPTS) DESTDIR=$(TARGET_DIR) install +endef + +define OPENCSD_INSTALL_STAGING_CMDS + $(TARGET_CONFIGURE_OPTS) $(MAKE) -C $(@D)/decoder/build/linux \ + $(OPENCSD_MAKE_OPTS) DESTDIR=$(STAGING_DIR) install +endef + +$(eval $(generic-package))