Re: Bug#842513: vlc: immediate crash on launch on powerpc
On Fri, Nov 04, 2016 at 10:44:21AM -0400, Lennart Sorensen wrote:
> This would of course go much faster if I currently had access to a
> powerpc box rather than running in qemu. :)
>
> I miss the p710 at my previous job.
So here is the patch I am currently building. I think it now builds
correctly.
If someone actually wants to test it on real hardware without altivec that
would be great. Not sure I will have much luck testing it under qemu.
--
Len Sorensen
diff -urN --exclude Makefile.in --exclude install-sh --exclude configure vlc-2.2.4.orig/compat/dummy.c vlc-2.2.4/compat/dummy.c
--- vlc-2.2.4.orig/compat/dummy.c 2016-02-04 17:08:51.000000000 -0500
+++ vlc-2.2.4/compat/dummy.c 1969-12-31 19:00:00.000000000 -0500
@@ -1 +0,0 @@
-/* Automatically generated */
diff -urN --exclude Makefile.in --exclude install-sh --exclude configure vlc-2.2.4.orig/configure.ac vlc-2.2.4/configure.ac
--- vlc-2.2.4.orig/configure.ac 2016-05-31 12:11:07.000000000 -0400
+++ vlc-2.2.4/configure.ac 2016-11-04 12:22:02.543265439 -0400
@@ -1422,25 +1422,23 @@
VLC_SAVE_FLAGS
AC_CACHE_CHECK([if \$CC groks AltiVec C extensions],
[ac_cv_c_altivec], [
- CFLAGS="${CFLAGS} -maltivec"
+ CFLAGS="${CFLAGS} -maltivec -fno-vectorize"
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([
[#include <altivec.h>]], [
[vec_ld(0, (unsigned char *)0);]])], [
- ac_cv_c_altivec="-maltivec"
+ ac_cv_c_altivec="-maltivec -fno-vectorize"
], [
ac_cv_c_altivec="no"
])
])
- VLC_RESTORE_FLAGS
AS_IF([test "${ac_cv_c_altivec}" != "no"], [
CPPFLAGS="${CPPFLAGS} ${ac_cv_c_altivec}"
AC_DEFINE(CAN_COMPILE_C_ALTIVEC, 1, [Define to 1 if C AltiVec extensions are available.])
- VLC_ADD_CFLAGS([libvlccore],[${ac_cv_c_altivec}])
- ALTIVEC_CFLAGS="$ALTIVEC_FLAGS ${ac_cv_c_altivec} ${ac_cv_c_altivec_abi}"
- VLC_ADD_CFLAGS([deinterlace],[${ac_cv_c_altivec} ${ac_cv_c_altivec_abi}])
+ ALTIVEC_CFLAGS="$ALTIVEC_CFLAGS ${ac_cv_c_altivec} ${ac_cv_c_altivec_abi}"
have_altivec="yes"
])
AC_CHECK_HEADERS(altivec.h)
+ VLC_RESTORE_FLAGS
VLC_SAVE_FLAGS
LDFLAGS="${LDFLAGS} -Wl,-framework,vecLib"
diff -urN --exclude Makefile.in --exclude install-sh --exclude configure vlc-2.2.4.orig/modules/video_filter/Modules.am vlc-2.2.4/modules/video_filter/Modules.am
--- vlc-2.2.4.orig/modules/video_filter/Modules.am 2015-02-02 14:42:29.000000000 -0500
+++ vlc-2.2.4/modules/video_filter/Modules.am 2016-11-04 12:00:24.907211119 -0400
@@ -29,6 +29,7 @@
libdeinterlace_plugin_la_SOURCES += deinterlace/merge_arm.S
libdeinterlace_plugin_la_CFLAGS += -DCAN_COMPILE_ARM
endif
+libdeinterlace_plugin_la_CFLAGS += $(ALTIVEC_CFLAGS)
video_filter_LTLIBRARIES += libdeinterlace_plugin.la
libdynamicoverlay_plugin_la_SOURCES = \
Reply to: