pkgsrc-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[pkgsrc/trunk]: pkgsrc/multimedia/libmpeg2 multimedia/libmpeg2: fix build on ...
details: https://anonhg.NetBSD.org/pkgsrc/rev/7482cd3ca95d
branches: trunk
changeset: 385729:7482cd3ca95d
user: he <he%pkgsrc.org@localhost>
date: Sun Sep 25 14:43:27 2022 +0000
description:
multimedia/libmpeg2: fix build on NetBSD/macppc.
This re-orders the two tests for altivec to first try with
<altivec.h> included, and the second without.
The configure script is hand-patched, corresponding to configure.ac;
I could not generate a working configure script...
diffstat:
multimedia/libmpeg2/distinfo | 5 +-
multimedia/libmpeg2/patches/patch-aa | 49 +++++++++++++++++++++++++-
multimedia/libmpeg2/patches/patch-configure.ac | 34 ++++++++++++++++++
3 files changed, 85 insertions(+), 3 deletions(-)
diffs (112 lines):
diff -r 06c89c426e50 -r 7482cd3ca95d multimedia/libmpeg2/distinfo
--- a/multimedia/libmpeg2/distinfo Sun Sep 25 12:56:23 2022 +0000
+++ b/multimedia/libmpeg2/distinfo Sun Sep 25 14:43:27 2022 +0000
@@ -1,7 +1,8 @@
-$NetBSD: distinfo,v 1.15 2021/10/26 11:01:09 nia Exp $
+$NetBSD: distinfo,v 1.16 2022/09/25 14:43:27 he Exp $
BLAKE2s (libmpeg2-0.5.1.tar.gz) = 052e01bcc751539f594f48d9b370fc2dc0ca0bda86e94c041eb2e1ef2270d3d4
SHA512 (libmpeg2-0.5.1.tar.gz) = 3648a2b3d7e2056d5adb328acd2fb983a1fa9a05ccb6f9388cc686c819445421811f42e8439418a0491a13080977f074a0d8bf8fa6bc101ff245ddea65a46fbc
Size (libmpeg2-0.5.1.tar.gz) = 524776 bytes
-SHA1 (patch-aa) = 6e6d47232ba20a307ac3a378b09fb08b50f80445
+SHA1 (patch-aa) = 925383d3e5eab74ba2b37d9def5a270ad0def3fc
SHA1 (patch-ab) = e732e35208eb62101f54bbf4a7800a3c4cf9adf0
+SHA1 (patch-configure.ac) = 05620d548994cf8e1125a816c545a9b12c5c2cd8
diff -r 06c89c426e50 -r 7482cd3ca95d multimedia/libmpeg2/patches/patch-aa
--- a/multimedia/libmpeg2/patches/patch-aa Sun Sep 25 12:56:23 2022 +0000
+++ b/multimedia/libmpeg2/patches/patch-aa Sun Sep 25 14:43:27 2022 +0000
@@ -1,4 +1,4 @@
-$NetBSD: patch-aa,v 1.6 2008/08/07 18:23:18 drochner Exp $
+$NetBSD: patch-aa,v 1.7 2022/09/25 14:43:27 he Exp $
--- configure.orig 2008-07-18 16:41:54.000000000 +0200
+++ configure
@@ -11,3 +11,50 @@
{ echo "$as_me:$LINENO: checking if $CC supports $TRY_CFLAGS flags" >&5
echo $ECHO_N "checking if $CC supports $TRY_CFLAGS flags... $ECHO_C" >&6; }
SAVE_CFLAGS="$CFLAGS"
+@@ -4981,6 +4981,7 @@ cat confdefs.h >>conftest.$ac_ext
+ cat >>conftest.$ac_ext <<_ACEOF
+ /* end confdefs.h. */
+
++#include <altivec.h>
+ int
+ main ()
+ {
+@@ -5007,8 +5008,12 @@ eval "echo \"\$as_me:$LINENO: $ac_try_ec
+ test -z "$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest.$ac_objext; then
+- have_altivec=yes; { echo "$as_me:$LINENO: result: no" >&5
+-echo "${ECHO_T}no" >&6; }
++cat >>confdefs.h <<\_ACEOF
++#define HAVE_ALTIVEC_H
++_ACEOF
++
++ have_altivec=yes; { echo "$as_me:$LINENO: result: yes" >&5
++echo "${ECHO_T}yes" >&6; }
+ else
+ echo "$as_me: failed program was:" >&5
+ sed 's/^/| /' conftest.$ac_ext >&5
+@@ -5019,7 +5024,6 @@ _ACEOF
+ cat confdefs.h >>conftest.$ac_ext
+ cat >>conftest.$ac_ext <<_ACEOF
+ /* end confdefs.h. */
+-#include <altivec.h>
+ int
+ main ()
+ {
+@@ -5045,13 +5049,8 @@ eval "echo \"\$as_me:$LINENO: $ac_try_ec
+ test -z "$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest.$ac_objext; then
+-
+-cat >>confdefs.h <<\_ACEOF
+-#define HAVE_ALTIVEC_H
+-_ACEOF
+-
+- have_altivec=yes; { echo "$as_me:$LINENO: result: yes" >&5
+-echo "${ECHO_T}yes" >&6; }
++ have_altivec=yes; { echo "$as_me:$LINENO: result: no" >&5
++echo "${ECHO_T}no" >&6; }
+ else
+ echo "$as_me: failed program was:" >&5
+ sed 's/^/| /' conftest.$ac_ext >&5
diff -r 06c89c426e50 -r 7482cd3ca95d multimedia/libmpeg2/patches/patch-configure.ac
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/multimedia/libmpeg2/patches/patch-configure.ac Sun Sep 25 14:43:27 2022 +0000
@@ -0,0 +1,34 @@
+$NetBSD: patch-configure.ac,v 1.1 2022/09/25 14:43:27 he Exp $
+
+--- configure.ac.orig 2008-07-18 14:30:17.000000000 +0000
++++ configure.ac
+@@ -41,7 +41,7 @@ elif test x"$GCC" = x"yes"; then
+ changequote(<<,>>)
+ TRY_CFLAGS=`echo "$OPT_CFLAGS $CFLAGS"|sed "s/-O[0-9]*//g"`
+ changequote([,])
+- TRY_CFLAGS="$TRY_CFLAGS -O3"
++ TRY_CFLAGS="$TRY_CFLAGS $CFLAGS"
+ AC_TRY_CFLAGS([$TRY_CFLAGS],[OPT_CFLAGS="$TRY_CFLAGS"])
+
+ AC_ARG_ENABLE([debug],
+@@ -78,15 +78,15 @@ elif test x"$GCC" = x"yes"; then
+ [save_CFLAGS="$CFLAGS"
+ CFLAGS="$OPT_CFLAGS $TRY_CFLAGS $CFLAGS"
+ AC_MSG_CHECKING([if <altivec.h> is needed])
+- AC_TRY_COMPILE([],
+- [typedef vector int t;
+- vec_ld(0, (unsigned char *)0);],
+- [have_altivec=yes; AC_MSG_RESULT(no)],
+- [AC_TRY_COMPILE([#include <altivec.h>],
++ [AC_TRY_COMPILE([#include <altivec.h>],
+ [typedef vector int t; vec_ld(0, (unsigned char *)0);],
+ [AC_DEFINE([HAVE_ALTIVEC_H],,
+ [Define to 1 if you have the <altivec.h> header.])
+ have_altivec=yes; AC_MSG_RESULT(yes)],
++ AC_TRY_COMPILE([],
++ [typedef vector int t;
++ vec_ld(0, (unsigned char *)0);],
++ [have_altivec=yes; AC_MSG_RESULT(no)],
+ [AC_MSG_RESULT(unsupported)])])
+ CFLAGS="$save_CFLAGS"])
+ if test "$have_altivec" = "yes"; then
Home |
Main Index |
Thread Index |
Old Index