initial buildroot for linux 5.15
This commit is contained in:
@@ -0,0 +1,72 @@
|
||||
http://patchwork.openembedded.org/patch/921/
|
||||
|
||||
diff -ur libmad-0.15.1b-orig/fixed.h libmad-0.15.1b/fixed.h
|
||||
--- libmad-0.15.1b-orig/fixed.h 2004-02-17 12:32:03.000000000 +1030
|
||||
+++ libmad-0.15.1b/fixed.h 2009-08-05 10:46:30.000000000 +0930
|
||||
@@ -299,6 +299,23 @@
|
||||
|
||||
# elif defined(FPM_MIPS)
|
||||
|
||||
+/* Test for gcc >= maj.min, as per __GNUC_PREREQ in glibc */
|
||||
+#if defined (__GNUC__) && defined (__GNUC_MINOR__)
|
||||
+#define __GNUC_PREREQ(maj, min) \
|
||||
+ ((__GNUC__ << 16) + __GNUC_MINOR__ >= ((maj) << 16) + (min))
|
||||
+#else
|
||||
+#define __GNUC_PREREQ(maj, min) 0
|
||||
+#endif
|
||||
+
|
||||
+#if __GNUC_PREREQ(4,4)
|
||||
+ typedef unsigned int u64_di_t __attribute__ ((mode (DI)));
|
||||
+# define MAD_F_MLX(hi, lo, x, y) \
|
||||
+ do { \
|
||||
+ u64_di_t __ll = (u64_di_t) (x) * (y); \
|
||||
+ hi = __ll >> 32; \
|
||||
+ lo = __ll; \
|
||||
+ } while (0)
|
||||
+#else
|
||||
/*
|
||||
* This MIPS version is fast and accurate; the disposition of the least
|
||||
* significant bit depends on OPT_ACCURACY via mad_f_scale64().
|
||||
@@ -328,6 +345,7 @@
|
||||
: "%r" ((x) >> 12), "r" ((y) >> 16))
|
||||
# define MAD_F_MLZ(hi, lo) ((mad_fixed_t) (lo))
|
||||
# endif
|
||||
+#endif /* __GNU_PREREQ(4,4) */
|
||||
|
||||
# if defined(OPT_SPEED)
|
||||
# define mad_f_scale64(hi, lo) \
|
||||
diff -ur libmad-0.15.1b-orig/mad.h libmad-0.15.1b/mad.h
|
||||
--- libmad-0.15.1b-orig/mad.h 2004-02-17 13:25:44.000000000 +1030
|
||||
+++ libmad-0.15.1b/mad.h 2009-08-05 10:42:40.000000000 +0930
|
||||
@@ -344,6 +344,23 @@
|
||||
|
||||
# elif defined(FPM_MIPS)
|
||||
|
||||
+/* Test for gcc >= maj.min, as per __GNUC_PREREQ in glibc */
|
||||
+#if defined (__GNUC__) && defined (__GNUC_MINOR__)
|
||||
+#define __GNUC_PREREQ(maj, min) \
|
||||
+ ((__GNUC__ << 16) + __GNUC_MINOR__ >= ((maj) << 16) + (min))
|
||||
+#else
|
||||
+#define __GNUC_PREREQ(maj, min) 0
|
||||
+#endif
|
||||
+
|
||||
+#if __GNUC_PREREQ(4,4)
|
||||
+ typedef unsigned int u64_di_t __attribute__ ((mode (DI)));
|
||||
+# define MAD_F_MLX(hi, lo, x, y) \
|
||||
+ do { \
|
||||
+ u64_di_t __ll = (u64_di_t) (x) * (y); \
|
||||
+ hi = __ll >> 32; \
|
||||
+ lo = __ll; \
|
||||
+ } while (0)
|
||||
+#else
|
||||
/*
|
||||
* This MIPS version is fast and accurate; the disposition of the least
|
||||
* significant bit depends on OPT_ACCURACY via mad_f_scale64().
|
||||
@@ -373,6 +390,7 @@
|
||||
: "%r" ((x) >> 12), "r" ((y) >> 16))
|
||||
# define MAD_F_MLZ(hi, lo) ((mad_fixed_t) (lo))
|
||||
# endif
|
||||
+#endif /* __GNU_PREREQ(4,4) */
|
||||
|
||||
# if defined(OPT_SPEED)
|
||||
# define mad_f_scale64(hi, lo) \
|
||||
@@ -0,0 +1,16 @@
|
||||
configure.ac: don't require GNU-specific files when running automake
|
||||
|
||||
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
|
||||
|
||||
diff -ur libmad-0.15.1b-orig/configure.ac libmad-0.15.1b/configure.ac
|
||||
--- libmad-0.15.1b-orig/configure.ac 2019-01-17 21:24:52.259194527 +0100
|
||||
+++ libmad-0.15.1b/configure.ac 2019-01-17 21:25:32.779481058 +0100
|
||||
@@ -26,7 +26,7 @@
|
||||
|
||||
AC_CONFIG_SRCDIR([decoder.h])
|
||||
|
||||
-AM_INIT_AUTOMAKE
|
||||
+AM_INIT_AUTOMAKE([foreign])
|
||||
|
||||
AM_CONFIG_HEADER([config.h])
|
||||
|
||||
@@ -0,0 +1,51 @@
|
||||
config BR2_PACKAGE_LIBMAD
|
||||
bool "libmad"
|
||||
help
|
||||
High-quality MPEG audio decoder. All computations are
|
||||
performed with fixed-point integer arithmetic, making it ideal
|
||||
for systems without a floating-point unit.
|
||||
|
||||
http://www.underbit.com/products/mad/
|
||||
|
||||
if BR2_PACKAGE_LIBMAD
|
||||
|
||||
choice
|
||||
prompt "Speed vs. accuracy"
|
||||
default BR2_PACKAGE_LIBMAD_OPTIMIZATION_DEFAULT
|
||||
|
||||
config BR2_PACKAGE_LIBMAD_OPTIMIZATION_DEFAULT
|
||||
bool "Default"
|
||||
help
|
||||
Keep optimizations balanced between speed and accuracy.
|
||||
|
||||
config BR2_PACKAGE_LIBMAD_OPTIMIZATION_SPEED
|
||||
bool "Optimize for speed over accuracy"
|
||||
help
|
||||
Compromise accuracy for speed.
|
||||
|
||||
config BR2_PACKAGE_LIBMAD_OPTIMIZATION_ACCURACY
|
||||
bool "Optimize for accuracy over speed"
|
||||
help
|
||||
Compromise speed for accuracy.
|
||||
|
||||
endchoice
|
||||
|
||||
config BR2_PACKAGE_LIBMAD_SSO
|
||||
bool "Subband synthesis optimization"
|
||||
help
|
||||
Use the subband synthesis optimization, with reduced accuracy.
|
||||
|
||||
config BR2_PACKAGE_LIBMAD_ASO
|
||||
bool "Architecture-specific optimizations"
|
||||
default y
|
||||
# arm optimization needs classic arm instructions support
|
||||
depends on !(BR2_arm && !BR2_ARM_CPU_HAS_ARM)
|
||||
help
|
||||
Use certain architecture-specific optimizations.
|
||||
|
||||
config BR2_PACKAGE_LIBMAD_STRICT_ISO
|
||||
bool "Strict ISO/IEC interpretations"
|
||||
help
|
||||
Use strict ISO/IEC interpretations.
|
||||
|
||||
endif
|
||||
@@ -0,0 +1,6 @@
|
||||
# From http://snapshot.debian.org/archive/debian/20190310T213528Z/pool/main/libm/libmad/libmad_0.15.1b-10.dsc
|
||||
sha256 bbfac3ed6bfbc2823d3775ebb931087371e142bb0e9bb1bee51a76a6e0078690 libmad_0.15.1b.orig.tar.gz
|
||||
sha256 dfeabd5d2398bf902660edc31f87ad40600f0aa732b946f864d8ee6bbf56a99c libmad_0.15.1b-10.diff.gz
|
||||
|
||||
# Hash for license file:
|
||||
sha256 32b1062f7da84967e7019d01ab805935caa7ab7321a7ced0e30ebe75e5df1670 COPYING
|
||||
@@ -0,0 +1,49 @@
|
||||
################################################################################
|
||||
#
|
||||
# libmad
|
||||
#
|
||||
################################################################################
|
||||
|
||||
LIBMAD_VERSION = 0.15.1b
|
||||
LIBMAD_PATCH = libmad_$(LIBMAD_VERSION)-10.diff.gz
|
||||
LIBMAD_SOURCE = libmad_$(LIBMAD_VERSION).orig.tar.gz
|
||||
LIBMAD_SITE = \
|
||||
http://snapshot.debian.org/archive/debian/20190310T213528Z/pool/main/libm/libmad
|
||||
LIBMAD_INSTALL_STAGING = YES
|
||||
LIBMAD_LICENSE = GPL-2.0+
|
||||
LIBMAD_LICENSE_FILES = COPYING
|
||||
|
||||
define LIBMAD_APPLY_DEBIAN_PATCHES
|
||||
if [ -d $(@D)/debian/patches ]; then \
|
||||
$(APPLY_PATCHES) $(@D) $(@D)/debian/patches *.patch; \
|
||||
fi
|
||||
endef
|
||||
|
||||
LIBMAD_POST_PATCH_HOOKS += LIBMAD_APPLY_DEBIAN_PATCHES
|
||||
|
||||
# debian/patches/md_size.diff
|
||||
LIBMAD_IGNORE_CVES += CVE-2017-8372 CVE-2017-8373
|
||||
|
||||
# debian/patches/length-check.patch
|
||||
LIBMAD_IGNORE_CVES += CVE-2017-8374
|
||||
|
||||
# Force autoreconf to be able to use a more recent libtool script, that
|
||||
# is able to properly behave in the face of a missing C++ compiler.
|
||||
LIBMAD_AUTORECONF = YES
|
||||
|
||||
define LIBMAD_INSTALL_STAGING_PC
|
||||
$(INSTALL) -D package/libmad/mad.pc \
|
||||
$(STAGING_DIR)/usr/lib/pkgconfig/mad.pc
|
||||
endef
|
||||
|
||||
LIBMAD_POST_INSTALL_STAGING_HOOKS += LIBMAD_INSTALL_STAGING_PC
|
||||
|
||||
LIBMAD_CONF_OPTS = \
|
||||
--disable-debugging \
|
||||
$(if $(BR2_PACKAGE_LIBMAD_OPTIMIZATION_SPEED),--enable-speed) \
|
||||
$(if $(BR2_PACKAGE_LIBMAD_OPTIMIZATION_ACCURACY),--enable-accuracy) \
|
||||
--$(if $(BR2_PACKAGE_LIBMAD_SSO),enable,disable)-sso \
|
||||
--$(if $(BR2_PACKAGE_LIBMAD_ASO),enable,disable)-aso \
|
||||
--$(if $(BR2_PACKAGE_LIBMAD_STRICT_ISO),enable,disable)-strict-iso
|
||||
|
||||
$(eval $(autotools-package))
|
||||
@@ -0,0 +1,11 @@
|
||||
prefix=/usr
|
||||
exec_prefix=${prefix}
|
||||
libdir=${exec_prefix}/lib
|
||||
includedir=${prefix}/include
|
||||
|
||||
Name: mad
|
||||
Description: MPEG Audio Decoder
|
||||
Requires:
|
||||
Version: 0.15.1b
|
||||
Libs: -L${libdir} -lmad
|
||||
Cflags: -I${includedir}
|
||||
Reference in New Issue
Block a user