added my Recipes
This commit is contained in:
@@ -0,0 +1,47 @@
|
||||
From 26342d1c775205f661f5cf005b7e054a04f5d32e Mon Sep 17 00:00:00 2001
|
||||
From: Khem Raj <raj.khem@gmail.com>
|
||||
Date: Tue, 16 May 2023 10:14:57 -0700
|
||||
Subject: [PATCH] configure: Respect the cflags from environment
|
||||
|
||||
This is needed with OE like cross-build envs where certain important
|
||||
flags maybe passed as global policy to aid cross compiling or
|
||||
reproducibility etc.
|
||||
|
||||
Upstream-Status: Inappropriate [OE-Specific]
|
||||
|
||||
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
||||
---
|
||||
configure.ac | 5 +----
|
||||
1 file changed, 1 insertion(+), 4 deletions(-)
|
||||
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -73,12 +73,9 @@ debug=""
|
||||
optimize=""
|
||||
profile=""
|
||||
|
||||
-set -- $CFLAGS
|
||||
-CFLAGS=""
|
||||
-
|
||||
if test "$GCC" = yes
|
||||
then
|
||||
- CFLAGS="-Wall"
|
||||
+ CFLAGS="$CFLAGS -Wall"
|
||||
fi
|
||||
|
||||
while test $# -gt 0
|
||||
@@ -115,10 +112,13 @@ do
|
||||
optimize="$optimize $1"
|
||||
shift
|
||||
;;
|
||||
- *)
|
||||
+ -*)
|
||||
CFLAGS="$CFLAGS $1"
|
||||
shift
|
||||
;;
|
||||
+ *)
|
||||
+ shift
|
||||
+ ;;
|
||||
esac
|
||||
done
|
||||
|
||||
@@ -0,0 +1,83 @@
|
||||
From 3d3fce9b8b927a817b89dd78a60b5cf7d978f64c Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Sebastian=20Dr=C3=B6ge?= <sebastian@centricular.com>
|
||||
Date: Tue, 16 Sep 2014 12:28:47 +0300
|
||||
Subject: [PATCH 4/4] Remove clang unsupported compiler flags
|
||||
|
||||
---
|
||||
configure.ac | 12 ++++++------
|
||||
1 file changed, 6 insertions(+), 6 deletions(-)
|
||||
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -124,70 +124,7 @@ done
|
||||
|
||||
if test "$GCC" = yes
|
||||
then
|
||||
- if test -z "$arch"
|
||||
- then
|
||||
- case "$host" in
|
||||
- i386-*) ;;
|
||||
- i?86-*) arch="-march=i486" ;;
|
||||
- arm*-empeg-*) arch="-march=armv4 -mtune=strongarm1100" ;;
|
||||
- armv4*-*) arch="-march=armv4 -mtune=strongarm" ;;
|
||||
- powerpc-*) ;;
|
||||
- mips*-agenda-*) arch="-mcpu=vr4100" ;;
|
||||
- mips*-luxsonor-*) arch="-mips1 -mcpu=r3000 -Wa,-m4010" ;;
|
||||
- esac
|
||||
- fi
|
||||
-
|
||||
- case "$optimize" in
|
||||
- -O|"-O "*)
|
||||
- optimize="-O"
|
||||
- optimize="$optimize -fforce-addr"
|
||||
- : #x optimize="$optimize -finline-functions"
|
||||
- : #- optimize="$optimize -fstrength-reduce"
|
||||
- optimize="$optimize -fthread-jumps"
|
||||
- optimize="$optimize -fcse-follow-jumps"
|
||||
- optimize="$optimize -fcse-skip-blocks"
|
||||
- : #x optimize="$optimize -frerun-cse-after-loop"
|
||||
- : #x optimize="$optimize -frerun-loop-opt"
|
||||
- : #x optimize="$optimize -fgcse"
|
||||
- optimize="$optimize -fexpensive-optimizations"
|
||||
- optimize="$optimize -fregmove"
|
||||
- : #* optimize="$optimize -fdelayed-branch"
|
||||
- : #x optimize="$optimize -fschedule-insns"
|
||||
- optimize="$optimize -fschedule-insns2"
|
||||
- : #? optimize="$optimize -ffunction-sections"
|
||||
- : #? optimize="$optimize -fcaller-saves"
|
||||
- : #> optimize="$optimize -funroll-loops"
|
||||
- : #> optimize="$optimize -funroll-all-loops"
|
||||
- : #x optimize="$optimize -fmove-all-movables"
|
||||
- : #x optimize="$optimize -freduce-all-givs"
|
||||
- : #? optimize="$optimize -fstrict-aliasing"
|
||||
- : #* optimize="$optimize -fstructure-noalias"
|
||||
-
|
||||
- case "$host" in
|
||||
- arm*-*)
|
||||
- optimize="$optimize -fstrength-reduce"
|
||||
- ;;
|
||||
- mips*-*)
|
||||
- optimize="$optimize -fstrength-reduce"
|
||||
- optimize="$optimize -finline-functions"
|
||||
- ;;
|
||||
- i?86-*)
|
||||
- optimize="$optimize -fstrength-reduce"
|
||||
- ;;
|
||||
- powerpc-apple-*)
|
||||
- # this triggers an internal compiler error with gcc2
|
||||
- : #optimize="$optimize -fstrength-reduce"
|
||||
-
|
||||
- # this is really only beneficial with gcc3
|
||||
- : #optimize="$optimize -finline-functions"
|
||||
- ;;
|
||||
- *)
|
||||
- # this sometimes provokes bugs in gcc 2.95.2
|
||||
- : #optimize="$optimize -fstrength-reduce"
|
||||
- ;;
|
||||
- esac
|
||||
- ;;
|
||||
- esac
|
||||
+ optimize="-O2"
|
||||
fi
|
||||
|
||||
case "$host" in
|
||||
@@ -0,0 +1,70 @@
|
||||
Here is a patch for adding pkg-config support to libmad.
|
||||
It would make life a bit easier for distro maintainers if this was applied.
|
||||
In case you didn't know, pkg-config is a tool for providing LDFLAGS and
|
||||
CFLAGS for packages using shared libraries. It's on freedesktop.org.
|
||||
Debian has already been distributing the pkg-config file mad.pc with
|
||||
libmad for some time, and people developing on debian (notably xmms2
|
||||
developers) have started relying on this support being present, causing
|
||||
some confusion for people installing from source and on some BSDs which
|
||||
do not provide mad.pc (google: pkgconfig libmad).
|
||||
|
||||
EMH
|
||||
|
||||
Upstream-Status: Inappropriate [configuration]
|
||||
|
||||
--h31gzZEtNLTqOjlF
|
||||
Content-Type: text/plain; charset=us-ascii
|
||||
Content-Disposition: attachment; filename="libmad-0.15.1b-pkgconfig.patch"
|
||||
|
||||
diff -Naur libmad-0.15.1b.old/configure.ac libmad-0.15.1b/configure.ac
|
||||
--- libmad-0.15.1b.old/configure.ac 2004-01-23 10:41:32.000000000 +0100
|
||||
+++ libmad-0.15.1b/configure.ac 2004-08-07 02:25:24.633462168 +0200
|
||||
@@ -429,5 +429,5 @@
|
||||
dnl AC_SUBST(LTLIBOBJS)
|
||||
|
||||
AC_CONFIG_FILES([Makefile msvc++/Makefile \
|
||||
- libmad.list])
|
||||
+ libmad.list mad.pc])
|
||||
AC_OUTPUT
|
||||
diff -Naur libmad-0.15.1b.old/mad.pc.in libmad-0.15.1b/mad.pc.in
|
||||
--- libmad-0.15.1b.old/mad.pc.in 1970-01-01 01:00:00.000000000 +0100
|
||||
+++ libmad-0.15.1b/mad.pc.in 2004-08-07 02:04:59.617692872 +0200
|
||||
@@ -0,0 +1,14 @@
|
||||
+# libmad pkg-config source file
|
||||
+
|
||||
+prefix=@prefix@
|
||||
+exec_prefix=@exec_prefix@
|
||||
+libdir=@libdir@
|
||||
+includedir=@includedir@
|
||||
+
|
||||
+Name: mad
|
||||
+Description: MPEG Audio Decoder
|
||||
+Version: @VERSION@
|
||||
+Requires:
|
||||
+Conflicts:
|
||||
+Libs: -L${libdir} -lmad -lm
|
||||
+Cflags: -I${includedir}
|
||||
diff -Naur libmad-0.15.1b.old/Makefile.am libmad-0.15.1b/Makefile.am
|
||||
--- libmad-0.15.1b.old/Makefile.am 2004-02-17 03:02:03.000000000 +0100
|
||||
+++ libmad-0.15.1b/Makefile.am 2004-08-07 02:03:19.859858368 +0200
|
||||
@@ -24,6 +24,9 @@
|
||||
SUBDIRS =
|
||||
DIST_SUBDIRS = msvc++
|
||||
|
||||
+pkgconfigdir = $(libdir)/pkgconfig
|
||||
+pkgconfig_DATA = mad.pc
|
||||
+
|
||||
lib_LTLIBRARIES = libmad.la
|
||||
include_HEADERS = mad.h
|
||||
|
||||
@@ -34,7 +37,8 @@
|
||||
minimad_LDADD = libmad.la
|
||||
|
||||
EXTRA_DIST = mad.h.sed \
|
||||
- CHANGES COPYRIGHT CREDITS README TODO VERSION
|
||||
+ CHANGES COPYRIGHT CREDITS README TODO VERSION \
|
||||
+ mad.pc.in
|
||||
|
||||
exported_headers = version.h fixed.h bit.h timer.h stream.h frame.h \
|
||||
synth.h decoder.h
|
||||
|
||||
@@ -0,0 +1,12 @@
|
||||
Pass foreign to AM_INIT_AUTOMAKE so it doesn't enforce GNU strictness.
|
||||
|
||||
Upstream-Status: Pending
|
||||
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
||||
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index e602fd3..e075b86 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -29 +29 @@ AC_CONFIG_SRCDIR([decoder.h])
|
||||
-AM_INIT_AUTOMAKE
|
||||
+AM_INIT_AUTOMAKE([foreign])
|
||||
@@ -0,0 +1,31 @@
|
||||
gcc 4.4 did this: The MIPS port no longer recognizes the h asm constraint. It was necessary to remove this constraint in order to avoid generating unpredictable code sequences.
|
||||
|
||||
so the libmad build with gcc-4.5.0 was failing.
|
||||
|
||||
Found a solution here:
|
||||
|
||||
http://us.generation-nt.com/answer/bug-568418-libmad0-dev-mpg321-compilation-errors-mips-mipsel-architectures-help-169033451.html
|
||||
|
||||
Upstream-Status: Pending
|
||||
|
||||
2010/07/29
|
||||
Nitin A Kamble <nitin.a.kamble@intel.com>
|
||||
|
||||
--- a/fixed.h
|
||||
+++ b/fixed.h
|
||||
@@ -297,6 +297,15 @@ mad_fixed_t mad_f_mul_inline(mad_fixed_t
|
||||
|
||||
/* --- MIPS ---------------------------------------------------------------- */
|
||||
|
||||
+# elif defined(FPM_MIPS) && (defined(__clang__) || __GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 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)
|
||||
+
|
||||
# elif defined(FPM_MIPS)
|
||||
|
||||
/*
|
||||
@@ -0,0 +1,18 @@
|
||||
This option no longer exists in gcc 3.4.1
|
||||
|
||||
RP - 18/07/2008
|
||||
|
||||
Upstream-Status: Inappropriate [configuration]
|
||||
|
||||
Index: libmad-0.15.1b/configure.ac
|
||||
===================================================================
|
||||
--- libmad-0.15.1b.orig/configure.ac 2008-07-18 15:45:30.000000000 +0100
|
||||
+++ libmad-0.15.1b/configure.ac 2008-07-18 15:45:37.000000000 +0100
|
||||
@@ -140,7 +140,6 @@
|
||||
case "$optimize" in
|
||||
-O|"-O "*)
|
||||
optimize="-O"
|
||||
- optimize="$optimize -fforce-mem"
|
||||
optimize="$optimize -fforce-addr"
|
||||
: #x optimize="$optimize -finline-functions"
|
||||
: #- optimize="$optimize -fstrength-reduce"
|
||||
@@ -0,0 +1,14 @@
|
||||
Upstream-Status: Submitted [https://sourceforge.net/tracker/?group_id=12349&atid=112349]
|
||||
|
||||
Signed-off-by: Marko Lindqvist <cazfi74@gmail.com>
|
||||
diff -Nurd libmad-0.15.1b/configure.ac libmad-0.15.1b/configure.ac
|
||||
--- libmad-0.15.1b/configure.ac 2004-01-23 11:41:32.000000000 +0200
|
||||
+++ libmad-0.15.1b/configure.ac 2013-01-03 08:28:23.718693697 +0200
|
||||
@@ -28,7 +28,7 @@
|
||||
|
||||
AM_INIT_AUTOMAKE
|
||||
|
||||
-AM_CONFIG_HEADER([config.h])
|
||||
+AC_CONFIG_HEADERS([config.h])
|
||||
|
||||
dnl System type.
|
||||
@@ -0,0 +1,38 @@
|
||||
SUMMARY = "MPEG Audio Decoder library"
|
||||
HOMEPAGE = "http://sourceforge.net/projects/mad/"
|
||||
BUGTRACKER = "http://sourceforge.net/tracker/?group_id=12349&atid=112349"
|
||||
LICENSE = "GPL-2.0-or-later"
|
||||
LICENSE_FLAGS = "commercial"
|
||||
LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f \
|
||||
file://COPYRIGHT;md5=8e55eb14894e782b84488d5a239bc23d \
|
||||
file://version.h;beginline=1;endline=8;md5=aa07311dd39288d4349f28e1de516454"
|
||||
SECTION = "libs"
|
||||
DEPENDS = "libid3tag"
|
||||
PR = "r3"
|
||||
|
||||
SRC_URI = "ftp://ftp.mars.org/pub/mpeg/libmad-${PV}.tar.gz \
|
||||
file://no-force-mem.patch \
|
||||
file://add-pkgconfig.patch \
|
||||
file://fix_for_mips_with_gcc-4.5.0.patch \
|
||||
file://obsolete_automake_macros.patch \
|
||||
file://automake-foreign.patch \
|
||||
file://0001-configure-Respect-the-cflags-from-environment.patch \
|
||||
"
|
||||
SRC_URI:append:toolchain-clang = " file://0004-Remove-clang-unsupported-compiler-flags.patch "
|
||||
|
||||
SRC_URI[md5sum] = "1be543bc30c56fb6bea1d7bf6a64e66c"
|
||||
SRC_URI[sha256sum] = "bbfac3ed6bfbc2823d3775ebb931087371e142bb0e9bb1bee51a76a6e0078690"
|
||||
|
||||
S = "${WORKDIR}/libmad-${PV}"
|
||||
|
||||
inherit autotools pkgconfig
|
||||
|
||||
EXTRA_OECONF = "-enable-speed --enable-shared"
|
||||
EXTRA_OECONF:append:arm = " --enable-fpm=arm"
|
||||
|
||||
do_configure:prepend () {
|
||||
# damn picky automake...
|
||||
touch NEWS AUTHORS ChangeLog
|
||||
}
|
||||
|
||||
ARM_INSTRUCTION_SET = "arm"
|
||||
Reference in New Issue
Block a user