!10 [sync] PR-9: 添加sw架构

From: @openeuler-sync-bot 
Reviewed-by: @gitee-cmd 
Signed-off-by: @gitee-cmd
This commit is contained in:
openeuler-ci-bot 2022-12-15 09:01:21 +00:00 committed by Gitee
commit b67d6094e1
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
2 changed files with 59 additions and 1 deletions

54
lame-3.100-sw.patch Executable file
View File

@ -0,0 +1,54 @@
diff -Nuar lame-3.100.org/configure lame-3.100.sw/configure
--- lame-3.100.org/configure 2022-05-26 15:39:59.220000000 +0000
+++ lame-3.100.sw/configure 2022-05-26 15:46:24.500000000 +0000
@@ -17507,7 +17507,7 @@
*86)
OPTIMIZATION="${OPTIMIZATION} -mfancy-math-387"
;;
- alpha*)
+ alpha* | sw_64*)
OPTIMIZATION="${OPTIMIZATION} -mfp-regs"
$as_echo "#define FLOAT double" >>confdefs.h
@@ -17670,7 +17670,7 @@
# LINUX on Digital/Compaq Alpha CPUs
##########################################################################
case $host in
-alpha*-*-linux*)
+alpha*-*-linux* | sw_64*-*-linux*)
################################################################
#### Check if 'ccc' is in our path
diff -Nuar lame-3.100.org/libmp3lame/lame.c lame-3.100.sw/libmp3lame/lame.c
--- lame-3.100.org/libmp3lame/lame.c 2022-05-26 15:39:59.240000000 +0000
+++ lame-3.100.sw/libmp3lame/lame.c 2022-05-26 15:44:51.440000000 +0000
@@ -48,7 +48,7 @@
#include "tables.h"
-#if defined(__FreeBSD__) && !defined(__alpha__)
+#if defined(__FreeBSD__) && !defined(__alpha__) && !defined(__sw_64__)
#include <floatingpoint.h>
#endif
#ifdef __riscos__
diff -Nuar lame-3.100.org/libmp3lame/util.c lame-3.100.sw/libmp3lame/util.c
--- lame-3.100.org/libmp3lame/util.c 2022-05-26 15:39:59.240000000 +0000
+++ lame-3.100.sw/libmp3lame/util.c 2022-05-26 15:43:59.070000000 +0000
@@ -34,7 +34,7 @@
#include "tables.h"
#define PRECOMPUTE
-#if defined(__FreeBSD__) && !defined(__alpha__)
+#if defined(__FreeBSD__) && !defined(__alpha__) && !defined(__sw_64__)
# include <machine/floatingpoint.h>
#endif
@@ -845,7 +845,7 @@
-#if defined(__FreeBSD__) && !defined(__alpha__)
+#if defined(__FreeBSD__) && !defined(__alpha__) && !defined(__sw_64__)
{
/* seet floating point mask to the Linux default */
fp_except_t mask;

View File

@ -1,6 +1,6 @@
Name: lame
Version: 3.100
Release: 9
Release: 10
Summary: Free MP3 audio compressor
License: GPL-2.0+ and GPL-2.0 and LGPL-2.0
URL: http://lame.sourceforge.net/
@ -8,6 +8,7 @@ Source0: http://downloads.sourceforge.net/sourceforge/lame/%{name}-%{vers
Patch0001: lame-noexecstack.patch
Patch0002: libmp3lame-symbols.patch
Patch0003: 0001-fix-fuzz-undefined-behavior-error.patch
Patch0004: lame-3.100-sw.patch
BuildRequires: ncurses-devel gtk+-devel gcc
@ -84,6 +85,9 @@ make test
%{_bindir}/mp3x
%changelog
* Fri Oct 21 2022 wuzx<wuzx1226@qq.com> - 3.100-10
- add sw64 patch
* Thu Jun 03 2021 wulei <wulei80@huawei.com> - 3.100-9
- fixes failed: no acceptable C compiler found in $PATH